Tagged “Case-Study”
18 articles with this tag.
- Chat SystemA one-to-one and group chat system designed with the 18-step framework: WebSocket gateways and a session registry, message IDs and per-chat ordering, store-then-fan-out delivery, offline sync and push notifications, delivery receipts, presence, media, end-to-end encryption, and storing trillions of messages in a wide-column store.
- Distributed Key-Value StoreA highly available key-value store designed from first principles: consistent hashing with virtual nodes, replication to N nodes, tunable quorums (W + R > N), vector clocks and conflict resolution, sloppy quorums and hinted handoff, gossip membership, Merkle-tree anti-entropy, and an LSM-tree storage engine.
- Flash SaleA system for limited-stock sales that attract millions of users at the same second, designed with the 18-step framework: shielding the core with CDNs, waiting rooms and rate limits, atomic stock reservation in Redis, asynchronous order creation through a queue, reservation expiry, preventing overselling and bots, and keeping the user experience honest.
- Metrics and AlertingA Prometheus-style monitoring platform designed with the 18-step framework: the metrics data model and cardinality, pull versus push collection, Kafka buffering, time-series storage with compression and downsampling, query engines, rule evaluation, alert routing, deduplication and silencing, and SLO burn-rate alerts.
- News FeedA social news feed designed with the 18-step framework: fan-out on write versus fan-out on read, the hybrid approach for celebrities, timeline caches of post IDs in Redis, hydration and ranking, cursor pagination, media, and the numbers behind each decision.
- Notification ServiceA multi-channel notification system (push, SMS, email, in-app) designed with the 18-step framework: event intake with idempotency, user preferences and quiet hours, templates and localisation, per-channel queues and workers, provider integration, retries and dead letters, rate limiting, delivery tracking and the decision flow that suppresses unwanted notifications.
- Payment SystemA payment system designed with the 18-step framework: pay-in and pay-out flows, payment service, executor, PSP integration with hosted payment pages, wallet and double-entry ledger, exactly-once execution through retries plus idempotency keys, handling unknown outcomes, reconciliation with settlement files, clearing and settlement, and payment security.
- Proximity ServiceDesigning 'find restaurants near me' with the 18-step framework: requirements and estimates, why latitude and longitude range queries are slow, geohash (prefixes, precision, boundary issues, neighbours), quadtrees built in memory, Google S2, a read-heavy architecture with a business service and location-based service, and why read replicas beat sharding here.
- Rate LimiterA distributed rate limiter designed with the 18-step framework: where to place it, token bucket, leaky bucket, fixed window, sliding log and sliding window counter algorithms compared, atomic Redis implementation with Lua, race conditions, multi-region synchronisation, HTTP 429 and rate-limit headers, and failure modes.
- Ride SharingA ride-hailing platform designed with the 18-step framework: ingesting millions of driver location updates, an in-memory geospatial index with H3 hexagonal cells, the dispatch flow from request to offer and acceptance, the trip state machine, ETA and surge pricing, consistency for driver assignment, and regional sharding.
- Stock ExchangeAn exchange designed for microsecond latency with the 18-step framework: the critical path from gateway to matching engine, order books with price-time priority, a sequencer and event journal for determinism, single-threaded in-memory matching (the LMAX architecture and Disruptor), market data distribution, hot-warm failover and why ordinary web architecture does not apply.
- URL ShortenerA complete URL shortener design using the 18-step framework: requirements, capacity calculations, API, base62 short codes from a unique ID versus hashing, 301 versus 302 redirects, a read-heavy architecture with caching, key-value storage, analytics through a queue, abuse prevention and trade-offs.
- Video StreamingA video platform designed with the 18-step framework: resumable uploads, a parallel transcoding DAG producing a bitrate ladder, HLS and DASH segments and manifests, adaptive bitrate playback, CDN and ISP-embedded caches like Netflix Open Connect, metadata and view counting, cost control and failure handling.
- Web CrawlerA distributed web crawler designed with the 18-step framework: the URL frontier with priority and per-host politeness queues, robots.txt, DNS caching, fetchers, parsing, URL normalisation and Bloom-filter deduplication, near-duplicate detection with SimHash, crawler traps, recrawl scheduling and storage.
- Order Management SystemA complete system design for an e-commerce order management system using the 18-step framework: requirements, labelled assumptions and capacity calculations, API, data model, architecture, saga with transactional outbox, idempotent payments, failure handling, scaling and trade-offs — including when a modular monolith is the better choice.
- Collaborative EditingA real-time collaborative document editor designed with the 18-step framework: why naive last-write-wins fails, operational transformation with a central server and revision log, CRDTs as the peer-to-peer alternative, WebSocket sessions per document, presence and cursors, snapshots, offline edits, permissions and scaling by document.
- File Storage and SyncA cloud file storage and synchronisation service designed with the 18-step framework: chunking and content-addressed block storage, deduplication and delta sync, separating metadata from blocks, strongly consistent metadata, presigned uploads, change notification with cursors, conflict handling, sharing and versioning.
- Search AutocompleteA typeahead suggestion system designed with the 18-step framework: tries with top-k results cached at every node, an offline data-collection and trie-building pipeline, serving from in-memory shards, browser caching and request debouncing, personalisation, filtering and trending queries.