SlideShare ist ein Scribd-Unternehmen logo
1 von 59
Downloaden Sie, um offline zu lesen
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
06.11.19
How to build a global
serverless service
Alex Casalboni
Technical Evangelist
Amazon Web Services
@alex_casalboni
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
About me
• Software Engineer & Web Developer
• Worked in a startup for 4.5 years
• ServerlessDays Organizer
• AWS Customer since 2013
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
How (and why) do we build
global serverless services?
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Some fundamentals first!
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Availability in parallel
A = 1 – (1 – Ax)2
Part X
Part X
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Availability in parallel
Component Availability Downtime
X 99% (2-nines) 3 days 15 hours
Two X in parallel 99.99% (4-nines) 52 minutes
Three X in parallel 99.9999% (6-nines) 31 seconds
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Component redundancy increases
availability significantly!
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
21 Geographic Regions
66 Availability Zones (AZs)
Upcoming: 4 regions and 12 AZs
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Region and availability zones
Region
Availability zone a Availability zone b Availability zone c
data center
data center
data center
data center
data center
data center
data center
data center
data center
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Multi-AZ
Region
Availability zone a Availability zone b Availability zone c
Application Application Application
ELB
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Multi-region
Region
Availability
zone a
Availability
zone b
Availability
zone c
Application
Region
Availability
zone a
Availability
zone b
Availability
zone c
Application Application Application ApplicationApplication
Route 53
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Serverless components
Region
Availability zone a Availability zone b Availability zone c
Serverless Services
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Why serverless components??
No provisioning,
no management
Pay for value
Fault Tolerant and
Automatic scaling
Highly available
and secure
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Why build a multi-region
active-active architecture?
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Improve latency for end-users
~300ms
~140ms
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Improve availability and disaster recovery
Applications in
US West
Applications in
US East
Users from
San Francisco
Users from
New York
Service 1
Service 2
Service 3
Service 4
Service 1
Service 2
Service 3
Service 4
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Prerequisites to building a
multi-region architecture
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
CAP Theorem
Consistency Availability Partition Tolerance
Data is consistent.
All nodes see the same state.
Every request is non-failing. Service still responds as expected
if some nodes crash.
Distributed System
In the presence of a network partition, you must
choose between consistency and availability!
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Embrace eventual consistency
… if no new updates are made to a
given data item, eventually all
accesses to that item will return the
last updated value.
Availability
An eventually consistent system can
return any value before it converges!!
https://en.wikipedia.org/wiki/Eventual_consistency
Distributed System
Every request is non-failing.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Secure and reliable global network
youtube.com/watch?v=AyOAjFNPAbA
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
How can you achieve data replication?
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Build high performance, globally distributed applications
Low latency reads & writes to locally available tables
Disaster proof with multi-region redundancy
Easy to set up and no application rewrites required
Globally dispersed users
Replica (N. America)
Replica (Europe)
Replica (Asia)
Global App
Global Table
Amazon DynamoDB Global Tables
Fully managed, multi-master, multi-region database
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Replicates your data with no impact on database performance
Typical cross-region replication latencies below 1 second
An Aurora cluster can recover in less than 1 minute even in
the event of a complete regional outage
Recovery Point Objective (RPO) of 1 second
Recovery Time Objective (RTO) of less than 1 minute
Amazon Aurora Global Database
Designed for globally distributed applications
Globally dispersed users
Replica (N. America)
Replica (Europe)
Replica (Asia)
Global App
Global Table
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Amazon S3 cross-region replication
S3 Bucket S3 Bucket
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
What about routing?
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Global routing with
Route 53
Route 53
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Latency based routing
RegionRegion
Application Application
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Geo-based routing
Region us-east-1Region us-west-2
Application Application
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Weighted round robin routing
Region us-east-1Region us-west-2
Application Application
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
DNS failover
Region us-east-1Region us-west-2
Application Application
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
AWS Global Accelerator
AWS Global Accelerator: Before and After
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Region eu-west-1
Region eu-central-1
Global Table
AWS Lambda
AWS Lambda
Amazon DynamoDB
Amazon DynamoDB
Amazon API Gateway
Amazon API Gateway
Amazon Route 53
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Region eu-west-1
Region eu-central-1
Global Table
Amazon DynamoDB
Amazon DynamoDB
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Region eu-west-1
Region eu-central-1
Global Table
AWS Lambda
AWS Lambda
Amazon DynamoDB
Amazon DynamoDB
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Region eu-west-1
Region eu-central-1
Global Table
AWS Lambda
AWS Lambda
Amazon DynamoDB
Amazon DynamoDB
Amazon API Gateway
Amazon API Gateway
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Region eu-west-1
Region eu-central-1
Global Table
AWS Lambda
AWS Lambda
Amazon DynamoDB
Amazon DynamoDB
Amazon API Gateway
Amazon API Gateway
Amazon Route 53
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Route53: Latency-based routing
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Let’s see it in action!
https://map.global.faas.website
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
A quick look at SLA’s
AWS Lambda: 99.95% (4h of downtime)
Amazon API Gateway: 99.95% (4h of downtime)
Amazon DynamoDB: 99.999% (5min of downtime)
Route 53: 100% (no downtime)
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Region eu-west-1
Region eu-central-1
AWS Lambda
AWS Lambda
Amazon DynamoDB
Amazon DynamoDB
Amazon API Gateway
Amazon API Gateway
Amazon Route 53
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Region eu-west-1
Region eu-central-1
99.95% 99.95% 99.999%
99.95% 99.95% 99.999%
100%
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Region eu-west-1
Region eu-central-1
99.899%
100%
99.95% 99.95% 99.999%
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Region eu-west-1
Region eu-central-1
99.899%
100% 99.9898%
(2 regions)
99.95% 99.95% 99.999%
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
With 1 region: 99.899% (9h of downtime)
With 2 regions: 99.9898% (1h of downtime)
With 3 regions: 99.999% (5min of downtime)
With 4 regions: 99.9999% (30s of downtime)
With 5 regions: 100% (no downtime)
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Want to read more?
bit.ly/adhorn-serverless-multi-region
Thank you!
© 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Alex Casalboni
@alex_casalboni

