The Desi Architect
Notes / Design Interview Problems
Track 5

Design Interview Problems

Full practice designs: requirements, numbers, APIs, data model, build-up, failure modes and the cross-questions you will get.

case file

Design Notification System (Push, SMS, Email at Scale)

Order updates, OTPs, a Diwali sale blast to one crore phones, all through the same pipe. The hard part is not sending. It is making sure the OTP never waits behind the sale and nobody gets the same SMS twice.

22 min read
case file

Design Razorpay / Stripe (Payment Gateway & Settlement)

A customer taps Pay, the bank takes the money, and our server crashes before saving. How a payment gateway guarantees zero double debits, handles unknown outcomes, and balances every paisa using double-entry ledgers.

26 min read
case file

Design Razorpay / Stripe (Reliable Webhook Delivery at Scale)

A customer payment succeeds, but the merchant server is crashing or timing out. How an enterprise webhook engine delivers millions of events with at-least-once guarantees, noisy-neighbour isolation, tiered backoff, and SSRF protection.

25 min read
case file

Design PhonePe / Paytm (Real-Time Fraud Detection Engine for UPI & Wallets)

Rohan transfers ₹50,000 to an unknown VPA at 3:00 AM from a new device in Jharkhand. How an enterprise risk engine evaluates payment fraud in under 50 milliseconds using Redis sliding windows, velocity tracking, and dual-path ML scoring.

26 min read
case file

Design MakeMyTrip / OYO (Hotel Reservation & Inventory Hold System)

Five thousand tourists click 'Reserve' for Goa on New Year's Eve for a boutique hotel with only 12 luxury suites. How an enterprise reservation engine handles multi-day temporal inventory, 10-minute temporary cart holds, and automated lock expiry without double-booking.

25 min read
case file

Design Atlassian / Multi-Tenant SaaS (Tenant Isolation, Sharding & Noisy-Neighbour Defense)

A three-person startup and a global bank with 200,000 employees share the same Jira and Confluence cluster. How modern multi-tenant SaaS isolates noisy neighbours, enforces zero data leaks using database Row-Level Security (RLS), and shards data across shared and dedicated pools.

25 min read
case file

Design LaunchDarkly / Unleash (Feature Flags & Dynamic Config at Scale)

Fifty thousand backend microservices evaluate flags on every HTTP request with zero network latency, while millions of mobile apps receive real-time toggles within 500 milliseconds. How a feature flag system splits server-side from client-side evaluation, prevents thundering herds with Server-Sent Events (SSE), and guarantees sub-microsecond local evaluations.

25 min read
case file

Design Web Crawler at Scale (Search Engine Ingestion & Politeness Engine)

Crawling ten billion documents without crashing target web servers or blowing up your storage. How to architect a distributed web crawler with dual frontier queues for priority and politeness, Bloom filter URL deduplication, asynchronous DNS pre-fetching, SimHash near-duplicate detection, and defensive spider trap filters.

25 min read
case file

Design LeetCode / HackerRank (Code Execution Sandbox & Evaluation Engine)

Safely compiling and executing arbitrary, untrusted user code under two-second time limits and strict memory caps. How an online judge isolates execution using gVisor and seccomp, differentiates CPU time from wall-clock time, prevents fork bombs with cgroups v2, and defends worker nodes from infinite output denial of service.

25 min read
case file

Design UPI (NPCI Unified Payments Interface)

How NPCI, payer PSPs, remitter banks, and beneficiary banks coordinate a payment in under two seconds across four separate organizations.

24 min read
case file

Design Zerodha / Groww (Stock Trading Order Matching)

NSE at 09:15 AM open. How an in-memory price-time priority matching engine processes 100,000 orders per second with microsecond latency and zero database transactions in the critical path.

25 min read
case file

Design Flash Sale & Inventory (Blinkit / Amazon Last-Unit Race)

Blinkit and Zepto dark stores with 10-minute delivery. When two carts race to buy the last packet of Amul butter, how to guarantee zero overselling while keeping checkout latency under 50ms.

25 min read
case file

Design Distributed Rate Limiter (API Gateway Throttling)

Protecting IRCTC Tatkal and payment endpoints from bot swarms and noisy neighbors. Comparing Token Bucket, Leaky Bucket, and Sliding Window with Redis Lua scripts.

25 min read
case file

Design WhatsApp (Real-Time Messaging at Scale)

Two billion active users, 100 billion messages per day. How to manage millions of persistent connections, deliver offline queues, and track the three ticks.

22 min read
case file

Design Instagram / Twitter (News Feed & Reels)

A creator with two crore followers posts a Reel at 9 PM on a Sunday, and ten crore phones expect it to show up in a second. Building a hybrid push-pull feed engine with direct media uploads, asynchronous transcoding, and strict privacy filters.

28 min read
case file

Design YouTube / Netflix (Global Video Streaming)

From 4K creator upload to 360p playback on a moving bus. How chunking, transcoding pipelines, and CDN edge caching deliver stutter-free video at petabyte scale.

25 min read
case file

Design Dream11 / Leaderboard (Real-Time Gaming Scoreboard)

10 million cricket fans in a Dream11 IPL mega contest. How to calculate real-time ranks when Bumrah takes a wicket and 60 lakh teams gain points simultaneously.

25 min read
case file

Design Ad Click Aggregator (Google Ads / Meta Ads)

Scale an ad click tracking and aggregation engine to 100,000 clicks per second during IPL matches. API contracts, database schemas, deduplication, 1-minute windowing, and fraud defense.

25 min read
case file

Design TinyURL / Bitly (URL Shortener)

Scale a URL shortening service to 10 crore links per month and 25,000 peak redirects/sec. Range-based token generation, Base62 encoding, 301 vs 302 redirects, and fraud prevention.

20 min read
case file

Design Redis / Memcached (Distributed Cache)

Designing an in-memory distributed cache from scratch. Consistent hashing, LRU eviction with O(1) ops, cache stampedes, and surviving node outages.

25 min read
case file

Design Datadog / ELK (Distributed Log Aggregator)

Ingesting 50 Terabytes of microservice logs per day. Comparing Elasticsearch full-text indexing versus Loki chunked label stores under incident traffic spikes.

25 min read
case file

Design Distributed Job Scheduler (Cron at Scale)

Distributed task and cron execution at enterprise scale. Hierarchical timing wheels, distributed leader locks, and guaranteed single execution under network drops.

25 min read
case file

Design Google Search Autocomplete (Typeahead Suggestion)

Real-time search suggestions under 30 milliseconds. Prefix trees, pre-computed Top-K nodes, offline frequency aggregation, and edge debouncing.

25 min read
case file

Design Google Docs (Collaborative Real-Time Editing)

Real-time concurrent document editing like Google Docs and Notion. Operational Transformation (OT) vs CRDTs, offline sync convergence, and stateful document sessions.

25 min read
case file

Design Google Maps (Routing, ETA & Navigation)

Google Maps and MapMyIndia navigation. Vector tile pyramids, Contraction Hierarchies for sub-10ms routing across India, and live traffic telemetry.

25 min read
case file

Design Uber / Ola (Ride Hailing & Driver Dispatch)

Uber, Ola, and Rapido dispatch architecture. Geospatial indexing with Uber H3 hexagons, high-frequency driver GPS streams, and atomic dispatch matching.

25 min read