System Design Interview Questions — SD Architecture Practice

Reviewed by Mark Dickie · Last updated

System design is the practice of defining a software system's architecture, components, data flow, and interfaces before implementation begins. For interview purposes, it tests how you reason about large-scale systems under real-world constraints like latency, throughput, fault tolerance, and cost. The questions on this page focus on architectural decisions: how you choose between a monolith and microservices, where you place caching and message queues, how you partition data, and how you justify each choice with concrete trade-offs. A strong candidate draws diagrams, names specific technologies, and explains what breaks first when load triples.

ConceptWhat the Interviewer Listens For
Load balancingRound-robin vs consistent hashing; stateless vs stateful routing
CachingWrite-through vs write-behind; cache invalidation strategy; CDN placement
Database scalingVertical vs horizontal sharding; read replicas; CAP theorem trade-offs
Message queuesAt-least-once vs exactly-once delivery; partition ordering; backpressure
API designREST vs gRPC vs GraphQL; idempotency; rate limiting strategy
ObservabilityMetrics vs logs vs traces; SLO definitions; alerting thresholds

What does a system design interview actually test?

Most SD architecture rounds are open-ended: the interviewer gives a problem like "design a URL shortener" or "design a notification system," and you have 40–45 minutes to walk through it on a whiteboard or shared doc. They are not looking for a single correct answer. They want to see your process: clarifying requirements, estimating capacity, sketching a high-level diagram, then going deep on one or two components. If you jump straight to a solution without asking about scale (reads vs writes, consistency needs, SLA targets), that is a red flag.

How should you structure your answer during the round?

  1. Clarify requirements — functional and non-functional. Ask about expected QPS, data volume, latency targets, and consistency guarantees before drawing anything.
  2. Estimate capacity — back-of-the-envelope numbers for storage, bandwidth, and connections. These do not need to be exact, but they should be in the right order of magnitude.
  3. Draw the high-level architecture — boxes for clients, load balancers, app servers, databases, caches. Show data flow arrows and label protocols.
  4. Go deep on a bottleneck — pick the component most likely to fail under load and explain your mitigation: sharding strategy, replication lag handling, cache eviction policy, queue backpressure.
  5. Discuss failure modes — what happens when a node dies, when a partition occurs, when traffic spikes 10x. Name the specific behavior (retry, circuit break, degrade gracefully).

What are the most common architecture patterns to know?

The patterns that come up again and again in SD interviews are: reverse proxy and load balancing layers, leader-follower database replication, consistent hashing for distributed caches and databases, partitioned (sharded) data stores, publish-subscribe messaging, and the CQRS/event-sourcing combination for high-write systems. You should be able to explain each one in a sentence, name a real-world system that uses it, and state its main drawback. Interviewers frequently probe the drawback — they want to see that you understand why a pattern is not universal.

Key facts

  • Tarmac has 50 System Design interview questions on this topic, 10 of them on this page, at difficulty 1–5 of 5.
  • Tarmac last reviewed these System Design interview questions on 10 August 2026.

At a glance

Questions10 shown · 50 in the bank
Difficulty1–5 of 5
FormatsTrue / false, Fill in the blank, Multiple answer, Multiple choice, Ordering

What you'll review

  1. sd architecture

Practice questions

System Design/sd-architecture

A monolithic architecture packages all application components (UI, business logic, and data access) into a single deployable unit, which means the entire application must be redeployed whenever any component changes.#

Options

Show answer

True. In a monolithic architecture, all components—UI, business logic, and data access—are packaged into one deployable unit. A change to any component requires rebuilding and redeploying the entire application. This coupling is a primary reason teams adopt microservices, which allow individual services to be deployed independently.

Why:

By definition, a monolith is a single deployable artifact. All components are tightly coupled and compiled/packaged together. Any code change—regardless of which layer it affects—requires rebuilding and redeploying the whole unit. This is one of the key motivations for moving toward microservices, which allow individual components to be deployed independently.

System Design/sd-architecture

