diff options
author | omg-by <504094596@qq.com> | 2020-04-18 00:49:16 +0800 |
---|---|---|
committer | omg-by <504094596@qq.com> | 2020-04-18 00:49:16 +0800 |
commit | 9d27e00ddb7f49d9af104ab66e87c2a626d68ab8 (patch) | |
tree | b8906ca4daf566a47a5abaa2e2124c6c358697bf | |
parent | 6d2f1188ac7fdbb03c0f3f83bfa06a02f2bbca3d (diff) | |
download | redis-9d27e00ddb7f49d9af104ab66e87c2a626d68ab8.tar.gz |
fix(sentinel): sentinel.running_scripts will always increase more times and not reset
when trigger a always fail scripts, sentinel.running_scripts will increase ten times, however it
only decrease one times onretry the maximum. and it will't reset, when it become
SENTINEL_SCRIPT_MAX_RUNNING, sentinel don't trigger scripts.
-rw-r--r-- | src/sentinel.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/sentinel.c b/src/sentinel.c index 10c003d03..7a25e5ae4 100644 --- a/src/sentinel.c +++ b/src/sentinel.c @@ -859,6 +859,7 @@ void sentinelCollectTerminatedScripts(void) { sj->pid = 0; sj->start_time = mstime() + sentinelScriptRetryDelay(sj->retry_num); + sentinel.running_scripts--; } else { /* Otherwise let's remove the script, but log the event if the * execution did not terminated in the best of the ways. */ |