Advanced serverless application architecture and design considerations

AWS User Group Bengaluru
AWS User Group BengaluruAWS User Group Bengaluru
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Advanced serverless application
architecture and design
considerations
DILIP KUMAR KOLA, Co-founder Tensult | 6th October 2018
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Why Serverless?
Image caption 1 Image caption 3
Scalability Reduce Cost AutomationFaster Deployments
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
You want to host a large-scale
blog platform with highly dynamic
content leveraging, “serverless
technology”. How would you do
it?
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
CMS Back-end Architecture
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Authorization of backend users
Cognito
User Pool
CMS
Application
API
Gateway
CMS
API
CloudFront
Cognito
Identity Pool
S3
For storing photos and videos
DynamoDB Lambda Elastic
Search
Populating to ES to enable search
Lambda S3
Sitemaps and RSS feeders
CMS User
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Website Architecture
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
API
Gateway
Website
API
CloudFront
DynamoDB
Elastic
Search
S3
Web User
Sitemaps and RSS feeders
Data Retrieval
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Application Components Architecture
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
API
Gateway
CMS API Internal
Request
Handler
Authentication
Handler
Authorization
Handler
Error
Handler
Routes Services
Validations
DynamoDB
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Deployment Architecture
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Code
Repository
Services
CMS Routes
Web Routes
API
Gateway
API
Gateway
CMS API
Services
CMS Routes
Web Routes
Web API
Deploy to
CMS API
Deploy to
Web API
CMS API
Web API
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
let userGreeting = "Hello <name>! Have a Nice day!!”;
exports.handler = async (event) => {
console.log("event received", event);
userGreeting = userGreeting.replace("<name>", event.name);
console.log(userGreeting);
return userGreeting;
};
Is there any problem with the above lambda function?
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
function getUserGreeting() {
return "Hello <name>! Have a Nice day!!";
}
exports.handler = async (event) => {
console.log("event received", event);
let userGreeting = getUserGreeting();
userGreeting = userGreeting.replace("<name>", event.name);
console.log(userGreeting);
return userGreeting;
};
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Global Variables
• Lambda will re-use the container to execute the function so, treat
everything outside the handler of lambda function as constant
• Incase if you want to modify any global variables while executing, wrap
it in a function like the example shown before
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
You have to sent news letters to
thousands of your blog subscribers,
how will you do that?
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
CloudWatch
Rule
Fetch News Letter
Template
News Letter
Template
Cache
Elastic
Search
Fetch List of
Users
Send News Letter
SES
SNS
Send Token to fetch
next User List
Newsletter Function
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Cloud Reports Architecture
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
ReportersAnalyzersCollectors
Collects Information
from cloud provider
Analyzes Information
against best
practices
Generates Report in
Various Formats
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
API
Gateway
DynamoDBLambda Lambda SQS Cloud Reports
Application
S3
Validations
Storing Meta-Data
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Loop Prevention:
• Code review
• Data flow review
Loop Detection:
• Set up an invocation count alarm for each Lambda function and set
notification using SNS.
• Setting up Billing alerts to monitor resource usage.
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Monitoring
• Memory Utilization
• Invocation Count
• Duration of execution
• Load testing with different memory size
• Throttling
• Dashboards
© 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Thank you
1 of 22

Recommended