Complete the two key concepts: A _____ balances incoming network traffic across multiple servers to improve availability and throughput. When user session data must remain on the same server for the duration of a session, this is called _____ persistence.#

Show answer

Complete the two key concepts: A load balancer balances incoming network traffic across multiple servers to improve availability and throughput. When user session data must remain on the same server for the duration of a session, this is called sticky persistence.

Why:

A load balancer sits in front of a pool of servers and distributes client requests using algorithms such as round-robin or least-connections. When an application stores session state locally on a specific server, a 'sticky session' (also called session affinity) configuration tells the load balancer to always route a given client to the same backend server so that session data remains accessible. This avoids the need to share session state across servers but can create uneven load distribution.

System Design/sd-architecture

In a stateless web architecture, any server in the pool can handle any incoming request without needing access to session data stored on a specific server.#

Options

Show answer

True — in a stateless web architecture, no application server stores session data locally. State is kept in a shared external store (like Redis or a database) or carried in the request (e.g., a JWT). This means any server can handle any request, enabling simple horizontal scaling and eliminating 'sticky session' requirements.

Why:

Stateless architecture means no session or user state is persisted on individual application servers. Session data is either stored in a shared external store (e.g., Redis, a database) or encoded in the request itself (e.g., a signed JWT). Because no server holds unique local state, any server can serve any request, making horizontal scaling and failover straightforward. This is a foundational principle behind scalable, cloud-native architectures.

System Design/sd-architecture

A team is designing a caching layer (e.g., Redis) in front of a relational database. Identify all correct statements about common cache-writing strategies:#

Options

Pick every one that applies.

Show answer

The correct statements are 1, 2, and 4. Write-through synchronously writes to both cache and DB; write-behind writes to cache first and flushes to the DB asynchronously; and write-behind risks data loss if the cache crashes before flushing. Statement 3 is false because write-through has higher write latency (it waits for a synchronous DB write). Statement 5 is false because read-through is a reactive/lazy strategy triggered by cache misses, not a proactive pre-population technique.

Why:

Statements 1, 2, and 4 are correct. Write-through (Statement 1) synchronously writes to both the cache and the database on every write, keeping them consistent for written keys at the cost of higher write latency. Write-behind / write-back (Statement 2) writes to the cache first and flushes to the database asynchronously, improving write throughput. Write-behind (Statement 4) does risk data loss: if the cache node crashes before the asynchronous flush completes, those pending writes are lost.

Statement 3 is false. Write-through has higher write latency than write-behind because it must wait for both the cache write and the synchronous database write to complete before acknowledging success; write-behind returns as soon as the cache write is done.

Statement 5 is false. Read-through is a reactive (lazy) strategy: the cache intercepts a read, detects a miss, fetches the data from the database on behalf of the caller, populates the cache, and then returns the result. Proactive pre-population before any miss occurs describes cache warming (or cache priming), not read-through.

System Design/sd-architecture

You are designing a globally distributed, multi-region active-active database (e.g., a shopping-cart service). Each region accepts both reads and writes and replicates asynchronously to the others. A user updates their cart from two different regions nearly simultaneously before either update has replicated.#

Options

Show answer

Vector clocks (or version vectors) with application-level or CRDT-based merging are the best fit. They capture causal relationships between writes across regions, allowing the system to detect true conflicts (concurrent writes with no causal ordering) and apply deterministic merge logic — without requiring cross-region coordination on the write path. LWW risks silent data loss due to clock skew, 2PC sacrifices availability, and read repair only acts on the read path.

Why:

In a multi-region active-active architecture, the core challenge with eventual consistency is handling concurrent writes to the same record from different regions. Vector clocks (or similar mechanisms like CRDTs) track causality across nodes so that conflicts can be detected and resolved rather than silently overwriting data. Last-Write-Wins (LWW) based solely on wall-clock time is unsafe because clocks can skew, making it possible to overwrite a newer write with an older one. Two-phase commit provides strong consistency but introduces cross-region coordination latency and is an availability risk — the opposite of what active-active targets. Read repair is a read-path technique and does not prevent write conflicts. Vector clocks remain the standard causality-tracking answer for active-active replication conflict detection.

