Professional Documents
Culture Documents
on AWS
Overview
2016 Amazon Web Services LLC and its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent of Amazon.com, Inc.
Agenda
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Module 1
Databas
e
Use case 1
Use case 1
Module 2
<<includes>>
Use case 2
<<extends>>
Use case 4
Use case 2
Use case 3
Relational
Use case 3
Module 3
Use case 4
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
NFS
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Web Server
(User Experience)
Application Server
(Business Services)
Module 1
Module 2
Use case 1
Use case 2
Module 3
Use case 3
User interface
Use case 4
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Database
Application Server
Application 1
Application 2
Application 3
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Database
Application Server
Application 1
Application 2
Application 3
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Database
Application
A
Application A
Application B
Application
B
Application
C
Application C
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Application B
Application C
Service BUS
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Database
Application Server
Application 1
Application 2
Application 3
Initially for
development / QA
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
solved
servers
Consolidation of storages on
SANs
Simplification of infrastructure
management
If the systems are slow:
developers fault
Heavy applications
Waterfall development
Tightly coupled
Scaling problems
Web-Middle-Data architecture
Lack of ownership
Failure dependencies
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Memory or CPU
App 2
App 1
Application Server/
Service BUS
Operating System
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Memory or CPU
App 3
Do
we
really
need
App 2
Do these applications really need
uniqueto standard
live together (and bother each
other)?
App 1
techs and
Do all the applications share the
practices
for for availability,
same requirements
Application Server/
scalability and fault tolerance?
Service BUS
everything?
Can we change applications
Operating System
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Module 1
Use case 1
Module 2
Databas
e
CPU
Mem
I/O
DB
Function 1
Function 2
Function 3
Function 4
Use case 2
Use case 3
Module 3
Function 5
Function 6
Function 7
Function 8
Function 9
Use case 4
Function 10
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Concur
.
Module 1
Databas
e
Function 1
API Call
(CodeLess)
Use case 1
Function 2
Module 2
Function 3
Container
Use case 2
Function 9
Use case 3
Function 10
Module 3
Use case 4
Function 6
Function 4
Function 5
Serverles
s
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Function 7
Function 8
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
The Microservices
way of building systems
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Microservices architecture
The microservice architectural style is an approach to
developing a single application as a suite of small
services, each running in its own process and
communicating with lightweight mechanisms, often an HTTP
resource API. These services are built around business
capabilities and independently deployable by fully
automated deployment machinery. There is a bare
minimum of centralized management of these services,
which may be written in different programming
languages and use different data storage technologies.
-- James Lewis and Martin Fowler
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Monolithic
Single Unit
SOA
Coarsegrained
Microservices Architecture
Microservice
s
Fine-grained
- Adrian Cockcroft
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Elastic
Independen
t
Resilient
Ownership
Composable
Polyglot
Minimal
Complete
Do one
thing well
Blackbox
Registration
Discovery
Wiring
Administrati
on
Versioning
State
Management
Service
Metadata
Public API
Caching
Automated
Deployment
Automated
Management
Automated
Monitoring
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Amazon
DynamoDB
Amazon
RDS
Amazon
Redshift
Amazon
ElastiCache
Amazon
S3
Application
g
in
n
a
t
io Master
Da rtit
(shard 1)
Pa
Read Replica
Read Replica
Master
Master
(shard 2)
(shard 3)
Read Replica
Read Replica
Taxation
Scale on memory
Checkout
Scale on CPU
Read Replica
Read Replica
Cloning
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Amazon
EFS
Order
*
0..1
OrderItem
*
Customer
1
1
*
SpecialPriceLi
st
*
1
Product
1
*
PriceList
*
1
Region
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Microservice challenges
Service discovery
Increase coordination
Microservices
and DevOps
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
DevOps
What is it ?
A philosophy? Cultural change? Paradigm shift ?
Alignment of development and IT operations with better
communication and collaboration ?
Improvement in software deployment ?
Breaking down the barriers between development and IT operations ?
Akin to Agile software development applied to infrastructure and IT
operations
Code
Developer
W
a
l
l
ITOperations
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Automating Everything
Re-Think Deployment
Manual Deployment
User Experience
Business Services
Production
Release
Packaged Version
Unit
Test
Syste
m Test
Commi
t
Unit
Test
Syste
m Test
Commi
t
Unit
Test
Syste
m Test
UAT
Stagin
g
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Prod
Microservice development
lifecycle
develope
rs
services
build
test
release
build
test
release
build
test
release
build
test
release
build
test
release
build
test
release
delivery pipelines
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Decentralized
Two-pizza teams
Agility, autonomy,
accountability, and
ownership
DevOps
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Change
Change
Time
Larger Effort
Increased Risk
Time
Smaller Effort
Minimized Risk
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Deployments at Amazon.com
~11.6s
~1,079
~10,000
~30,000
2011
numbers
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Thousands of teams
Microservice architecture
Continuous delivery
Multiple environments
= 50 million deployments a year
2014
numbers
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Microservices
on
AWS
(or, a sneak peek on some AWS microservices capabilities)
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
On
Demand Resources
No capacity guessing
Resources in any size
Parallel environments
Built-in features
Monitoring via CloudWatch
Security: IAM, CloudTrail,
KMS, CloudHSM
Logging: CloudWatch logs
Scalability: Auto-scaling, ELB,
S3
Availability: multiple regions,
AZs
Options
Standard services, standard
servers, your own servers,
managed services, no servers
Managed/Programmable
Services
Stop RIGHT NOW
If you are writing your own
Notification system
E-mail component
Search engine
Workflow engine
Queue
Transcoding system
Monitoring system
Managed/Programable
Infrastructure as code
Automatic/Programmable
provisioning from single
services to a full network
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Continuous Integration
Code
Build
Test
Continuous Deployment
Deploy
Provision
Monitor
AWS CodePipeline
AWS
OpsWorks
AWS
Code
Deploy
AWS Cloud
Formation
Amazon
ECS
AWS
Cloud
Watch
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Continuous Integration
Code
Build
Test
Continuous Deployment
Deploy
Provision
Monitor
AWS CodePipeline
AWS
OpsWorks
AWS
Code
Deploy
AWS Cloud
Formation
Amazon
ECS
AWS
Cloud
Watch
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
AWS CodeDeploy
AWS OpsWorks
Convenience
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Control
Typical
microservices architectures
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Microservices architectures
Content
Delivery
API
Layer
Elastic Load
Balancing
CloudFron
t
Application
Layer
Amazon
EC2
Elastic Load
Balancing
Persistency
Layer
Amazon
EC2
Amazon
RDS
Autoscaling
group
Autoscaling
group
Amazon
ElastiCache
Static content
Amazon
S3
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Microservices architectures
Content
Delivery
API
Layer
Application
Layer
Elastic Load
Balancing
CloudFron
t
Persistency
Layer
Amazon
EC2
Amazon
RDS
Amazon API
Gateway
Static content
Amazon
S3
Autoscaling
group
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Amazon
ElastiCache
Microservices architectures
Content
Delivery
API
Layer
Application
Layer
Elastic Load
Balancing
CloudFron
t
Persistency
Layer
EC2
Container
Service
Amazon
RDS
Amazon API
Gateway
Static content
Amazon
S3
Amazon
EC2
Amazon
ElastiCache
Autoscaling
group
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Microservices architectures
Content
Delivery
API
Layer
Application
Layer
Elastic Load
Balancing
CloudFron
t
Persistency
Layer
EC2
Container
Service
Amazon
DynamoDB
Amazon API
Gateway
Amazon
EC2
Static content
Amazon
S3
Autoscaling
group
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Single digit
millisecond
latency at any
scale
Highly
scalable
NoSQL
database
Microservices architectures
Content
Delivery
API
Layer
Application
Layer
Persistency
Layer
CloudFron
t
Lambda calls
Amazon API
Gateway
Static content
AWS
Lambda
Amazon
S3
Lambda
triggers
Serverles
s
First 1
million requests
computin
per month are free
$0.20 per 1g
million
requests thereafter
($0.0000002 per request)
Pay for 100ms units *
Memory size (charged
$0.00001667 for every
GB-second used).
https://aws.amazon.com/blogs/compute/microservices-without-the-s
ervers
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
Amazon
DynamoDB
Codeless computing
Amazon
CloudFront
Amazon API
Gateway
Amazon
DynamoDB
Amazon
S3
https://aws.amazon.com/blogs/compute/using-amazon-api-gateway-as-a-proxy-for-dynamodb/
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
A sample architecture
https://aws.amazon.com/solutions/case-studies/localytics/
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
AWS
Lambda
CloudWatch
logs
Amazon
Kinesis
Firehose
Amazon
Redshift
Amazon
QuickSight
Amazon
EC2
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
AWS
Lambda
CloudWatch
logs
Amazon
Elasticsearch
Service
Amazon
EC2
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
https://
www.youtube.com/watch?v=JWXoX50hWXA
https://www.youtube.com/watch?v=a45J6xAGUvA
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
https://www.youtube.com/watch?v=C4c0pkY4NgQ
https://www.youtube.com/watch?v=3e2YgLHKePI
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.
https://
www.youtube.com/watch?v=QuYNxoqz0oY
2016 Amazon Web Services, Inc. or its affiliates. All rights reserved. May not be copied, modified or distributed in whole or in part without the express consent.