Cache invalidation.
also: invalidate the cache · invalidating the cache · cache invalidations · write-invalidate · write-update · invalidation strategy · invalidation strategiesRemoving or updating cached entries when the source data changes, so readers don't keep seeing stale values.
the two-minute refresher
- One of the two hard things in computer science, for good reason.
- Strategies: TTL, event-driven invalidation, versioned keys, write-invalidate vs write-update.
- Decide per data type how stale is acceptable: prices and stock differ from avatars.
- Combine them: events for freshness, TTL as the safety net when an event is lost.