Dhaval Nagar 28th July @ AppGambit
● 9 Amazon Web Service Certifications
● 2 Google Cloud Certifications
● Frequently writes about AWS and Cloud Technologies on
Medium.com
● Cloud Consultant to AWS Consulting Partners
● Create Certification Tests for Whizlabs
About me
Why Serverless!
No server is easier to manage than no server.
Werner Vogels, CTO, Amazon.com
No Infrastructure Provisioning,
no management
Automatic Scaling
Pay for only what you
use
High Availability and Secure
Environment
Serverless Consumption and Cost Model
Data Center IaaS Containers Serverless
Buying the Servers
and managing them
manually
Leasing/Renting the
Office
Leasing the space for
a day or few days
Renting the space for
few hours
Buying an Office
Space
Using Virtual
Machines in the Cloud
environment
Containers running for
defined duration
Short-lived Containers
/ Event driven
Backend as a Service
BaaS
Function as a Service
FaaS
Parse
Firebase
Auth0
Cognito
AWS Lambda
Google Cloud Functions
Azure Functions
Auth0 Webtask
Serverless and Event Driven Architecture
AWS Serverless Stack
● Alexa Skills
○ Amazon Alexa + Lambda
● Media transform on upload
○ Amazon S3 Events + Lambda
● On-the-fly image resizing
○ AWS Lambda@Edge + CloudFront
● Serverless Website
○ Amazon S3 + API Gateway + DynamoDB + CloudFront +
Lambda
● Ordered event process
○ Kinesis + Lambda
● Workflows
○ Step Functions + Lambda
Serverless Patterns
● Serverless event triggers
○ CloudWatch events + Lambda
● Serverless cron jobs
○ CloudWatch scheduled events + Lambda
● Serverless event triggers
○ CloudWatch events + Lambda
● Ordered event process
○ Kinesis + Lambda
● Workflows
○ Step Functions + Lambda
● Serverless cron jobs
○ CloudWatch scheduled events + Lambda
Serverless Patterns
● IoT Automation
○ Amazon IoT + Lambda
● Serverless Auth
○ Cognito + API Gateway authorizer + Lambda
● Stored Procedures
○ Aurora + Lambda
● Email rules
○ AWS SES + Lambda
● Compliance Management
○ AWS Config + Lambda
● DevOps
○ CloudWatch alarms + Lambda
Serverless Patterns
2018 re:Invent Serverless Announcements
● Lambda Layers
● Lambda - Bring Your Own Runtime (BYOR)
● WebSocket support for API Gateway
● ALB can now point to Lambda
● Firecracker - Open source Lambda Runtime
● Aurora Serverless
Framework Selection
Serverless Application Model
http://bit.ly/serverless-aws-sam
From AWS
CloudFormation based Templates
Integrated with AWS services
CloudFormation knowledge req.
Serverless Framework
https://serverless.com
Premium + Open Source
Community Driven
Lots of Plugins
Easy to Start
serverless.yml
service:
name: simpleService
provider:
name: aws
runtime: nodejs10.x
functions:
helloWorld:
handler: handler.helloWorld
events:
- http:
path: hello-world
method: get
module.exports.helloWorld = (event,
context, callback) => {
const response = {
statusCode: 200,
headers: {
'Access-Control-Allow-Origin': '*',
},
body: JSON.stringify({
message: `Hello, World`
}),
};
callback(null, response);
};
handler.js
Monitoring and Logging
● Lambda, API Gateway Dashboard
● AWS X-Ray
● Correlation IDs (Request Ids)
● CloudWatch Logs
● Kinesis Data Streams
● ElasticSearch
● 3rd Party Tools like IOPipes, Datadog, etc
Lambda Runtime and Layers (reduce size and
complexities)
● In case you are using any binary dependencies on local, make
sure you use suitable dependencies when you deploy your
lambdas to AWS
● Another easy option is to use Layers and get away from
uploading dependencies every time
● AWS Serverless Doc / https://aws.amazon.com/serverless/
● AWS Amplify / https://aws-amplify.github.io/
● AWS Lex / https://aws.amazon.com/lex/
● Alexa Blueprints / https://blueprints.amazon.com/
● AWS YouTube Channel
● Serverless Framework / https://serverless.com
● Serverless Stack / https://serverless-stack.com/
● Yan Cui / https://theburningmonk.com / AWS Serverless Hero
● Jeremy Daly / https://www.jeremydaly.com/ / AWS Serverless Hero
Resources
Upcoming Surat Meetups
● EC2 Spot and Low Cost Cloud Computing / August 2019
● Building Voice and Visual Skills for Amazon Alexa / August
2019
● Containers and Kubernetes on AWS
Thank You!

