Glossary

Cache Stampede

When a popular cached key expires and thousands of requests miss at once, all hammering the database together.

1 min read·4 sections
Open the interactive version → diagrams, practice & more

Definition

When a popular cached key expires and thousands of requests miss at once, all hammering the database together.

How it works

Also called a thundering herd or dogpile. A single expiry turns into a synchronized flood that can topple the origin. Defences: a per-key lock so one request refills while others wait, serving slightly-stale data during refresh, jittered/staggered TTLs, and async/background re-computation.

Common questions

What is Cache Stampede?

When a popular cached key expires and thousands of requests miss at once, all hammering the database together.

How does Cache Stampede work?

Also called a thundering herd or dogpile. A single expiry turns into a synchronized flood that can topple the origin. Defences: a per-key lock so one request refills while others wait, serving slightly-stale data during refresh, jittered/staggered TTLs, and async/background…

What is Cache Stampede used for in system design?

Also called a thundering herd or dogpile. A single expiry turns into a synchronized flood that can topple the origin. Defences: a per-key lock so one request refills while others wait, serving slightly-stale data during refresh, jittered/staggered TTLs, and async/background…

Part of Glossary on SystemLore — system design explained with 148 deep topics, interactive diagrams, and a build-it-yourself game. Browse the glossary and "X vs Y" comparisons, or build this one →