- Learn AWS
- Architecture patterns
AWS architecture patterns
An architecture pattern is a shape a whole class of systems shares. Almost every brief — in an exam, in an interview, and at work — is one of these 16 with the names changed, so recognising the shape is most of the work. Each one below says when it is the right answer, the services it runs through, the phrases in a brief that point at it, and the trade-off it carries. Nothing has only upsides.
Static site
when the front end is files, not a server
A single-page app is a bundle of files. Nothing has to run to serve them, so nothing should. S3 holds the objects, CloudFront copies them to edge locations near each viewer, and there is no instance to patch or scale.
Static site in full →- Web clientBrowser / web client
- CloudFrontAmazon CloudFront
- S3Amazon S3
Serverless API
when ordinary requests, and nothing to patch
Request in, response out, with compute that exists only for the length of the call. API Gateway handles the front door and auth; Lambda scales with the request rate; DynamoDB keeps the latency flat as the table grows.
Serverless API in full →- Web clientBrowser / web client
- API Gateway (REST)Amazon API Gateway — REST API
- LambdaAWS Lambda
- DynamoDBAmazon DynamoDB
Queue-based load levelling
when the front takes more than the back can absorb
The classic answer to a spike hitting a system that cannot spike with it. Intake accepts and enqueues in milliseconds, so the customer gets an answer immediately; the worker drains at whatever rate the database can actually take. The queue is also the thing that stops an outage losing work.
Queue-based load levelling in full →Live updates
when the server has to push, not be asked
A WebSocket API keeps the connection open so the server can send without being asked, and bills per message rather than per hour. Redis holds the state everyone is watching, with counters and sorted sets for ranking and pub/sub to tell the other handlers something changed.
Live updates in full →- Web clientBrowser / web client
- API Gateway (WebSocket)Amazon API Gateway — WebSocket API
- LambdaAWS Lambda
- ElastiCache RedisAmazon ElastiCache for Redis
Classic three-tier
when a normal web application that has to stay up
The shape most enterprise applications actually are. A load balancer spreads traffic across instances in more than one Availability Zone, an Auto Scaling group replaces anything that dies, and a Multi-AZ database fails over without you. Unfashionable and completely correct for a stateful app you cannot rewrite.
Classic three-tier in full →Containerised services
when a long-running service that is not a single function
Between EC2 and Lambda. The container is your unit of deployment, Fargate runs it without you owning the host, and the load balancer routes to healthy tasks. The right answer when a process must stay warm, run longer than Lambda allows, or use a runtime Lambda does not.
Containerised services in full →- ALBApplication Load Balancer
- ECS on FargateAmazon ECS on AWS Fargate
- RDSAmazon RDS
Event fan-out
when one thing happens and several unrelated things must follow
The producer announces that something happened and stops caring. Each consumer subscribes to what it needs. Adding a fifth consumer later touches nothing that already exists, which is the whole reason to do it this way.
Event fan-out in full →- S3Amazon S3
- EventBridgeAmazon EventBridge
- LambdaAWS Lambda
- DynamoDBAmazon DynamoDB
Media processing pipeline
when uploads need heavy work that nobody is waiting on
Upload and processing are separate problems. The upload lands in S3 and returns immediately; the event queues the work; workers scale on queue depth and take minutes if they need to. A failed job retries without blocking the next one, and the finished asset is served from the edge.
Media processing pipeline in full →- S3Amazon S3
- EventBridgeAmazon EventBridge
- SQSAmazon SQS
- ECS on FargateAmazon ECS on AWS Fargate
- S3Amazon S3
- CloudFrontAmazon CloudFront
Streaming telemetry
when many devices sending small messages constantly
A stream, not a queue: the same records are read by several consumers independently and can be replayed. One consumer keeps the current state for dashboards, another writes history to S3 for analytics, a third watches for thresholds and alerts.
Streaming telemetry in full →- Kinesis Data StreamsAmazon Kinesis Data Streams
- LambdaAWS Lambda
- DynamoDBAmazon DynamoDB
- S3Amazon S3
Data lake and analytics
when questions are asked of history, not of live rows
Storage and query are separated. Everything lands cheaply in S3 in open formats, a catalog describes it, and query engines read it without a cluster running between questions. Analysts get SQL over years of data without touching the production database.
Data lake and analytics in full →- Data FirehoseAmazon Data Firehose
- S3Amazon S3
- GlueAWS Glue
- AthenaAmazon Athena
- QuickSightAmazon QuickSight
Workflow orchestration
when many steps, some slow, and failures must unwind
When a process is a sequence with retries, waits and compensations, the state machine should be explicit rather than smeared across services. Step Functions holds the state, retries a step without replaying the ones before it, and gives you one place to see where any order actually is.
Workflow orchestration in full →- API Gateway (REST)Amazon API Gateway — REST API
- Step FunctionsAWS Step Functions
- LambdaAWS Lambda
- RDSAmazon RDS
Cache-aside reads
when reads vastly outnumber writes and the database feels it
The application asks the cache first and falls back to the database on a miss, writing the answer back as it goes. Most reads never reach the database, which is what lets a modest instance serve a large audience.
Cache-aside reads in full →- ALBApplication Load Balancer
- ECS on FargateAmazon ECS on AWS Fargate
- ElastiCache RedisAmazon ElastiCache for Redis
- RDSAmazon RDS
Fan-out to independent consumers
when one event, several teams, none of them blocking each other
A topic fans the message out; each consumer gets its own queue. One slow or broken consumer backs up only its own queue, and its failures retry there instead of taking the publisher down with them.
Fan-out to independent consumers in full →Private service access
when traffic to AWS services must not cross the internet
A VPC endpoint gives a private route from your subnets to an AWS service, so private resources reach S3 or DynamoDB without a NAT Gateway or a public IP. Usually the answer when a compliance requirement appears in a networking question.
Private service access in full →- ECS on FargateAmazon ECS on AWS Fargate
- VPC EndpointVPC Endpoint / PrivateLink
- S3Amazon S3
Global multi-region
when users on several continents need the app to feel local
A full stack in each region and DNS sending people to the nearest healthy one. The edge absorbs the static and cacheable traffic; the regional stack handles what has to be computed near the user.
Global multi-region in full →- Route 53Amazon Route 53
- CloudFrontAmazon CloudFront
- ALBApplication Load Balancer
- ECS on FargateAmazon ECS on AWS Fargate
- DynamoDBAmazon DynamoDB
Pilot light disaster recovery
when a second region must exist, but not cost like one
Data is replicated continuously to a second region while the compute stays switched off, defined as templates. Recovery is bringing that stack up and repointing DNS — minutes, not days, at a fraction of running two production estates.
Pilot light disaster recovery in full →- RDSAmazon RDS
- S3Amazon S3
- CloudFormationAWS CloudFormation
- Route 53Amazon Route 53
Questions
- What is an AWS architecture pattern?
- A shape that a whole class of systems turns out to share — a static site, a queue in front of a slow back end, a load balancer across two Availability Zones. Naming the shape first is what stops a design being a pile of services: once you know a brief is queue-based load levelling, which queue and which compute are details rather than decisions.
- How many AWS architecture patterns are there?
- There is no fixed number — but 16 shapes cover most of what an exam asks about and most of what a small team builds. They are listed on this page, each with the signals in a brief that point at it and the trade-off it carries.
- How do I know which pattern a brief is asking for?
- By the phrases in it. Each pattern page lists its own signals — "must never reject an order" points at a queue, "users all over the world" points at a content delivery network, "cannot be rewritten" points at instances behind a load balancer rather than at functions. Reading for the signal before reading for the service is the habit worth building.
- Does every pattern have a downside?
- Yes, and each page says what its one is. A queue turns "done" into "accepted". Serverless brings cold starts and a data model you design around the access pattern. Containers bill while they idle. A shape with no stated trade-off is a shape somebody has not finished thinking about.
Reading a shape is half of it
The other half is producing one from a brief that never names a service. That is what the scenarios are for: you build the architecture on a canvas and it is scored against what the brief actually requires, with the reason behind every line.