mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2024-09-19 20:51:19 +02:00
Add ttl to in memory cache cache
This commit is contained in:
parent
5f8ef25d88
commit
e61f964d17
1 changed files with 3 additions and 1 deletions
|
@ -67,7 +67,9 @@ const maxStoredTimes = 200;
|
|||
|
||||
const cache = config.redis.clientCacheSize ? new LRUCache<RedisCommandArgument, string>({
|
||||
maxSize: config.redis.clientCacheSize,
|
||||
sizeCalculation: (value) => value.length
|
||||
sizeCalculation: (value) => value.length,
|
||||
ttl: 1000 * 60 * 30,
|
||||
ttlResolution: 1000 * 60 * 15
|
||||
}) : null;
|
||||
|
||||
// For redis
|
||||
|
|
Loading…
Reference in a new issue