From 7195512b991afa1add2edba263b148f32b5ccfa9 Mon Sep 17 00:00:00 2001 From: Ian Barwick Date: Tue, 8 Jan 2019 09:26:37 +0900 Subject: [PATCH] Note primary/standby aliases for "node check" and "node status" actions Add comment noting the intent behind those code sections, otherwise it looks like a copy'n'paste error. This currently isn't documented. --- repmgr-client.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/repmgr-client.c b/repmgr-client.c index d153e158..a6506ed4 100644 --- a/repmgr-client.c +++ b/repmgr-client.c @@ -808,6 +808,7 @@ main(int argc, char **argv) action = PRIMARY_REGISTER; else if (strcasecmp(repmgr_action, "UNREGISTER") == 0) action = PRIMARY_UNREGISTER; + /* allow "primary check"/"primary status" as aliases for "node check"/"node status" */ else if (strcasecmp(repmgr_action, "CHECK") == 0) action = NODE_CHECK; else if (strcasecmp(repmgr_action, "STATUS") == 0) @@ -834,6 +835,7 @@ main(int argc, char **argv) action = STANDBY_FOLLOW; else if (strcasecmp(repmgr_action, "SWITCHOVER") == 0) action = STANDBY_SWITCHOVER; + /* allow "standby check"/"standby status" as aliases for "node check"/"node status" */ else if (strcasecmp(repmgr_action, "CHECK") == 0) action = NODE_CHECK; else if (strcasecmp(repmgr_action, "STATUS") == 0)