SlideShare a Scribd company logo
Beginning
Serverless
Applications
With
AWS SAM
@Harprits
@NewsServerless
harprit
#01
An Overview
Serverless
002
Beginning Serverless Applications with AWS SAM
Beginning Serverless Applications with AWS SAM
Beginning Serverless Applications with AWS SAM
#02
A Developer’s View
06
Serverless
Applications
007
FaaSEvents BaaS
#03
AWS SAM – a framework for
building and managing
Serverless applications.
AWS
Serverless
Application
Model
08
09
Organize architectural
components of your serverless
application at one place.
SAM TEMPLATE
010
Manage lifecycle of your
serverless application with one
tool.
SAM CLI
011
AWSTemplateFormatVersion: 2010-09-09
Transform: AWS::Serverless-2016-10-31
Resources:
HelloWorldFunction:
Type: AWS::Serverless::Function
Properties:
CodeUri: target/helloworldsam-1.0.jar
Handler: com.Helloworldsam.App::handleRequest
Runtime: java8
Events:
HelloWorld:
Type: Api
Properties:
Path: /hello/{name}
Method: get
HelloWorldTable:
Type: AWS::Serverless::SimpleTable
Transform
Cloudformation
FaaS
Lambda
Event
API Gateway
Serverless Resource
DynamoDB Table
012
AWS::Serverless::Function
AWS::Serverless::Api
AWS::Serverless::SimpleTable
AWS::Serverless::Application
AWS::Serverless::LayerVersion
Serverless
Specific
Resources
013
Api
SNS
Schedule
SQS
Kinesis
DynamoDB
S3
CloudWatchEvent
CloudWatchLogs
IoTRule
AlexaSkill
Event
Sources Type: Api
Properties:
Path: /photos
Method: post
Type: S3
Properties:
Bucket: my-bucket
Events: s3:ObjectCreated:*
014
SAM
CLI
Commands
sam init
sam validate
sam build
sam local generate-event
sam local invoke
sam local start-api
sam local start-lambda
sam logs
sam package
sam deploy
sam publish
015
Local Testing and Debugging
sam local
AWS Ecosystem
Services, SAR, Cloud9
Serverless Friendly Cloudformation
one less thing to learn
Safe Lambda Deployments
CanaryXPercentYMinutes vs LinearXPercentEveryYMinutes
Why
SAM?
016
MyLambdaFunction:
Type: AWS::Serverless::Function
Properties:
Handler: index.handler
Runtime: nodejs6.10
AutoPublishAlias: live
DeploymentPreference:
Type: LinearXPercentEveryYMinutes
Traffic to new version will linearly increase in steps of X percentage every Y minutes. Ex:
Linear10PercentEvery10Minutes will add 10 percentage of traffic every 10 minute to complete in 100
minutes.
Type: CanaryXPercentYMinutes
X percent of traffic will be routed to new version for Y minutes. After Y minutes, 100 percent of traffic will be
sent to new version. Some people call this as Blue/Green deployment. Ex: Canary10Percent15Minutes will
send 10 percent traffic to new version and 15 minutes later complete deployment by sending all traffic to
new version.
Type: AllAtOnce
017
Demo

More Related Content

PDF
AWS ❤ SAM - Serverless on stage #9 (Milan, 20/02/2018)
PDF
Devops on serverless
PDF
AWS Community Day Ireland - Refactoring a serverless app
PDF
Building a Serverless Pipeline
PDF
"Automating AWS Infrastructure with PowerShell", Martin Beeby, AWS Dev Day Ky...
PDF
Serverless Apps with AWS Step Functions
PPTX
re:Invent 2019 CON328R Improving observability of your containers
PDF
Thinking Serverless (SVS213 AWS re:Invent 2019)
AWS ❤ SAM - Serverless on stage #9 (Milan, 20/02/2018)
Devops on serverless
AWS Community Day Ireland - Refactoring a serverless app
Building a Serverless Pipeline
"Automating AWS Infrastructure with PowerShell", Martin Beeby, AWS Dev Day Ky...
Serverless Apps with AWS Step Functions
re:Invent 2019 CON328R Improving observability of your containers
Thinking Serverless (SVS213 AWS re:Invent 2019)

Similar to Beginning Serverless Applications with AWS SAM (20)

