System design / 7 simulations
Reliability and API Gateways
Gateways, limits and surviving failures.
Open the lab → Change the load, break a part, watch what happens. Free, no sign-up.
All topics: edge and reliability
- API gateway with NginxIntermediate · 9 min
Routing, TLS, JWT auth, rate limits, caching and failover, with a live nginx.conf you can copy.
- Rate limiting: who gets a 429Intermediate · 5 min
Token bucket, fixed window and sliding window under steady, bursty and window-edge traffic.
- Timeouts, retries and circuit breakersAdvanced · 7 min
Watch retries turn a slow dependency into a retry storm, and a circuit breaker stop it.
- Multi-region failover: when a whole region goes darkAdvanced · 6 min
Kill the primary region and time the outage: health checks, replica promotion and DNS TTL. Async loses writes, sync costs latency.
- Retries and idempotency keysIntermediate · 6 min
A lost reply makes the client retry a payment. Watch double charges pile up, then stop with an idempotency key.
- Distributed locks, leases and fencing tokensAdvanced · 7 min
A frozen worker wakes after its lease ran out and overwrites someone else. Fencing tokens make storage refuse it.
- Service discovery: registry, heartbeats and stale cachesIntermediate · 5 min
Instances heartbeat to a registry; clients cache the list. Crash one and see traffic hit it until TTL and caches expire.