@@ -1248,6 +1248,8 @@ MtmVotingCompleted(MtmTransState* ts)
1248
1248
{
1249
1249
nodemask_t liveNodesMask = (((nodemask_t )1 << Mtm -> nAllNodes ) - 1 ) & ~Mtm -> disabledNodeMask & ~((nodemask_t )1 << (MtmNodeId - 1 ));
1250
1250
1251
+ Assert (ts -> gtid .node == MtmNodeId );
1252
+
1251
1253
if (ts -> nConfigChanges != Mtm -> nConfigChanges )
1252
1254
{
1253
1255
if (MtmGetCurrentStatus () == MTM_ONLINE )
@@ -1273,6 +1275,7 @@ MtmVotingCompleted(MtmTransState* ts)
1273
1275
&& (ts -> participantsMask & ~Mtm -> disabledNodeMask & ~ts -> votedMask ) == 0 ) /* all live participants voted */
1274
1276
{
1275
1277
if (ts -> isPrepared ) {
1278
+ Assert (ts -> isTwoPhase || !MtmUseDtm );
1276
1279
ts -> csn = MtmAssignCSN ();
1277
1280
ts -> votingCompleted = true;
1278
1281
ts -> status = TRANSACTION_STATUS_UNKNOWN ;
@@ -1282,6 +1285,7 @@ MtmVotingCompleted(MtmTransState* ts)
1282
1285
ts -> gid , MtmTxnStatusMnem [ts -> status ], ts -> participantsMask , Mtm -> disabledNodeMask , ts -> votedMask );
1283
1286
ts -> isPrepared = true;
1284
1287
if (ts -> isTwoPhase ) {
1288
+ Assert (false);
1285
1289
ts -> votingCompleted = true;
1286
1290
return true;
1287
1291
} else if (MtmUseDtm ) {
@@ -2110,16 +2114,12 @@ MtmPollStatusOfPreparedTransactions(bool majorMode)
2110
2114
{
2111
2115
MtmTransState * ts = MtmGetActiveTransaction (cur );
2112
2116
2113
- MTM_LOG1 ("X_MtmPollStatusOfPreparedTransactions %s, major=%d, status=%d, isPrepared=%d, valid=%d, completed=%d" , ts -> gid , majorMode , ts -> status , ts -> isPrepared , TransactionIdIsValid (ts -> gtid .xid ), ts -> votingCompleted );
2114
-
2115
2117
if (TransactionIdIsValid (ts -> gtid .xid )
2116
2118
&& ts -> votingCompleted /* If voting is not yet completed, then there is some backend coordinating this transaction */
2117
2119
&& (ts -> status == TRANSACTION_STATUS_UNKNOWN || ts -> status == TRANSACTION_STATUS_IN_PROGRESS ))
2118
2120
{
2119
2121
Assert (ts -> gid [0 ]);
2120
2122
2121
- MTM_LOG1 ("MtmPollStatusOfPreparedTransactions %s, major=%d, status=%d, isPrepared=%d" , ts -> gid , majorMode , ts -> status , ts -> isPrepared );
2122
-
2123
2123
if (majorMode )
2124
2124
{
2125
2125
MtmFinishPreparedTransaction (ts , ts -> status == TRANSACTION_STATUS_UNKNOWN );
0 commit comments