local cache
A cache kept inside one application process's own memory, such as a dictionary.
In more detail
A hit costs nanoseconds and no network, but each process holds its own copy, so twenty pods mean twenty caches with no reliable way to delete a key everywhere. Pair it with a very short expiry to bound how stale it can be.
Related terms
- shared cache — A cache service, such as Redis, that all application servers read from and write to.
- TTL — How long a stored item, such as a session, token or cache entry, stays valid before it expires.
- cache invalidation — Marking cached copies as out of date, or deleting them, when the real data changes so the next read fetches fresh data.
Taught in
- Caching Strategies And Topology — Scalable System Design & Distributed Architecture
- Load Balancing And The Failure Modes It Introduces — Scalable System Design & Distributed Architecture
- Worked Design Three: Scaling The Metrics Pipeline — Scalable System Design & Distributed Architecture