Weitere ähnliche Inhalte

Was ist angesagt?

Was ist angesagt? (19)

No Hassle NoSQL - Amazon DynamoDB & Amazon DocumentDB | AWS Summit Tel Aviv ...
 No Hassle NoSQL - Amazon DynamoDB & Amazon DocumentDB | AWS Summit Tel Aviv ... No Hassle NoSQL - Amazon DynamoDB & Amazon DocumentDB | AWS Summit Tel Aviv ...
No Hassle NoSQL - Amazon DynamoDB & Amazon DocumentDB | AWS Summit Tel Aviv ...
 
CI/CD best practices for building modern applications - MAD304 - Chicago AWS ...
CI/CD best practices for building modern applications - MAD304 - Chicago AWS ...CI/CD best practices for building modern applications - MAD304 - Chicago AWS ...
CI/CD best practices for building modern applications - MAD304 - Chicago AWS ...
 
Architecting Security & Governance Across Your AWS Landing Zone
Architecting Security & Governance Across Your AWS Landing ZoneArchitecting Security & Governance Across Your AWS Landing Zone
Architecting Security & Governance Across Your AWS Landing Zone
 
Scale CI/CD & Configuration Management Pipelines with Git, Amazon EFS, & SQS ...
Scale CI/CD & Configuration Management Pipelines with Git, Amazon EFS, & SQS ...Scale CI/CD & Configuration Management Pipelines with Git, Amazon EFS, & SQS ...
Scale CI/CD & Configuration Management Pipelines with Git, Amazon EFS, & SQS ...
 
Optimize your Machine Learning workloads | AWS Summit Tel Aviv 2019
Optimize your Machine Learning workloads  | AWS Summit Tel Aviv 2019Optimize your Machine Learning workloads  | AWS Summit Tel Aviv 2019
Optimize your Machine Learning workloads | AWS Summit Tel Aviv 2019
 
Predictive Scaling for More Responsive Applications (API330) - AWS re:Invent ...
Predictive Scaling for More Responsive Applications (API330) - AWS re:Invent ...Predictive Scaling for More Responsive Applications (API330) - AWS re:Invent ...
Predictive Scaling for More Responsive Applications (API330) - AWS re:Invent ...
 
Simplify Your Front End Apps with Serverless Backend in the Cloud.
Simplify Your Front End Apps with Serverless Backend in the Cloud.Simplify Your Front End Apps with Serverless Backend in the Cloud.
Simplify Your Front End Apps with Serverless Backend in the Cloud.
 
深探-IaC-(Infrastructure as Code-基礎設施即程式碼-)-在-AWS-上的應用
深探-IaC-(Infrastructure as Code-基礎設施即程式碼-)-在-AWS-上的應用深探-IaC-(Infrastructure as Code-基礎設施即程式碼-)-在-AWS-上的應用
深探-IaC-(Infrastructure as Code-基礎設施即程式碼-)-在-AWS-上的應用
 
Building an Augmented Reality Owner's Manual (AMT315) - AWS re:Invent 2018
Building an Augmented Reality Owner's Manual (AMT315) - AWS re:Invent 2018Building an Augmented Reality Owner's Manual (AMT315) - AWS re:Invent 2018
Building an Augmented Reality Owner's Manual (AMT315) - AWS re:Invent 2018
 
