提交 28917586 编写于 作者: J Jacob Champion 提交者: Xin Zhang

Fully revert two duplicated commits

This reverts commit 0277b584 (which was already partially reverted in
0039844) and commit 4b4643f8. Commit 2b939748 already applied the
logical intent of these commits, as well as some improvements which were
accidentally reverted.
上级 e58accb7
...@@ -7570,7 +7570,14 @@ StartupXLOG(void) ...@@ -7570,7 +7570,14 @@ StartupXLOG(void)
true); true);
#endif #endif
bool needToPromoteCatalog = (ControlFile->state == DB_IN_STANDBY_PROMOTED); /*
* If we are a standby with contentid -1 and undergoing promotion,
* update ourselves as the new master in catalog. This does not
* apply to a mirror (standby of a GPDB segment) because it is
* managed by FTS.
*/
bool needToPromoteCatalog = (GpIdentity.segindex == MASTER_CONTENT_ID &&
ControlFile->state == DB_IN_STANDBY_PROMOTED);
LWLockAcquire(ControlFileLock, LW_EXCLUSIVE); LWLockAcquire(ControlFileLock, LW_EXCLUSIVE);
ControlFile->state = DB_IN_PRODUCTION; ControlFile->state = DB_IN_PRODUCTION;
......
...@@ -116,6 +116,7 @@ HandleFtsWalRepSyncRepOff(void) ...@@ -116,6 +116,7 @@ HandleFtsWalRepSyncRepOff(void)
(errmsg("turning off synchronous wal replication due to FTS request"))); (errmsg("turning off synchronous wal replication due to FTS request")));
UnsetSyncStandbysDefined(); UnsetSyncStandbysDefined();
GetMirrorStatus(&response); GetMirrorStatus(&response);
SendFtsResponse(&response, FTS_MSG_SYNCREP_OFF); SendFtsResponse(&response, FTS_MSG_SYNCREP_OFF);
} }
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册