Weitere ähnliche Inhalte Ähnlich wie Open source applied: Real-world uses (20) Mehr von Rogue Wave Software (20) Kürzlich hochgeladen (20) Open source applied: Real-world uses1. 1© 2016 Rogue Wave Software, Inc. All Rights Reserved. 1
Top open source lessons
for every enterprise
Episode 3:
Open source applied: Real-world uses
2. 2© 2016 Rogue Wave Software, Inc. All Rights Reserved. 2
Justin Reock
Senior director, support & professional services
Rogue Wave Software
Presenter
3. 3© 2016 Rogue Wave Software, Inc. All Rights Reserved. 3
Poll #1
What percentage of your mission critical software is open source?
A: 0-25%
B: 26 to 50%
C: 51 to 75%
D: More than 75%
4. 4© 2016 Rogue Wave Software, Inc. All Rights Reserved. 4
Agenda
1. Introduction
2. PupBand: E-commerce website
3. UniTrack: Mobile PaaS
4. HelpingHumans: HPC machine learning
5. Conclusion
6. Q&A
5. 5© 2016 Rogue Wave Software, Inc. All Rights Reserved. 5
Introduction
OSS is everywhere!
• As we covered in our previous OSS webinar, OSS has eaten the world!
• How enterprises learned to stop worrying and love open source
• When is free not free: The true costs of open source
• Commonly we see businesses of all sizes utilizing open source solutions
to decrease time to market and reduce development effort
• Anyone with a great idea can build an infrastructure using open source
solutions without the financial barriers that existed a decade ago
• So how are people in the real world benefitting from open source?
• What technologies are they using, and where are they putting them?
6. 6© 2016 Rogue Wave Software, Inc. All Rights Reserved. 6
Case studies
Who’s using OSS?
• Today’s webinar centers around three fictitious companies
• Although the architecture and use cases are inspired by our real
customers, we’re going to protect their privacy
• All of these companies have built a full infrastructure stack using only OSS
solutions
• We’ll discuss the chosen architecture, point out some pitfalls, and see how
these development teams flexed the power of OSS to meet the demands
of their businesses
7. 7© 2016 Rogue Wave Software, Inc. All Rights Reserved. 7
PupBand
E-commerce website
8. 8© 2016 Rogue Wave Software, Inc. All Rights Reserved. 8
E-commerce website
PupBand
The only online store featuring specialty headbands for dogs!
Infrastructure needs
• Website front-end
• Order processing middleware
• Inventory database
Technology stack
• Apache web server
• OpenSSL
• PHP
• Apache ActiveMQ
• Apache Camel
• PostgreSQL
9. 9© 2016 Rogue Wave Software, Inc. All Rights Reserved. 9
Building PupBand
Selecting the stack
Front end
• For the front end, the developers knew they needed a robust web framework to work with and a
capable web server technology that supports SSL
• They looked at Java and PHP and decided on PHP 7. It’s easy to find qualified PHP developers and
the storefront didn’t need the overhead that comes with Java EE technologies.
• PHP 7 brings a number of significant enhancements, including a huge boost to performance
• OpenSSL is the de-facto standard for SSL encryption on the web and compiles easily into Apache
Web Server. Since the company collects sensitive payment data, strong SSL is a must!
• Nginx was considered, but, the development group was familiar with Apache and chose to
implement it for the web server stack
To get this project going, PupBand’s IT organization needed to vet out the
best open source projects they could find to build their stack
10. 10© 2016 Rogue Wave Software, Inc. All Rights Reserved. 10
Building PupBand
Selecting the stack
Order processing middleware
• Next, the company needed a reliable way of shuffling data between their
PHP front-end application and a backend inventory management system,
customer communications platform, and fulfillment warehouse
• They chose Apache ActiveMQ and Apache Camel
• ActiveMQ gave them the flexibility and reliability to integrate their PHP
front-end with Camel
• Camel ensured that they would have compatibility with all of the backend
systems needed to orchestrate their orders
11. 11© 2016 Rogue Wave Software, Inc. All Rights Reserved. 11
Building PupBand
Selecting the stack
Inventory database
• Finally, the developers at PupBand needed a way to store inventory and
order data
• They knew they needed a flexible and scalable solution, with replication
and disaster recovery functions
• And the data models they would be building might be fairly complex,
integrating customer data, fulfillment data, payment status, and RMA
• In the end, they settled on PostgreSQL, a truly FOSS database solution
meeting all their needs for performance, reliability, and RDBMS SQL
compliance
12. 12© 2016 Rogue Wave Software, Inc. All Rights Reserved. 12
Building PupBand
A complete picture
13. 13© 2016 Rogue Wave Software, Inc. All Rights Reserved. 13
Building PupBand
Front end
• The team deployed on CentOS in the cloud but, when they installed OpenSSL
and Apache using the CentOS repository framework, their security scans were
alerting them to vulnerabilities
• That’s because the newest version of OpenSSL and the newest version of
Apache weren’t available to them through CentOS’s repo
• They quickly decided to build the newest version of Apache from source,
against the newest version of OpenSSL
• They removed all legacy SSL protocol versions, and settled on TLS1.2, to
keep them protected from Heartbleed and DROWN
14. 14© 2016 Rogue Wave Software, Inc. All Rights Reserved. 14
Building PupBand
Middleware tier
• The middleware tier was complex, it needed to
integrate seamlessly with all the backend systems
• At first, the team decided to use the version of
Camel that was built into ActiveMQ
• ActiveMQ allowed the team to receive events from
the PHP front end and to queue those events for
processing
• But ActiveMQ became overwhelmed quickly when
using it’s embedded Camel implementation
• The team decided to deploy the Camel routes
standalone in a separate Java container, and
ActiveMQ’s footprint was reduced significantly
15. 15© 2016 Rogue Wave Software, Inc. All Rights Reserved. 15
Building PupBand
The backend
• The credit card API used RESTful services
• The team built a small webservices layer in front of Postgres, to loosely couple
the database
• And the fulfillment warehouse made use of traditional SOAP webservices
• Using Camel Components, the team was able to find a compatible solution for
all of the various integration endpoints they needed to interact with
16. 16© 2016 Rogue Wave Software, Inc. All Rights Reserved. 16
Building PupBand
• In the end, the development team at PupBand was able to develop their
entire E-commerce solution using community-supported, free, and open
source software
• The project was not without its challenges and the team had to research
and experiment to determine the safest, fastest, and most robust ways of
implementing the technology stack they chose
• Challenges around versioning, proper deployment, and performance
optimization took many cycles and hard work to overcome
• But in the end, PupBand was left with an infrastructure free from
proprietary commercial licenses, with room to grow
• And puppies everywhere rejoiced in their new head gear!
Code complete
17. 17© 2016 Rogue Wave Software, Inc. All Rights Reserved. 17
Poll #2
Which of the packages/technologies that we just
discussed are you using?
A: Apache ActiveMQ
B: Apache Camel
C: OpenSSL
D: PHP
E: PostgreSQL
18. 18© 2016 Rogue Wave Software, Inc. All Rights Reserved. 18
UniTrack
Mobile Platform as a
Service
19. 19© 2016 Rogue Wave Software, Inc. All Rights Reserved. 19
Mobile PaaS
Infrastructure needs
• API front-end
• Scalable event-processing middleware
• Location database
• Data visualization platform
Technology stack
• Nginx
• Node.js
• Docker
• Puppet
• Apache Cassandra
• Apache Spark
UniTrack
A crowd-sourced platform tracking the movement and migratory patterns of
unicorns
20. 20© 2016 Rogue Wave Software, Inc. All Rights Reserved. 20
Building UniTrack
Selecting the stack
API front end
• The team selected a combination of Nginx as a web server and Node.js as a
development platform
• The API was packaged in Docker containers, to allow for elastic auto-scaling
of the system
• Node.js would allow them strong concurrency and the ability to handle
thousands of simultaneous API calls
• Docker would allow the API servers to scale based on demand, and Puppet
would assist in spinning up new containers and deploying the API code
The dev team at UniTrack knew that they needed a lightweight, fast, and
concurrent system for receiving location data from millions of mobile clients
and presenting the data to subscribers
21. 21© 2016 Rogue Wave Software, Inc. All Rights Reserved. 21
Building UniTrack
Selecting the stack
Event-processing middleware / location database
• The team needed a highly concurrent and highly redundant solution to
store event and location data that came in through the front-end APIs
• The data would be spread across multiple cloud datacenters to allow the
best regional connectivity possible, along with disaster recovery features
• They chose Apache Cassandra for its easy replication strategy, its ability to
store and provide incredibly large datasets, and its performance
optimization capabilities
• Node.js was integrated directly with Cassandra, to shuttle data from the front-
end APIs into the database itself
• Puppet integration ensured easy deployment of additional Cassandra nodes in
the cloud, as system demand increased
22. 22© 2016 Rogue Wave Software, Inc. All Rights Reserved. 22
Building UniTrack
Selecting the stack
Data visualization
• Finally, the team needed a way to make sense of all this location and event
data
• The large data sets needed to be analyzed
• And data visualization needed to be provided to unicorn enthusiasts
everywhere via their smartphones
• Apache Spark was chosen for its lightning-fast data analytics capabilities
• And the GraphX plugin was implemented to visualize the large sets of unicorn
tracking data coming in from millions of worldwide users through the
smartphone client
23. 23© 2016 Rogue Wave Software, Inc. All Rights Reserved. 23
Building UniTrack
A complete picture
24. 24© 2016 Rogue Wave Software, Inc. All Rights Reserved. 24
Building UniTrack
Front-end APIs
• The team built Docker containers bundling Nginx with a lightweight node.js
application. The learning curve for Node.js proved to be a bottleneck, as
traditional JavaScript developers needed to rethink the way they developed
• A Puppet master server was built and orchestration for spinning up new
containers on-demand was developed. Security became a major concern,
as access to the Puppet master server by a malicious user could lead to
disastrous consequences
25. 25© 2016 Rogue Wave Software, Inc. All Rights Reserved. 25
Building UniTrack
Event-processing middleware
• Integration of the Node.js containers with Cassandra
proved to be easy, using Cassandra’s asynchronous
connection drivers for Node.js
• The real challenge was building a NoSQL data model that
could meet all of their data processing and visualization
needs, while remaining fast and responsive
• Cassandra’s deployment itself was simple, spinning up
nodes in various data centers using Cassandra’s in-built
deployment utilities and native replication protocol
26. 26© 2016 Rogue Wave Software, Inc. All Rights Reserved. 26
Building UniTrack
Visualization and analytics
• Spark made it easy to pull in and analyze the vast amounts of data
provided by UniTrack’s enormous user base
• The biggest challenge lay in determining which of the many client libraries
should be used to power Spark
• The team could pick from Java, Scala, Python, or R
• In the end, Java was selected, and a standalone application was built
around the Spark libraries to provide visualization of data via GraphX
• GraphX’s output was compressed and standardized for mobile platform
consumption
27. 27© 2016 Rogue Wave Software, Inc. All Rights Reserved. 27
Building UniTrack
• By leveraging the elastic scale and microservice capabilities of Docker and Node.js, the
team was able to build a highly concurrent architecture capable of servicing
thousands of requests a second
• The choice for Cassandra as a persistence backend proved wise, as the development
team was able to scale the Cassandra implementation into multiple regional datacenters,
and service the huge amount of traffic input by the front-end APIs
• Puppet worked well in detecting increases in load, and elastically scaling the API
containers on demand
• Spark and GraphX allowed the application to make sense of the huge amount of data,
and provide visual analysis to mobile clients
• Though so far all unicorn location claims have proven spurious, the UniTrack community
feels confident that with the powerful platform they have built, it is only a matter of time
before a real live unicorn is discovered and captured
Code complete
28. 28© 2016 Rogue Wave Software, Inc. All Rights Reserved. 28
Poll #3
In your opinion, how different are containers/microservices
vs. service-oriented architectures?
A: Very little difference
B: About the same
C: Very big difference
D: Don’t know
29. 29© 2016 Rogue Wave Software, Inc. All Rights Reserved. 29
HelpingHumans
HPC Machine Learning
30. 30© 2016 Rogue Wave Software, Inc. All Rights Reserved. 30
HPC machine learning
HelpingHumans
Advancing human society through artificial intelligence and robot
sentience
Infrastructure needs
• Multi-platform data gathering
automation
• Redundant storage and analytics
• Dashboard front-end
Technology stack
• Apache Camel
• Apache Cassandra
• Kubernetes
• TensorFlow
• AngularJS
31. 31© 2016 Rogue Wave Software, Inc. All Rights Reserved. 31
Building HelpingHumans
Selecting the stack
Multi-platform data gathering
• The secret development group responsible for building the platform knew they
would need a framework capable of gathering data from hundreds of potential
sources
• The platform needed to be capable of querying CDC data, military intelligence,
social media, human history, and more
• Apache Camel was chosen to act as a central data gathering platform for
pulling unstructured data from multiple, disparate sources
• Camel’s huge component library would allow for this kind of flexibility, while
developing against a standard, domain-specific language and reducing
boilerplate code
In order to assist the human race in performing useful tasks, the machines
must be capable of learning as much as they can about our species
32. 32© 2016 Rogue Wave Software, Inc. All Rights Reserved. 32
Building HelpingHumans
Selecting the stack
Redundant storage and analytics
• Once the data had been gathered, the dev group knew that they would need a
redundant storage system capable of quickly writing and reading a gigantic
amount of data
• And once that data was gathered, a machine learning analytics library was
necessary to normalize all that data and understand human activities,
capabilities, and behavior
• Apache Cassandra would be capable of storing all the data
• And the open source TensorFlow machine learning framework could help in
building learning patterns to make sense of all the disparate data
33. 33© 2016 Rogue Wave Software, Inc. All Rights Reserved. 33
Building HelpingHumans
Selecting the stack
Dashboard front-end
• The team needed a way to take data processed by TensorFlow and pushed
back into Cassandra, and build a useful dashboard to check the progress of
various learning initiatives
• The dashboard needed to be lightweight and cross-browser compatible
• It also needed a relatively low learning curve, since the bulk of the
development work would be spent on the learning and analytics engine
• The team decided on AngularJS, which allows a full MVC framework, reusable
components, and a low learning curve for developers who already understand
JavaScript
34. 34© 2016 Rogue Wave Software, Inc. All Rights Reserved. 34
Building HelpingHumans
Selecting the stack
Container orchestration
• Both the Camel data-gathering components and the TensorFlow analytics
needed to be deployed in such a way that they could be easily scaled up to
provide concurrent gathering and processing of data
• Ultimately, the architecture would contain thousands of individual
containers operating in concert
• For this, orchestration of Docker through Puppet was simply not sophisticated
enough, so the team implemented Kubernetes to provide a full management
platform for their large container infrastructure
• Service discovery, monitoring, and deployment would all be provided by the
Kubernetes management engine
35. 35© 2016 Rogue Wave Software, Inc. All Rights Reserved. 35
Building HelpingHumans
A complete picture
36. 36© 2016 Rogue Wave Software, Inc. All Rights Reserved. 36
Building HelpingHumans
Multi-platform data gathering
• Camel allowed the HelpingHumans team to source data from the hundreds of various
data sources they wished to pull from
• Initially, the development team thought it best to deploy Camel inside of a Tomcat
container and then contained inside of Docker
• Ultimately this solution had just too much overhead, and multiple instances of Tomcat
were found to be redundant when deployed in a containerized infrastructure
• The Dev team chose to build standalone Camel applications running per container and
the system was much more efficient
37. 37© 2016 Rogue Wave Software, Inc. All Rights Reserved. 37
Building HelpingHumans
Redundant storage and analytics
• It turned out TensorFlow was a great starting point for the type of machine learning the
HelpingHumans Dev team wanted to implement but there was functionality missing that
was critical to their work
• Ultimately they leveraged the power of FOSS by modifying the source code of
TensorFlow and spinning off their own internal branch
• And, in the spirit of their altruistic mission, the dev team offered these enhancements
back to the TensorFlow community
38. 38© 2016 Rogue Wave Software, Inc. All Rights Reserved. 38
Building HelpingHumans
Orchestration and dashboarding
• Kubernetes forced the development team at HelpingHumans to
change the way they thought about containerized deployment and
microservice management
• After the paradigm shift was complete, the team ended up with an
amazing elastically-scaling architecture that was able to meet
the high demands their data gathering and analytics needed
• AngularJS proved easy to learn and highly functional, and
integrated well with Cassandra
• Ultimately a lot of the visualization work was offloaded to backend
servers, though, with Angular acting as a proxy, since the client-side
limitations of Angular limited the analysis of the data
39. 39© 2016 Rogue Wave Software, Inc. All Rights Reserved. 39
Building HelpingHumans
• By leveraging powerful open source frameworks, the HelpingHumans team
was able to develop a sophisticated engine for learning new ways to analyze
human needs and behaviors
• Advanced container management through Kubernetes allowed for the
complex orchestration necessary to elastically scale their Camel and
TensorFlow based applications
• And Cassandra’s high performance big data storage allowed HelpingHumans
to efficiently store all the data they gathered from hundreds of sources
• Human civilization as we know it ended roughly six months after deployment
Code complete
40. 40© 2016 Rogue Wave Software, Inc. All Rights Reserved. 40
Conclusion and wrap-Up
41. 41© 2016 Rogue Wave Software, Inc. All Rights Reserved. 41
Support from a group like the OSS Support team at Rogue Wave
can ensure that what you implement works well, stays available, and
is scaled for growth
Conclusion
You can safely build an entire IT infrastructure on FOSS technologies,
if you make disciplined decisions surrounding the choice of technology
and the practices of development, implementation, and deployment
Careful vetting can help you ensure that the packages you
choose truly meet your use case
There is a ton of open source available to you, but certain
applications and projects will rise to the top based on their
maturity, the strength of their communities, and their reactiveness
to bug fixes and vulnerabilities
43. 43© 2016 Rogue Wave Software, Inc. All Rights Reserved. 43
Watch on demand
• Watch this webinar on demand
• Read the recap blog to see the results of the
polls and Q&A session
44. 44© 2016 Rogue Wave Software, Inc. All Rights Reserved. 44
Follow up
Free newsletter: vulnerabilities, industry news, and enterprise support stories
http://www.openlogic.com/products-services/openlogic-exchange/openupdate
For OpenLogic support customers:
OSS Radio
Get a free OSS support ticket to experience our expertise
roguewave.com/freeticket
45. 45© 2016 Rogue Wave Software, Inc. All Rights Reserved. 45
Stay tuned
Top open source lessons for every enterprise
July 27: Top issues in the top enterprise packages
Dive into specific packages with two architects to discover what goes right and what goes wrong.