System Design/sd-architecture

A distributed key-value store experiences a network partition that splits its nodes into a majority group and a minority group. Arrange the following architectural decision steps in the correct order a system architect should reason through when handling this scenario, from first principle to final action:#

Put these in order

Show answer

The correct order is: (A) Detect the partition → (B) Identify majority vs. minority nodes → (C) Determine CP vs. AP SLA → (D) Enforce the policy (CP: reject minority writes outright; AP: accept all writes and track divergence) → (E) Reconcile after healing (AP: conflict resolution; CP: minority re-syncs from the majority log). Identifying the majority/minority split must precede enforcement, and true CP systems reject — not queue — minority-side writes.

Why:

The question tests deep understanding of the CAP theorem applied to a concrete split-brain scenario. First, the system must detect the partition (A) — without detection, no decision can be made. Second, nodes must identify majority vs. minority (B) — this quorum assessment is a prerequisite to knowing which side to suppress or allow. Third, the architect must consult the system's SLA to decide between CP and AP behaviour (C). Fourth, the system enforces that decision (D): an AP system (e.g., Cassandra, DynamoDB) accepts writes on both sides and logs divergence; a true CP system (e.g., etcd, ZooKeeper — both Raft/Paxos-based) outright rejects writes that cannot achieve quorum on the minority side — queuing writes would defer the consistency decision and is an AP-leaning strategy, not CP. Finally, after healing (E), AP systems perform conflict resolution (LWW, vector clocks, CRDTs); CP systems simply re-sync minority nodes from the authoritative majority log, because those minority nodes accepted no writes and have nothing to replay.

System Design/sd-architecture

A senior engineer is reviewing a system design document for a high-traffic e-commerce platform. Which of the following architectural statements are correct? Select all that apply.#

Options

Pick every one that applies.

Show answer

The correct statements are (b), (c), and (d). A message queue like Kafka decouples producers and consumers and smooths traffic spikes. Stateful services require externalised or sharded state before horizontal scaling; just adding instances risks split-brain. Read replicas offload read traffic from the primary. Option (a) is wrong because CDNs cache HTTP responses at the edge — they cannot introspect or cache arbitrary database query results.

Why:

This question probes several common but costly misconceptions in large-scale system design. (1) Adding a CDN for database query caching is FALSE — CDNs cache static or edge-cacheable HTTP responses, not raw database queries; that role belongs to an in-process or distributed cache like Redis. (2) A message queue (e.g., Kafka, SQS) decouples producers from consumers and naturally absorbs traffic spikes by acting as a buffer, so bursts don't overwhelm downstream services — TRUE. (3) Horizontal scaling of stateful services is NOT simply a matter of adding instances; state must be externalised or partitioned (sharding, consistent hashing) to avoid split-brain and inconsistency — FALSE. (4) Database read replicas reduce load on the primary by offloading read traffic — TRUE. All four require careful evaluation, making this a multi-select question.

System Design/sd-architecture

You operate a multi-tenant SaaS platform backed by a horizontally sharded database. One shard becomes a persistent hot spot because a single mega-tenant drives 60 % of all writes. Which of the following strategies does NOT generally mitigate a write-heavy hot partition for that tenant?#

Options

Show answer

Adding read replicas does NOT mitigate a write-heavy hot partition. Read replicas offload read traffic to secondary copies, but every write still routes to the primary shard — so the write bottleneck is completely unchanged. Strategies that actually reduce write pressure include re-sharding with virtual nodes, write-behind/coalescing caches, and splitting the hot shard into finer-grained child shards.

Why:

All four techniques are valid strategies for avoiding hot partitions in high-throughput distributed systems. Consistent hashing with virtual nodes spreads load evenly across nodes and handles node churn gracefully. Write-behind caching absorbs burst writes before they hit the storage layer. Shard splitting (range sub-partitioning) breaks a hot shard into smaller shards to distribute the hot key range. However, simply adding read replicas only helps with read-heavy hot spots; it does NOT alleviate write hot spots because all writes must still go to the primary. If the hot partition is write-heavy — the most common production scenario — read replicas are ineffective. The question asks which strategy does NOT generally mitigate a write-skewed hot partition, making read replicas the correct answer.