Serverless Day Zero: How to Serveless [July 2019]

  • 1.
    Dhaval Nagar 28thJuly @ AppGambit
  • 2.
    ● 9 AmazonWeb Service Certifications ● 2 Google Cloud Certifications ● Frequently writes about AWS and Cloud Technologies on Medium.com ● Cloud Consultant to AWS Consulting Partners ● Create Certification Tests for Whizlabs About me
  • 3.
    Why Serverless! No serveris easier to manage than no server. Werner Vogels, CTO, Amazon.com No Infrastructure Provisioning, no management Automatic Scaling Pay for only what you use High Availability and Secure Environment
  • 4.
    Serverless Consumption andCost Model Data Center IaaS Containers Serverless Buying the Servers and managing them manually Leasing/Renting the Office Leasing the space for a day or few days Renting the space for few hours Buying an Office Space Using Virtual Machines in the Cloud environment Containers running for defined duration Short-lived Containers / Event driven
  • 5.
    Backend as aService BaaS Function as a Service FaaS Parse Firebase Auth0 Cognito AWS Lambda Google Cloud Functions Azure Functions Auth0 Webtask
  • 6.
    Serverless and EventDriven Architecture
  • 7.
  • 8.
    ● Alexa Skills ○Amazon Alexa + Lambda ● Media transform on upload ○ Amazon S3 Events + Lambda ● On-the-fly image resizing ○ AWS Lambda@Edge + CloudFront ● Serverless Website ○ Amazon S3 + API Gateway + DynamoDB + CloudFront + Lambda ● Ordered event process ○ Kinesis + Lambda ● Workflows ○ Step Functions + Lambda Serverless Patterns
  • 9.
    ● Serverless eventtriggers ○ CloudWatch events + Lambda ● Serverless cron jobs ○ CloudWatch scheduled events + Lambda ● Serverless event triggers ○ CloudWatch events + Lambda ● Ordered event process ○ Kinesis + Lambda ● Workflows ○ Step Functions + Lambda ● Serverless cron jobs ○ CloudWatch scheduled events + Lambda Serverless Patterns
  • 10.
    ● IoT Automation ○Amazon IoT + Lambda ● Serverless Auth ○ Cognito + API Gateway authorizer + Lambda ● Stored Procedures ○ Aurora + Lambda ● Email rules ○ AWS SES + Lambda ● Compliance Management ○ AWS Config + Lambda ● DevOps ○ CloudWatch alarms + Lambda Serverless Patterns
  • 11.
    2018 re:Invent ServerlessAnnouncements ● Lambda Layers ● Lambda - Bring Your Own Runtime (BYOR) ● WebSocket support for API Gateway ● ALB can now point to Lambda ● Firecracker - Open source Lambda Runtime ● Aurora Serverless
  • 13.
    Framework Selection Serverless ApplicationModel http://bit.ly/serverless-aws-sam From AWS CloudFormation based Templates Integrated with AWS services CloudFormation knowledge req. Serverless Framework https://serverless.com Premium + Open Source Community Driven Lots of Plugins Easy to Start
  • 15.
    serverless.yml service: name: simpleService provider: name: aws runtime:nodejs10.x functions: helloWorld: handler: handler.helloWorld events: - http: path: hello-world method: get module.exports.helloWorld = (event, context, callback) => { const response = { statusCode: 200, headers: { 'Access-Control-Allow-Origin': '*', }, body: JSON.stringify({ message: `Hello, World` }), }; callback(null, response); }; handler.js
  • 16.
    Monitoring and Logging ●Lambda, API Gateway Dashboard ● AWS X-Ray ● Correlation IDs (Request Ids) ● CloudWatch Logs ● Kinesis Data Streams ● ElasticSearch ● 3rd Party Tools like IOPipes, Datadog, etc
  • 17.
    Lambda Runtime andLayers (reduce size and complexities) ● In case you are using any binary dependencies on local, make sure you use suitable dependencies when you deploy your lambdas to AWS ● Another easy option is to use Layers and get away from uploading dependencies every time
  • 18.
    ● AWS ServerlessDoc / https://aws.amazon.com/serverless/ ● AWS Amplify / https://aws-amplify.github.io/ ● AWS Lex / https://aws.amazon.com/lex/ ● Alexa Blueprints / https://blueprints.amazon.com/ ● AWS YouTube Channel ● Serverless Framework / https://serverless.com ● Serverless Stack / https://serverless-stack.com/ ● Yan Cui / https://theburningmonk.com / AWS Serverless Hero ● Jeremy Daly / https://www.jeremydaly.com/ / AWS Serverless Hero Resources
  • 19.
    Upcoming Surat Meetups ●EC2 Spot and Low Cost Cloud Computing / August 2019 ● Building Voice and Visual Skills for Amazon Alexa / August 2019 ● Containers and Kubernetes on AWS
  • 20.