SlideShare ist ein Scribd-Unternehmen logo
1 von 37
Downloaden Sie, um offline zu lesen
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Architecting Next Generation Serverless SaaS
Solutions on AWS
Tod Golding
Partner Solutions Architect
Amazon Web Services
A R C 3 2 4
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
SaaS and serverless: a natural fit
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
No more over-provisioning
Tenants Tenant consumptionCost, scale, performance
Consumption Time
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
High level serverless SaaS architecture
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Shared onboarding services
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Serverless authentication and authorization
Amazon
CognitoTenant
JWT token
(user, tenant, role)
Validate tenant,
user, role access
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Tenant throttling strategies
Tenant 1
(Standard Tier)
Tenant 2
(Professional Tier)
Tenant 3
(Premium Tier)
API key(s)
Usage plan
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Compute isolation and serverless
EC2 Instances
EC2 silo model
Tenant 2Tenant 1
ECS Cluster
Tenant 1 Tenant 2
ECS silo model
EC2 Instances
ECS Cluster
How do these
map to serverless?
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Tenant isolation with siloes
Tenant 1 Tenant 2
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Tenant isolation with policies
Tenant 2Tenant 1
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Tenant isolation with tokens
Tenant 1 Tenant 2
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Wrapper-based isolation
var lambdaFunc = require('myModule/mymod.js’);
var lambda = require('lambda-wrapper').wrap(lambdaFunc);
lambda.run(event, function(err, data) {
if (err) {
... handle error
}
... process data returned by the Lambda function
})
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
The good news
Tenant 1 Tenant 2
Tenant 2Tenant 1
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Serverless application services
TenantID Name
Tenant-1 Jane Doe
Tenant-4 Mike Doe
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
A different scaling mindset
GetOrder()
UpdateOrder()
DeleteOrder()
GetOrder() GetOrder()
UpdateOrder()
Scale
Policy
Policy
Order
Management
Service
Order
Management
Service
Order
Management
Service
Order
Management
Service
POST /orders/712
PUT /orders/42
DELETE /orders/651
GET /orders
Scale
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Hiding away multi-tenant awareness
Multi-tenant data access
Metering&
analytics
Logging
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Flowing tenant context through services
Tenant
Token
Token (HTTP headers)
Metering
Logging
Data Access
Token
Tenant 1 Tenant 2
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
State residue for functions
Tenant 1
1
2
Tenant 2
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Serverless and SaaS agility
Scheduled Maintenance
Friday, April 1, 11:00-12:00PM
The system will be down for maintenance this
evening. We apologize for any inconvenience this
may cause.
Close
Achieving zero-downtime on SaaS requires
• Ability to deploy small, decoupled units of functionality
• A strategy that expects and embraces fault tolerance
• A well-defined mechanism for staging and releasing new features
• An approach that enables continual and frequent releases
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Can’t get much smaller than this
Commit
Unit
Test
System
Test
QA Staging Prod
Commit
Unit
Test
System
Test
QA Staging Prod
Commit
Unit
Test
System
Test
QA Staging Prod
GetOrder()
CreateOrder()
UpdateOrder()
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Smaller blast radius = better fault tolerance
• Finer grained functions promote more refined fault tolerance
• More opportunities for implement fallback strategies
• Less exposure and visibility when a service fails
• Greater resilience translates into greater agility
Catalog
Ratings
Checkout
Taxation
CrossSell
Cart
Search
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Servers impact SaaS storage
db.m4.large
db.m4.16xlarge
db.m4.4xlarge
Tenants
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Strategies for addressing compute size
Over provisioning
Load-driven resizing
Tenant 1 Tenant 2
Tenant 1
Tenant 1
Tenant 1
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Pooled storage compute challenges
TenantID Name StartDate
Tenant-1 Jane Doe 01-12-2012
Tenant-4 John Doe 09-01-2015
Tenant-9 Mary Smith 11-04-2017SaaS
Database
Customer table
Tenant 1
Tenants can rapidly saturate and instance
Tenant 2
Tenant 3
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
On-demand sizing with Amazon Aurora Serverless
Proxy fleet
Instance Instance Instance
Aurora instances
Application
Storage Storage Storage
• Remove the notion of servers/instances
• All data is kept in highly available
storage volume
• Application talks to a MySQL
compatible endpoint
• Fleet of proxy servers manage, queue
and route database traffic
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Leveraging pooled instances
Instance Instance Instance
Aurora instances
Warm instance pool
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Data partitioning with Amazon Aurora Serverless
Instance
Aurora instance
Tenant 1
Instance
Aurora instance
Tenant 1 Tenant 2
Instance
Aurora instance
Tenant 2
Warm instance pool
Silo partitioning Pool partitioning
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Full stack serverless SaaS
Amazon API Gateway
Aurora Serverless Storage
Tenant 1 Tenant 2
• Brings serverless to relational environments
• Isolation of compute and storage with no
idle costs
• Simplified management and deployment
• Less operational focus on tuning and sizing
policies
• More focus on your application IP
Tenant 1 Tenant 2
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Where does AWS Fargate fit?
Fargate cluster
Tenant 1 Tenant 2
• A more coarse-grained view of serverless
• Often fits the developer mental model
• Can represent a more natural transition for
legacy systems
Tenant 3
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Takeaways
• Use serverless to focus more attention on your IP
• Find the isolation balance that best suits your domain
• Tenant load profile should influence service decomposition
• Find the logical services for data encapsulation
• Consider extending the reach of serverless to storage
• Use serverless DevOps to simplify your zero downtime store
• Serverless and SaaS are a natural match
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Additional SaaS Breakouts
Monday, 11/26
GPSTEC3-2 - SaaS Reference Architectures: A Review of Real World Patterns and Strategies
6:15 PM | Venetian, Level 2, Venetian Theater
Tuesday, 11/27
ARC324 - Architecting Next Generation Serverless SaaS Solutions on AWS (Repeat)
4:00 PM | Venetian, Level 2, Titian 2204
Thursday, 11/29
ARC418 Deconstructing SaaS: Deep Dive into Building Multi-Tenant Solutions on AWS (Repeat)
4:00 PM | Aria, Aria West, Level 3, Ironwood 5
Wednesday, 11/28
ARC418 Deconstructing SaaS: Deep Dive into Building Multi-Tenant Solutions on AWS
12:15 PM | Mirage, Mirage Event Center B
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
SaaS Chalk Talks
Monday, 11/26
ARC216 - SaaS Operations: The Foundation of SaaS Agility
11:30 – 12:30 | Venetian, Level 2, Veronese 2406
Tuesday, 11/27
ARC210 - SaaS Jumpstart: A Primer for Launching Your SaaS Journey
9:15 – 10:15 | Venetian, Level 4, Lando 4304
Wednesday, 11/28
ARC419 – Optimizing Your SaaS Solutions on AWS
1:00 – 2:00 | Venetian, Level 3, Murano 3202
ARC326 - Migrating Single-Tenant Applications to Multi-Tenant SaaS
4:00 – 5:00 | Aria West, Level 3, Starvine 7
ARC210 - SaaS Jumpstart: A Primer for Launching Your SaaS Journey
1:45 – 2:45 | Aria West, Level 3, Ironwood 8
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
SaaS Chalk Talks
Thursday, 11/29
ARC210 - SaaS Jumpstart: A Primer for Launching Your SaaS Journey
1:45 – 2:45 | MGM, Level 1, South Concourse 105
Friday, 11/30
ARC326 – Migrating Single-Tenant Applications to Multi-Tenant SaaS
10:00 – 11:00 | MGM, Level 1, South Concourse 105
ARC419 – Optimizing Your SaaS Architecture on AWS
1:00 – 2:00 | Venetian, Level 3, Murano 3202
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
SaaS Workshops
Monday, 11/26
Hands-on SaaS: Constructing Multi-Tenant Solutions on AWS
4:00 – 6:15 PM | Mirage, Mirage Event Center C3
Friday, 11/30
Hands-on SaaS: Constructing Multi-Tenant Solutions on AWS
9:15 AM – 11:30 AM | Mirage, Mirage Event Center C2
Thank you!
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Tod Golding
todg@amazon.com
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.

Weitere ähnliche Inhalte

Was ist angesagt?

Was ist angesagt? (20)

[NEW LAUNCH!] AWS Transit Gateway and Transit VPCs - Reference Architectures ...
[NEW LAUNCH!] AWS Transit Gateway and Transit VPCs - Reference Architectures ...[NEW LAUNCH!] AWS Transit Gateway and Transit VPCs - Reference Architectures ...
[NEW LAUNCH!] AWS Transit Gateway and Transit VPCs - Reference Architectures ...
 
PrivateLink for Partners: Connectivity, Scale, Security (GPSTEC306) - AWS re:...
PrivateLink for Partners: Connectivity, Scale, Security (GPSTEC306) - AWS re:...PrivateLink for Partners: Connectivity, Scale, Security (GPSTEC306) - AWS re:...
PrivateLink for Partners: Connectivity, Scale, Security (GPSTEC306) - AWS re:...
 
AWS, I Choose You: Pokemon's Battle against the Bots (SEC402-R1) - AWS re:Inv...
AWS, I Choose You: Pokemon's Battle against the Bots (SEC402-R1) - AWS re:Inv...AWS, I Choose You: Pokemon's Battle against the Bots (SEC402-R1) - AWS re:Inv...
AWS, I Choose You: Pokemon's Battle against the Bots (SEC402-R1) - AWS re:Inv...
 
Serverless Architectural Patterns I AWS Dev Day 2018
Serverless Architectural Patterns I AWS Dev Day 2018Serverless Architectural Patterns I AWS Dev Day 2018
Serverless Architectural Patterns I AWS Dev Day 2018
 
Architecting ASP.NET Core Microservices Applications on AWS (WIN401) - AWS re...
Architecting ASP.NET Core Microservices Applications on AWS (WIN401) - AWS re...Architecting ASP.NET Core Microservices Applications on AWS (WIN401) - AWS re...
Architecting ASP.NET Core Microservices Applications on AWS (WIN401) - AWS re...
 
SID305 AWS Certificate Manager Private CA
SID305 AWS Certificate Manager Private CASID305 AWS Certificate Manager Private CA
SID305 AWS Certificate Manager Private CA
 
Data Design and Modeling for Microservices I AWS Dev Day 2018
Data Design and Modeling for Microservices I AWS Dev Day 2018Data Design and Modeling for Microservices I AWS Dev Day 2018
Data Design and Modeling for Microservices I AWS Dev Day 2018
 
AWS Certificate Management and Private Certificate Authority Deep Dive (SEC41...
AWS Certificate Management and Private Certificate Authority Deep Dive (SEC41...AWS Certificate Management and Private Certificate Authority Deep Dive (SEC41...
AWS Certificate Management and Private Certificate Authority Deep Dive (SEC41...
 
Containers State of the Union I AWS Dev Day 2018
Containers State of the Union I AWS Dev Day 2018Containers State of the Union I AWS Dev Day 2018
Containers State of the Union I AWS Dev Day 2018
 
Serverless: State of The Union I AWS Dev Day 2018
Serverless: State of The Union I AWS Dev Day 2018Serverless: State of The Union I AWS Dev Day 2018
Serverless: State of The Union I AWS Dev Day 2018
 
Enterprise Network Transformation Powered by OrangeX, with Nokia Nuage and AW...
Enterprise Network Transformation Powered by OrangeX, with Nokia Nuage and AW...Enterprise Network Transformation Powered by OrangeX, with Nokia Nuage and AW...
Enterprise Network Transformation Powered by OrangeX, with Nokia Nuage and AW...
 
SRV205 Architectures and Strategies for Building Modern Applications on AWS
 SRV205 Architectures and Strategies for Building Modern Applications on AWS SRV205 Architectures and Strategies for Building Modern Applications on AWS
SRV205 Architectures and Strategies for Building Modern Applications on AWS
 
Day Two Operations of Kubernetes on AWS (GPSTEC309) - AWS re:Invent 2018
Day Two Operations of Kubernetes on AWS (GPSTEC309) - AWS re:Invent 2018Day Two Operations of Kubernetes on AWS (GPSTEC309) - AWS re:Invent 2018
Day Two Operations of Kubernetes on AWS (GPSTEC309) - AWS re:Invent 2018
 
Deep Dive on Cloud File System Offerings: What to Use, Where, and Why (STG392...
Deep Dive on Cloud File System Offerings: What to Use, Where, and Why (STG392...Deep Dive on Cloud File System Offerings: What to Use, Where, and Why (STG392...
Deep Dive on Cloud File System Offerings: What to Use, Where, and Why (STG392...
 
Beyond the Basics: Advanced Infrastructure as Code Programming on AWS (DEV327...
Beyond the Basics: Advanced Infrastructure as Code Programming on AWS (DEV327...Beyond the Basics: Advanced Infrastructure as Code Programming on AWS (DEV327...
Beyond the Basics: Advanced Infrastructure as Code Programming on AWS (DEV327...
 
Visibility into Serverless Applications built using AWS Fargate (CON312-R1) -...
Visibility into Serverless Applications built using AWS Fargate (CON312-R1) -...Visibility into Serverless Applications built using AWS Fargate (CON312-R1) -...
Visibility into Serverless Applications built using AWS Fargate (CON312-R1) -...
 
Amazon VPC: Security at the Speed Of Light (NET313) - AWS re:Invent 2018
Amazon VPC: Security at the Speed Of Light (NET313) - AWS re:Invent 2018Amazon VPC: Security at the Speed Of Light (NET313) - AWS re:Invent 2018
Amazon VPC: Security at the Speed Of Light (NET313) - AWS re:Invent 2018
 
Run Kubernetes with Amazon EKS
Run Kubernetes with Amazon EKSRun Kubernetes with Amazon EKS
Run Kubernetes with Amazon EKS
 
使用 AWS 無伺服器化應用程式模型 (SAM) 釋放您的 "敏捷" 能量 (Level 300)
使用 AWS 無伺服器化應用程式模型 (SAM) 釋放您的 "敏捷" 能量 (Level 300)使用 AWS 無伺服器化應用程式模型 (SAM) 釋放您的 "敏捷" 能量 (Level 300)
使用 AWS 無伺服器化應用程式模型 (SAM) 釋放您的 "敏捷" 能量 (Level 300)
 
Optimizing Lambda@Edge for Performance and Cost Efficiency (CTD405-R2) - AWS ...
Optimizing Lambda@Edge for Performance and Cost Efficiency (CTD405-R2) - AWS ...Optimizing Lambda@Edge for Performance and Cost Efficiency (CTD405-R2) - AWS ...
Optimizing Lambda@Edge for Performance and Cost Efficiency (CTD405-R2) - AWS ...
 

Ähnlich wie Architecting Next Generation Serverless SaaS Solutions on AWS (ARC324-R1) - AWS re:Invent 2018

Getting Started with Serverless Architectures with Microservices_AWSPSSummit_...
Getting Started with Serverless Architectures with Microservices_AWSPSSummit_...Getting Started with Serverless Architectures with Microservices_AWSPSSummit_...
Getting Started with Serverless Architectures with Microservices_AWSPSSummit_...
Amazon Web Services
 

Ähnlich wie Architecting Next Generation Serverless SaaS Solutions on AWS (ARC324-R1) - AWS re:Invent 2018 (20)

SaaS Reference Architectures: Review of Real-World Patterns & Strategies (GPS...
SaaS Reference Architectures: Review of Real-World Patterns & Strategies (GPS...SaaS Reference Architectures: Review of Real-World Patterns & Strategies (GPS...
SaaS Reference Architectures: Review of Real-World Patterns & Strategies (GPS...
 
Deep Dive into AWS X-Ray: Monitor Modern Applications (DEV324) - AWS re:Inven...
Deep Dive into AWS X-Ray: Monitor Modern Applications (DEV324) - AWS re:Inven...Deep Dive into AWS X-Ray: Monitor Modern Applications (DEV324) - AWS re:Inven...
Deep Dive into AWS X-Ray: Monitor Modern Applications (DEV324) - AWS re:Inven...
 
SaaS Jumpstart: A Primer for Launching Your SaaS Journey (ARC210-R2) - AWS re...
SaaS Jumpstart: A Primer for Launching Your SaaS Journey (ARC210-R2) - AWS re...SaaS Jumpstart: A Primer for Launching Your SaaS Journey (ARC210-R2) - AWS re...
SaaS Jumpstart: A Primer for Launching Your SaaS Journey (ARC210-R2) - AWS re...
 
Migrating Single-Tenant Applications to Multi-Tenant SaaS (ARC326-R1) - AWS r...
Migrating Single-Tenant Applications to Multi-Tenant SaaS (ARC326-R1) - AWS r...Migrating Single-Tenant Applications to Multi-Tenant SaaS (ARC326-R1) - AWS r...
Migrating Single-Tenant Applications to Multi-Tenant SaaS (ARC326-R1) - AWS r...
 
Getting Started with Serverless Architectures with Microservices_AWSPSSummit_...
Getting Started with Serverless Architectures with Microservices_AWSPSSummit_...Getting Started with Serverless Architectures with Microservices_AWSPSSummit_...
Getting Started with Serverless Architectures with Microservices_AWSPSSummit_...
 
A New Approach to Continuous Monitoring in the Cloud: Migrate to AWS with NET...
A New Approach to Continuous Monitoring in the Cloud: Migrate to AWS with NET...A New Approach to Continuous Monitoring in the Cloud: Migrate to AWS with NET...
A New Approach to Continuous Monitoring in the Cloud: Migrate to AWS with NET...
 
From Monolithic to Modern Apps: Best Practices
From Monolithic to Modern Apps: Best PracticesFrom Monolithic to Modern Apps: Best Practices
From Monolithic to Modern Apps: Best Practices
 
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...
 
Vonage & Aspect: Transform Real-Time Communications & Customer Engagement (TL...
Vonage & Aspect: Transform Real-Time Communications & Customer Engagement (TL...Vonage & Aspect: Transform Real-Time Communications & Customer Engagement (TL...
Vonage & Aspect: Transform Real-Time Communications & Customer Engagement (TL...
 
Enabling Your Organization’s Amazon Redshift Adoption – Going from Zero to He...
Enabling Your Organization’s Amazon Redshift Adoption – Going from Zero to He...Enabling Your Organization’s Amazon Redshift Adoption – Going from Zero to He...
Enabling Your Organization’s Amazon Redshift Adoption – Going from Zero to He...
 
Serverless Architectural Patterns and Best Practices
Serverless Architectural Patterns and Best PracticesServerless Architectural Patterns and Best Practices
Serverless Architectural Patterns and Best Practices
 
How can your business benefit from going Serverless
How can your business benefit from going ServerlessHow can your business benefit from going Serverless
How can your business benefit from going Serverless
 
Microservices for Startups
Microservices for StartupsMicroservices for Startups
Microservices for Startups
 
Building Massively Parallel Event-Driven Architectures (SRV373-R1) - AWS re:I...
Building Massively Parallel Event-Driven Architectures (SRV373-R1) - AWS re:I...Building Massively Parallel Event-Driven Architectures (SRV373-R1) - AWS re:I...
Building Massively Parallel Event-Driven Architectures (SRV373-R1) - AWS re:I...
 
SaaS Operations: The Foundation of SaaS Agility (ARC216) - AWS re:Invent 2018
SaaS Operations: The Foundation of SaaS Agility (ARC216) - AWS re:Invent 2018SaaS Operations: The Foundation of SaaS Agility (ARC216) - AWS re:Invent 2018
SaaS Operations: The Foundation of SaaS Agility (ARC216) - AWS re:Invent 2018
 
From Monolith to Modern Apps: Best Practices (SRV322-R2) - AWS re:Invent 2018
From Monolith to Modern Apps: Best Practices (SRV322-R2) - AWS re:Invent 2018From Monolith to Modern Apps: Best Practices (SRV322-R2) - AWS re:Invent 2018
From Monolith to Modern Apps: Best Practices (SRV322-R2) - AWS re:Invent 2018
 
Build Your Own Log Analytics Solutions on AWS (ANT323-R) - AWS re:Invent 2018
Build Your Own Log Analytics Solutions on AWS (ANT323-R) - AWS re:Invent 2018Build Your Own Log Analytics Solutions on AWS (ANT323-R) - AWS re:Invent 2018
Build Your Own Log Analytics Solutions on AWS (ANT323-R) - AWS re:Invent 2018
 
Deploying Microservices using AWS Fargate (CON315-R1) - AWS re:Invent 2018
Deploying Microservices using AWS Fargate (CON315-R1) - AWS re:Invent 2018Deploying Microservices using AWS Fargate (CON315-R1) - AWS re:Invent 2018
Deploying Microservices using AWS Fargate (CON315-R1) - AWS re:Invent 2018
 
How can your business benefit from going serverless?
How can your business benefit from going serverless?How can your business benefit from going serverless?
How can your business benefit from going serverless?
 
Build High-Throughput, Bursty Data Apps with Amazon SQS, SNS, & Lambda (API30...
Build High-Throughput, Bursty Data Apps with Amazon SQS, SNS, & Lambda (API30...Build High-Throughput, Bursty Data Apps with Amazon SQS, SNS, & Lambda (API30...
Build High-Throughput, Bursty Data Apps with Amazon SQS, SNS, & Lambda (API30...
 

Mehr von Amazon Web Services

Tools for building your MVP on AWS
Tools for building your MVP on AWSTools for building your MVP on AWS
Tools for building your MVP on AWS
Amazon Web Services
 
How to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckHow to Build a Winning Pitch Deck
How to Build a Winning Pitch Deck
Amazon Web Services
 
Building a web application without servers
Building a web application without serversBuilding a web application without servers
Building a web application without servers
Amazon Web Services
 
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
Amazon Web Services
 

Mehr von Amazon Web Services (20)

Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
Come costruire servizi di Forecasting sfruttando algoritmi di ML e deep learn...
 
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
Big Data per le Startup: come creare applicazioni Big Data in modalità Server...
 
Esegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS FargateEsegui pod serverless con Amazon EKS e AWS Fargate
Esegui pod serverless con Amazon EKS e AWS Fargate
 
Costruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWSCostruire Applicazioni Moderne con AWS
Costruire Applicazioni Moderne con AWS
 
Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot Come spendere fino al 90% in meno con i container e le istanze spot
Come spendere fino al 90% in meno con i container e le istanze spot
 
Open banking as a service
Open banking as a serviceOpen banking as a service
Open banking as a service
 
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
Rendi unica l’offerta della tua startup sul mercato con i servizi Machine Lea...
 
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...OpsWorks Configuration Management: automatizza la gestione e i deployment del...
OpsWorks Configuration Management: automatizza la gestione e i deployment del...
 
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows WorkloadsMicrosoft Active Directory su AWS per supportare i tuoi Windows Workloads
Microsoft Active Directory su AWS per supportare i tuoi Windows Workloads
 
Computer Vision con AWS
Computer Vision con AWSComputer Vision con AWS
Computer Vision con AWS
 
Database Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatareDatabase Oracle e VMware Cloud on AWS i miti da sfatare
Database Oracle e VMware Cloud on AWS i miti da sfatare
 
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJSCrea la tua prima serverless ledger-based app con QLDB e NodeJS
Crea la tua prima serverless ledger-based app con QLDB e NodeJS
 
API moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e webAPI moderne real-time per applicazioni mobili e web
API moderne real-time per applicazioni mobili e web
 
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatareDatabase Oracle e VMware Cloud™ on AWS: i miti da sfatare
Database Oracle e VMware Cloud™ on AWS: i miti da sfatare
 
Tools for building your MVP on AWS
Tools for building your MVP on AWSTools for building your MVP on AWS
Tools for building your MVP on AWS
 
How to Build a Winning Pitch Deck
How to Build a Winning Pitch DeckHow to Build a Winning Pitch Deck
How to Build a Winning Pitch Deck
 
Building a web application without servers
Building a web application without serversBuilding a web application without servers
Building a web application without servers
 
Fundraising Essentials
Fundraising EssentialsFundraising Essentials
Fundraising Essentials
 
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
AWS_HK_StartupDay_Building Interactive websites while automating for efficien...
 
Introduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container ServiceIntroduzione a Amazon Elastic Container Service
Introduzione a Amazon Elastic Container Service
 

Architecting Next Generation Serverless SaaS Solutions on AWS (ARC324-R1) - AWS re:Invent 2018

  • 1.
  • 2. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Architecting Next Generation Serverless SaaS Solutions on AWS Tod Golding Partner Solutions Architect Amazon Web Services A R C 3 2 4
  • 3. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. SaaS and serverless: a natural fit
  • 4. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. No more over-provisioning Tenants Tenant consumptionCost, scale, performance Consumption Time
  • 5. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. High level serverless SaaS architecture
  • 6. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Shared onboarding services
  • 7. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Serverless authentication and authorization Amazon CognitoTenant JWT token (user, tenant, role) Validate tenant, user, role access
  • 8. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Tenant throttling strategies Tenant 1 (Standard Tier) Tenant 2 (Professional Tier) Tenant 3 (Premium Tier) API key(s) Usage plan
  • 9. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Compute isolation and serverless EC2 Instances EC2 silo model Tenant 2Tenant 1 ECS Cluster Tenant 1 Tenant 2 ECS silo model EC2 Instances ECS Cluster How do these map to serverless?
  • 10. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Tenant isolation with siloes Tenant 1 Tenant 2
  • 11. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Tenant isolation with policies Tenant 2Tenant 1
  • 12. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Tenant isolation with tokens Tenant 1 Tenant 2
  • 13. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Wrapper-based isolation var lambdaFunc = require('myModule/mymod.js’); var lambda = require('lambda-wrapper').wrap(lambdaFunc); lambda.run(event, function(err, data) { if (err) { ... handle error } ... process data returned by the Lambda function })
  • 14. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. The good news Tenant 1 Tenant 2 Tenant 2Tenant 1
  • 15. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Serverless application services TenantID Name Tenant-1 Jane Doe Tenant-4 Mike Doe
  • 16. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. A different scaling mindset GetOrder() UpdateOrder() DeleteOrder() GetOrder() GetOrder() UpdateOrder() Scale Policy Policy Order Management Service Order Management Service Order Management Service Order Management Service POST /orders/712 PUT /orders/42 DELETE /orders/651 GET /orders Scale
  • 17. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Hiding away multi-tenant awareness Multi-tenant data access Metering& analytics Logging
  • 18. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Flowing tenant context through services Tenant Token Token (HTTP headers) Metering Logging Data Access Token Tenant 1 Tenant 2
  • 19. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. State residue for functions Tenant 1 1 2 Tenant 2
  • 20. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Serverless and SaaS agility Scheduled Maintenance Friday, April 1, 11:00-12:00PM The system will be down for maintenance this evening. We apologize for any inconvenience this may cause. Close Achieving zero-downtime on SaaS requires • Ability to deploy small, decoupled units of functionality • A strategy that expects and embraces fault tolerance • A well-defined mechanism for staging and releasing new features • An approach that enables continual and frequent releases
  • 21. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Can’t get much smaller than this Commit Unit Test System Test QA Staging Prod Commit Unit Test System Test QA Staging Prod Commit Unit Test System Test QA Staging Prod GetOrder() CreateOrder() UpdateOrder()
  • 22. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Smaller blast radius = better fault tolerance • Finer grained functions promote more refined fault tolerance • More opportunities for implement fallback strategies • Less exposure and visibility when a service fails • Greater resilience translates into greater agility Catalog Ratings Checkout Taxation CrossSell Cart Search
  • 23. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Servers impact SaaS storage db.m4.large db.m4.16xlarge db.m4.4xlarge Tenants
  • 24. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Strategies for addressing compute size Over provisioning Load-driven resizing Tenant 1 Tenant 2 Tenant 1 Tenant 1 Tenant 1
  • 25. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Pooled storage compute challenges TenantID Name StartDate Tenant-1 Jane Doe 01-12-2012 Tenant-4 John Doe 09-01-2015 Tenant-9 Mary Smith 11-04-2017SaaS Database Customer table Tenant 1 Tenants can rapidly saturate and instance Tenant 2 Tenant 3
  • 26. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. On-demand sizing with Amazon Aurora Serverless Proxy fleet Instance Instance Instance Aurora instances Application Storage Storage Storage • Remove the notion of servers/instances • All data is kept in highly available storage volume • Application talks to a MySQL compatible endpoint • Fleet of proxy servers manage, queue and route database traffic
  • 27. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Leveraging pooled instances Instance Instance Instance Aurora instances Warm instance pool
  • 28. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Data partitioning with Amazon Aurora Serverless Instance Aurora instance Tenant 1 Instance Aurora instance Tenant 1 Tenant 2 Instance Aurora instance Tenant 2 Warm instance pool Silo partitioning Pool partitioning
  • 29. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Full stack serverless SaaS Amazon API Gateway Aurora Serverless Storage Tenant 1 Tenant 2 • Brings serverless to relational environments • Isolation of compute and storage with no idle costs • Simplified management and deployment • Less operational focus on tuning and sizing policies • More focus on your application IP Tenant 1 Tenant 2
  • 30. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Where does AWS Fargate fit? Fargate cluster Tenant 1 Tenant 2 • A more coarse-grained view of serverless • Often fits the developer mental model • Can represent a more natural transition for legacy systems Tenant 3
  • 31. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Takeaways • Use serverless to focus more attention on your IP • Find the isolation balance that best suits your domain • Tenant load profile should influence service decomposition • Find the logical services for data encapsulation • Consider extending the reach of serverless to storage • Use serverless DevOps to simplify your zero downtime store • Serverless and SaaS are a natural match
  • 32. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Additional SaaS Breakouts Monday, 11/26 GPSTEC3-2 - SaaS Reference Architectures: A Review of Real World Patterns and Strategies 6:15 PM | Venetian, Level 2, Venetian Theater Tuesday, 11/27 ARC324 - Architecting Next Generation Serverless SaaS Solutions on AWS (Repeat) 4:00 PM | Venetian, Level 2, Titian 2204 Thursday, 11/29 ARC418 Deconstructing SaaS: Deep Dive into Building Multi-Tenant Solutions on AWS (Repeat) 4:00 PM | Aria, Aria West, Level 3, Ironwood 5 Wednesday, 11/28 ARC418 Deconstructing SaaS: Deep Dive into Building Multi-Tenant Solutions on AWS 12:15 PM | Mirage, Mirage Event Center B
  • 33. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. SaaS Chalk Talks Monday, 11/26 ARC216 - SaaS Operations: The Foundation of SaaS Agility 11:30 – 12:30 | Venetian, Level 2, Veronese 2406 Tuesday, 11/27 ARC210 - SaaS Jumpstart: A Primer for Launching Your SaaS Journey 9:15 – 10:15 | Venetian, Level 4, Lando 4304 Wednesday, 11/28 ARC419 – Optimizing Your SaaS Solutions on AWS 1:00 – 2:00 | Venetian, Level 3, Murano 3202 ARC326 - Migrating Single-Tenant Applications to Multi-Tenant SaaS 4:00 – 5:00 | Aria West, Level 3, Starvine 7 ARC210 - SaaS Jumpstart: A Primer for Launching Your SaaS Journey 1:45 – 2:45 | Aria West, Level 3, Ironwood 8
  • 34. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. SaaS Chalk Talks Thursday, 11/29 ARC210 - SaaS Jumpstart: A Primer for Launching Your SaaS Journey 1:45 – 2:45 | MGM, Level 1, South Concourse 105 Friday, 11/30 ARC326 – Migrating Single-Tenant Applications to Multi-Tenant SaaS 10:00 – 11:00 | MGM, Level 1, South Concourse 105 ARC419 – Optimizing Your SaaS Architecture on AWS 1:00 – 2:00 | Venetian, Level 3, Murano 3202
  • 35. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. SaaS Workshops Monday, 11/26 Hands-on SaaS: Constructing Multi-Tenant Solutions on AWS 4:00 – 6:15 PM | Mirage, Mirage Event Center C3 Friday, 11/30 Hands-on SaaS: Constructing Multi-Tenant Solutions on AWS 9:15 AM – 11:30 AM | Mirage, Mirage Event Center C2
  • 36. Thank you! © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Tod Golding todg@amazon.com
  • 37. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.