Skip to content

v10.11.0

Choose a tag to compare

@camilb camilb released this 16 Sep 19:04
· 327 commits to main since this release
fc39aa8

Memory cache refill from Redis and byte-bounded LRU (DEV-24150)

  • The stacked cache refills earlier layers from a hit found in a later one, carrying the entry's own version and retention. A key invalidated in memory by a version bump is served from memory again after one Redis read. New optional Cache.lookup method; third-party caches implementing only get keep working and are never used as a refill source.
  • The in-process store is a deterministic least-recently-used cache bounded by estimated bytes (128 MiB) and records (20,000) by default, replacing the probabilistic cleanup. PrezlyAdapter.connect({ memory: { maxBytes, maxRecords } }) changes the bounds; ContentDelivery.inspectSharedMemoryCache() reports occupancy.
  • Redis renewal rewrites an entry only once it has consumed half of its lifetime, through a compare-and-swap Lua script, instead of an EXPIRE on every read. Entries from older releases are renewed on first read; not-found entries are never renewed.
  • Memory set keeps a newer entry over a late older write and skips entries larger than maxBytes.

Full changes: #1043