Search

Lessons (20)

  • Design a Chat Application

    Deliver live messages without losing them by separating durable messages from fan-out, presence and offline notifications. ![Chat …

  • Design a URL Shortener

    Generate durable short links, redirect in milliseconds, prevent abuse and keep analytics off the redirect path. A short …

  • Brokers, Replication & Durability

    … 62 🐢 fell behind<br/ removed from ISR"] The durability trio ⭐ These three settings together decide whether an acknowledged …

  • Database Internals, Replication and Scaling

    Connect storage-engine choices, durability, replicas, query plans, pooling and data layout to real production behaviour. ![Database path …

  • Design a File Storage Service

    Upload bytes directly to object storage while the API owns durable metadata, authorization, sharing and synchronization. ![File storage …

  • Design a Logging and Monitoring Platform

    … agents batch into an ingestion layer, durable streams feed hot search, metrics and cold archival](/img/system-design …

  • Design a Social Media Feed

    Build a fast home feed with fan-out choices, durable post storage, eventual consistency and safeguards for celebrity …

  • Flash Sale: 10 Million Buyers, No Oversell

    … The durable inventory owner decides the winner atomically. The invariant Never sell more units than exist. The winner …

  • Exactly-Once Payment Processing

    Safe payment retries need a durable idempotency record, atomic state transition and provider-side deduplication. The invariant For …

  • Design an E-Commerce Checkout

    … inventory reservation, idempotent payment, order creation and durable events. ![Checkout: catalog/search are read paths while inventory, payment …

  • What Is Apache Kafka?

    Kafka is a distributed, durable log of events that many systems can write to and read from at …

  • Big Data: ETL, Warehouses and Streaming

    … raw events land durably, ETL/stream processing creates curated lake and warehouse datasets](/img/system-design-l6/big …

  • Proxies, APIs and Real-Time Protocols

    … A queue is not a WebSocket, and a WebSocket is not a durable message log.

  • Premiere-Night Video Streaming

    … Heartbeat progress to Redis for fast resume and persist asynchronously to durable storage. Include a timestamp/sequence so …

  • Transactions, Indexes & Concurrency

    … Atomicity is all-or-nothing; consistency preserves constraints; isolation defines concurrent visibility; durability survives failure. Never wait for …

  • The L6 System-Design Thinking Loop

    … Explain metrics, mitigation, and the durable fix. 💡 A good trade-off is specific: “I accept a few seconds …

  • Message Queues & RabbitMQ

    … crypto.randomUUID() }, // write to disk ); js // consumer.js const channel = await connection.createChannel(); await channel.assertQueue("emails", { durable …

  • ACID, Transactions & Locks

    … Two buyers cannot both reserve the last item. Durability Crash after success A committed payment record is recovered …

  • Kafka vs RabbitMQ & the Kafka Ecosystem

    … takeaways - RabbitMQ = smart routing + delete after delivery; Kafka = durable, replayable, ordered log at huge scale. - Choose Kafka for …

  • Data in Microservices: Sagas & the Outbox Pattern

    … A simple orchestrator (tools like Temporal make this durable and crash-safe) async function placeOrderSaga(order) { const done …