Advanced Serverless application architecture and design considerations by
Advanced Serverless application architecture and design considerationsAdvanced Serverless application architecture and design considerations
Advanced Serverless application architecture and design considerationsDilip Kola
178 views24 slides
An ops discovery of serverless by
An ops discovery of serverlessAn ops discovery of serverless
An ops discovery of serverlessAWS User Group Bengaluru
72 views10 slides
Build a Photo-Sharing App with AI-Powered Face and Object Detection (MOB306) ... by
Build a Photo-Sharing App with AI-Powered Face and Object Detection (MOB306) ...Build a Photo-Sharing App with AI-Powered Face and Object Detection (MOB306) ...
Build a Photo-Sharing App with AI-Powered Face and Object Detection (MOB306) ...Amazon Web Services
483 views22 slides
Serverless Industry 4.0 & AI: Drive Business Insights from Machine Data (IOT4... by
Serverless Industry 4.0 & AI: Drive Business Insights from Machine Data (IOT4...Serverless Industry 4.0 & AI: Drive Business Insights from Machine Data (IOT4...
Serverless Industry 4.0 & AI: Drive Business Insights from Machine Data (IOT4...Amazon Web Services
445 views8 slides
Transforming the Upstream Oil and Gas with AWS ML Solutions (OIG302) - AWS re... by
Transforming the Upstream Oil and Gas with AWS ML Solutions (OIG302) - AWS re...Transforming the Upstream Oil and Gas with AWS ML Solutions (OIG302) - AWS re...
Transforming the Upstream Oil and Gas with AWS ML Solutions (OIG302) - AWS re...Amazon Web Services
399 views38 slides
Build and Collaborate on a Modern Web Application on AWS - SRV403 - Atlanta A... by
Build and Collaborate on a Modern Web Application on AWS - SRV403 - Atlanta A...Build and Collaborate on a Modern Web Application on AWS - SRV403 - Atlanta A...
Build and Collaborate on a Modern Web Application on AWS - SRV403 - Atlanta A...Amazon Web Services
90 views8 slides

More Related Content

What's hot

Hollywood's Cloud-Based Content Lakes: Modernized Media Archives (MAE203) - A... by
Hollywood's Cloud-Based Content Lakes: Modernized Media Archives (MAE203) - A...Hollywood's Cloud-Based Content Lakes: Modernized Media Archives (MAE203) - A...
Hollywood's Cloud-Based Content Lakes: Modernized Media Archives (MAE203) - A...Amazon Web Services
8.4K views30 slides
Automatic Model Tuning Using Amazon SageMaker (AIM412) - AWS re:Invent 2018 by
Automatic Model Tuning Using Amazon SageMaker (AIM412) - AWS re:Invent 2018Automatic Model Tuning Using Amazon SageMaker (AIM412) - AWS re:Invent 2018
Automatic Model Tuning Using Amazon SageMaker (AIM412) - AWS re:Invent 2018Amazon Web Services
606 views35 slides
The Intelligent Edge for IoT: Help Customers Harness the Power of Connected I... by
The Intelligent Edge for IoT: Help Customers Harness the Power of Connected I...The Intelligent Edge for IoT: Help Customers Harness the Power of Connected I...
The Intelligent Edge for IoT: Help Customers Harness the Power of Connected I...Amazon Web Services
361 views29 slides
Using Graph Databases by
Using Graph DatabasesUsing Graph Databases
Using Graph DatabasesAmazon Web Services
295 views35 slides
Building IoT Analytics (IOT327-R1) - AWS re:Invent 2018 by
Building IoT Analytics (IOT327-R1) - AWS re:Invent 2018Building IoT Analytics (IOT327-R1) - AWS re:Invent 2018
Building IoT Analytics (IOT327-R1) - AWS re:Invent 2018Amazon Web Services
190 views21 slides
AWS Community Day Nordics 2018 - Aino Health: Transition to serverless and le... by
AWS Community Day Nordics 2018 - Aino Health: Transition to serverless and le...AWS Community Day Nordics 2018 - Aino Health: Transition to serverless and le...
AWS Community Day Nordics 2018 - Aino Health: Transition to serverless and le...Rolf Koski
310 views13 slides

What's hot(20)

Hollywood's Cloud-Based Content Lakes: Modernized Media Archives (MAE203) - A... by Amazon Web Services
Hollywood's Cloud-Based Content Lakes: Modernized Media Archives (MAE203) - A...Hollywood's Cloud-Based Content Lakes: Modernized Media Archives (MAE203) - A...
Hollywood's Cloud-Based Content Lakes: Modernized Media Archives (MAE203) - A...
Amazon Web Services8.4K views
Automatic Model Tuning Using Amazon SageMaker (AIM412) - AWS re:Invent 2018 by Amazon Web Services
Automatic Model Tuning Using Amazon SageMaker (AIM412) - AWS re:Invent 2018Automatic Model Tuning Using Amazon SageMaker (AIM412) - AWS re:Invent 2018
Automatic Model Tuning Using Amazon SageMaker (AIM412) - AWS re:Invent 2018
The Intelligent Edge for IoT: Help Customers Harness the Power of Connected I... by Amazon Web Services
The Intelligent Edge for IoT: Help Customers Harness the Power of Connected I...The Intelligent Edge for IoT: Help Customers Harness the Power of Connected I...
The Intelligent Edge for IoT: Help Customers Harness the Power of Connected I...
Building IoT Analytics (IOT327-R1) - AWS re:Invent 2018 by Amazon Web Services
Building IoT Analytics (IOT327-R1) - AWS re:Invent 2018Building IoT Analytics (IOT327-R1) - AWS re:Invent 2018
Building IoT Analytics (IOT327-R1) - AWS re:Invent 2018
AWS Community Day Nordics 2018 - Aino Health: Transition to serverless and le... by Rolf Koski
AWS Community Day Nordics 2018 - Aino Health: Transition to serverless and le...AWS Community Day Nordics 2018 - Aino Health: Transition to serverless and le...
AWS Community Day Nordics 2018 - Aino Health: Transition to serverless and le...
Rolf Koski310 views
Gaining Visibility and Insight into Your Distributed Applications with AWS X-... by Amazon Web Services
Gaining Visibility and Insight into Your Distributed Applications with AWS X-...Gaining Visibility and Insight into Your Distributed Applications with AWS X-...
Gaining Visibility and Insight into Your Distributed Applications with AWS X-...
Build a "Who's Who" App for Your Media Content (AIM409) - AWS re:Invent 2018 by Amazon Web Services
Build a "Who's Who" App for Your Media Content (AIM409) - AWS re:Invent 2018Build a "Who's Who" App for Your Media Content (AIM409) - AWS re:Invent 2018
Build a "Who's Who" App for Your Media Content (AIM409) - AWS re:Invent 2018
AI/ML with Data Lakes: Counterintuitive Consumer Insights in Retail (RET206) ... by Amazon Web Services
AI/ML with Data Lakes: Counterintuitive Consumer Insights in Retail (RET206) ...AI/ML with Data Lakes: Counterintuitive Consumer Insights in Retail (RET206) ...
AI/ML with Data Lakes: Counterintuitive Consumer Insights in Retail (RET206) ...
Adding Search to DynamoDB: Database Week San Francisco by Amazon Web Services
Adding Search to DynamoDB: Database Week San FranciscoAdding Search to DynamoDB: Database Week San Francisco
Adding Search to DynamoDB: Database Week San Francisco
Hosting For Your Startup, Side Project, or Big Dollar App - Minnebar 12 by Keith Resar
Hosting For Your Startup, Side Project, or Big Dollar App - Minnebar 12Hosting For Your Startup, Side Project, or Big Dollar App - Minnebar 12
Hosting For Your Startup, Side Project, or Big Dollar App - Minnebar 12
Keith Resar385 views
Extending kubernetes - kyma template by Marek Nawa
Extending kubernetes - kyma templateExtending kubernetes - kyma template
Extending kubernetes - kyma template
Marek Nawa67 views
Create Immersive Experiences Using Amazon Sumerian (ARV204-R1) - AWS re:Inven... by Amazon Web Services
Create Immersive Experiences Using Amazon Sumerian (ARV204-R1) - AWS re:Inven...Create Immersive Experiences Using Amazon Sumerian (ARV204-R1) - AWS re:Inven...
Create Immersive Experiences Using Amazon Sumerian (ARV204-R1) - AWS re:Inven...
Driving Machine Learning and Analytics Use Cases with AWS Storage (STG302) - ... by Amazon Web Services
Driving Machine Learning and Analytics Use Cases with AWS Storage (STG302) - ...Driving Machine Learning and Analytics Use Cases with AWS Storage (STG302) - ...
Driving Machine Learning and Analytics Use Cases with AWS Storage (STG302) - ...

Similar to Advanced serverless application architecture and design considerations

AWS Lambda use cases and best practices - Builders Day Israel by
AWS Lambda use cases and best practices - Builders Day IsraelAWS Lambda use cases and best practices - Builders Day Israel
AWS Lambda use cases and best practices - Builders Day IsraelAmazon Web Services
2.2K views37 slides
Serverless best practices plus design principles 20m version by
Serverless   best practices plus design principles 20m versionServerless   best practices plus design principles 20m version
Serverless best practices plus design principles 20m versionHeitor Lessa
448 views47 slides
Build Your Own Log Analytics Solutions on AWS (ANT323-R) - AWS re:Invent 2018 by
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 2018Amazon Web Services
1K views67 slides
Taking serverless to the edge by
Taking serverless to the edgeTaking serverless to the edge
Taking serverless to the edgeAmazon Web Services
1K views56 slides
Serverless Architectural Patterns I AWS Dev Day 2018 by
Serverless Architectural Patterns I AWS Dev Day 2018Serverless Architectural Patterns I AWS Dev Day 2018
Serverless Architectural Patterns I AWS Dev Day 2018AWS Germany
297 views65 slides
Scaling Up to Your First 10 Million Users (ARC205-R1) - AWS re:Invent 2018 by
Scaling Up to Your First 10 Million Users (ARC205-R1) - AWS re:Invent 2018Scaling Up to Your First 10 Million Users (ARC205-R1) - AWS re:Invent 2018
Scaling Up to Your First 10 Million Users (ARC205-R1) - AWS re:Invent 2018Amazon Web Services
5K views124 slides

Similar to Advanced serverless application architecture and design considerations(20)

AWS Lambda use cases and best practices - Builders Day Israel by Amazon Web Services
AWS Lambda use cases and best practices - Builders Day IsraelAWS Lambda use cases and best practices - Builders Day Israel
AWS Lambda use cases and best practices - Builders Day Israel
Amazon Web Services2.2K views
Serverless best practices plus design principles 20m version by Heitor Lessa
Serverless   best practices plus design principles 20m versionServerless   best practices plus design principles 20m version
Serverless best practices plus design principles 20m version
Heitor Lessa448 views
Build Your Own Log Analytics Solutions on AWS (ANT323-R) - AWS re:Invent 2018 by Amazon Web Services
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
Serverless Architectural Patterns I AWS Dev Day 2018 by AWS Germany
Serverless Architectural Patterns I AWS Dev Day 2018Serverless Architectural Patterns I AWS Dev Day 2018
Serverless Architectural Patterns I AWS Dev Day 2018
AWS Germany297 views
Scaling Up to Your First 10 Million Users (ARC205-R1) - AWS re:Invent 2018 by Amazon Web Services
Scaling Up to Your First 10 Million Users (ARC205-R1) - AWS re:Invent 2018Scaling Up to Your First 10 Million Users (ARC205-R1) - AWS re:Invent 2018
Scaling Up to Your First 10 Million Users (ARC205-R1) - AWS re:Invent 2018
The Serverless Tidal Wave - SwampUP 2018 Keynote by Arun Gupta
The Serverless Tidal Wave - SwampUP 2018 KeynoteThe Serverless Tidal Wave - SwampUP 2018 Keynote
The Serverless Tidal Wave - SwampUP 2018 Keynote
Arun Gupta345 views
使用 AWS Step Functions 靈活調度 AWS Lambda (Level:200) by Amazon Web Services
使用 AWS Step Functions 靈活調度 AWS Lambda (Level:200)使用 AWS Step Functions 靈活調度 AWS Lambda (Level:200)
使用 AWS Step Functions 靈活調度 AWS Lambda (Level:200)
Under the Hood: How Amazon Uses AWS Services for Analytics at a Massive Scale... by Amazon Web Services
Under the Hood: How Amazon Uses AWS Services for Analytics at a Massive Scale...Under the Hood: How Amazon Uses AWS Services for Analytics at a Massive Scale...
Under the Hood: How Amazon Uses AWS Services for Analytics at a Massive Scale...
Amazon Web Services2.3K views
Come scalare da zero ai tuoi primi 10 milioni di utenti.pdf by Amazon Web Services
Come scalare da zero ai tuoi primi 10 milioni di utenti.pdfCome scalare da zero ai tuoi primi 10 milioni di utenti.pdf
Come scalare da zero ai tuoi primi 10 milioni di utenti.pdf
善用 GraphQL 與 AWS AppSync 讓您的 Progressive Web App (PWA) 加速進化 (Level 200) by Amazon Web Services
善用  GraphQL 與 AWS AppSync 讓您的  Progressive Web App (PWA) 加速進化 (Level 200)善用  GraphQL 與 AWS AppSync 讓您的  Progressive Web App (PWA) 加速進化 (Level 200)
善用 GraphQL 與 AWS AppSync 讓您的 Progressive Web App (PWA) 加速進化 (Level 200)
Taking your Progressive Web App to the Next Level - AWS Summit Sydney 2018 by Amazon Web Services
Taking your Progressive Web App to the Next Level - AWS Summit Sydney 2018Taking your Progressive Web App to the Next Level - AWS Summit Sydney 2018
Taking your Progressive Web App to the Next Level - AWS Summit Sydney 2018
Amazon Web Services1.1K views
Build your APPs in Lean and Agile Way using AWS Amplify by Amazon Web Services
Build your APPs in Lean and Agile Way using AWS AmplifyBuild your APPs in Lean and Agile Way using AWS Amplify
Build your APPs in Lean and Agile Way using AWS Amplify
Amazon Web Services1.2K views
Running Lean Architectures: How to Optimize for Cost Efficiency (ARC202-R2) -... by Amazon Web Services
Running Lean Architectures: How to Optimize for Cost Efficiency (ARC202-R2) -...Running Lean Architectures: How to Optimize for Cost Efficiency (ARC202-R2) -...
Running Lean Architectures: How to Optimize for Cost Efficiency (ARC202-R2) -...
Amazon Web Services1.4K views
Day Two Operations of Kubernetes on AWS (GPSTEC309) - AWS re:Invent 2018 by Amazon Web Services
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

More from AWS User Group Bengaluru

Demystifying identity on AWS by
Demystifying identity on AWSDemystifying identity on AWS
Demystifying identity on AWSAWS User Group Bengaluru
440 views108 slides
AWS Secrets for Best Practices by
AWS Secrets for Best PracticesAWS Secrets for Best Practices
AWS Secrets for Best PracticesAWS User Group Bengaluru
931 views21 slides
Cloud Security by
Cloud SecurityCloud Security
Cloud SecurityAWS User Group Bengaluru
1.9K views133 slides
Lessons learnt building a Distributed Linked List on S3 by
Lessons learnt building a Distributed Linked List on S3Lessons learnt building a Distributed Linked List on S3
Lessons learnt building a Distributed Linked List on S3AWS User Group Bengaluru
312 views27 slides
Medlife journey with AWS by
Medlife journey with AWSMedlife journey with AWS
Medlife journey with AWSAWS User Group Bengaluru
336 views17 slides
Building Efficient, Scalable and Resilient Front-end logging service with AWS by
Building Efficient, Scalable and Resilient Front-end logging service with AWSBuilding Efficient, Scalable and Resilient Front-end logging service with AWS
Building Efficient, Scalable and Resilient Front-end logging service with AWSAWS User Group Bengaluru
443 views33 slides

More from AWS User Group Bengaluru(20)

Building Efficient, Scalable and Resilient Front-end logging service with AWS by AWS User Group Bengaluru
Building Efficient, Scalable and Resilient Front-end logging service with AWSBuilding Efficient, Scalable and Resilient Front-end logging service with AWS
Building Efficient, Scalable and Resilient Front-end logging service with AWS
Building Efficient, Scalable and Resilient Front-end logging service with AWS by AWS User Group Bengaluru
Building Efficient, Scalable and Resilient Front-end logging service with AWSBuilding Efficient, Scalable and Resilient Front-end logging service with AWS
Building Efficient, Scalable and Resilient Front-end logging service with AWS

Recently uploaded

Why and How CloudStack at weSystems - Stephan Bienek - weSystems by
Why and How CloudStack at weSystems - Stephan Bienek - weSystemsWhy and How CloudStack at weSystems - Stephan Bienek - weSystems
Why and How CloudStack at weSystems - Stephan Bienek - weSystemsShapeBlue
238 views13 slides
Extending KVM Host HA for Non-NFS Storage - Alex Ivanov - StorPool by
Extending KVM Host HA for Non-NFS Storage -  Alex Ivanov - StorPoolExtending KVM Host HA for Non-NFS Storage -  Alex Ivanov - StorPool
Extending KVM Host HA for Non-NFS Storage - Alex Ivanov - StorPoolShapeBlue
123 views10 slides
Generative AI: Shifting the AI Landscape by
Generative AI: Shifting the AI LandscapeGenerative AI: Shifting the AI Landscape
Generative AI: Shifting the AI LandscapeDeakin University
53 views55 slides
Zero to Cloud Hero: Crafting a Private Cloud from Scratch with XCP-ng, Xen Or... by
Zero to Cloud Hero: Crafting a Private Cloud from Scratch with XCP-ng, Xen Or...Zero to Cloud Hero: Crafting a Private Cloud from Scratch with XCP-ng, Xen Or...
Zero to Cloud Hero: Crafting a Private Cloud from Scratch with XCP-ng, Xen Or...ShapeBlue
198 views20 slides
KVM Security Groups Under the Hood - Wido den Hollander - Your.Online by
KVM Security Groups Under the Hood - Wido den Hollander - Your.OnlineKVM Security Groups Under the Hood - Wido den Hollander - Your.Online
KVM Security Groups Under the Hood - Wido den Hollander - Your.OnlineShapeBlue
221 views19 slides
Transitioning from VMware vCloud to Apache CloudStack: A Path to Profitabilit... by
Transitioning from VMware vCloud to Apache CloudStack: A Path to Profitabilit...Transitioning from VMware vCloud to Apache CloudStack: A Path to Profitabilit...
Transitioning from VMware vCloud to Apache CloudStack: A Path to Profitabilit...ShapeBlue
159 views25 slides

Recently uploaded(20)

Why and How CloudStack at weSystems - Stephan Bienek - weSystems by ShapeBlue
Why and How CloudStack at weSystems - Stephan Bienek - weSystemsWhy and How CloudStack at weSystems - Stephan Bienek - weSystems
Why and How CloudStack at weSystems - Stephan Bienek - weSystems
ShapeBlue238 views
Extending KVM Host HA for Non-NFS Storage - Alex Ivanov - StorPool by ShapeBlue
Extending KVM Host HA for Non-NFS Storage -  Alex Ivanov - StorPoolExtending KVM Host HA for Non-NFS Storage -  Alex Ivanov - StorPool
Extending KVM Host HA for Non-NFS Storage - Alex Ivanov - StorPool
ShapeBlue123 views
Zero to Cloud Hero: Crafting a Private Cloud from Scratch with XCP-ng, Xen Or... by ShapeBlue
Zero to Cloud Hero: Crafting a Private Cloud from Scratch with XCP-ng, Xen Or...Zero to Cloud Hero: Crafting a Private Cloud from Scratch with XCP-ng, Xen Or...
Zero to Cloud Hero: Crafting a Private Cloud from Scratch with XCP-ng, Xen Or...
ShapeBlue198 views
KVM Security Groups Under the Hood - Wido den Hollander - Your.Online by ShapeBlue
KVM Security Groups Under the Hood - Wido den Hollander - Your.OnlineKVM Security Groups Under the Hood - Wido den Hollander - Your.Online
KVM Security Groups Under the Hood - Wido den Hollander - Your.Online
ShapeBlue221 views
Transitioning from VMware vCloud to Apache CloudStack: A Path to Profitabilit... by ShapeBlue
Transitioning from VMware vCloud to Apache CloudStack: A Path to Profitabilit...Transitioning from VMware vCloud to Apache CloudStack: A Path to Profitabilit...
Transitioning from VMware vCloud to Apache CloudStack: A Path to Profitabilit...
ShapeBlue159 views
TrustArc Webinar - Managing Online Tracking Technology Vendors_ A Checklist f... by TrustArc
TrustArc Webinar - Managing Online Tracking Technology Vendors_ A Checklist f...TrustArc Webinar - Managing Online Tracking Technology Vendors_ A Checklist f...
TrustArc Webinar - Managing Online Tracking Technology Vendors_ A Checklist f...
TrustArc170 views
Elevating Privacy and Security in CloudStack - Boris Stoyanov - ShapeBlue by ShapeBlue
Elevating Privacy and Security in CloudStack - Boris Stoyanov - ShapeBlueElevating Privacy and Security in CloudStack - Boris Stoyanov - ShapeBlue
Elevating Privacy and Security in CloudStack - Boris Stoyanov - ShapeBlue
ShapeBlue222 views
DRaaS using Snapshot copy and destination selection (DRaaS) - Alexandre Matti... by ShapeBlue
DRaaS using Snapshot copy and destination selection (DRaaS) - Alexandre Matti...DRaaS using Snapshot copy and destination selection (DRaaS) - Alexandre Matti...
DRaaS using Snapshot copy and destination selection (DRaaS) - Alexandre Matti...
ShapeBlue139 views
"Surviving highload with Node.js", Andrii Shumada by Fwdays
"Surviving highload with Node.js", Andrii Shumada "Surviving highload with Node.js", Andrii Shumada
"Surviving highload with Node.js", Andrii Shumada
Fwdays56 views
State of the Union - Rohit Yadav - Apache CloudStack by ShapeBlue
State of the Union - Rohit Yadav - Apache CloudStackState of the Union - Rohit Yadav - Apache CloudStack
State of the Union - Rohit Yadav - Apache CloudStack
ShapeBlue297 views
Migrating VMware Infra to KVM Using CloudStack - Nicolas Vazquez - ShapeBlue by ShapeBlue
Migrating VMware Infra to KVM Using CloudStack - Nicolas Vazquez - ShapeBlueMigrating VMware Infra to KVM Using CloudStack - Nicolas Vazquez - ShapeBlue
Migrating VMware Infra to KVM Using CloudStack - Nicolas Vazquez - ShapeBlue
ShapeBlue218 views
Keynote Talk: Open Source is Not Dead - Charles Schulz - Vates by ShapeBlue
Keynote Talk: Open Source is Not Dead - Charles Schulz - VatesKeynote Talk: Open Source is Not Dead - Charles Schulz - Vates
Keynote Talk: Open Source is Not Dead - Charles Schulz - Vates
ShapeBlue252 views
Setting Up Your First CloudStack Environment with Beginners Challenges - MD R... by ShapeBlue
Setting Up Your First CloudStack Environment with Beginners Challenges - MD R...Setting Up Your First CloudStack Environment with Beginners Challenges - MD R...
Setting Up Your First CloudStack Environment with Beginners Challenges - MD R...
ShapeBlue173 views
NTGapps NTG LowCode Platform by Mustafa Kuğu
NTGapps NTG LowCode Platform NTGapps NTG LowCode Platform
NTGapps NTG LowCode Platform
Mustafa Kuğu423 views
Mitigating Common CloudStack Instance Deployment Failures - Jithin Raju - Sha... by ShapeBlue
Mitigating Common CloudStack Instance Deployment Failures - Jithin Raju - Sha...Mitigating Common CloudStack Instance Deployment Failures - Jithin Raju - Sha...
Mitigating Common CloudStack Instance Deployment Failures - Jithin Raju - Sha...
ShapeBlue180 views
Live Demo Showcase: Unveiling Dell PowerFlex’s IaaS Capabilities with Apache ... by ShapeBlue
Live Demo Showcase: Unveiling Dell PowerFlex’s IaaS Capabilities with Apache ...Live Demo Showcase: Unveiling Dell PowerFlex’s IaaS Capabilities with Apache ...
Live Demo Showcase: Unveiling Dell PowerFlex’s IaaS Capabilities with Apache ...
ShapeBlue126 views
Business Analyst Series 2023 - Week 4 Session 7 by DianaGray10
Business Analyst Series 2023 -  Week 4 Session 7Business Analyst Series 2023 -  Week 4 Session 7
Business Analyst Series 2023 - Week 4 Session 7
DianaGray10139 views

Advanced serverless application architecture and design considerations

  • 1. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Advanced serverless application architecture and design considerations DILIP KUMAR KOLA, Co-founder Tensult | 6th October 2018
  • 2. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Why Serverless? Image caption 1 Image caption 3 Scalability Reduce Cost AutomationFaster Deployments
  • 3. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. You want to host a large-scale blog platform with highly dynamic content leveraging, “serverless technology”. How would you do it?
  • 4. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. CMS Back-end Architecture
  • 5. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Authorization of backend users Cognito User Pool CMS Application API Gateway CMS API CloudFront Cognito Identity Pool S3 For storing photos and videos DynamoDB Lambda Elastic Search Populating to ES to enable search Lambda S3 Sitemaps and RSS feeders CMS User
  • 6. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Website Architecture
  • 7. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. API Gateway Website API CloudFront DynamoDB Elastic Search S3 Web User Sitemaps and RSS feeders Data Retrieval
  • 8. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Application Components Architecture
  • 9. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. API Gateway CMS API Internal Request Handler Authentication Handler Authorization Handler Error Handler Routes Services Validations DynamoDB
  • 10. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Deployment Architecture
  • 11. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Code Repository Services CMS Routes Web Routes API Gateway API Gateway CMS API Services CMS Routes Web Routes Web API Deploy to CMS API Deploy to Web API CMS API Web API
  • 12. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. let userGreeting = "Hello <name>! Have a Nice day!!”; exports.handler = async (event) => { console.log("event received", event); userGreeting = userGreeting.replace("<name>", event.name); console.log(userGreeting); return userGreeting; }; Is there any problem with the above lambda function?
  • 13. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. function getUserGreeting() { return "Hello <name>! Have a Nice day!!"; } exports.handler = async (event) => { console.log("event received", event); let userGreeting = getUserGreeting(); userGreeting = userGreeting.replace("<name>", event.name); console.log(userGreeting); return userGreeting; };
  • 14. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Global Variables • Lambda will re-use the container to execute the function so, treat everything outside the handler of lambda function as constant • Incase if you want to modify any global variables while executing, wrap it in a function like the example shown before
  • 15. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. You have to sent news letters to thousands of your blog subscribers, how will you do that?
  • 16. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. CloudWatch Rule Fetch News Letter Template News Letter Template Cache Elastic Search Fetch List of Users Send News Letter SES SNS Send Token to fetch next User List Newsletter Function
  • 17. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Cloud Reports Architecture
  • 18. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. ReportersAnalyzersCollectors Collects Information from cloud provider Analyzes Information against best practices Generates Report in Various Formats
  • 19. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. API Gateway DynamoDBLambda Lambda SQS Cloud Reports Application S3 Validations Storing Meta-Data
  • 20. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Loop Prevention: • Code review • Data flow review Loop Detection: • Set up an invocation count alarm for each Lambda function and set notification using SNS. • Setting up Billing alerts to monitor resource usage.
  • 21. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Monitoring • Memory Utilization • Invocation Count • Duration of execution • Load testing with different memory size • Throttling • Dashboards
  • 22. © 2018, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Thank you

Editor's Notes

  1. Loop detection, monitoring, deployments, global variables, Over coming the time out limitations