Content & privacy
Architecture · INTERVIEW GUIDE

System design

Architecture decisions, distributed systems, and ten design scenarios.

Practice this topic
Filters
4 questions

Queue vs event vs worker?

System design·Messaging & reliability

A queue holds work waiting to be processed, a worker executes that work, and an event describes a fact that already happened. Commands request an action, while events can notify multiple interested consumers. Delivery and acknowledgement rules determine what happens when workers crash or messages are repeated.

Advanced2 min read

How do I design retries and dead-letter handling?

System design·Messaging & reliability

Retries repeat failed work in the hope that a temporary problem has passed. Backoff spreads attempts over time, jitter avoids synchronized retry bursts, and a dead-letter queue stores work that exceeded its retry policy. Without limits, retries can turn a small outage into sustained overload.

Advanced2 min read

What are idempotency and the outbox pattern?

System design·Messaging & reliability

Idempotency makes repeated requests for one logical operation produce one intended effect. The outbox pattern stores an event record in the same database transaction as the business change, allowing a later publisher to send it reliably. These solve related but different failure windows: duplicate work and losing the message between a commit and publication.

Advanced2 min read

How do I handle partial failure across services?

System design·Messaging & reliability

A cross-service workflow can partly succeed because each service commits independently. A saga coordinates local steps and compensating actions to recover when a later step fails. Compensation is a business recovery action, such as refunding a payment, and may not exactly erase every observable effect of the original action.

Advanced2 min read

Difficulty is an editorial estimate. Completion means you chose to mark a question as understood.