System Design/sd-architecture

You are designing a globally distributed database that must satisfy:#

Options

Show answer

A Paxos/Raft-based geo-distributed consensus protocol cannot provide both strong consistency and high availability across multiple regions simultaneously, regardless of quorum placement.

Why:

This question probes deep understanding of consensus, replication, and failure-domain design in globally distributed systems. (1) Synchronous cross-region replication is correct — it guarantees no data loss (RPO=0) but sacrifices availability during partition (violates the 'stays available' requirement). (2) Asynchronous replication with tunable staleness is correct — it keeps the system available but risks data loss on region failure, so it does NOT give RPO=0. (3) Multi-master active-active with CRDTs is correct — CRDTs provide availability and eventual consistency but do NOT guarantee strong consistency or zero divergence on conflicting writes. (4) Paxos/Raft-based geo-consensus IS the canonical approach to achieve both strong consistency and high availability across regions when paired with enough quorum members in distinct failure domains, but it trades off latency (write latency ≥ cross-region RTT). So the claim that Paxos/Raft 'cannot provide both' is FALSE — it is exactly what systems like Google Spanner and CockroachDB implement. The question asks which statement is FALSE, so the answer is the Paxos/Raft option.

System Design/sd-architecture

A team is evolving a high-scale e-commerce order management system. Arrange the following architectural milestones in the recommended evolutionary order — from earliest (most foundational) to latest (most mature) — to maximize stability and minimize risk at each transition:#

Put these in order

Show answer

The recommended evolutionary order is: (1) Monolith, (2) Message queue / microservice decomposition, (3) Saga orchestration, (4) CQRS, (5) Event sourcing, (6) Geo-replication. Microservice decomposition immediately removes ACID guarantees, so saga orchestration must come next — before CQRS or event sourcing — as Richardson's Microservices Patterns argues. CQRS then prepares the write/read split that makes event sourcing lower-risk, and geo-replication is safe only once the event-sourced write model is stable.

Why:

The defensible canonical progression follows the 'concrete operational pain at each step' principle from Richardson's Microservices Patterns and Newman's Building Microservices: (1) Monolith — proves product-market fit with minimal operational complexity. (2) Message queue / microservice decomposition — synchronous bottlenecks and tight coupling become painful under load; introducing Kafka and drawing service boundaries enables independent deployment but immediately removes the monolith's ACID transaction guarantee. (3) Saga orchestration — as Richardson explicitly argues, the first architectural problem exposed by microservice decomposition is the loss of distributed ACID transactions; sagas (orchestration or choreography) must be introduced at this point to manage compensating transactions across service boundaries before any further persistence changes are layered on. (4) CQRS — once service boundaries are stable and transactions are safely coordinated by sagas, read and write workloads diverge sharply; CQRS separates the command model from read projections and is a lower-risk prerequisite for event sourcing because it can be applied to ordinary state-mutation services. (5) Event sourcing — building on the already-separated command model and saga-coordinated boundaries, mutable state is replaced with an immutable event log in a dedicated event store (e.g., EventStoreDB); CQRS projections already in place make this migration far less risky. Event sourcing does not require the message queue as a technical prerequisite, but sagas and CQRS being in place dramatically reduce the blast radius. (6) Geo-replication — only after the event-sourced architecture is stable does replicating the event log across regions become operationally safe and worthwhile; attempting geo-replication before the write model is settled multiplies operational risk.

Related interview questions

The other 40 questions

This page shows 10. A free account opens the rest and marks your answers, which a page of answers can't do. Miss one and it returns a few days later, then a week after that, until you stop missing it.

Start free

Free · the whole bank · 100 graded answers per 30 days · written feedback and job-ad quizzes on the paid plan

What moved, monthly

One email a month when the bulletin comes out: what moved in the markets we track, and the new question topics we published. Confirm your address to join. Unsubscribe any time.