Advanced use cases and approaches with stratos paa s


Published on

Published in: Technology
  • Be the first to comment

No Downloads
Total views
On SlideShare
From Embeds
Number of Embeds
Embeds 0
No embeds

No notes for slide

Advanced use cases and approaches with stratos paa s

  1. 1. Advanced Use Cases and Approaches with WSO2 Stratos Paul Fremantle CTO and Co-Founder @pzfreo #wso2
  2. 2. Agenda• This is a follow on to the presentation I gave at Qcon: –• Quick recap• Understanding the system architecture of Stratos – Identity model – Multi-tenancy – Elastic Load Balancer• How do new Services fit in?• How can I multi-tenant existing code?• Integrating development management into Stratos• Advanced use cases• Summary @pzfreo #wso2 2
  3. 3. What should you take away from thispresentation?• What are Stratos and StratosLive?• How can I try out Stratos? – On the Web? – On your machine?• How can I extend Stratos?• Where can an extensible open PaaS give me competitive advantage?• Where can I get more information? @pzfreo #wso2 3
  4. 4. Moore’s Law for Data• The amount of data online went from – 5 exabytes in 2002 – 281 exabytes in 2009• Doubling every 15 months• You cannot deal with this data growth with the same applications – A reasonable conclusion is that the number of applications will double every 15 months too @pzfreo #wso2
  5. 5. Stratos Overview• Stratos – an Open Source project / product – A full middleware platform available as a service, with self service • Fast provisioning – Based on OSGi • Modular, componentized, standard – Multi-tenant, Elastic, Metered and Billed • Effective and powerful – Available under the Apache License • Open Source, Open License, Open Development• StratosLive – a Platform-as-a-Service – Stratos running in the cloud with various plans • Including a free demo plan @pzfreo #wso2
  6. 6. Stratos resources• Running on the web –• Stratos SVN –• Stratos-dev list – dev• Blog on how to build / install – stratos-in-personal.html @pzfreo #wso2 6
  7. 7. Private Cloud Middleware Platform @pzfreo #wso2
  8. 8. StratosLive vs Stratos• StratosLive contains all the “Services” in a default / vanilla state• Stratos can contain: – More services • e.g. New services you create – Fewer services • e.g. just AS/DSS – Customized deployments of services • e.g. ready configured with libraries / APIs / host objects @pzfreo #wso2 8
  9. 9. Installation options• 1. Full installation (like StratosLive) – Pre-reqs • IaaS – Eucalyptus, vmWare, Ubuntu or Amazon • MySQL & Perl & JVM • Ability to run a number of VMs (one per service)• 2. Laptop/Simple install (on my laptop) – Pre-reqs • A machine with lots of memory (4Gb min, 8GB preferred) • JVM • MySQL & Perl @pzfreo #wso2 9
  10. 10. Examples and Case Studies• System Integrator – Currently running Stratos for internal projects – Examining the use of Stratos for customer projects and SaaS• Home Loan Bank – WSO2 runs a private deployment of Stratos – Developer sandbox and test environment – Currently apps are then deployed internally in Carbon• Ecosystem PaaS – Combination of cross tenant services / APIs – Allow each tenant to deploy / customise the logic• Mobile PaaS – Building a PaaS environment for a mobile telco• SaaS-enablement of legacy applications @pzfreo #wso2
  11. 11. ESB and PaaS example Tenant Tenant Tenant Tenant App App App App Internet Gateway (WSO2 ESB providing Traffic Core ESB shaping, QoS, and LB) Core Services @pzfreo #wso2
  12. 12. Available Services in Stratos(a selection) @pzfreo #wso2 12
  13. 13. Every Service has a network API• All admin functions and all the low level services are available as SOAP APIs – Full SOAP support, REST in some cases – Always possible to bridge into REST using the ESB• Why? – Clear SOA design • Allow mashups, BPEL and ESB integration – Automated provisioning – Support hybrid multi-tenancy models for legacy software @pzfreo #wso2 13
  14. 14. Multi-tenancy• Every service can support multiple tenants in the same container – Higher efficiency, lower resources – Can be split tenant per-VM using the MT-aware Load Balancer• Isolation includes classloaders, code signing and Java security policies – Cross-tenant sharing is via the network (REST, SOAP, etc)• Every tenant has all services by default but they can be turned off• You can deploy webapps that are available to all tenants – Super Tenant mode @pzfreo #wso2 14
  15. 15. Carbon Context• org.wso2.carbon.context.CarbonContext• Access to: – UserRealm (Identity) – Registry – Cache (JSR107) – Endpoint Discovery• All within the correct environment for the tenant or within a super-tenant environment @pzfreo #wso2 15
  16. 16. Stratos 1.5.2 Services © WSO2 2011 @pzfreo #wso2
  17. 17. What is a “Stratos Service”• A cluster of one or more network-available servers – could be VMs or JVMs or Linux partitions – Each cluster can logically handle all tenants • Maybe that there is partitioning by tenant or group of tenants – Should support SAML2 single-sign on • Identity is used to identify which tenant• Can be elastically scaled – Not a hard requirement – Elasticity and Multi-tenancy are orthogonal @pzfreo #wso2 17
  18. 18. List of Stratos Services• cloud-services-desc.xml<cloudServices xmlns=""> <cloudService name="WSO2 Stratos Enterprise Service Bus" default="true"> <label>Stratos Enterprise Service Bus</label> <link></link> <icon> </icon> <productPageURL></productPageURL> <description>Enterprise Service Bus in the cloud.</description></cloudService>…• The Registry is used to manage which tenants have access to which services: – E.g. /_system/governance/repository/components/org.wso2.stratos/cloud- manager/cloud-services/27/WSO2 Stratos Enterprise Service Bus @pzfreo #wso2 18
  19. 19. Elastic Auto-Scaling• The WSO2 Elastic Load Balancer is a key part of the Stratos infrastructure – Tenant Self-registration, self-deployment and multi-tenancy could lead to a lot of work on a single server – The Stratos multi-tenancy approach is designed to support the “long-tail” @pzfreo #wso2 19
  20. 20. Elastic Load Balancer @pzfreo #wso2 20
  21. 21. Stratos Elastic Load Balancer• A custom deployment of Synapse tuned for passthru proxying and performance• Currently supports EC2 APIs – Amazon, Eucalyptus, OpenStack with vmWare and Rackspace in plan• There is a base AMI ID and a per-service payload zip – ELB starts the AMI on a new VM by passing a – - Payload contains S3 credentials, information about Product to be – deployed, configuration files locations, etc. – AMI downloads the – AMI connects to S3 using credentials, downloads the service binary from S3 and config files using information from• Autoscaling is currently based on concurrent message load – Extensible model – Looking at using wider metering results @pzfreo #wso2 21
  22. 22. Example of a new Service• PHP Services (in progress) – Using chroot environments • Also looking at LXC ( • A lightweight model for virtualization/tenant separation• Each tenant runs on a different ip+port on the server – • is URL rewritten to – http://ip:port/app• The PHP environment uses the Identity Server and Registry – Provide a store for code – Tenant identity and authorization model• This will be extended to become a full SPI (Service Provider Interface) to plug in any new non-Java Service @pzfreo #wso2 22
  23. 23. Adding multi-tenancy to existing apps• Start with the PHP Service model• Add in: – HDFS support (multi-tenant filesystem) – RSS support (multi-tenant JDBC/RDBMS) – Multi-tenant Logging model • Can be syslog-based logging calls – Elastic scaling – Metering and Billing calls • Optional – but useful • Multi-language Thrift API @pzfreo #wso2 23
  24. 24. Integrating Development Managementinto Stratos• The Stratos Service model is very extensible and flexible – E.g. Dev / Staging / Production can be different “Stratos Services” – Use Registry lifecycles or BPEL to manage the workflow / lifecycle of code into those Services @pzfreo #wso2 24
  25. 25. Integrating Development Managementinto Stratos @pzfreo #wso2 25
  26. 26. WorkflowsExamples• Add project (aka tenant) – Creates Project Management, SVN, and Stratos Tenant• Add user to project – Configures permissions in SVN, PM and Stratos• Deploy project into production – Initiates approval governance process – Maven build of the code – Deploys into staging • Notifies approval team of new project awaiting approval – Once approved, automatically deploys into Production @pzfreo #wso2 26
  27. 27. Recap• Understanding Stratos• What are Stratos Services – How do I extend, re-use, reconfigure, add my own• What is the Stratos ELB? – How does it work – Roadmap• How to add multi-tenancy to existing apps• Managing development and governance @pzfreo #wso2 27
  28. 28. Enterprise Application DevelopmentAPI Store and API Management @pzfreo #wso2
  29. 29. UsersPartners “Your Business As A Service” Tenant Tenant Tenant Tenant Apps Apps Apps AppsEcosystem Owner PaaS / Stratos API Management / API Store Existing business systems as APIs @pzfreo #wso2
  30. 30. Vertical PaaS“Your Business as a Service”• Based on real projects that WSO2 is running• Beyond APIs – because it creates a shared governance model and runtime• An opportunity to add significant value to partners: • A complete environment that they can customize • Can include multi-tenanted legacy software • Not just the look and feel but also the behaviour • An ideal platform for shared revenue• A shift in business models enabled by cloud technology @pzfreo #wso2
  31. 31. “Your Business”-as-a-Service summary• Inherent deep multi-tenancy enables ecosystem plays • Not just shallow per-tenant customization • E.g. eBay Stores, Amazon Sellers • But significant per-tenant customization• Client success stories demonstrates key aspects: • Ecosystem creation • Shared governance and revenue model • Significant benefit beyond APIs • Cloud Development • Automated Governance @pzfreo #wso2
  32. 32. Questions? @pzfreo #wso2 32