mirror of https://github.com/valkey-io/valkey
Allow dual channel full sync in plain failover (#2659)
PSYNC_FULLRESYNC_DUAL_CHANNEL is also a full sync, as the comment says, we need to allow it. While we have not yet identified the exact edge case that leads to this line, but during a failover, there should be no difference between different sync strategies. Signed-off-by: Binbin <binloveplay1314@qq.com>
This commit is contained in:
parent
86db609219
commit
a06cf15b20
|
|
@ -4097,7 +4097,8 @@ void syncWithPrimary(connection *conn) {
|
|||
* but there is nothing technically wrong with a full resync which
|
||||
* could happen in edge cases. */
|
||||
if (server.failover_state == FAILOVER_IN_PROGRESS) {
|
||||
if (psync_result == PSYNC_CONTINUE || psync_result == PSYNC_FULLRESYNC) {
|
||||
if (psync_result == PSYNC_CONTINUE || psync_result == PSYNC_FULLRESYNC ||
|
||||
psync_result == PSYNC_FULLRESYNC_DUAL_CHANNEL) {
|
||||
clearFailoverState(true);
|
||||
} else {
|
||||
abortFailover("Failover target rejected psync request");
|
||||
|
|
|
|||
Loading…
Reference in New Issue