Bring N-Tier Apps to containers 2015 ContainerCon
-
Upload
chris-haddad -
Category
Software
-
view
580 -
download
2
Transcript of Bring N-Tier Apps to containers 2015 ContainerCon
![Page 1: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/1.jpg)
Last Updated: June. 2015
Bringing N-Tier Apps To Containers
Vice President, Platform Evangelism, WSO2
@cobiacomm
Chris Haddad
![Page 2: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/2.jpg)
Moving from Lab to Production
![Page 3: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/3.jpg)
Moving from Old to New
![Page 4: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/4.jpg)
Legacy 3-Tier Applications
![Page 5: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/5.jpg)
Legacy Enterprise Topologies – Complex Interactions
![Page 6: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/6.jpg)
6
N-Tier Perspectives
Solution Template
Infrastructure
PolicyArchitecture
![Page 7: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/7.jpg)
7
N-Tier Solution Attributes o Architecture
o Application Oriented, Service-Oriented, Resource-Orientedo Composition / Orchestration
o Policyo Quality of Service
o Resiliency, High Availability, Scalability o Security o Isolation
o Infrastructureo Topologyo Connectivity - Networking o Resource Management - Scheduling, Reservation o Storage
![Page 8: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/8.jpg)
8
Architecture:Application, Resource, Service-Oriented
Constraint Platform Requirement KubernetesMesos
MarathonDocker
ComposeApache Stratos
higher level, aggregate view
application as first-class citizen, labels N Y Y Y
Resource viewresource as first-class citizen, labels, URLS Y N N N
Business capability viewservice as first-class citizen, labels Y Y N Y
![Page 9: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/9.jpg)
9
Composition
Constraint Platform Requirement KubernetesMesos
MarathonDocker
ComposeApache Stratos
cluster (session and state management)
network addressable, coordination service N N N * N
container group (web app database )
network overlays, orchestration N N N Y
container links (web app , database )
network overlays, orchestration
N (flat, plug-in?) N ? Y Y
server farm register worker nodes Y Y N Y
![Page 10: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/10.jpg)
10
Isolation
Constraint KubernetesMesos
MarathonDocker
ComposeApache Stratos
CPU, PID, Memory Y Y Y Y
Network N N (?) Y Y
Tenant Management N N N Y
![Page 11: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/11.jpg)
11
Networking
Constraint Platform Requirement KubernetesMesos
MarathonDocker
ComposeApache Stratos
Load balancer (HW, SW)known routes, hostname addressing Y (plug-in) N ? Y
Public IPpublic IP, hostname assignment, route Y (plug-in) N Y Y
![Page 12: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/12.jpg)
12
Resource Management
Constraint Platform Requirement KubernetesMesos
MarathonDocker
ComposeApache Stratos
CPU loadresource reservation, scheduling * Y Y S
memory footprintresource reservation, scheduling * Y Y S
![Page 13: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/13.jpg)
13
More Constraints
Category Constraint Platform RequirementSecurity identity management
Securitynetwork segment security (web app, database) access control policies
Storageshared access to database service
Storage shared access to files shared volumesStorage shared access to files networked drivesTopology Cross-Data Center cross-zone monitor and controlTopology Cross-IaaS cross-zone monitor and controlTopology pre-built, hardwired complex declarations
![Page 14: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/14.jpg)
Moving N-Tier Apps to Containers
![Page 15: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/15.jpg)
Containerization Adoption BarriersNetworking and Load Balancing
Monitoring and QoS
ClusteringBacking Stores / Persistence Strategies
Discovery and Composition
Workflow
![Page 16: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/16.jpg)
16
Common Level Zero Container Challenges
o Networkingo Discoveryo Load balancing between Tierso Persistence – Tight Coupling with File System o Monitoring and Log files
![Page 17: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/17.jpg)
Operate at the Speed of BusinessAccelerate DevOps
Flow
![Page 18: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/18.jpg)
Operate at the Speed of Business
![Page 19: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/19.jpg)
o Deploymento Discoveryo Linkingo Monitoringo Resiliency
![Page 20: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/20.jpg)
DevOps Vectors
o Continuous deliveryo Continuous buildo Continuous integrationo Continuous deployment
![Page 21: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/21.jpg)
DevOps Vectors
o Reliabilityo Availabilityo Scalabilityo Performance
![Page 22: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/22.jpg)
o Iterative releaseso Incremental testingo Co-evolution
![Page 23: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/23.jpg)
Compass and GearingPlatform Compass
• Operations Perspective• Manage Container Quality of Service• Ensure Security
• Development perspective• Micro-service architecture patterns• Application packaging strategies • Container lifecycle decisions
![Page 24: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/24.jpg)
Composite Application Model and Policy Model
![Page 25: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/25.jpg)
*
What are the smart policies?๏ Auto scaling๏ Deployment
Auto scaling policy๏ Define thresholds values pertaining scale up/down
decision ๏ Auto Scaler refer this policy๏ Defined by DevOps
Deployment policy๏ Defined how and where to spawn cartridge instances๏ Defined min and max instances in a selected service
cluster๏ Defined by DevOps based on deployment patterns
Smart Policies
![Page 26: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/26.jpg)
*
Groups Compose Container Instances
![Page 27: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/27.jpg)
*
Scaling algorithm can use multiple factors. such as- Load average of the instance- Memory consumption of the instance- In-flight request count in LB
How do you specify elastic scale?
![Page 28: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/28.jpg)
*
Group Scaling Scenario
![Page 29: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/29.jpg)
*
Dependent Scaling Scenario
![Page 30: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/30.jpg)
Internet as a Data Center
© Mathias Rosenthal - Fotolia.com
![Page 31: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/31.jpg)
*
Burst based on policy and load
Ever try to Cloud Burst Containers?
![Page 32: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/32.jpg)
*
Rapidly Evolve with Micro-service Applications
![Page 33: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/33.jpg)
33
Infrastructure Alternatives
o Docker Composeo Apache Mesos / Mesos Marathono Google Kuberneteso Apache Stratos
![Page 34: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/34.jpg)
*
Manage clusters and containers● Schedule● ControlConcepts● Pods● Labels● Nodes
Why add Kubernetes?
![Page 35: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/35.jpg)
*
Kubernetes – Opportunity Zone
Source: https://github.com/GoogleCloudPlatform/kubernetes/blob/master/DESIGN.md
“we want Kubernetes to be built as a collection of pluggable components and layers, with the ability to use alternative schedulers, storage systems, and distribution mechanisms, and we're evolving its current code in that
direction.”
“A single Kubernetes cluster is not intended to span multiple availability zones. Instead, we recommend building a higher-level layer to replicate complete
deployments of highly available applications across multiple zones.”
![Page 36: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/36.jpg)
*
The Role of Apache Stratos
● Package Manager● Define Security and Network Policies● Manage Micro-service Definition● Define Composite Application● Container Auto-Scaler Logic● Manage Service Subscriptions
![Page 37: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/37.jpg)
*
Containerize Applications and Services
![Page 38: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/38.jpg)
*
Apache Stratos L1 Deployment Architecture for Docker based Cartridges
![Page 39: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/39.jpg)
Stratos Architecture
![Page 40: Bring N-Tier Apps to containers 2015 ContainerCon](https://reader035.fdocuments.in/reader035/viewer/2022070523/58ed83031a28ab481d8b46c1/html5/thumbnails/40.jpg)
Test Drive the Cloud in a Box Distro
Install Kubernetes Distro:https://github.com/imesh/kubernetes-vagrant-
setup.git
Download Stratos distribution, load balancer & samples:
http://stratos.apache.org
Follow Getting Started Guide