Cache invalidation removes or marks cached data unusable when it expires or stops being authoritative. It balances faster reads and lower backend load against stale data, consistency, and operational complexity. section 6.4
Reason about invalidation at the layer that owns the cached data:
- Client caches require careful asset or response versioning so updates do not leave browsers serving outdated content; Cache-Control and ETag provide control. section 6.4
- CDN caches need correctly configured expiration and purging rules, especially for generated content reused across visitors. section 6.4
- Application caches can improve response time while making consistency across distributed services harder to maintain. section 6.4
Interview scenario
When asked how an updated product image reaches users, discuss versioning for client assets, expiration or purge rules at the CDN, and the risk of stale data across application caches. Follow-up questions typically probe consistency, complexity, and invalidation choices. section 6.4



