A comprehensive collection of system design case studies, architectural patterns, production-grade implementations, and interview preparation resources.
mindmap
root((System Design))
Case Studies
Financial Systems
E-Commerce
Food Delivery
IoT & Streaming
Collaboration
Patterns
Communication
Resilience
Data
Messaging
Deployment
Implementations
URL Shortener
Rate Limiter
Leaderboard
OAuth 2.0
JWT Auth
Products API
Resources
Interview Guide
Compliance Guide
Job Search HQ
Workflow Tools
| Topic | Description | Key Concepts | Links |
|---|---|---|---|
| Financial Clearing House | Interbank settlement system with multilateral netting achieving 93%+ efficiency | Graph algorithms, Two-phase settlement, Saga pattern | 📘 Overview • 🏛️ Architecture • 🔄 Flow |
| Seller Payment System | E-commerce seller payouts with configurable schedules and fee optimization | Exactly-once semantics, State machines, Idempotency | 📘 Overview • 🏛️ Architecture • 💾 Data Models |
| Fintech Data Platform | End-to-end data architecture with CDC, event streaming, and federated queries | CDC (Debezium), Kafka, HTAP, Data Lake | 📘 Overview • 📊 E2E Diagram |
| Topic | Description | Key Concepts | Links |
|---|---|---|---|
| Merchandise Browsing | Large-scale product discovery for 1M+ DAU with real-time trending | Popularity scoring, Flink streaming, Personalization | 📘 Overview • 📊 Diagrams |
| Uber Cart System | Multi-merchant cart with family accounts and offline-first behavior | CRDT sync, Multi-tenant, Event sourcing | 📘 Overview • 🏛️ Architecture • 📱 API |
| Issue Tracking System | Multi-tenant Jira-like platform for 50M DAU with 10B issues | Row-level security, Elasticsearch, Tenant isolation | 📘 Overview • 🏛️ Architecture • 🔍 Search |
| Topic | Description | Key Concepts | Links |
|---|---|---|---|
| Uber Eats Feed | Restaurant feed with H3 spatial indexing handling 10K+ views/sec | H3 hexagonal grid, Geo-sharding, ML ranking | 📘 Overview • 🗺️ Spatial Indexing • 📊 Ranking |
| Topic | Description | Key Concepts | Links |
|---|---|---|---|
| Collaborative Editor | Google Docs-like editor with CRDTs for 100 concurrent editors | CRDT, WebSocket, Offline-first, Causal consistency | 📘 Overview • 🧬 CRDT Design • 🔄 Sync Protocol |
| Real-Time Leaderboard | Gaming leaderboard for 100M users with global/regional rankings | Redis Sorted Sets, Kafka, WebSocket push | 📘 Overview • 🏛️ Architecture • 📊 Redis Deep Dive |
| Topic | Description | Key Concepts | Links |
|---|---|---|---|
| Trucking Crash Detection | Real-time crash detection for 1M vehicles with <30s notification | Stream processing, ML inference, IoT ingestion | 📘 Overview • 🏛️ Architecture • 🧠 ML Pipeline |
📚 Complete Pattern Reference — Decision flowcharts, trade-off analysis, and implementation examples
| Pattern | When to Use | Trade-offs | Link |
|---|---|---|---|
| REST API | Public APIs, CRUD operations | Simple ↔ Over/under-fetching | 📄 Docs |
| GraphQL | Mobile apps, complex queries | Flexible ↔ Caching complexity | 📄 Docs |
| gRPC | Internal microservices, high performance | Fast ↔ Browser support | 📄 Docs |
| WebSockets | Real-time bidirectional | Low latency ↔ Connection overhead | 📄 Docs |
| Pattern | When to Use | Trade-offs | Link |
|---|---|---|---|
| API Gateway | Centralized entry point | Single entry ↔ SPOF risk | 📄 Docs |
| Backend for Frontend | Multi-platform clients | Optimized UX ↔ Code duplication | 📄 Docs |
| Aggregator | Composite responses | Reduced round trips ↔ Complexity | 📄 Docs |
| Pattern | When to Use | Trade-offs | Link |
|---|---|---|---|
| Circuit Breaker | Prevent cascading failures | Fail-fast ↔ Implementation complexity | 📄 Docs |
| Retry with Backoff | Handle transient failures | Reliability ↔ Thundering herd | 📄 Docs |
| Bulkhead | Isolate resource pools | Fault isolation ↔ Resource underutilization | 📄 Docs |
| Rate Limiting | Traffic spike protection | System protection ↔ User experience | 📄 Docs |
| Timeout | Prevent hung connections | Responsiveness ↔ False positives | 📄 Docs |
| Pattern | When to Use | Trade-offs | Link |
|---|---|---|---|
| CQRS | Separate read/write scaling | Performance ↔ Complexity | 📄 Docs |
| Event Sourcing | Audit trails, temporal queries | Complete history ↔ Storage costs | 📄 Docs |
| Saga Pattern | Distributed transactions | Eventual consistency ↔ Coordination | 📄 Docs |
| Outbox Pattern | Reliable event publishing | Guaranteed delivery ↔ At-least-once | 📄 Docs |
| Two-Phase Commit | Strong consistency needed | ACID guarantees ↔ Availability | 📄 Docs |
| Pattern | When to Use | Trade-offs | Link |
|---|---|---|---|
| Pub/Sub | Fan-out notifications | Decoupling ↔ Message ordering | 📄 Docs |
| Message Queue | Work distribution | Reliability ↔ Latency | 📄 Docs |
| Event-Driven Architecture | Reactive systems | Flexibility ↔ Debugging complexity | 📄 Docs |
| Pattern | When to Use | Trade-offs | Link |
|---|---|---|---|
| Service Registry | Dynamic service discovery | Flexibility ↔ Additional infrastructure | 📄 Docs |
| Sidecar | Cross-cutting concerns | Separation of concerns ↔ Resource overhead | 📄 Docs |
| Service Mesh | Complex microservices | Full observability ↔ Operational complexity | 📄 Docs |
| Pattern | When to Use | Trade-offs | Link |
|---|---|---|---|
| Blue-Green Deployment | Zero-downtime releases | Instant rollback ↔ 2x infrastructure | 📄 Docs |
| Canary Deployment | Gradual rollouts | Lower risk ↔ Complexity | 📄 Docs |
| Rolling Deployment | Resource-efficient updates | Simple ↔ Slower rollback | 📄 Docs |
| Feature Flags | Runtime feature control | Flexibility ↔ Tech debt | 📄 Docs |
| Strangler Fig | Legacy migration | Incremental ↔ Longer timeline | 📄 Docs |
| Database Per Service | Microservices data isolation | Autonomy ↔ Distributed complexity | 📄 Docs |
Full-stack URL shortener scaling from local to 500M URLs/month globally
| Tier | Scale | Architecture |
|---|---|---|
| 1 | Local | SQLite + Single binary |
| 2 | Startup (100K/mo) | PostgreSQL + Redis |
| 3 | Growth (10M/mo) | Multi-instance + Replicas |
| 4 | Scale (100M/mo) | Multi-region + DynamoDB |
| 5 | Global (500M/mo) | Edge computing + Sharded |
Stack: Rust (Axum) • DynamoDB Global Tables • CloudFront • Terraform • Kubernetes
| Resource | Link |
|---|---|
| Rust Version | 📘 README |
| Java Version | 📘 README |
| Architecture | 🏛️ Docs |
| Security & Compliance | 🔒 GDPR/SOC2 |
High-performance rate limiter for API Gateway (100K-1M RPS)
Features: Sliding window counter • Composite keys (user + endpoint) • Fail-open/closed modes • Circuit breaker integration
Stack: Java 21 (Spring Boot) • Redis Cluster • Resilience4j • Prometheus
| Resource | Link |
|---|---|
| Overview | 📘 README |
| Architecture | 🏛️ Docs |
| Algorithms | 🧮 Docs |
Gaming leaderboard for 100M users with 50M DAU, supporting global/regional/friend rankings
Features: O(log N) Redis Sorted Sets • WebSocket push notifications • Multiple time windows • Circuit breakers
Stack: Java 21 (Spring Boot) • Redis Cluster • Kafka • PostgreSQL • WebSocket
| Resource | Link |
|---|---|
| Overview | 📘 README |
| Architecture | 🏛️ Docs |
| Redis Deep Dive | 📊 Docs |
| Demo Scripts | 🎮 Scripts |
Complete OAuth 2.0 implementation with Authorization Server and Resource Server
Features: Authorization Code + PKCE • Client Credentials • Refresh Tokens • JWT with custom claims • PostgreSQL persistence
Stack: Java (Spring Boot 3.2) • Spring Authorization Server • Spring Security • PostgreSQL
| Resource | Link |
|---|---|
| Overview | 📘 README |
| Postman Collection | 📬 Collection |
Simple JWT auth system with access/refresh tokens
Features: Token rotation • Secure refresh flow • Spring Security integration
Stack: Java (Spring Boot 3.2) • Spring Security • MySQL • jjwt
| Resource | Link |
|---|---|
| Overview | 📘 README |
| Architecture | 🏛️ Docs |
| Postman Collection | 📬 Collection |
RESTful CRUD API demonstrating Cassandra/ScyllaDB patterns
Features: CQL operations • Docker Compose setup • Seed data
Stack: Java (Spring Boot) • Apache Cassandra 4.1 • Docker
| Resource | Link |
|---|---|
| Overview | 📘 README |
MySQL column type codecs with zero-copy decoding (Go)
Features: Text/Binary protocol • Temporal types with timezone • DECIMAL precision • database/sql helpers
| Resource | Link |
|---|---|
| Overview | 📘 README |
| Source | 📦 Go Package |
📚 Complete Guide — 12-part comprehensive preparation resource
| # | Topic | Description |
|---|---|---|
| 01 | Interview Framework | Step-by-step approach for any interview |
| 02 | Requirements & Estimation | Capacity planning basics |
| 02a | Back-of-Envelope (Detailed) | Mental math tricks & calculations |
| 03 | Core Building Blocks | DBs, caching, load balancers |
| 04 | Scalability Patterns | Sharding, replication, scaling |
| 05 | Distributed Concepts | CAP, consistency, consensus |
| 06 | Data Storage | SQL vs NoSQL, partitioning |
| 07 | Caching Strategies | Patterns, invalidation, CDNs |
| 08 | Messaging & Async | Queues, event-driven |
| 09 | API Design | REST, GraphQL, gRPC |
| 10 | Observability | Monitoring, fault tolerance |
| 11 | Common Problems | URL shortener, chat, feed |
| 12 | Quick Reference | One-page cheatsheet |
Complete job search framework with trackers, templates, and guides
| Category | Topics | Link |
|---|---|---|
| Resume | Quantified achievements, LinkedIn optimization | 📄 Resume Guide |
| Behavioral | STAR stories, EM philosophy | 📄 STAR Bank |
| System Design | Quick reference sheets | 📄 Cheat Sheets |
| LLD | Patterns, problem bank | 📄 LLD Guide |
| Coding | Pattern-based approach | 📄 Coding Patterns |
| Negotiation | Compensation strategy | 📄 Negotiation |
| Tracker | Company research template | 📄 Tracker |
| Company | Type | Link |
|---|---|---|
| Agoda | System Design + LLD | 📁 Folder |
| Kuvera | System Design | 📁 Folder |
| Fintech Org | Architecture Review | 📁 Folder |
📚 Complete Guide — 42 compliance frameworks across 6 regions
Comprehensive reference covering:
| Region | Key Regulations |
|---|---|
| Global | Basel III/IV, FATF, PCI DSS, ISO 27001 |
| North America | SOX, GLBA, BSA/AML, Dodd-Frank, CCPA, NYDFS |
| Europe | GDPR, PSD2/PSD3, MiFID II, DORA, AMLD 5/6 |
| Asia Pacific | RBI Master Directions, DPDP Act, PIPL, MAS TRM, CPS 234 |
| Middle East | CBUAE, SAMA Cybersecurity, PDPL |
| Latin America | LGPD, BCB Resolution 4893 |
| Africa | POPIA, SARB, NDPR |
Workflow orchestration with practical DAG examples
Use Cases: ETL pipelines • ML orchestration • Data quality • Report generation
| Resource | Link |
|---|---|
| Getting Started | 📘 README |
| Core Concepts | 📄 Concepts |
| Best Practices | 📄 Guide |
| Example DAGs | 📦 dags/ |
flowchart LR
A[Interview Guide] --> B[Patterns Reference]
B --> C[URL Shortener]
C --> D[Rate Limiter]
D --> E[Leaderboard]
- Foundation: System Design Interview Guide
- Patterns: Distributed Patterns
- Build: URL Shortener
- Scale: Rate Limiter
- Real-time: Leaderboard
flowchart LR
A[JWT Auth] --> B[OAuth 2.0]
B --> C[Compliance Guide]
C --> D[Seller Payments]
- Basics: JWT Authentication
- OAuth: OAuth 2.0 Demo
- Compliance: Financial Compliance Guide
- Apply: Seller Payment System
flowchart LR
A[Event-Driven Patterns] --> B[Collaborative Editor]
B --> C[Uber Eats Feed]
C --> D[Crash Detection]
- Foundation: Messaging Patterns
- Collaboration: Collaborative Editor
- Geo-Spatial: Uber Eats Feed
- IoT Streaming: Crash Detection
flowchart LR
A[Data Patterns] --> B[Issue Tracker]
B --> C[Seller Payments]
C --> D[Clearing House]
- Patterns: Data Patterns
- Multi-Tenant: Issue Tracking System
- Payments: Seller Payment System
- Finance: Clearing House
flowchart LR
A[Interview Guide] --> B[Quick Reference]
B --> C[Case Studies]
C --> D[Mock Practice]
- Guide: Interview Framework
- Reference: Cheatsheet
- Study: Any case study from above
- Review: Interview Experiences
| Pattern | Used In |
|---|---|
| Event Sourcing / CDC | Fintech Data Platform, E-Commerce, Collaborative Editor |
| CQRS | E-Commerce, Uber Eats Feed, Issue Tracking |
| Saga Pattern | Financial Clearing House, Seller Payments |
| Exactly-Once Semantics | Clearing House, Seller Payments, Leaderboard |
| CRDT | Collaborative Editor |
| Redis Sorted Sets | Leaderboard, Rate Limiter |
| Batch + Real-time (Lambda) | E-Commerce, Crash Detection |
| H3 Spatial Indexing | Uber Eats Feed |
| Circuit Breaker | Rate Limiter, Seller Payments, Leaderboard |
| Multi-Tenancy (RLS) | Issue Tracking System |
| WebSocket | Collaborative Editor, Leaderboard |
| OAuth 2.0 / JWT | OAuth 2.0 Demo, JWT Auth |
| Sharding / Partitioning | All case studies |
cd oauth2-demo && ./run.sh
# Auth Server: http://localhost:9001
# Resource Server: http://localhost:8080cd leaderboard
docker-compose up -d redis zookeeper kafka postgres
./mvnw spring-boot:run
./scripts/demo-data.sh# Python
cd financial-clearing-house/src/python && python3 demo.py
# Java
cd financial-clearing-house
mkdir -p target && find src/java -name "*.java" | xargs javac -d target
java -cp target com.clearinghouse.SettlementAppcd url-shortener && docker-compose up -d
# API available at http://localhost:8080cd rate-limiter && docker-compose up -d redis && ./mvnw spring-boot:runcd jwt-auth && docker-compose up -d --build
# API available at http://localhost:8080cd products-api && docker-compose up -d --build
# API available at http://localhost:8080cd apache-airflow && docker-compose up -d
# UI at http://localhost:8080 (admin/admin)MIT — See LICENSE for details.
Built for engineers who want depth over breadth in system design.