Upload
activestate
View
280
Download
3
Embed Size (px)
DESCRIPTION
Getting your new applications into the cloud is a relatively simple procedure. However, enterprises are faced with a large number of existing applications in their current portfolio that may not be quite ready for the new cloud world. Before migrating legacy apps to the cloud, like moving to a new house, enterprises need to assess their current portfolio of apps and determine what they should consolidate, what they should get rid of and what they should keep. But deciding what to keep is only half of the equation. Enterprises need to understand how some application properties and the development process need to change in order to have a successful migration. Companies can reduce their costs significantly by optimizing their applications development and maintenance. Moving away from the "old way" to the "new way" not only results in saving money, but will also result in saving significant time. Ho Ming Li, Cloud Solution Architect and Phil Whelan, Technology Evangelist, discuss some of the changes to the development process or application structure/properties that companies need to implement in order to successfully migrate their apps: - Connecting to databases - service binding - Frontend/Backend - REST/MQ - Statefulness vs. Statelessness - Consistency across Environments - Dependency Management - Logging and Monitoring http://www.activestate.com/webinars/bringing-legacy-apps-cloud
Citation preview
Legacy Apps... to the CloudConsiderations and PracticesPhil WhelanTechnology Evangelist
Ho Ming LiCloud Solution Architect
May 2014
activestate.com/stackato | @activestate | #stackato | activestate.com/blog | Copyright 2014
Moving To The Cloud
Legacy applications are not designed to run in the cloud.
Cloud-enabled applications are.
How do we define "legacy" and "cloud-enabled"?
How do we cloud-enable our legacy applications?
activestate.com/stackato | @activestate | #stackato | activestate.com/blog | Copyright 2014
Cloud-Enabled Application
Attributes
Portable
Scalable (horizontally)
Modular...
Challenges
Different infrastructure
Scaling issues
Dependency management
...
activestate.com/stackato | @activestate | #stackato | activestate.com/blog | Copyright 2014
Twelve-Factor App http://12factor.net/
I. Codebase One codebase tracked in revision control, many deploys
II. Dependencies Explicitly declare and isolate dependencies
III. Config Store config in the environment
IV. Backing Services Treat backing services as attached resources
V. Build, release, run Strictly separate build and run stages
VI. Processes Execute the app as one or more stateless processes
VII. Port binding Export services via port binding
VIII. Concurrency Scale out via the process model
IX. Disposability Maximize robustness with fast startup and graceful shutdown
X. Dev/prod parity Keep development, staging, and production as similar as possible
XI. Logs Treat logs as event streams
XII. Admin processes Run admin/management tasks as one-off processes
activestate.com/stackato | @activestate | #stackato | activestate.com/blog | Copyright 2014
Today...
• Statefulness vs. Statelessness• Connecting to databases - service binding• Frontend/Backend - REST/MQ
• Consistency across environments
• Dependency management
• Logging and monitoring
activestate.com/stackato | @activestate | #stackato | activestate.com/blog | Copyright 2014
From Legacy To The Cloud
Your legacy software falls into one of the following categories:
1.It just works!
2.Needs a few tweaks
3.Runs with limitations
4.Not suitable for the cloud
activestate.com/stackato | @activestate | #stackato | activestate.com/blog | Copyright 2014
Potential Outcomes
Your legacy application in the cloud might be...
1.Running with major limitations
2.Running with minor limitations
3.Fully cloudifiedreal word?
activestate.com/stackato | @activestate | #stackato | activestate.com/blog | Copyright 2014
1) Statefulness Vs. Statelessness
Examples...
•Sessions
•In-memory data structures
•Local disk storage
Cloud-enabled
Use shared data stores
Half-way there
Use sticky sessions
activestate.com/stackato | @activestate | #stackato | activestate.com/blog | Copyright 2014
1) Statefulness Vs. Statelessness
http://www.github.com/homingli/node-session
legacy - sessionhalfway - sticky session
cloud - session storehttp://www.ideachampions.com/weblogs/Public-Speaking.jpg
Sessions DEMO
activestate.com/stackato | @activestate | #stackato | activestate.com/blog | Copyright 2014
2) Data Service Binding
Legacy applications involve
manual invention to configure
service bindings.
PaaS can auto-provision service
instances and inject service
location and credentials into the
application
Cloud-enabled
Grabs service credentials from environment on
start-up
Half-way there
Using legacy data services and hard-coded
credentials will work
activestate.com/stackato | @activestate | #stackato | activestate.com/blog | Copyright 2014
3) Frontend/Backend - REST/MQ
By breaking up a monolithic application to its components, components can scale on demand individually.
Communications: REST common interface, MQ for app internals.
Cloud-enabled
Components are broken up, communicating via
REST/MQ
Half-way there
Running in cloud environment
Existing communications path
activestate.com/stackato | @activestate | #stackato | activestate.com/blog | Copyright 2014
3) Frontend/Backend - REST/MQ
http://www.github.com/homingli/node-febe
REST calls
Service bindings
http://www.ideachampions.com/weblogs/Public-Speaking.jpg
DEMO
activestate.com/stackato | @activestate | #stackato | activestate.com/blog | Copyright 2014
4) Consistency Across Environments
How close can you get your
development environment to
production?
Stackato provides a consistent
environment wherever you run it
- development QA, or production
Cloud-enabled
Use PaaS as part of the development workflow
Half-way there
Use continuous integration to ensure production
compatibility
activestate.com/stackato | @activestate | #stackato | activestate.com/blog | Copyright 2014
5) Dependency Management
Having Ops independently
configure the environment for
applications is error prone and
does not scale.
PaaS applications couple
dependencies and application
code together.
Cloud-enabled
Use buildpacks.
Use stackato.yml to define system dependencies
Half-way there
Add Ops scripts to application
activestate.com/stackato | @activestate | #stackato | activestate.com/blog | Copyright 2014
6) Logging And Monitoring
Managing logs across
horizontally scaled applications
being difficult
PaaS enables streaming all logs
to a central repository
Cloud-enabled
Application logs only written to
STDERR/STDOUT
Half-way there
Configure where logs a written to and have PaaS
read them
activestate.com/stackato | @activestate | #stackato | activestate.com/blog | Copyright 2014
6) Logging And Monitoring
https://github.com/Stackato-Apps/go-env
staging logs
application logs
web console logginghttp://www.ideachampions.com/weblogs/Public-Speaking.jpg
Logging DEMO
activestate.com/stackato | @activestate | #stackato | activestate.com/blog | Copyright 2014
Over To You
What will it take to get your applications running on the cloud?
It doesn't have to be all-or-nothing
Stackato provides lots of ways to support legacy applications that are not written with the cloud in mind
Questions?
Phil Whelan@[email protected]
May 2014
Contact Us: Ho Ming Li@[email protected]
www.activestate.com/stackato
Download Stackatohttp://www.activestate.com/stackato