Documentation

LeanRedis.Cache.CacheSWR

Equations
Instances For
    @[inline, specialize #[]]

    Gets a value from the cache by key.

    • If a fresh value is found, it is returned immediately.
    • If a stale value is found, it is returned immediately and a background refresh is triggered to update the cache.
    • If no value is found, the callback will be called to populate it. The callback is executed exactly once for each key, even if multiple requests request the same key concurrently.
    • Cache stampedes are prevented.
    Equations
    • One or more equations did not get rendered due to their size.
    Instances For