Skip to content

Defined in: packages/cache/src/cache.ts:36

One thing a cache did, reported to CacheOptions.trace in the order it happened.

  • hit and miss: a get found the key, or did not (an expired key reports expire first, then miss). peek and has report neither.
  • insert and update: a set stored a key the cache did not hold, or replaced one it did. It follows the evict and expire events the same set caused.
  • evict: the policy chose the key to make room; it is one of the entries set returns.
  • delete: delete removed an unexpired key.
  • expire: an entry was dropped because it had expired, by any member that found it, including deleteExpired and an eviction that reached it.

clear reports nothing.

K

readonly kind: "delete" | "hit" | "miss" | "insert" | "update" | "evict" | "expire"

Defined in: packages/cache/src/cache.ts:38

What the cache did.


readonly key: K

Defined in: packages/cache/src/cache.ts:40

The key it did it to.