Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit ca905f8

Browse files
committed
do not update restartLSN upon walsender start
1 parent e75fbe6 commit ca905f8

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

multimaster.c

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3587,13 +3587,13 @@ MtmReplicationStartupHook(struct PGLogicalStartupHookArgs* args)
35873587
ulong64 recoveredLSN;
35883588
sscanf(strVal(elem->arg), "%llx", &recoveredLSN);
35893589
MTM_LOG1("Recovered position of node %d is %llx", MtmReplicationNodeId, recoveredLSN);
3590-
if (Mtm->nodes[MtmReplicationNodeId-1].restartLSN < recoveredLSN) {
3591-
MTM_LOG1("Advance restartLSN for node %d from %llx to %llx (MtmReplicationStartupHook)",
3592-
MtmReplicationNodeId, Mtm->nodes[MtmReplicationNodeId-1].restartLSN, recoveredLSN);
3593-
// Assert(Mtm->nodes[MtmReplicationNodeId-1].restartLSN == INVALID_LSN
3594-
// || recoveredLSN < Mtm->nodes[MtmReplicationNodeId-1].restartLSN + MtmMaxRecoveryLag);
3595-
Mtm->nodes[MtmReplicationNodeId-1].restartLSN = recoveredLSN;
3596-
}
3590+
// if (Mtm->nodes[MtmReplicationNodeId-1].restartLSN < recoveredLSN) {
3591+
// MTM_LOG1("Advance restartLSN for node %d from %llx to %llx (MtmReplicationStartupHook)",
3592+
// MtmReplicationNodeId, Mtm->nodes[MtmReplicationNodeId-1].restartLSN, recoveredLSN);
3593+
// // Assert(Mtm->nodes[MtmReplicationNodeId-1].restartLSN == INVALID_LSN
3594+
// // || recoveredLSN < Mtm->nodes[MtmReplicationNodeId-1].restartLSN + MtmMaxRecoveryLag);
3595+
// Mtm->nodes[MtmReplicationNodeId-1].restartLSN = recoveredLSN;
3596+
// }
35973597
} else {
35983598
MTM_ELOG(ERROR, "Recovered position is not specified");
35993599
}

0 commit comments

Comments
 (0)