mirror of
https://codeberg.org/redict/redict.git
synced 2025-01-23 08:38:27 -05:00
Sentinel: clarify effect of resetting failover_start_time.
This commit is contained in:
parent
5080f2d699
commit
20700fe566
@ -1379,7 +1379,9 @@ void sentinelDelFlagsToDictOfRedisInstances(dict *instances, int flags) {
|
|||||||
* 1) Remove all slaves.
|
* 1) Remove all slaves.
|
||||||
* 2) Remove all sentinels.
|
* 2) Remove all sentinels.
|
||||||
* 3) Remove most of the flags resulting from runtime operations.
|
* 3) Remove most of the flags resulting from runtime operations.
|
||||||
* 4) Reset timers to their default value.
|
* 4) Reset timers to their default value. For example after a reset it will be
|
||||||
|
* possible to failover again the same master ASAP, without waiting the
|
||||||
|
* failover timeout delay.
|
||||||
* 5) In the process of doing this undo the failover if in progress.
|
* 5) In the process of doing this undo the failover if in progress.
|
||||||
* 6) Disconnect the connections with the master (will reconnect automatically).
|
* 6) Disconnect the connections with the master (will reconnect automatically).
|
||||||
*/
|
*/
|
||||||
@ -1402,7 +1404,7 @@ void sentinelResetMaster(sentinelRedisInstance *ri, int flags) {
|
|||||||
}
|
}
|
||||||
ri->failover_state = SENTINEL_FAILOVER_STATE_NONE;
|
ri->failover_state = SENTINEL_FAILOVER_STATE_NONE;
|
||||||
ri->failover_state_change_time = 0;
|
ri->failover_state_change_time = 0;
|
||||||
ri->failover_start_time = 0;
|
ri->failover_start_time = 0; /* We can failover again ASAP. */
|
||||||
ri->promoted_slave = NULL;
|
ri->promoted_slave = NULL;
|
||||||
sdsfree(ri->runid);
|
sdsfree(ri->runid);
|
||||||
sdsfree(ri->slave_master_host);
|
sdsfree(ri->slave_master_host);
|
||||||
|
Loading…
Reference in New Issue
Block a user