Quick Decision Rule: When A hot homepage key cached for 60s expires during peak traffic, causing 5,000 concurrent requests to miss cache simultaneously and crush the database, choose Request coalescing (singleflight / lock-on-miss) combined with TTL jitter or stale-while-revalidate.
| Trigger Condition | A hot homepage key cached for 60s expires during peak traffic, causing 5,000 concurrent requests to miss cache simultaneously and crush the database |
|---|---|
| Recommended Choice | Request coalescing (singleflight / lock-on-miss) combined with TTL jitter or stale-while-revalidate |
| Classic Trap | Plain cache-aside with fixed TTL creates synchronized thundering herds that cascade into full database meltdowns. |
| Verification | Audited on 2026-11-23 · Distributed Systems Core · 2026 |
30-SECOND DECISION TRAP CHECK · PERFORMANCE
Every hour on the dot, your Redis cache for the trending catalog expires and 8,000 concurrent API requests slam PostgreSQL simultaneously, triggering a 3-minute outage. What is the cleanest architectural fix?
Synchronized cache expiration causes a thundering herd. Singleflight coalesces concurrent misses into a single DB query, while TTL jitter and background refresh prevent synchronized expiry cliffs.
Trap: Uniform TTL on hot keys triggers cache stampedes; combine singleflight coalescing with TTL jitter.