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. */
| 3507 | * The function can be used both to initialize the manual failover state at |
| 3508 | * startup or to abort a manual failover in progress. */ |
| 3509 | void resetManualFailover(void) { |
| 3510 | if (g_pserver->cluster->mf_end) { |
| 3511 | checkClientPauseTimeoutAndReturnIfPaused(); |
| 3512 | } |
| 3513 | g_pserver->cluster->mf_end = 0; /* No manual failover in progress. */ |
| 3514 | g_pserver->cluster->mf_can_start = 0; |
| 3515 | g_pserver->cluster->mf_slave = NULL; |
| 3516 | g_pserver->cluster->mf_master_offset = -1; |
| 3517 | } |
| 3518 | |
| 3519 | /* If a manual failover timed out, abort it. */ |
| 3520 | void manualFailoverCheckTimeout(void) { |
no test coverage detected