Twelve-Factor App Methodology and Modern Applications | AWS Summit Tel Aviv 2019
Twelve-Factor App Methodology and Modern Applications | AWS Summit Tel Aviv 2019Twelve-Factor App Methodology and Modern Applications | AWS Summit Tel Aviv 2019
Twelve-Factor App Methodology and Modern Applications | AWS Summit Tel Aviv 2019
 
Deep-Dive-with-Cloud-Monitoring-with-Amazon-EKS-and-Prometheus
Deep-Dive-with-Cloud-Monitoring-with-Amazon-EKS-and-PrometheusDeep-Dive-with-Cloud-Monitoring-with-Amazon-EKS-and-Prometheus
Deep-Dive-with-Cloud-Monitoring-with-Amazon-EKS-and-Prometheus
 
Breaking down the Monowhat
Breaking down the MonowhatBreaking down the Monowhat
Breaking down the Monowhat
 
Intro to AWS Lambda and Serverless Applications: re:Invent 2018 Recap at the ...
Intro to AWS Lambda and Serverless Applications: re:Invent 2018 Recap at the ...Intro to AWS Lambda and Serverless Applications: re:Invent 2018 Recap at the ...
Intro to AWS Lambda and Serverless Applications: re:Invent 2018 Recap at the ...
 
From Code to a running container | AWS Summit Tel Aviv 2019
From Code to a running container | AWS Summit Tel Aviv 2019From Code to a running container | AWS Summit Tel Aviv 2019
From Code to a running container | AWS Summit Tel Aviv 2019
 
Rapid API Prototyping Using Serverless Backend in the Cloud
Rapid API Prototyping Using Serverless Backend in the CloudRapid API Prototyping Using Serverless Backend in the Cloud
Rapid API Prototyping Using Serverless Backend in the Cloud
 
AWS 如何協助客戶建立 DevOps 流程
AWS 如何協助客戶建立 DevOps 流程AWS 如何協助客戶建立 DevOps 流程
AWS 如何協助客戶建立 DevOps 流程
 
Building a Multi-Region, Active-Active Serverless Backends.
Building a Multi-Region, Active-Active Serverless Backends.Building a Multi-Region, Active-Active Serverless Backends.
Building a Multi-Region, Active-Active Serverless Backends.
 
利用 AWS Step Functions 建構穩定的資料處理流程.pdf
利用 AWS Step Functions 建構穩定的資料處理流程.pdf利用 AWS Step Functions 建構穩定的資料處理流程.pdf
利用 AWS Step Functions 建構穩定的資料處理流程.pdf
 
Building Business Workflows with AWS Step Functions: re:Invent 2018 Recap at ...
Building Business Workflows with AWS Step Functions: re:Invent 2018 Recap at ...Building Business Workflows with AWS Step Functions: re:Invent 2018 Recap at ...
Building Business Workflows with AWS Step Functions: re:Invent 2018 Recap at ...
 

Ähnlich wie "How to build a global serverless service", Alex Casalboni, AWS Dev Day Kyiv 2019 "

Building Global Serverless Backends powered by Amazon DynamoDB Global Tables
Building Global Serverless Backends powered by Amazon DynamoDB Global TablesBuilding Global Serverless Backends powered by Amazon DynamoDB Global Tables
Building Global Serverless Backends powered by Amazon DynamoDB Global Tables
Amazon Web Services
 

Ähnlich wie "How to build a global serverless service", Alex Casalboni, AWS Dev Day Kyiv 2019 " (20)

AWS DevDay Berlin 2019 - Going Global With Serverless
AWS DevDay Berlin 2019 - Going Global With ServerlessAWS DevDay Berlin 2019 - Going Global With Serverless
AWS DevDay Berlin 2019 - Going Global With Serverless
 
BuildingGlobalServices_DevDays2019.pdf
BuildingGlobalServices_DevDays2019.pdfBuildingGlobalServices_DevDays2019.pdf
BuildingGlobalServices_DevDays2019.pdf
 
BuildingGlobalServices_DevDays2019.pdf
BuildingGlobalServices_DevDays2019.pdfBuildingGlobalServices_DevDays2019.pdf
BuildingGlobalServices_DevDays2019.pdf
 
AWS DevDay Vienna - Resiliency and availability design patterns for the cloud
AWS DevDay Vienna - Resiliency and availability design patterns for the cloudAWS DevDay Vienna - Resiliency and availability design patterns for the cloud
AWS DevDay Vienna - Resiliency and availability design patterns for the cloud
 
AWS DevDay Cologne - Resiliency and availability design patterns for the cloud
AWS DevDay Cologne - Resiliency and availability design patterns for the cloudAWS DevDay Cologne - Resiliency and availability design patterns for the cloud
AWS DevDay Cologne - Resiliency and availability design patterns for the cloud
 
