๐๐ผ๐ ๐๐ผ ๐ฎ๐ป๐๐๐ฒ๐ฟ ๐๐๐๐๐ฒ๐บ ๐ฑ๐ฒ๐๐ถ๐ด๐ป ๐พ๐๐ฒ๐๐๐ถ๐ผ๐ป๐ ๐๐๐ถ๐ป๐ด ๐๐ต๐ฒ ๐ฆ๐๐๐๐ฒ๐บ ๐๐ฒ๐๐ถ๐ด๐ป ๐ ๐ฎ๐๐๐ฒ๐ฟ ๐ง๐ฒ๐บ๐ฝ๐น๐ฎ๐๐ฒ?
Here is the System Design Master Template, which you can use as a basis for any system design problem you may encounter during an interview.
A list of topics that you should know:
๐ญ. ๐๐ผ๐ฎ๐ฑ ๐๐ฎ๐น๐ฎ๐ป๐ฐ๐ฒ๐ฟ. Distributes inbound requests across healthy nodes using rules such as round-robin or least-connections. Keeps latency stable and enables rolling upgrades without downtime.
๐ฎ. ๐๐ฃ๐ ๐๐ฎ๐๐ฒ๐๐ฎ๐. Single entry that authenticates callers, enforces quotas, and routes each call to the right microservice. It can also aggregate responses so that clients hit a single endpoint.
๐ฏ. ๐๐ผ๐ป๐๐ฒ๐ป๐ ๐๐ฒ๐น๐ถ๐๐ฒ๐ฟ๐ ๐ก๐ฒ๐๐๐ผ๐ฟ๐ธ (๐๐๐ก). An edge network that caches immutable assets near users, cutting round-trips and shielding origins from spikes. Often handles TLS and compression as well.
๐ฐ. ๐ ๐ฒ๐๐ฎ๐ฑ๐ฎ๐๐ฎ ๐ฆ๐ฒ๐ฟ๐๐ฒ๐ฟ. Stores pointers, permissions, and object properties in a small, fast store. Replicates data for reads and writes to block servers when files are changed.
๐ฑ. ๐๐น๐ผ๐ฐ๐ธ ๐ฆ๐ฒ๐ฟ๐๐ฒ๐ฟ. Persists data chunks on commodity disks, replicates across racks, and self-heals after failures. Clients stream blocks in parallel for throughput.
๐ฒ. ๐ฆ๐ต๐ฎ๐ฟ๐ฑ / ๐ฃ๐ฎ๐ฟ๐๐ถ๐๐ถ๐ผ๐ป ๐ ๐ฎ๐ป๐ฎ๐ด๐ฒ๐บ๐ฒ๐ป๐. Splits a growing dataset by user ID, time, or hash so that each DB instance remains small. Rebalances shards when a node fills or a hot key appears.
๐ณ. ๐๐ฎ๐ฐ๐ต๐ฒ (๐ฅ๐ฒ๐ฑ๐ถ๐/๐ ๐ฒ๐บ๐ฐ๐ฎ๐ฐ๐ต๐ฒ๐ฑ). Holds hot keys in RAM with TTL, counters, and locks. Reduces read latency from milliseconds to microseconds and offloads the primary store.
๐ด. ๐๐ถ๐๐๐ฟ๐ถ๐ฏ๐๐๐ฒ๐ฑ ๐ ๐ฒ๐๐๐ฎ๐ด๐ถ๐ป๐ด (๐๐ฎ๐ณ๐ธ๐ฎ/๐ฅ๐ฎ๐ฏ๐ฏ๐ถ๐๐ ๐ค). Durable log that decouples producers from consumers, provides replay, back-pressure, and at-least-once delivery. Enables event-driven designs.
๐ต. ๐ก๐ผ๐๐ถ๐ณ๐ถ๐ฐ๐ฎ๐๐ถ๐ผ๐ป ๐ฆ๐ฒ๐ฟ๐๐ถ๐ฐ๐ฒ. Pulls events from the queue, batches them, and pushes email, SMS, or mobile alerts. Retries with exponential back-off and user-level throttling.
๐ญ๐ฌ. ๐๐ผ๐ฏ ๐ช๐ผ๐ฟ๐ธ๐ฒ๐ฟ๐. Stateless containers that pick tasks such as video encoding or thumbnail generation from a queue. Scale horizontally by adding replicas.
๐ญ๐ญ. ๐๐ถ๐๐๐ฟ๐ถ๐ฏ๐๐๐ฒ๐ฑ ๐๐ผ๐ด๐ด๐ถ๐ป๐ด ๐ฎ๐ป๐ฑ ๐ง๐ฟ๐ฎ๐ฐ๐ถ๐ป๐ด. Ships structured logs and distributed spans to a central store, then indexes by request ID. Let's you trace a single user action across dozens of services.
๐ญ๐ฎ. ๐๐ฎ๐๐ฐ๐ต / ๐ฆ๐๐ฟ๐ฒ๐ฎ๐บ ๐ฃ๐ฟ๐ผ๐ฐ๐ฒ๐๐๐ถ๐ป๐ด (๐ฆ๐ฝ๐ฎ๐ฟ๐ธ, ๐๐ฎ๐ฑ๐ผ๐ผ๐ฝ). Transforms raw events into aggregates, ML features, and reports. Supports windowed joins for near-real-time dashboards.
๐ญ๐ฎ. ๐ ๐ฒ๐๐ฟ๐ถ๐ฐ๐ ๐ฎ๐ป๐ฑ ๐๐น๐ฒ๐ฟ๐๐ถ๐ป๐ด. Scrapes time-series data, stores it efficiently, and renders dashboards. The Alert Rules page alerts you when latency, error rate, or saturation crosses SLOs.