Refactor "standby follow" functionality

"standby follow" was originally co-opted to start up a demoted node;
this functionality is now delegated to "node rejoin", with the core
functionality of "standby follow" implemented as an internal function.
This commit is contained in:
Ian Barwick
2017-08-09 13:26:27 +09:00
parent b1e544f962
commit df425a38b7
4 changed files with 215 additions and 204 deletions

View File

@@ -1189,6 +1189,14 @@ check_cli_parameters(const int action)
}
break;
case NODE_REJOIN:
if (runtime_options.upstream_conninfo[0] == '\0')
{
item_list_append(
&cli_errors,
"--upstream-conninfo must be provided with NODE REJOIN");
}
break;
case CLUSTER_SHOW:
case CLUSTER_MATRIX:
case CLUSTER_CROSSCHECK:
@@ -1416,6 +1424,7 @@ check_cli_parameters(const int action)
switch (action)
{
case STANDBY_SWITCHOVER:
case NODE_REJOIN:
break;
default:
item_list_append_format(