OptionalcontextThe context option provided to a memo or fetch operation
In practice, of course, this will be the same type as the FC
fetch context param used to instantiate the LRUCache, but the
convolutions of threading that through would get quite complicated,
and preclude forcing/forbidding the passing of a context param
where it is/isn't expected, which is more valuable for error
prevention.
OptionaldeleteThe status of a delete() operation.
OptionalentryThe calculated size for the item, if sizes are used.
OptionalfetchThe status of a LRUCache#fetch operation. Note that this can change as the underlying fetch() moves through various states.
OptionalfetchThe fetch received an abort signal
OptionalfetchThe abort signal received was ignored, and the fetch was allowed to continue in the background.
OptionalfetchThe OptionsBase.fetchMethod was called
OptionalfetchThe reason for a fetch() rejection. Either the error raised by the OptionsBase.fetchMethod, or the reason for an AbortSignal.
OptionalfetchThe fetchMethod promise was rejected
OptionalfetchThe fetchMethod promise resolved successfully
OptionalfetchThe cached value was updated after a successful call to OptionsBase.fetchMethod
OptionalforceforceRefresh option was used for either a fetch or memo operation
OptionalgetThe status of a LRUCache#get operation.
returnedStale flag will be set.returnedStale flag will be set.OptionalhasThe results of a LRUCache#has operation
OptionalkeyThe key that was set or retrieved
OptionalmaxA flag indicating that the item was not stored, due to exceeding the OptionsBase.maxEntrySize
OptionalmemoThe status of a memo() operation.
memoMethod function was calledOptionalnowThe timestamp used for TTL calculation
OptionaloldThe old value, specified in the case of set:'replace'
OptionalopThe operation being performed
OptionalpeekThe result of a peek() operation
Optionalremainingthe remaining ttl for the item, or undefined if ttls are not used.
OptionalreturnedA fetch or get operation returned a stale value.
OptionalsetThe status of a set() operation.
Optionalstartthe start time for the item, or undefined if ttls are not used.
OptionaltotalThe total calculated size of the cache, if sizes are used.
OptionaltraceA tracingChannel trace was started for this operation
Optionalttlthe ttl stored for the item, or undefined if ttls are not used.
OptionalvalueThe value that was set
Occasionally, it may be useful to track the internal behavior of the cache, particularly for logging, debugging, or for behavior within the
fetchMethod. To do this, you can pass astatusobject to the LRUCache#fetch, LRUCache#get, LRUCache#set, LRUCache#memo, and LRUCache#has methods.The
statusoption should be a plain JavaScript object. The following fields will be set on it appropriately, depending on the situation.These objects are also the context objects passed to listeners on the
lru-cache:metricsdiagnostic channel, and thelru-cachetracing channels, in platforms that support them.