Case studies
23 small demos, modelled on well-known kinds of systems. Each one solves one hard problem: short links, feeds, chat, maps, payments and more. They are simplified designs based on public information.
URL shortenerTurn a long URL into a short Base62 code and resolve it again.Snowflake IDsGenerate unique, time-ordered 64-bit IDs without a central counter, and see how the bits are laid out.Key-value storePut and get keys on a small replicated store and see how quorum settings change consistency.Web crawlerFetch pages from a queue of URLs, wait between hits on one site, and skip pages already seen.Notification systemFan a notification out to push, SMS and email channels through queues with retries.News feedCompare fan-out on write (push) and fan-out on read (pull) for building timelines.Chat systemSend messages between users over persistent connections.Search autocompleteType a prefix and see how a trie returns the most popular completions.Video streamingFollow a video from upload through transcoding to adaptive streaming from a CDN.File sync (Google Drive)Upload, chunk and sync files across devices, and resolve edit conflicts.Proximity search (geohash)Place a rider on a map and find what is nearby, by scanning every point, by grid cells, or with a quadtree.Nearby friendsStream location updates and find friends within a radius.Maps routingFind a shortest path across a small road graph.Distributed message queueSend events through a Kafka-like queue and watch partitions, consumer groups, replication and delivery.Metrics & monitoringWatch a live service through its metrics: percentiles, an error budget, and alerts that fire in time.Ad click aggregationCount a stream of ad clicks in time windows, and see what late and repeated clicks do to the totals.Hotel reservationBook rooms without double-booking when requests race each other.Email serviceSend, store and search mail at scale.Object storage (S3)Store objects as metadata plus replicated data chunks.Real-time leaderboardKeep a live ranking with a sorted set.Payment flowMove a payment through its states and see why each step must be idempotent.Stock exchange matchingMatch buy and sell orders in an order book by price and time.Object-oriented design patternsClassic GoF patterns with small examples (low-level design, not distributed systems).