PPTX
Aws serverless application repository
PDF
20180111 we bde-bs - serverless url shortener
PDF
Jak nie zwariować z architekturą Serverless?
PDF
Serverless Day Zero: How to Serveless [July 2019]
PPTX
Primeros pasos en desarrollo serverless
PDF
Building Serverless Microservices with AWS
PDF
Serverless architectures-with-aws-lambda
PDF
AWS and Serverless Computing
PDF
AWS Summit Singapore 2019 | The Serverless Lifecycle: Development and Operati...
PPTX
Meet AWS SAM
PDF
Modern Applications Web Day | Impress Your Friends with Your First Serverless...
PDF
Montréal AWS Users United: Let's go Serverless!
PDF
AWS SAM(Serverless Application Model) 을 이용한 백오피스 마이그레이션 (현창훈, HBSmith) :: AWS...
PDF
AWS DevDay AWS SAM을 이용한 백오피스 마이그레이션
PDF
AWS Serverless Introduction (Lambda)
PDF
Whizlabs webinar - Deploying Portfolio Site with AWS Serverless
PDF
Building serverless apps with Node.js
PDF
Serverless Toronto User Group - Let's go Serverless!
PDF
Serverless Computing
PDF
Contruyendo tu primera aplicación con AWS
Aws serverless application repository
20180111 we bde-bs - serverless url shortener
Jak nie zwariować z architekturą Serverless?
Serverless Day Zero: How to Serveless [July 2019]
Primeros pasos en desarrollo serverless
Building Serverless Microservices with AWS
Serverless architectures-with-aws-lambda
AWS and Serverless Computing
AWS Summit Singapore 2019 | The Serverless Lifecycle: Development and Operati...
Meet AWS SAM
Modern Applications Web Day | Impress Your Friends with Your First Serverless...
Montréal AWS Users United: Let's go Serverless!
AWS SAM(Serverless Application Model) 을 이용한 백오피스 마이그레이션 (현창훈, HBSmith) :: AWS...
AWS DevDay AWS SAM을 이용한 백오피스 마이그레이션
AWS Serverless Introduction (Lambda)
Whizlabs webinar - Deploying Portfolio Site with AWS Serverless
Building serverless apps with Node.js
Serverless Toronto User Group - Let's go Serverless!
Serverless Computing
Contruyendo tu primera aplicación con AWS
Ad

Recently uploaded (20)

PDF
Machine learning based COVID-19 study performance prediction
PPTX
Programs and apps: productivity, graphics, security and other tools
PDF
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
PDF
Electronic commerce courselecture one. Pdf
PDF
cuic standard and advanced reporting.pdf
PDF
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
PPTX
MYSQL Presentation for SQL database connectivity
PPT
Teaching material agriculture food technology
PDF
Dropbox Q2 2025 Financial Results & Investor Presentation
PDF
Encapsulation theory and applications.pdf
PPTX
ACSFv1EN-58255 AWS Academy Cloud Security Foundations.pptx
PPTX
Digital-Transformation-Roadmap-for-Companies.pptx
PDF
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
PDF
Agricultural_Statistics_at_a_Glance_2022_0.pdf
DOCX
The AUB Centre for AI in Media Proposal.docx
PDF
Review of recent advances in non-invasive hemoglobin estimation
PPTX
Spectroscopy.pptx food analysis technology
PDF
Unlocking AI with Model Context Protocol (MCP)
PPTX
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
PDF
Building Integrated photovoltaic BIPV_UPV.pdf
Machine learning based COVID-19 study performance prediction
Programs and apps: productivity, graphics, security and other tools
Build a system with the filesystem maintained by OSTree @ COSCUP 2025
Electronic commerce courselecture one. Pdf
cuic standard and advanced reporting.pdf
Optimiser vos workloads AI/ML sur Amazon EC2 et AWS Graviton
MYSQL Presentation for SQL database connectivity
Teaching material agriculture food technology
Dropbox Q2 2025 Financial Results & Investor Presentation
Encapsulation theory and applications.pdf
ACSFv1EN-58255 AWS Academy Cloud Security Foundations.pptx
Digital-Transformation-Roadmap-for-Companies.pptx
How UI/UX Design Impacts User Retention in Mobile Apps.pdf
Agricultural_Statistics_at_a_Glance_2022_0.pdf
The AUB Centre for AI in Media Proposal.docx
Review of recent advances in non-invasive hemoglobin estimation
Spectroscopy.pptx food analysis technology
Unlocking AI with Model Context Protocol (MCP)
VMware vSphere Foundation How to Sell Presentation-Ver1.4-2-14-2024.pptx
Building Integrated photovoltaic BIPV_UPV.pdf
Ad

Beginning Serverless Applications with AWS SAM