Probabilistic early expiration.
also: probabilistic expiration · early expiration · XFetch · TTL jitterRefreshing an entry at a random moment shortly before its TTL ends, so keys don't all expire at once.
the two-minute refresher
- Same TTL everywhere means synchronised expiry and a synchronised stampede.
- Each read may refresh early, more likely as expiry approaches.
- A single unlucky request refreshes the value while others keep hitting the cache.
- Cheap and stateless: no lock needed.