Skip to content
Commitwise
Menu

System Design

Design systems that scale, from load balancers and caches to full case studies, including mobile system design.

19 lessons
0 of 19 completed
  1. 01

    How System Design Interviews Work

    What happens in a system design interview, what interviewers score at junior and senior level, and a step-by-step method for requirements, estimates, the big picture and deep dives that works for any question.

    6–30 min beginner Junior & senior

  2. 02

    Scaling and load balancing

    Grow a backend from one server to many, keep servers stateless, spread traffic with a load balancer and health checks, and find the next bottleneck before it finds you, with examples in Kotlin, Java and TypeScript.

    5–25 min beginner Junior & senior

  3. 03

    Caching

    Decide where to cache (client, CDN, server, Redis), how to keep cached data fresh enough with TTLs and invalidation, and how caches fail in production, from stampedes and hot keys to stale writes, with examples in Kotlin, Java and TypeScript.

    5–25 min beginner Junior & senior

  4. 04

    Databases: SQL, NoSQL, indexes and sharding

    Choose between relational and NoSQL databases by how your data is read and written, make queries fast with the right indexes, and scale reads with replicas and writes with sharding, including the shard keys and pagination patterns that hold up in production.

    5–30 min intermediate Junior & senior

  5. 05

    Replication and consistency

    Keep copies of data on several machines for availability and read scaling, understand what replication lag does to users (stale reads, time going backwards, answers before questions), pick consistency guarantees per feature, and handle failover, conflicts and quorums.

    4–25 min intermediate Junior & senior

  6. 06

    CAP theorem

    What the CAP theorem actually says (during a network partition, a system must choose between consistency and availability), why "pick two of three" is misleading, how to choose per feature rather than per database, and how PACELC adds the everyday trade-off between latency and consistency.

    4–20 min intermediate Junior & senior

  7. 07

    Message queues

    Move slow and unreliable work out of the request with queues, understand at-least-once delivery and why consumers must be idempotent, publish events reliably with an outbox, and scale consumers without breaking order, with examples in Kotlin, Java and TypeScript.

    5–25 min intermediate Junior & senior

  8. 08

    CDNs

    Serve images, video, app bundles and even API responses from servers close to users with a content delivery network, control what's cached and for how long with Cache-Control, design cache keys that hit, ship changes with versioned URLs instead of purges, and protect private files with signed URLs.

    4–20 min beginner Junior & senior

  9. 09

    Rate limiting

    Understand why systems limit traffic, where limits belong (edge, gateway, service, outbound calls), what to key them on, how the common algorithms compare, and the related tools that protect a service when rate limits aren't enough, such as concurrency limits, bulkheads and load shedding, with code in Kotlin, Java and TypeScript.

    4–20 min beginner Junior & senior

  10. 10

    API design: REST, GraphQL and gRPC

    Design APIs that are easy to use, safe to retry and possible to change without breaking apps already in users' hands, and choose between REST, GraphQL and gRPC for each kind of client, with examples for Swift, Kotlin, Java and TypeScript clients.

    4–30 min intermediate Junior & senior

  11. 11

    Design a URL Shortener

    The classic system design interview question, step by step, from requirements and estimates to short codes, caching, redirects and scaling, with code in Swift, Kotlin, Java and TypeScript.

    7–25 min intermediate Junior & senior

  12. 12

    Design a chat app

    The classic system design question, step by step, from requirements and estimates to WebSocket gateways, message storage partitioned by conversation, per-conversation ordering, delivery and read receipts, offline sync, group fan-out and push notifications, with code in Swift, Kotlin, Java and TypeScript.

    3–25 min intermediate Junior & senior

  13. 13

    Design a news feed

    Design a social news feed step by step, with estimates, fan-out on write versus fan-out on read, a hybrid for accounts with millions of followers, feed caches in Redis, cursor pagination that doesn't repeat or skip posts, ranking, and a mobile client that loads pages smoothly, with code in Kotlin, Java, TypeScript and Swift.

    5–25 min intermediate Junior & senior

  14. 14

    Design a notification system

    Design a service that sends push notifications, emails, SMS and in-app messages for many products, step by step, with queues per channel, user preferences and quiet hours, deduplication and rate limits, device token management for APNs and FCM, retries, and delivery tracking, with code in Swift, Kotlin, Java and TypeScript.

    4–25 min intermediate Junior & senior

  15. 15

    Design a rate limiter

    Design a rate limiter step by step, from requirements and algorithms (fixed window, sliding window, token bucket) to Redis counters, HTTP 429 responses and failure modes, with code in Swift, Kotlin, Java and TypeScript.

    7–30 min intermediate Junior & senior

  16. 16

    Design file upload

    Design photo and file uploads for a mobile app step by step, with presigned URLs so bytes go straight to object storage, verifying what actually arrived, resumable multipart uploads that survive bad networks and app restarts, background uploads on iOS and Android, and a processing pipeline for scanning and thumbnails, with code in Kotlin, Java, TypeScript and Swift.

    5–25 min intermediate Junior & senior

  17. 17

    Mobile: offline-first and sync

    Design a mobile app that works without a connection, with a local database as the source of truth, an outbox for writes, idempotent sync, cursors, tombstones and conflict resolution, with code in Kotlin, Swift and TypeScript.

    7–35 min intermediate Junior & senior

  18. 18

    Mobile: image loading and caching

    Design image loading for a mobile app, with a memory cache, a disk cache and the network, downsampling to the size actually shown, request deduplication, cancellation and the wrong-image-in-a-reused-row bug, prefetching for lists, and server-side resizing through a CDN, with code in Swift, Kotlin and TypeScript.

    4–25 min intermediate Junior & senior

  19. 19

    Mobile: pagination and real-time updates

    Design long lists that load page by page and stay up to date while open, with cursor-based paging, guarding against overlapping and stale page loads, Paging 3 and SwiftUI infinite lists, choosing between polling, server-sent events, WebSockets and push, and reconnecting on mobile without missing or duplicating updates, with code in Kotlin, Swift and TypeScript.

    4–20 min intermediate Junior & senior

Esc

Type to search the whole site.