High-Level Design

HLD Topics

System architecture, distributed systems, databases, caching & real-world system designs

88 Foundation Topics 108 Case Studies 8 Deep Dives
88 Topics — 14 Categories

Foundations

Core Principles

Networking

Databases

NoSQL & DB Selection

MongoDB
BSON, flexible schema, aggregation pipeline
Redis Deep Dive
Data structures, persistence, clustering, Lua
Cassandra
Partition keys, gossip protocol, tunable consistency
Neo4j
Cypher, graph traversals, when to use graphs

Caching

Strategies
Cache-aside, write-through, write-behind, refresh-ahead
Eviction Internals
LRU, LFU, Redis TTL sampling, jemalloc
Invalidation
TTL, event-based, cache stampede, thundering herd
CDN
PoPs, push vs pull, edge computing, origin shielding
Caching Levels
Browser → API → Redis → DB, materialized views

Messaging

Message Queues
SQS, RabbitMQ, DLQ, exactly-once delivery
Kafka Deep Dive
Partitions, ISR, consumer groups, compaction
Pub/Sub
Redis Pub/Sub, fan-out, config push patterns
Async Patterns
Task queues, backpressure, flow control

Distributed Systems

Consistency Models
Strong, eventual, causal, linearizability
Consensus
Raft, Paxos, how nodes agree despite failures
Clocks & Ordering
Lamport, vector clocks, TrueTime
Consistent Hashing
Ring, vnodes, data migration, jump hashing

Load Balancing & Resilience

Load Balancers
L4 vs L7, algorithms, health checks, DNS-based
API Gateway
Auth, rate limiting, routing, aggregation
Rate Limiting
Token bucket, sliding window, library vs service
Circuit Breaker
3-state model, bulkhead, exponential backoff
Idempotency
Keys, exactly-once patterns, Stripe's approach

Storage & Data

S3 / Blob Storage
Signed URLs, multipart, erasure coding, 11 nines
Distributed FS
GFS, HDFS, chunk storage, fault tolerance
Tiered Storage
Hot/warm/cold/glacier, cost optimization
Batch Processing
MapReduce, Spark, data locality, lineage

Serialization

Serialization Formats
Protobuf, Avro, Thrift, schema evolution
Compression
gzip, zstd, Snappy, columnar compression

Architecture Patterns

Monolith vs Micro
Trade-offs, decomposition, database per service
Event-Driven
Event sourcing, CQRS, saga, outbox pattern
Service Mesh
Istio, sidecar proxies, Consul, etcd
Communication
sync (REST, gRPC) vs async (events), BFF

Security

Auth
OAuth 2.0, JWT, SSO, RBAC/ABAC, session management
TLS / Encryption
Handshake, certificates, mTLS, KMS
API Security
CORS, CSRF, DDoS, OWASP top 10
Zero Trust
Service-to-service auth, VPC, segmentation

Observability

Logging
Structured logging, ELK, correlation IDs
Metrics
Prometheus, Grafana, RED/USE methods
Tracing
Jaeger, OpenTelemetry, trace/span propagation
Alerting
On-call, runbooks, alert fatigue, postmortems

Infrastructure

Containers & K8s
Docker, pods, services, ingress, scaling
CI/CD
Build, test, deploy, artifacts, GitOps
Deployment
Blue-green, canary, rolling, feature flags
Serverless
Lambda, cold starts, concurrency, event-driven
IaC
Terraform, CloudFormation, immutable infrastructure