mirror of
https://github.com/EnterpriseDB/repmgr.git
synced 2026-03-22 22:56:29 +00:00
repmgrd: catch cases where more than one node has initiated voting
The node(s) with higher ID will "yield", leaving the decision making up to the node with the lower ID. This happens very rarely, usually when the random delay is close enough on two or mode nodes that vote initiation is simultaneous.
This commit is contained in:
4
repmgr.c
4
repmgr.c
@@ -206,13 +206,11 @@ request_vote(PG_FUNCTION_ARGS)
|
||||
|
||||
initStringInfo(&query);
|
||||
|
||||
#if (PG_VERSION_NUM >= 100000)
|
||||
appendStringInfo(
|
||||
&query,
|
||||
#if (PG_VERSION_NUM >= 100000)
|
||||
"SELECT pg_catalog.pg_last_wal_receive_lsn()");
|
||||
#else
|
||||
appendStringInfo(
|
||||
&query,
|
||||
"SELECT pg_catalog.pg_last_xlog_receive_location()");
|
||||
#endif
|
||||
|
||||
|
||||
Reference in New Issue
Block a user