add functions to determine when primary last seen by repmgrd node

This commit is contained in:
Ian Barwick
2018-11-16 17:09:18 +09:00
parent a2d38c6084
commit 1458f6e6aa
2 changed files with 64 additions and 5 deletions

View File

@@ -118,6 +118,16 @@ CREATE FUNCTION standby_get_last_updated()
AS 'MODULE_PATHNAME', 'standby_get_last_updated'
LANGUAGE C STRICT;
CREATE FUNCTION set_primary_last_seen()
RETURNS VOID
AS 'MODULE_PATHNAME', 'set_primary_last_seen'
LANGUAGE C STRICT;
CREATE FUNCTION get_primary_last_seen()
RETURNS INT
AS 'MODULE_PATHNAME', 'get_primary_last_seen'
LANGUAGE C STRICT;
/* failover functions */
CREATE FUNCTION notify_follow_primary(INT)