AWS DevDay Berlin - Resiliency and availability design patterns for the cloud
AWS DevDay Berlin - Resiliency and availability design patterns for the cloudAWS DevDay Berlin - Resiliency and availability design patterns for the cloud
AWS DevDay Berlin - Resiliency and availability design patterns for the cloud
 
Building Global Multi-Region, Active-Active Serverless Backends
Building Global Multi-Region, Active-Active Serverless Backends Building Global Multi-Region, Active-Active Serverless Backends
Building Global Multi-Region, Active-Active Serverless Backends
 
PatternsResiliency_DevDays2019.pdf
PatternsResiliency_DevDays2019.pdfPatternsResiliency_DevDays2019.pdf
PatternsResiliency_DevDays2019.pdf
 
PatternsResiliency_DevDays2019.pdf
PatternsResiliency_DevDays2019.pdfPatternsResiliency_DevDays2019.pdf
PatternsResiliency_DevDays2019.pdf
 
Resiliency-and-Availability-Design-Patterns-for-the-Cloud
Resiliency-and-Availability-Design-Patterns-for-the-CloudResiliency-and-Availability-Design-Patterns-for-the-Cloud
Resiliency-and-Availability-Design-Patterns-for-the-Cloud
 
"Resiliency and Availability Design Patterns for the Cloud", Sebastien Storma...
"Resiliency and Availability Design Patterns for the Cloud", Sebastien Storma..."Resiliency and Availability Design Patterns for the Cloud", Sebastien Storma...
"Resiliency and Availability Design Patterns for the Cloud", Sebastien Storma...
 
Architecture Patterns for Multi-Region Active-Active Applications (ARC209-R2)...
Architecture Patterns for Multi-Region Active-Active Applications (ARC209-R2)...Architecture Patterns for Multi-Region Active-Active Applications (ARC209-R2)...
Architecture Patterns for Multi-Region Active-Active Applications (ARC209-R2)...
 
Making s3 more resilient using lambda@edge
Making s3 more resilient using lambda@edgeMaking s3 more resilient using lambda@edge
Making s3 more resilient using lambda@edge
 
Tools for building your Startup on AWS
Tools for building your Startup on AWSTools for building your Startup on AWS
Tools for building your Startup on AWS
 
Best Practices for Building Multi-Region, Active-Active Serverless Applicatio...
Best Practices for Building Multi-Region, Active-Active Serverless Applicatio...Best Practices for Building Multi-Region, Active-Active Serverless Applicatio...
Best Practices for Building Multi-Region, Active-Active Serverless Applicatio...
 
Introduction to AWS Global Accelerator - SVC211 - Chicago AWS Summit
Introduction to AWS Global Accelerator - SVC211 - Chicago AWS SummitIntroduction to AWS Global Accelerator - SVC211 - Chicago AWS Summit
Introduction to AWS Global Accelerator - SVC211 - Chicago AWS Summit
 
Building Global Multi-Region, Active-Active Serverless Backends I AWS Dev Day...
Building Global Multi-Region, Active-Active Serverless Backends I AWS Dev Day...Building Global Multi-Region, Active-Active Serverless Backends I AWS Dev Day...
Building Global Multi-Region, Active-Active Serverless Backends I AWS Dev Day...
 
Migliora la disponibilità e le prestazioni delle tue applicazioni con Amazon ...
Migliora la disponibilità e le prestazioni delle tue applicazioni con Amazon ...Migliora la disponibilità e le prestazioni delle tue applicazioni con Amazon ...
Migliora la disponibilità e le prestazioni delle tue applicazioni con Amazon ...
 
Building Global Serverless Backends powered by Amazon DynamoDB Global Tables
Building Global Serverless Backends powered by Amazon DynamoDB Global TablesBuilding Global Serverless Backends powered by Amazon DynamoDB Global Tables
Building Global Serverless Backends powered by Amazon DynamoDB Global Tables
 
How to build scalable and resilient applications in the cloud - AWS Summit Ca...
How to build scalable and resilient applications in the cloud - AWS Summit Ca...How to build scalable and resilient applications in the cloud - AWS Summit Ca...
How to build scalable and resilient applications in the cloud - AWS Summit Ca...
 

Mehr von Provectus

AI Stack on AWS: Amazon SageMaker and Beyond
AI Stack on AWS: Amazon SageMaker and BeyondAI Stack on AWS: Amazon SageMaker and Beyond
AI Stack on AWS: Amazon SageMaker and Beyond
Provectus
 
Feature Store as a Data Foundation for Machine Learning
Feature Store as a Data Foundation for Machine LearningFeature Store as a Data Foundation for Machine Learning
Feature Store as a Data Foundation for Machine Learning
Provectus
 
