export interface SweepOptions<Key, Value>
Options for sweeping a single type of item from cache
Type Parameters
Key
Value
GlobalSweepFilter<Key, Value> filter :
The function used to determine the function passed to the sweep method This property is optional when the key is invites
, messages
, or threads
and lifetime
is set
number interval :
The interval (in seconds) at which to perform sweeping of the item
number lifetime :
How long an item should stay in cache until it is considered sweepable. This property is only valid for the invites
, messages
, and threads
keys. The filter
property is mutually exclusive to this property and takes priority