Distributed Rate Limiter & Token Bucket
Protect multi-region microservices from traffic spikes, brute-force attacks, and noisy neighbors.
Practice distributed-system reasoning with 100 categorized interview questions across 15 engineering domains. Explore worked blueprints, capacity calculations, and database schemas, then use a timed rehearsal to test your own explanation.
One question · 45 minutes · One retry
Pick a question from the bank below. Keep its blueprint closed for the first 35 minutes. Use a timer and a blank sheet, alone or with a practice partner.
New to this format? Start with a URL shortener. Practicing a specific weakness? Choose a rate limiter for shared state or chat for message delivery. These are suggested drills, not predictions of an employer’s interview.
Choose a question from the blueprintsName the users, two core operations, and one thing you will not build. State the latency and availability goals as assumptions to discuss.
Choose a daily user count and requests per user. Convert to requests per second, explain a peak multiplier, and estimate storage with units.
Sketch the simplest architecture on paper or a whiteboard. Trace one write and one read through the components. Name the stored records and their keys.
Make a cache unavailable or delay a database replica. Trace what the user sees, how the system recovers, and what can be lost or duplicated.
Compare your choice with one plausible alternative. Explain which requirement wins and what new evidence would change your decision.
Use the checklist below and then open a blueprint. Find one gap in your reasoning. Treat the reference as a design to question, not a script to memorize.
Hide the reference and explain the corrected section aloud. Finish by choosing one changed constraint for your next session.
For each row, mark missing, stated, or demonstrated. Demonstrated means you can point to your calculation, trace, or reason. Keep one note as evidence. This is a self-review rubric, not an automated score or a hiring prediction.
| Check | Evidence to look for | Follow-up question |
|---|---|---|
| Scope | Two core operations and a measurable goal | Could another person tell what is out of scope? |
| Capacity | Arithmetic with units and stated assumptions | Do the numbers change a design choice? |
| Data flow | A complete read and write path, including stored keys | Can you explain where each piece of data lives? |
| Failure handling | A user-visible effect and a recovery path | What happens to a request already in flight? |
| Tradeoffs | An alternative and a reason tied to a requirement | When would the alternative become the better choice? |
Example: if a cache outage makes every request hit the database, retry that failure explanation. State a load limit, decide which requests to reject or delay, and explain the user-visible result. Next time, repeat with ten times the traffic.
Use the capacity calculator to check your arithmetic after the first attempt. ClawPad can provide structured answer guidance and diagrams for study; you run the session and review your own reasoning.
Full technical blueprints with capacity math formulas, component topologies, SQL schemas, and trade-off analyses.
Protect multi-region microservices from traffic spikes, brute-force attacks, and noisy neighbors.
Design a globally distributed TinyURL service with 100:1 read-heavy traffic and sub-10ms redirects.
Scale a real-time messaging pipeline for 500M daily active users with message delivery receipts.
Build a fault-tolerant, low-latency in-memory cache supporting LRU eviction and Raft replication.
Design a YouTube / Netflix video platform with multi-bitrate HLS/DASH streaming and edge CDN delivery.
Deliver billions of multi-channel transactional notifications with priority queues and rate limiting.
Design an Uber / Lyft dispatch platform with spatial indexing, dynamic surge pricing, and ETA routing.
Crawl 10 billion web pages with politeness policies, deduplication, and distributed URL frontiers.
Design a mission-critical Stripe / FinTech payment engine with exactly-once settlement and audit ledgers.
Collect, aggregate, and alert on 100 million metric data points per second with sub-minute query SLAs.
Design a high-throughput microblogging feed with fan-out-on-write vs fan-out-on-read for celebrity accounts.
Sync multi-gigabyte files across millions of devices with 4MB chunking, content-addressable storage, and delta synchronization.
Handle viral stadium concert ticket drops with virtual waiting rooms, seat reservation locks, and anti-scalping defenses.
Manage massive shared channels with live fanout to 100,000+ online members, message edit history, and reaction counters.
Low-latency multi-party video conferencing utilizing WebRTC, Selective Forwarding Units (SFUs), and bandwidth adaptation.
Orchestrate real-time food delivery between customers, restaurants, and couriers with batched routing and live order tracking.
Trace FIFO priority, partial fills and cancellation in a hypothetical continuous limit book, then reason about sequencing, journal capacity and recovery.
Execute millions of recurring cron and delayed background jobs reliably with worker heartbeats and distributed locking.
Follow a conceptual Kafka example through partitions, committed offsets and a consumer crash, then size a hypothetical distributed log.
Design a hypothetical large language model (LLM) service. The scale and latency figures below are interview targets, not measured ClawPad or vLLM results.
Every classic and modern system design question asked across FAANG, fintech, high-growth startups, and AI labs.
WebSockets, long-polling, adaptive video transcoding, audio streaming, and WebRTC.
Deliver end-to-end encrypted instant messaging with bidirectional WebSockets, presence tracking, and offline message storage.
Manage massive shared channels with live fanout to 100,000+ online members, message edit history, and reaction counters.
Ingest, transcode, and stream petabytes of on-demand video globally with adaptive bitrate streaming and multi-CDN distribution.
Stream compressed audio with instant playback start, playlist collaborative sync, and encrypted offline device storage.
Low-latency multi-party video conferencing utilizing WebRTC, Selective Forwarding Units (SFUs), and bandwidth estimation.
Distributed file systems, S3 blob stores, consistent hashing, and key-value stores.
Sync files across desktop and mobile devices with block-level chunking, content-addressable storage, and conflict resolution.
Store exabytes of unstructured blob data with 99.999999999% durability using erasure coding and distributed metadata clusters.
Provide sub-millisecond key-value lookups at millions of QPS using consistent hashing, virtual nodes, and active-passive failover.
Implement a highly available, partitioned key-value store with tunable consistency, vector clocks, and gossip-based failure detection.
Distribute web content with BGP Anycast routing, multi-tiered edge caches, and millisecond purge invalidations.
Manage petabytes of sequential analytical data across commodity hardware with single-master coordination and chunkserver replication.
Geohash & H3 indexing, quadtree partitioning, live driver dispatch, and routing algorithms.
Match passengers with nearby drivers in real time with high-frequency GPS telemetry, dynamic surge pricing, and ETA routing.
Query millions of businesses by radius and bounding box with quadtrees, spatial indexing, and read-heavy caching.
Compute shortest and fastest driving routes across global road networks with real-time traffic updates and vector tile rendering.
Orchestrate real-time food delivery between customers, restaurants, and couriers with batched routing and live order tracking.
Process billions of daily swipes with geospatial distance filters, reciprocal match detection, and instant notification dispatch.
Distributed inventory locks, flash sale throttling, double-booking defenses, and shopping carts.
Handle viral concert ticket drops with virtual waiting rooms, seat reservation locks, and anti-scalping rate limits.
Sell 10,000 limited inventory units to 1,000,000 simultaneous shoppers without overselling or crashing downstream databases.
Book lodging rooms across dynamic date ranges with overbooking prevention, calendar sync, and payment escrow holds.
Support multi-vendor item catalogs, persistent cross-device shopping carts, and inventory fulfillment workflows.
Calculate and update sales ranks across millions of products in real time using rolling sliding window aggregations.
Idempotent payment gateways, double-entry ledgers, low-latency matching engines, and fraud checks.
Authorize and settle multi-currency transactions with strict idempotency, third-party PSP failover, and ledger reconciliation.
Track user fiat and crypto balances with zero precision loss, ACID auditability, and Two-Phase Commit / Saga guarantees.
Trace FIFO priority, partial fills and cancellation in a hypothetical continuous limit book, then reason about sequencing, journal capacity and recovery.
Ingest live stock price feeds via WebSockets, place options and stock orders, and maintain real-time portfolio market value.
Score payment card transactions in under 50ms using rule-based velocity limits, ML feature evaluation, and anomaly scoring.
Web crawlers, prefix tries, inverted indexes, ad click stream aggregation, and heavy hitters.
Crawl billions of web pages across the public internet respecting robots.txt politeness, duplicate URL detection, and DNS caching.
Return top 5 search query suggestions in under 10ms as users type using distributed prefix tries and frequency ranking.
Build an inverted index across billions of crawled HTML documents and serve ranked search results using BM25 and PageRank.
Ingest and aggregate millions of ad click events per second for advertisers with exactly-once stream processing and minute rollups.
Identify the top 100 most viewed videos or trending hashtags in real time using probabilistic streaming algorithms.
Maintain live player rankings for 25 million active gamers with score updates and instant percentile lookups.
Rate limiters, distributed cron schedulers, snowflake IDs, message brokers, and APM tracing.
Protect multi-region microservices from traffic spikes, brute-force attacks, and noisy neighbors with sub-millisecond overhead.
Compress long URLs into 7-character aliases with high read-to-write ratios, fast HTTP 301/302 redirects, and analytics tracking.
Fan out millions of transactional and promotional notifications across APNs, FCM, SMS, and Email with priority queues.
Collect, aggregate, and query millions of infrastructure metrics per second with configurable alerting thresholds and dashboards.
Execute millions of recurring cron and delayed background jobs reliably with worker heartbeats and distributed locking.
Generate 64-bit globally unique, roughly time-sorted integers across distributed worker nodes without database coordination.
Follow a conceptual Kafka example through partitions, committed offsets and a consumer crash, then size a hypothetical distributed log.
Synchronize access to shared resources across untrusted distributed processes with lease timers and fencing tokens.
Track end-to-end request journeys across hundreds of microservices with trace context propagation and adaptive sampling.
Compile and run untrusted user code safely across 30+ languages with strict CPU/memory timeouts and vulnerability sandboxing.
Deliver billions of outbound HTTP webhooks to third-party customer endpoints with exponential backoff, signatures, and circuit breakers.
Enable concurrent multi-user editing on documents and canvas trees with conflict resolution, presence cursors, and undo/redo.
LLM serving with continuous batching, vector search, recommendation feeds, and streaming ASR.
Serve personalized video feeds in under 50ms combining two-stage candidate generation, deep ranking models, and real-time user feedback.
Search a catalog of 10 billion products by uploaded image using Vision Transformers, vector indexing, and real-time metadata filtering.
Serve generative Large Language Models with continuous batching, PagedAttention KV cache memory management, and speculative decoding.
Ingest enterprise documents, chunk and embed text into vector databases, and perform hybrid lexical-semantic retrieval for LLMs.
Transcribe live microphone audio in under 200ms latency using chunked streaming ASR, connection pooling, and speaker diarization.
Lakehouse storage, real-time stream ingestion, Change Data Capture (CDC), and partition compaction.
Ingest 1M events/sec from mobile and web, deduplicate, sessionize with tumbling/session windows, and sink into analytical lakehouses.
Stream transactional database mutation logs (PostgreSQL WAL) into Apache Iceberg tables with partition compaction and ACID guarantees.
Erase specific user identifier records across petabytes of immutable historical Parquet files in S3 while minimizing write amplification and compute cost.
Reconcile billions of daily financial transactions across multiple payment rails with point-in-time snapshot auditability and zero ledger drift.
Ingest 10M time-series telemetry data points per second, compute multi-tier downsampling rollups (1m, 1h, 1d), and detect statistical anomalies.
Enterprise A/B testing platforms, switchback experiments, variance reduction (CUPED), and metric evaluation.
Deterministically assign millions of daily active users into concurrent experiment buckets, evaluate metric shifts, and prevent sample ratio mismatches.
Measure pricing and dispatch algorithm changes in two-sided marketplaces without cannibalization or spatial network spillover.
Accelerate A/B test runtimes by 50% using Controlled-experiment Using Pre-Experiment Data (CUPED) to remove pre-existing user variance.
Evaluate search ranking algorithms against human evaluation judgments and implicit click logs using NDCG, MAP, and MRR metrics.
Ingest daily user product engagement signals, compute RFM (Recency, Frequency, Monetary) metrics, and score probability of 30-day account abandonment.
Multi-region active-active disaster recovery, distributed APM tracing, canary rollouts, and chaos injection.
Route traffic dynamically across three global cloud regions with zero-downtime automated failover, data synchronization, and split-brain immunity.
Ingest 1M spans per second across microservices, trace distributed context propagation, and execute tail-based anomaly sampling.
Gradually shift production traffic to new service releases (5% -> 25% -> 100%), monitor live Prometheus error budgets, and trigger instant rollbacks.
Securely replicate dynamic credentials and configuration across 500 Kubernetes clusters with automated rotation and zero plain-text storage.
Proactively inject simulated latency, packet drops, CPU exhaustion, and AZ outages into production clusters with automated blast radius containment.
Enterprise secrets management, zero-trust remote proxies, SIEM threat correlation, and E2EE protocols.
Store and broker application API keys, database credentials, and cryptographic certificates with leasing, revocation, and envelope encryption.
Replace corporate VPNs by authenticating employee identity, verifying MDM device posture, and proxying internal enterprise applications.
Ingest 200k audit events/sec from cloud trail logs, firewalls, and endpoint agents to detect lateral movement and credential exfiltration.
Guarantee forward secrecy and post-compromise security for asynchronous one-to-one and group messaging across distributed devices.
Evaluate complex attribute-based access control (ABAC) and role-based policies in under 1 millisecond for every internal microservice request.
Real-time collaborative canvases (CRDTs), offline-first sync engines, media prefetching, and spreadsheets.
Synchronize infinite vector canvas nodes, shapes, and presence cursors across dozens of concurrent editors with smooth interactive responsiveness.
Enable instant local writes on client devices without network connectivity and reliably resolve state conflicts upon reconnect.
Deliver zero-latency vertical video swiping on constrained mobile devices with predictive chunk prefetching and strict memory caps.
Render 1,000,000 tabular rows at 60fps with cell formula dependency graphs, virtualized DOM scrolling, and Web Worker computation.
Orchestrate 30+ independently deployed frontend applications into a unified single-page shell with shared dependencies and sandboxing.
Agentic tool loops, real-time AI search, inference serving, semantic caching, and LLM evaluation.
Provide inline code completions and repository-aware chat by indexing AST symbols, open editor tabs, and local git diffs.
Orchestrate an autonomous agent that explores codebases, edits files, executes test suites, and iterates until builds pass.
Decompose user queries into parallel web searches, scrape candidate documents, rerank snippets, and stream answers with verifiable citations.
Provide a unified multi-provider control plane with vector semantic caching, automated fallbacks, dynamic model routing, and token quotas.
Run regression test suites, track prompt drift, and score generated outputs against golden datasets using automated judge models.
Stream bidirectional audio for natural voice conversations with client-side voice activity detection and instant barge-in cancellation.
Process high-volume creative prompts with safety classifiers, tiered GPU priority scheduling, and latent diffusion multi-step denoising.
Extract declarative facts, user preferences, and entity relationship graphs across chat sessions and inject relevant memories on demand.
Inspect user prompts and model responses to block direct jailbreaks, indirect injections, and confidential credential leaks.
Orchestrate multi-node GPU training across thousands of accelerators with 3D parallelism and non-blocking asynchronous checkpoint saves.
Generate millions of high-quality synthetic training pairs, score model outputs, and execute direct preference optimization alignment.
Ingest scanned enterprise PDFs, slides, and invoices with vision-based layout analysis, table reconstruction, and hierarchical chunking.
Run untrusted Python and bash code generated by AI agents inside disposable, secured microVM environments.
Accelerate large model token generation by employing a lightweight draft model to speculate multiple candidate tokens in parallel.
Manage thousands of OpenAPI tool definitions, dynamically filter context schemas, and safely execute distributed external actions.
Combine dense vector similarity, sparse keyword search, and knowledge graph entity traversal to eliminate RAG retrieval blind spots.
Resolve customer issues autonomously with intent classification, policy-bounded tool execution, and seamless human agent handoffs.
Control graphical desktop interfaces by taking screenshots, detecting interactive UI elements, and generating mouse and keyboard events.
Process petabyte-scale raw web crawls through fuzzy deduplication, quality filtering, PII removal, and synthetic document refinement.
Use these areas to organize your practice. Adjust the depth to the role and the time available.
Lock down functional APIs and non-functional SLAs (availability, latency, consistency).
Derive peak QPS, storage growth per year, cache memory, and network ingress/egress.
Draw client gateways, load balancers, microservices, caches, and storage tiers.
Define relational vs NoSQL schemas, primary keys, partition strategies, and indexes.
Address cache invalidation, network partitions, replication lag, and leader elections.
Defend architectural compromises (CAP theorem, sync vs async, consistency vs latency).
The question bank contains 100 system design practice questions across 15 architectural domains. This page also links to 20 worked blueprints with example designs.
The worked blueprints cover requirements, capacity estimates, architecture components, data models, and trade-offs. Treat their numbers as example assumptions and explain how your design would change if those assumptions changed.
Choose a question and spend 35 minutes explaining requirements, estimates, data flow, a failure case, and a tradeoff without a reference. Use the final ten minutes to review the evidence and retry the weakest section. ClawPad can provide structured answers and diagrams for study.
Social Media & Feeds
(7 questions)Fan-out architectures, feed ranking pipelines, follower graphs, and read-heavy caching.
Twitter / X Timeline & Fan-Out Engine
Design a high-throughput microblogging feed with fan-out-on-write vs fan-out-on-read for celebrity accounts.
Facebook News Feed & Ranking
Architect personalized social feeds incorporating social graph edge weights, affinity ranking, and infinite scrolling.
Instagram Photo Sharing & Follower Graph
Handle massive image uploads with bidirectional follower graphs, asynchronous resizing, and real-time feed delivery.
Reddit & Hacker News Threaded Discussion
Scale hierarchical comment trees, live upvote/downvote counters, and sub-community caching.
Pastebin & Text Snippet Storage
Build an expiring text snippet storage system with collision-resistant unique short keys and automated TTL cleanup.
Quora & Stack Overflow Q&A Platform
Design a high-volume question-and-answer platform with search tagging, view count deduplication, and reputation scoring.
Mint / Personal Finance Aggregator
Aggregate financial transactions from heterogeneous banking APIs with transaction categorization and audit logging.