James Strong
Technical Principal @ Contino
AWS SAM template specification
Transform: 'AWS::Serverless-2016-10-31'
Resources:
ThumbnailFunction:
# This resource creates a Lambda function.
Type: 'AWS::Serverless::Function'
Properties:
# This function uses the Nodejs v6.10 runtime.
Runtime: nodejs6.10
# This is the Lambda function's handler.
Handler: index.handler
# The location of the Lambda function code.
CodeUri: ./src
# Event sources to attach to this function. In this case, we are attaching
# one API Gateway endpoint to the Lambda function. The function is
# called when a HTTP request is made to the API Gateway endpoint.
Events:
ThumbnailApi:
# Define an API Gateway endpoint that responds to HTTP GET at /thumbnail
Type: Api
Properties:
Path: /thumbnail
Method: GET
“AWS Lambda is a compute resource that runs your code in response to events and automatically manages the compute resources for you, making it easy to build applications that respond quickly to new information”
“Run and forget”
Drawback: Does NOT respond to HTTP Events
Serverless Web scale NOSQL AWS managed database.
Web Scale Storage
There’s three basic options for structuring this using AWS Lambda:
Spend more time programming. One command for an instant, secure URL to your localhost server through any NAT or firewall.
brew upgrade
brew update
brew tap aws/tap
brew install aws-sam-cli
go get github.com/aws/aws-sdk-go
go get github.com/aws/aws-lambda-go/events
go get github.com/aws/aws-lambda-go/lambda
go get github.com/awslabs/aws-lambda-go-api-proxy
go get github.com/awslabs/aws-lambda-go-api-proxy/gin
docker run -p 8000:8000 amazon/dynamodb-local:1.11.477
This is great if we stick to the AWS Cloudformation