CacheEntry<T>
@blobs/sdk / cache / CacheEntry
Defined in: cache/CacheProvider.ts:66
Wire shape of an entry stored by a CacheProvider.
Implementations serialize this structure (e.g. as JSON in LocalStorageCache) so they can detect expiry on read.
Type Parameters
T
T = any
Type of the cached value.
Properties
value
value:
T
Defined in: cache/CacheProvider.ts:68
The cached value.
timestamp
timestamp:
number
Defined in: cache/CacheProvider.ts:70
Unix timestamp (ms) at which the entry was written.
ttl?
optionalttl?:number
Defined in: cache/CacheProvider.ts:72
Time-to-live in milliseconds; absent or 0 means no expiry.