Store the replication user in repmgr.nodes

When creating recovery.conf outside of "repmgr standby clone",
there was no way of knowing if a replication user had been
explicitly provided with --replication-user, meaning the value
of "primary_conninfo" would be set to the "conninfo" field of the
node's upstream node record.

We'll add an extra column to store the replication user for each
node so it can be referenced at any time.
This commit is contained in:
Ian Barwick
2017-06-14 23:27:26 +09:00
parent aa5539ac5e
commit 36b3782009
8 changed files with 58 additions and 25 deletions

View File

@@ -10,6 +10,7 @@ CREATE TABLE nodes (
priority INT NOT NULL DEFAULT 100,
conninfo TEXT NOT NULL,
repluser TEXT NOT NULL,
slot_name TEXT NULL
);