Content-Length: 274394 | pFad | http://github.com/postgrespro/mmts/commit/80fb551c30d4d5716f7a07f832e061d5458be9b3
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 26db1c2 commit 80fb551Copy full SHA for 80fb551
src/multimaster.c
@@ -1428,6 +1428,19 @@ mtm_join_node(PG_FUNCTION_ARGS)
1428
}
1429
PQclear(res);
1430
1431
+ /*
1432
+ * FIXME: await for new node joining or there is a small probablity of
1433
+ * this (alter_sequences) xact commit failure due to gen switch including
1434
+ * new node.
1435
+ */
1436
+ while (true)
1437
+ {
1438
+ MtmGeneration curr_gen = MtmGetCurrentGen(false);
1439
+
1440
+ if (BIT_CHECK(curr_gen.members, new_node_id - 1))
1441
+ break;
1442
+ MtmSleep(USECS_PER_SEC / 10);
1443
+ }
1444
/* call mtm.alter_sequences since n_nodes is changed */
1445
query = psprintf("select mtm.alter_sequences()");
1446
rc = SPI_execute(query, false, 0);
Fetched URL: http://github.com/postgrespro/mmts/commit/80fb551c30d4d5716f7a07f832e061d5458be9b3
Alternative Proxies:
Alternative Proxy
pFad Proxy
pFad v3 Proxy
pFad v4 Proxy
0 commit comments