Cloud computing model where the provider manages infrastructure automatically, allowing code execution without provisioning or managing servers, paying only for actual usage.
Serverless is a cloud execution model where the provider allocates resources dynamically and charges only for compute consumed. It doesn't mean "no servers" — it means the developer doesn't manage them. The provider handles provisioning, scaling, patching, and availability.
| Service | Function |
|---|---|
| Lambda | Functions as a Service (FaaS) |
| API Gateway | HTTP/REST/WebSocket APIs |
| DynamoDB | NoSQL database |
| S3 | Object storage |
| Step Functions | Workflow orchestration |
| EventBridge | Event bus |
| SQS / SNS | Messaging |
A cold start occurs when Lambda creates a new execution environment. Latency varies significantly by runtime and package size:
| Runtime | Typical cold start | With SnapStart/provisioned |
|---|---|---|
| Node.js | 100–300 ms | N/A |
| Python | 150–400 ms | N/A |
| Java | 1–3 s | 200–400 ms with SnapStart |
| .NET | 400–800 ms | 100–200 ms with Native AOT |
| Rust/Go | 10–30 ms | Not needed |
Mitigation strategies:
| Criteria | Serverless (Lambda) | Containers (Fargate) |
|---|---|---|
| Maximum duration | 15 minutes | No limit |
| Scaling | Automatic, per invocation | Automatic, by metrics (slower) |
| Cold start | 100 ms – 3 s | 30–60 s (task provisioning) |
| Idle cost | $0 | Cost per vCPU/memory while running |
| High traffic cost | Can be high (per invocation) | More predictable (per hour) |
| State | Stateless | Can maintain in-memory state |
| Networking | Optional VPC, slow ENI | Native VPC, full networking |
Use serverless when: variable or unpredictable traffic, short executions (under 15 min), small teams wanting zero ops, event-driven architectures.
Use containers when: long-running processes, need for in-memory state, constant and predictable traffic, complex networking requirements.
Lambda charges $0.20 per million invocations plus $0.0000166667 per GB-second. For an API with 1 million requests/month, 256 MB memory, and 200 ms average:
The same load on Fargate (0.25 vCPU, 0.5 GB, running 24/7): ~$9.10/month. Serverless wins for variable loads. But at 100M requests/month, Lambda costs ~$103 while Fargate stays at ~$9.10 — the crossover point depends on the traffic pattern.
Serverless eliminates server management and payment for idle capacity. For workloads with variable traffic — APIs, event processing, scheduled tasks — the pay-per-execution model can dramatically reduce costs while scaling automatically.
AWS serverless compute service that runs code in response to events without provisioning or managing servers, automatically scaling from zero to thousands of concurrent executions.
Practice of defining and managing infrastructure through versioned configuration files instead of manual processes. Foundation of modern operations automation.
Architectural pattern where components communicate through asynchronous events, enabling decoupled, scalable, and reactive systems.
Serverless compute engine for containers that eliminates server management, allowing Docker container execution paying only for consumed resources.
AWS serverless service providing access to foundation models from multiple providers (Anthropic, Meta, Mistral, Amazon) via unified API, without managing ML infrastructure.
Development approach leveraging cloud advantages: containers, microservices, immutable infrastructure, and declarative automation for scalable and resilient systems.
Practices and strategies to minimize cloud spending without sacrificing performance, including right-sizing, reservations, spot instances, and eliminating idle resources.
Architecture design for scaling a personal second brain to a production system with AWS serverless — from the current prototype to specialized use cases in legal, research, and community building.
Chronicle of building a second brain with a knowledge graph, bilingual pipeline, and agent endpoints — in days, not weeks, and what that teaches about the gap between theory and working systems.
Collection of 13 Terraform modules published on the Terraform Registry for deploying serverless architectures on AWS, with 12 examples covering basic ECS to full-stack CRUD with DynamoDB and AgentCore with MCP.
Slidev presentation on 10 reasons to adopt a serverless-first architecture. Deployed on GitHub Pages.
Production-ready serverless backend for a personal knowledge graph — DynamoDB, Lambda, Bedrock, MCP, Step Functions. The implementation of the architecture described in the 'From Prototype to Production' essay.
Personal lab for serverless architecture experiments: prototypes, patterns, and learnings about event-driven applications on AWS.
Serverless GitHub App that auto-approves pull requests after CI passes, with optional AI code review via Amazon Bedrock. Five repositories: TypeScript/Probot app, AWS Terraform module (Lambda + API Gateway + Secrets Manager + SQS DLQ), GitHub Terraform module (webhooks), deployment infra, and test repo.
Devcontainer template for serverless fullstack development with Python backend, React frontend, and local AWS services.
Web applications using modern technologies to deliver native app-like experiences: installable, offline-capable, and with push notifications.
React framework for full-stack web applications with Server Components, file-based routing, SSR/SSG, and built-in performance optimizations.
Practices for implementing effective logging in distributed systems: structured logging, levels, correlation, and centralized aggregation.
Techniques to reduce cost, latency, and resources needed to run language models in production, from quantization to distributed serving.
AWS framework with six pillars of best practices for designing and operating reliable, secure, efficient, and cost-effective cloud systems.
AWS serverless orchestration service that coordinates multiple services into visual workflows using Amazon States Language (ASL), with built-in error handling, retries, and parallel execution.
AWS fully managed message queue service that decouples distributed application components, guaranteeing message delivery with unlimited scalability.
AWS pub/sub messaging service that distributes messages to multiple subscribers simultaneously, enabling fan-out patterns and notifications at scale.
AWS open-source framework for building serverless applications with simplified CloudFormation syntax, CLI for local development, and integrated deployment.
AWS object storage service with 99.999999999% durability, unlimited scalability, and multiple storage classes for cost optimization.
AWS serverless event bus connecting applications using events, enabling decoupled event-driven architectures with rule-based routing.
AWS serverless NoSQL database with single-digit millisecond latency at any scale, ideal for applications requiring high performance and automatic scalability.
AWS managed service for creating, publishing, and managing REST, HTTP, and WebSocket APIs that act as entry points to Lambda functions and other backend services.
Pattern providing a single entry point for multiple microservices, handling routing, authentication, rate limiting, and response aggregation.