MLOps and Reproducible ML on AWS with Kubeflow and SageMaker
MLOps and Reproducible ML on AWS with Kubeflow and SageMakerMLOps and Reproducible ML on AWS with Kubeflow and SageMaker
MLOps and Reproducible ML on AWS with Kubeflow and SageMaker
Provectus
 

Mehr von Provectus (20)

Choosing the right IDP Solution
Choosing the right IDP SolutionChoosing the right IDP Solution
Choosing the right IDP Solution
 
Intelligent Document Processing in Healthcare. Choosing the Right Solutions.
Intelligent Document Processing in Healthcare. Choosing the Right Solutions.Intelligent Document Processing in Healthcare. Choosing the Right Solutions.
Intelligent Document Processing in Healthcare. Choosing the Right Solutions.
 
Choosing the Right Document Processing Solution for Healthcare Organizations
Choosing the Right Document Processing Solution for Healthcare OrganizationsChoosing the Right Document Processing Solution for Healthcare Organizations
Choosing the Right Document Processing Solution for Healthcare Organizations
 
MLOps and Data Quality: Deploying Reliable ML Models in Production
MLOps and Data Quality: Deploying Reliable ML Models in ProductionMLOps and Data Quality: Deploying Reliable ML Models in Production
MLOps and Data Quality: Deploying Reliable ML Models in Production
 
AI Stack on AWS: Amazon SageMaker and Beyond
AI Stack on AWS: Amazon SageMaker and BeyondAI Stack on AWS: Amazon SageMaker and Beyond
AI Stack on AWS: Amazon SageMaker and Beyond
 
Feature Store as a Data Foundation for Machine Learning
Feature Store as a Data Foundation for Machine LearningFeature Store as a Data Foundation for Machine Learning
Feature Store as a Data Foundation for Machine Learning
 
MLOps and Reproducible ML on AWS with Kubeflow and SageMaker
MLOps and Reproducible ML on AWS with Kubeflow and SageMakerMLOps and Reproducible ML on AWS with Kubeflow and SageMaker
MLOps and Reproducible ML on AWS with Kubeflow and SageMaker
 
Cost Optimization for Apache Hadoop/Spark Workloads with Amazon EMR
Cost Optimization for Apache Hadoop/Spark Workloads with Amazon EMRCost Optimization for Apache Hadoop/Spark Workloads with Amazon EMR
Cost Optimization for Apache Hadoop/Spark Workloads with Amazon EMR
 
ODSC webinar "Kubeflow, MLFlow and Beyond — augmenting ML delivery" Stepan Pu...
ODSC webinar "Kubeflow, MLFlow and Beyond — augmenting ML delivery" Stepan Pu...ODSC webinar "Kubeflow, MLFlow and Beyond — augmenting ML delivery" Stepan Pu...
ODSC webinar "Kubeflow, MLFlow and Beyond — augmenting ML delivery" Stepan Pu...
 
"Automating AWS Infrastructure with PowerShell", Martin Beeby, AWS Dev Day Ky...
"Automating AWS Infrastructure with PowerShell", Martin Beeby, AWS Dev Day Ky..."Automating AWS Infrastructure with PowerShell", Martin Beeby, AWS Dev Day Ky...
"Automating AWS Infrastructure with PowerShell", Martin Beeby, AWS Dev Day Ky...
 
"Analyzing your web and application logs", Javier Ramirez, AWS Dev Day Kyiv 2...
"Analyzing your web and application logs", Javier Ramirez, AWS Dev Day Kyiv 2..."Analyzing your web and application logs", Javier Ramirez, AWS Dev Day Kyiv 2...
"Analyzing your web and application logs", Javier Ramirez, AWS Dev Day Kyiv 2...
 
"Architecting SaaS solutions on AWS", Oleksandr Mykhalchuk, AWS Dev Day Kyiv ...
"Architecting SaaS solutions on AWS", Oleksandr Mykhalchuk, AWS Dev Day Kyiv ..."Architecting SaaS solutions on AWS", Oleksandr Mykhalchuk, AWS Dev Day Kyiv ...
"Architecting SaaS solutions on AWS", Oleksandr Mykhalchuk, AWS Dev Day Kyiv ...
 
"Developing with .NET Core on AWS", Martin Beeby, AWS Dev Day Kyiv 2019
"Developing with .NET Core on AWS", Martin Beeby, AWS Dev Day Kyiv 2019"Developing with .NET Core on AWS", Martin Beeby, AWS Dev Day Kyiv 2019
"Developing with .NET Core on AWS", Martin Beeby, AWS Dev Day Kyiv 2019
 
"How to build real-time backends", Martin Beeby, AWS Dev Day Kyiv 2019
"How to build real-time backends", Martin Beeby, AWS Dev Day Kyiv 2019"How to build real-time backends", Martin Beeby, AWS Dev Day Kyiv 2019
"How to build real-time backends", Martin Beeby, AWS Dev Day Kyiv 2019
 
