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

Commit 5560b28

Browse files
committed
another take on MtmFilterTransaction behaviour
1 parent 234c13a commit 5560b28

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

multimaster.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3789,10 +3789,10 @@ bool MtmFilterTransaction(char* record, int size)
37893789
restart_lsn = origin_node == MtmReplicationNodeId ? end_lsn : origin_lsn;
37903790
if (Mtm->nodes[origin_node-1].restartLSN < restart_lsn) {
37913791
MTM_LOG2("[restartlsn] node %d: %llx -> %llx (MtmFilterTransaction)", MtmReplicationNodeId, Mtm->nodes[MtmReplicationNodeId-1].restartLSN, restart_lsn);
3792-
if (event != PGLOGICAL_PREPARE) {
3793-
/* Transactions can be prepared in different order, so to avoid loosing transactions we should not update restartLsn for them */
3794-
Mtm->nodes[origin_node-1].restartLSN = restart_lsn;
3795-
}
3792+
// if (event != PGLOGICAL_PREPARE) {
3793+
// /* Transactions can be prepared in different order, so to avoid loosing transactions we should not update restartLsn for them */
3794+
// Mtm->nodes[origin_node-1].restartLSN = restart_lsn;
3795+
// }
37963796
} else {
37973797
duplicate = true;
37983798
}

pglogical_apply.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -468,8 +468,8 @@ process_remote_message(StringInfo s)
468468
}
469469
if (Mtm->nodes[origin_node-1].restartLSN < msg->origin_lsn) {
470470
MTM_LOG1("Receive logical abort message for transaction %s from node %d: %llx < %llx", msg->gid, origin_node, Mtm->nodes[origin_node-1].restartLSN, msg->origin_lsn);
471-
Mtm->nodes[origin_node-1].restartLSN = msg->origin_lsn;
472-
replorigin_session_origin_lsn = msg->origin_lsn;
471+
// Mtm->nodes[origin_node-1].restartLSN = msg->origin_lsn;
472+
// replorigin_session_origin_lsn = msg->origin_lsn;
473473
MtmRollbackPreparedTransaction(origin_node, msg->gid);
474474
} else {
475475
if (msg->origin_lsn != INVALID_LSN) {

0 commit comments

Comments
 (0)