mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2025-12-27 01:48:33 +03:00
Fix uncached misses tracking
This commit is contained in:
@@ -103,8 +103,6 @@ if (config.redis?.enabled) {
|
|||||||
return Promise.resolve(cache.get(key));
|
return Promise.resolve(cache.get(key));
|
||||||
} else if (shouldClientCacheKey(key)) {
|
} else if (shouldClientCacheKey(key)) {
|
||||||
memoryCacheMisses++;
|
memoryCacheMisses++;
|
||||||
} else {
|
|
||||||
memoryCacheUncachedMisses++;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (memoryCacheHits + memoryCacheMisses > 50000) {
|
if (memoryCacheHits + memoryCacheMisses > 50000) {
|
||||||
@@ -189,6 +187,9 @@ if (config.redis?.enabled) {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// For tracking
|
||||||
|
if (!shouldClientCacheKey(key)) memoryCacheUncachedMisses++;
|
||||||
|
|
||||||
const start = Date.now();
|
const start = Date.now();
|
||||||
activeRequests++;
|
activeRequests++;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user