standby clone: explicitly log that replication slots not in use

Helps with diagnosing output.
This commit is contained in:
Ian Barwick
2020-04-27 13:55:02 +09:00
parent 38b3447bd3
commit d0c5dffe91

View File

@@ -6032,7 +6032,7 @@ check_upstream_config(PGconn *conn, int server_version_num, t_node_info *upstrea
config_ok = false;
}
if (config_file_options.use_replication_slots)
if (config_file_options.use_replication_slots == true)
{
pg_setting_ok = get_pg_setting_int(conn, "max_replication_slots", &i);
@@ -6058,7 +6058,6 @@ check_upstream_config(PGconn *conn, int server_version_num, t_node_info *upstrea
log_info(_("parameter \"max_replication_slots\" set to %i"), i);
}
}
/*
* physical replication slots not available or not requested - check if
* there are any circumstances where `wal_keep_segments` should be set
@@ -6118,6 +6117,12 @@ check_upstream_config(PGconn *conn, int server_version_num, t_node_info *upstrea
}
if (config_file_options.use_replication_slots == false && server_version_num >= 90400)
{
log_info(_("replication slot usage not requested; no replication slot will be set up for this standby"));
}
/*
* If archive_mode is enabled, check that 'archive_command' is non empty
* (however it's not practical to check that it actually represents a