"Scaling ML from 0 to millions of users", Julien Simon, AWS Dev Day Kyiv 2019
"Scaling ML from 0 to millions of users", Julien Simon, AWS Dev Day Kyiv 2019"Scaling ML from 0 to millions of users", Julien Simon, AWS Dev Day Kyiv 2019
"Scaling ML from 0 to millions of users", Julien Simon, AWS Dev Day Kyiv 2019
 
How to implement authorization in your backend with AWS IAM
How to implement authorization in your backend with AWS IAMHow to implement authorization in your backend with AWS IAM
How to implement authorization in your backend with AWS IAM
 
Yurii Gavrilin | ML Interpretability: From A to Z | Kazan ODSC Meetup
Yurii Gavrilin | ML Interpretability: From A to Z | Kazan ODSC MeetupYurii Gavrilin | ML Interpretability: From A to Z | Kazan ODSC Meetup
Yurii Gavrilin | ML Interpretability: From A to Z | Kazan ODSC Meetup
 
Andrei Grigoriev | Version Control in Data Science | Kazan ODSC Meetup
Andrei Grigoriev | Version Control in Data Science | Kazan ODSC MeetupAndrei Grigoriev | Version Control in Data Science | Kazan ODSC Meetup
Andrei Grigoriev | Version Control in Data Science | Kazan ODSC Meetup
 
Modern word embeddings | Andrei Kulagin | Kazan ODSC Meetup
Modern word embeddings | Andrei Kulagin | Kazan ODSC MeetupModern word embeddings | Andrei Kulagin | Kazan ODSC Meetup
Modern word embeddings | Andrei Kulagin | Kazan ODSC Meetup
 
Eva Sokolyanskaya, QA Stand Up: Episode 4
Eva Sokolyanskaya, QA Stand Up: Episode 4Eva Sokolyanskaya, QA Stand Up: Episode 4
Eva Sokolyanskaya, QA Stand Up: Episode 4
 

Kürzlich hochgeladen

Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...
Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...
Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...
amitlee9823
 
Call Girls Bommasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Bommasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...Call Girls Bommasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Bommasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
amitlee9823
 
Call Girls Jalahalli Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...
Call Girls Jalahalli Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...Call Girls Jalahalli Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...
Call Girls Jalahalli Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...
amitlee9823
 
Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...
Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...
Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...
amitlee9823
 
