Record: CacheConfig
Represents configurations for the cache:Cache
object.
Closed record
Fields
- capacity int(default 100)
- evictionFactor float(default 0.25)
- evictionPolicy EvictionPolicy(default LRU)
- defaultMaxAge decimal(default -1)
- cleanupInterval decimal?
Maximum number of entries allowed in the cache
The factor by which the entries will be evicted once the cache is full
The policy which is used to evict entries once the cache is full
The default value in seconds which all the cache entries are valid. '-1' means, the entries are
valid forever. This will be overwritten by the the maxAge
property set when inserting item to
the cache
Interval (in seconds) of the timer task, which will clean up the cache