Reset the manual failover state. This works for both masters and slaves * as all the state about manual failover is cleared. * * The function can be used both to initialize the manual failover state at * startup or to abort a manual failover in progress. */
| 3449 | * The function can be used both to initialize the manual failover state at |
| 3450 | * startup or to abort a manual failover in progress. */ |
| 3451 | void resetManualFailover(void) { |
| 3452 | if (server.cluster->mf_end) { |
| 3453 | checkClientPauseTimeoutAndReturnIfPaused(); |
| 3454 | } |
| 3455 | server.cluster->mf_end = 0; /* No manual failover in progress. */ |
| 3456 | server.cluster->mf_can_start = 0; |
| 3457 | server.cluster->mf_slave = NULL; |
| 3458 | server.cluster->mf_master_offset = -1; |
| 3459 | } |
| 3460 | |
| 3461 | /* If a manual failover timed out, abort it. */ |
| 3462 | void manualFailoverCheckTimeout(void) { |
no test coverage detected