Abortion pills in Doha Qatar (+966572737505 ! Get Cytotec
Abortion pills in Doha Qatar (+966572737505 ! Get CytotecAbortion pills in Doha Qatar (+966572737505 ! Get Cytotec
Abortion pills in Doha Qatar (+966572737505 ! Get Cytotec
Abortion pills in Riyadh +966572737505 get cytotec
 
Al Barsha Escorts $#$ O565212860 $#$ Escort Service In Al Barsha
Al Barsha Escorts $#$ O565212860 $#$ Escort Service In Al BarshaAl Barsha Escorts $#$ O565212860 $#$ Escort Service In Al Barsha
Al Barsha Escorts $#$ O565212860 $#$ Escort Service In Al Barsha
AroojKhan71
 
Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...
Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...
Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...
amitlee9823
 
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service BangaloreCall Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
amitlee9823
 

Kürzlich hochgeladen (20)

Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...
Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...
Mg Road Call Girls Service: 🍓 7737669865 🍓 High Profile Model Escorts | Banga...
 
Accredited-Transport-Cooperatives-Jan-2021-Web.pdf
Accredited-Transport-Cooperatives-Jan-2021-Web.pdfAccredited-Transport-Cooperatives-Jan-2021-Web.pdf
Accredited-Transport-Cooperatives-Jan-2021-Web.pdf
 
Smarteg dropshipping via API with DroFx.pptx
Smarteg dropshipping via API with DroFx.pptxSmarteg dropshipping via API with DroFx.pptx
Smarteg dropshipping via API with DroFx.pptx
 
Call Girls Bommasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Bommasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...Call Girls Bommasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
Call Girls Bommasandra Just Call 👗 7737669865 👗 Top Class Call Girl Service B...
 
Call Girls Jalahalli Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...
Call Girls Jalahalli Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...Call Girls Jalahalli Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...
Call Girls Jalahalli Just Call 👗 7737669865 👗 Top Class Call Girl Service Ban...
 
Predicting Loan Approval: A Data Science Project
Predicting Loan Approval: A Data Science ProjectPredicting Loan Approval: A Data Science Project
Predicting Loan Approval: A Data Science Project
 
Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...
Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...
Vip Mumbai Call Girls Marol Naka Call On 9920725232 With Body to body massage...
 
Abortion pills in Doha Qatar (+966572737505 ! Get Cytotec
Abortion pills in Doha Qatar (+966572737505 ! Get CytotecAbortion pills in Doha Qatar (+966572737505 ! Get Cytotec
Abortion pills in Doha Qatar (+966572737505 ! Get Cytotec
 
ELKO dropshipping via API with DroFx.pptx
ELKO dropshipping via API with DroFx.pptxELKO dropshipping via API with DroFx.pptx
ELKO dropshipping via API with DroFx.pptx
 
BabyOno dropshipping via API with DroFx.pptx
BabyOno dropshipping via API with DroFx.pptxBabyOno dropshipping via API with DroFx.pptx
BabyOno dropshipping via API with DroFx.pptx
 
Al Barsha Escorts $#$ O565212860 $#$ Escort Service In Al Barsha
Al Barsha Escorts $#$ O565212860 $#$ Escort Service In Al BarshaAl Barsha Escorts $#$ O565212860 $#$ Escort Service In Al Barsha
Al Barsha Escorts $#$ O565212860 $#$ Escort Service In Al Barsha
 
Week-01-2.ppt BBB human Computer interaction
Week-01-2.ppt BBB human Computer interactionWeek-01-2.ppt BBB human Computer interaction
Week-01-2.ppt BBB human Computer interaction
 
Carero dropshipping via API with DroFx.pptx
Carero dropshipping via API with DroFx.pptxCarero dropshipping via API with DroFx.pptx
Carero dropshipping via API with DroFx.pptx
 
Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...
Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...
Chintamani Call Girls: 🍓 7737669865 🍓 High Profile Model Escorts | Bangalore ...
 
Ravak dropshipping via API with DroFx.pptx
Ravak dropshipping via API with DroFx.pptxRavak dropshipping via API with DroFx.pptx
Ravak dropshipping via API with DroFx.pptx
 
Cheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 night
Cheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 nightCheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 night
Cheap Rate Call girls Sarita Vihar Delhi 9205541914 shot 1500 night
 
Call me @ 9892124323 Cheap Rate Call Girls in Vashi with Real Photo 100% Secure
Call me @ 9892124323  Cheap Rate Call Girls in Vashi with Real Photo 100% SecureCall me @ 9892124323  Cheap Rate Call Girls in Vashi with Real Photo 100% Secure
Call me @ 9892124323 Cheap Rate Call Girls in Vashi with Real Photo 100% Secure
 
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service BangaloreCall Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
Call Girls Begur Just Call 👗 7737669865 👗 Top Class Call Girl Service Bangalore
 
Invezz.com - Grow your wealth with trading signals
Invezz.com - Grow your wealth with trading signalsInvezz.com - Grow your wealth with trading signals
Invezz.com - Grow your wealth with trading signals
 
Digital Advertising Lecture for Advanced Digital & Social Media Strategy at U...
Digital Advertising Lecture for Advanced Digital & Social Media Strategy at U...Digital Advertising Lecture for Advanced Digital & Social Media Strategy at U...
Digital Advertising Lecture for Advanced Digital & Social Media Strategy at U...
 

"How to build a global serverless service", Alex Casalboni, AWS Dev Day Kyiv 2019 "

  • 1. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. 06.11.19 How to build a global serverless service Alex Casalboni Technical Evangelist Amazon Web Services @alex_casalboni
  • 2. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. About me • Software Engineer & Web Developer • Worked in a startup for 4.5 years • ServerlessDays Organizer • AWS Customer since 2013
  • 3.
  • 4. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. How (and why) do we build global serverless services?
  • 5. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Some fundamentals first!
  • 6. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Availability in parallel A = 1 – (1 – Ax)2 Part X Part X
  • 7. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Availability in parallel Component Availability Downtime X 99% (2-nines) 3 days 15 hours Two X in parallel 99.99% (4-nines) 52 minutes Three X in parallel 99.9999% (6-nines) 31 seconds
  • 8. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Component redundancy increases availability significantly!
  • 9. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. 21 Geographic Regions 66 Availability Zones (AZs) Upcoming: 4 regions and 12 AZs
  • 10. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. AWS Region and availability zones Region Availability zone a Availability zone b Availability zone c data center data center data center data center data center data center data center data center data center
  • 11. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Multi-AZ Region Availability zone a Availability zone b Availability zone c Application Application Application ELB
  • 12. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Multi-region Region Availability zone a Availability zone b Availability zone c Application Region Availability zone a Availability zone b Availability zone c Application Application Application ApplicationApplication Route 53
  • 13. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Serverless components Region Availability zone a Availability zone b Availability zone c Serverless Services
  • 14. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Why serverless components?? No provisioning, no management Pay for value Fault Tolerant and Automatic scaling Highly available and secure
  • 15. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Why build a multi-region active-active architecture?
  • 16. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Improve latency for end-users ~300ms ~140ms
  • 17. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Improve availability and disaster recovery Applications in US West Applications in US East Users from San Francisco Users from New York Service 1 Service 2 Service 3 Service 4 Service 1 Service 2 Service 3 Service 4
  • 18. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Prerequisites to building a multi-region architecture
  • 19. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. CAP Theorem Consistency Availability Partition Tolerance Data is consistent. All nodes see the same state. Every request is non-failing. Service still responds as expected if some nodes crash. Distributed System In the presence of a network partition, you must choose between consistency and availability!
  • 20. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Embrace eventual consistency … if no new updates are made to a given data item, eventually all accesses to that item will return the last updated value. Availability An eventually consistent system can return any value before it converges!! https://en.wikipedia.org/wiki/Eventual_consistency Distributed System Every request is non-failing.
  • 21. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Secure and reliable global network youtube.com/watch?v=AyOAjFNPAbA
  • 22. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. How can you achieve data replication?
  • 23. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Build high performance, globally distributed applications Low latency reads & writes to locally available tables Disaster proof with multi-region redundancy Easy to set up and no application rewrites required Globally dispersed users Replica (N. America) Replica (Europe) Replica (Asia) Global App Global Table Amazon DynamoDB Global Tables Fully managed, multi-master, multi-region database
  • 24. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Replicates your data with no impact on database performance Typical cross-region replication latencies below 1 second An Aurora cluster can recover in less than 1 minute even in the event of a complete regional outage Recovery Point Objective (RPO) of 1 second Recovery Time Objective (RTO) of less than 1 minute Amazon Aurora Global Database Designed for globally distributed applications Globally dispersed users Replica (N. America) Replica (Europe) Replica (Asia) Global App Global Table
  • 25. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Amazon S3 cross-region replication S3 Bucket S3 Bucket
  • 26. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. What about routing?
  • 27. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Global routing with Route 53 Route 53
  • 28. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Latency based routing RegionRegion Application Application
  • 29. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Geo-based routing Region us-east-1Region us-west-2 Application Application
  • 30. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Weighted round robin routing Region us-east-1Region us-west-2 Application Application
  • 31. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. DNS failover Region us-east-1Region us-west-2 Application Application
  • 32. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. AWS Global Accelerator
  • 33. AWS Global Accelerator: Before and After
  • 34. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  • 35. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Region eu-west-1 Region eu-central-1 Global Table AWS Lambda AWS Lambda Amazon DynamoDB Amazon DynamoDB Amazon API Gateway Amazon API Gateway Amazon Route 53
  • 36. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Region eu-west-1 Region eu-central-1 Global Table Amazon DynamoDB Amazon DynamoDB
  • 37. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  • 38. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  • 39. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  • 40. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  • 41. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  • 42. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Region eu-west-1 Region eu-central-1 Global Table AWS Lambda AWS Lambda Amazon DynamoDB Amazon DynamoDB
  • 43. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  • 44. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Region eu-west-1 Region eu-central-1 Global Table AWS Lambda AWS Lambda Amazon DynamoDB Amazon DynamoDB Amazon API Gateway Amazon API Gateway
  • 45. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  • 46. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  • 47. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Region eu-west-1 Region eu-central-1 Global Table AWS Lambda AWS Lambda Amazon DynamoDB Amazon DynamoDB Amazon API Gateway Amazon API Gateway Amazon Route 53
  • 48. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Route53: Latency-based routing
  • 49. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Let’s see it in action! https://map.global.faas.website
  • 50. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  • 51. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. A quick look at SLA’s AWS Lambda: 99.95% (4h of downtime) Amazon API Gateway: 99.95% (4h of downtime) Amazon DynamoDB: 99.999% (5min of downtime) Route 53: 100% (no downtime)
  • 52. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Region eu-west-1 Region eu-central-1 AWS Lambda AWS Lambda Amazon DynamoDB Amazon DynamoDB Amazon API Gateway Amazon API Gateway Amazon Route 53
  • 53. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Region eu-west-1 Region eu-central-1 99.95% 99.95% 99.999% 99.95% 99.95% 99.999% 100%
  • 54. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Region eu-west-1 Region eu-central-1 99.899% 100% 99.95% 99.95% 99.999%
  • 55. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Region eu-west-1 Region eu-central-1 99.899% 100% 99.9898% (2 regions) 99.95% 99.95% 99.999%
  • 56. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. With 1 region: 99.899% (9h of downtime) With 2 regions: 99.9898% (1h of downtime) With 3 regions: 99.999% (5min of downtime) With 4 regions: 99.9999% (30s of downtime) With 5 regions: 100% (no downtime)
  • 57. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved.
  • 58. © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Want to read more? bit.ly/adhorn-serverless-multi-region
  • 59. Thank you! © 2019, Amazon Web Services, Inc. or its affiliates. All rights reserved. Alex Casalboni @alex_casalboni