Add more detailed redis error message

This commit is contained in:
Ajay 2023-02-04 14:07:09 -05:00
parent 663bd96130
commit 399bda869f

View file

@ -98,7 +98,7 @@ if (config.redis?.enabled) {
if ((config.redis.maxWriteConnections && activeRequests > config.redis.maxWriteConnections)
|| (config.redis.responseTimePause
&& Date.now() - lastResponseTimeLimit < config.redis.responseTimePause)) {
reject("Too many active requests to write");
reject(`Too many active requests to write due to ${activeRequests} requests and ${Date.now() - lastResponseTimeLimit}ms since last response time limit`);
return;
}