Serverless on AWS in thirty-eight slides: the worker fleet replaced by a function; a Lambda function, its execution environment, the handler, the execution role and the resource-based policy; synchronous, asynchronous and event source mapping invocations, retries and destinations; concurrency, reserved and provisioned, cold starts and the limits that force another choice; Lambda in a VPC, layers, container images, versions and aliases; API Gateway, REST and HTTP APIs, stages, throttling, caching and authorizers; Cognito user pools and identity pools; serverless patterns with S3, DynamoDB Streams and SQS, AppSync and Amplify, and the cost of Lambda against Fargate and EC2. Every section ends with five exam questions.
The slides
The tool is thirty-eight slides: an introduction, then seven sections, listed on its left. Every section ends with five
exam questions, each with its answer and the tempting wrong answer.
- 0. Introduction
- Serverless: Lambda, API Gateway, Cognito: the project after this session's lab.
- The worker fleet and the function that replaces it: session 10's Auto Scaling group beside one function.
- 1. The execution model
- A Lambda function: the code, the handler, the runtime, the memory, the timeout, the two policies.
- The execution environment: Init, Invoke, frozen, Shutdown.
- The handler: event and context: what runs once, and what runs for each invocation.
- The execution role: Lambda assumes a role: the IAM thread, beside session 3's instance role.
- Two policies on every function: who may invoke it, and what it may call.
- 2. Invocation
- Three ways Lambda is invoked: synchronous, asynchronous, event source mapping.
- Asynchronous invocation: the event queue, the retries, the destinations.
- An event source mapping: batches from SQS, the visibility timeout, the dead-letter queue.
- 3. Concurrency and limits
- Concurrency: environments at the same time, Reserved and provisioned concurrency and A cold start.
- The limits that force another choice: the 15-minute timeout, the payloads, and what to use beyond them.
- 4. VPC access and packaging
- Lambda in a VPC: Hyperplane ENIs and the NAT gateway.
- Layers and container images and Versions and aliases.
- 5. API Gateway
- Amazon API Gateway, REST APIs and HTTP APIs, Deployments and stages.
- Throttling: a token bucket, Caching responses (REST APIs), Authorizers: who may call the API.
- 6. Cognito
- A Cognito user pool, A Cognito identity pool, and the two together.
- 7. Serverless patterns
- S3 events to Lambda, DynamoDB Streams to Lambda, SQS between a producer and a function.
- AWS AppSync and AWS Amplify.
- Lambda, Fargate or EC2: the cost of one workload: one API's monthly bill on each, as its requests grow.
The buttons on the left and right edges move between slides. So do the arrow keys and a swipe.
The lab
Serverless Lab: the Worker, the API and the Stream practices it.
The limits and prices were read from AWS's documentation and pricing pages on 2026-11-16: Lambda in us-east-1 on x86
($0.20 per million requests, $0.0000166667 per GB-second), Fargate on Linux x86 ($0.000011244 per vCPU-second,
$0.000001235 per GB-second) and a t3.micro On-Demand ($0.0104 an hour, read with the Price List API). The cost chart
leaves the free tiers out. The account ID, the API ID and the request IDs are AWS's documentation placeholders.
Sources