A 4-Step Framework for System Design Interviews & Architecture Reviews
Why Structure Beats Memorization
4-Step System Design Framework
Step 1: Understand the Problem & Establish Scope (5–10 Minutes)
- Functional Requirements (Core Flows):
- Which 2–3 user journeys are actually in scope? (e.g., for YouTube: upload + stream video, skip comments/live chat unless requested).
- Scale & Non-Functional Requirements:
- Daily Active Users (DAU), Read-to-Write ratio, expected growth rate.
- Latency targets (e.g.,
< 100msp99) vs. consistency guarantees (Strong ACIDvs.Eventual). - Availability targets (
99.9%vs.99.999%).
- Quick Capacity Check:
- Estimate QPS, peak QPS, storage growth, and bandwidth to anchor every later choice.
Step 2: Propose High-Level Design & Get Buy-In (10–15 Minutes)
- Define Public APIs & Contracts:
- Explicitly sketch
POST /v1/...andGET /v1/...request/response payloads, or WebSocket/gRPC contracts.
- Explicitly sketch
- Draw the End-to-End Component Diagram:
- Clients → DNS/CDN → API Gateway → Core Stateless Services → Caches → Storage/Queues.
- Design Core Data Schemas:
- Choose SQL vs. NoSQL and justify why based on query patterns and transaction guarantees.
- Trace Primary Flows:
- Walk through one write path and one read path end-to-end to prove components fit cleanly.
Pro Tip: Pause after drawing the high-level diagram and confirm alignment with stakeholders before diving deep into optimizations.
Step 3: Design Deep Dive (15–20 Minutes)
- Read-Heavy Feed/URL Service: Multi-layer caching (CDN + Redis), fanout hybrid for celebrity users, bloom filters.
- Write-Heavy Telemetry/Logs: Partitioned message queues, batch ingestion, LSM-tree storage (Cassandra/ClickHouse), downsampling.
- Financial / Booking Systems: Idempotency keys, optimistic/pessimistic locking, double-entry ledgers, Saga/TCC compensation.
- Geo-Spatial Systems: Geohash precision vs. Quadtree adaptive grids, WebSocket pub/sub channels.
Always Articulate Trade-Offs
- Consistency vs. Availability (CAP/PACELC)
- Latency vs. Durability (
acks=1vs.acks=all) - Storage Cost vs. Compute (pre-computing feeds vs. merging at read time)
Step 4: Wrap Up, Failure Modes & Operations (5 Minutes)
- Single Points of Failure (SPOFs): What happens if a Redis cluster, primary DB, or entire Availability Zone goes offline?
- Observability: Which golden signals (P99 latency, consumer lag, cache hit ratio, error rates) trigger alerts?
- Scaling Path: How does this design evolve from $1\times$ to $10\times$ traffic without a complete rewrite?
Common Anti-Patterns to Avoid
- Designing in silence without checking alignment.
- Dropping buzzwords ("we'll add Kubernetes and Kafka") without explaining why a simpler queue or VM wouldn't work.
- Ignoring failure recovery, retries, and backpressure.