1
0
mirror of https://github.com/postgres/postgres.git synced 2025-07-30 11:03:19 +03:00

Reclassify replication-related GUC variables as "master" and "standby".

Per discussion, this structure seems more understandable than what was
there before.  Make config.sgml and postgresql.conf.sample agree.

In passing do a bit of editorial work on the variable descriptions.
This commit is contained in:
Tom Lane
2011-07-07 15:10:32 -04:00
parent 5b2b444f66
commit 60a81ad133
4 changed files with 103 additions and 72 deletions

View File

@ -551,10 +551,12 @@ const char *const config_group_names[] =
gettext_noop("Write-Ahead Log / Checkpoints"),
/* WAL_ARCHIVING */
gettext_noop("Write-Ahead Log / Archiving"),
/* WAL_REPLICATION */
gettext_noop("Write-Ahead Log / Streaming Replication"),
/* WAL_STANDBY_SERVERS */
gettext_noop("Write-Ahead Log / Standby Servers"),
/* REPLICATION */
gettext_noop("Replication"),
/* REPLICATION_MASTER */
gettext_noop("Replication / Master Server"),
/* REPLICATION_STANDBY */
gettext_noop("Replication / Standby Servers"),
/* QUERY_TUNING */
gettext_noop("Query Tuning"),
/* QUERY_TUNING_METHOD */
@ -1357,7 +1359,7 @@ static struct config_bool ConfigureNamesBool[] =
},
{
{"hot_standby", PGC_POSTMASTER, WAL_STANDBY_SERVERS,
{"hot_standby", PGC_POSTMASTER, REPLICATION_STANDBY,
gettext_noop("Allows connections and queries during recovery."),
NULL
},
@ -1367,7 +1369,7 @@ static struct config_bool ConfigureNamesBool[] =
},
{
{"hot_standby_feedback", PGC_SIGHUP, WAL_STANDBY_SERVERS,
{"hot_standby_feedback", PGC_SIGHUP, REPLICATION_STANDBY,
gettext_noop("Allows feedback from a hot standby to the primary that will avoid query conflicts."),
NULL
},
@ -1534,7 +1536,7 @@ static struct config_int ConfigureNamesInt[] =
},
{
{"max_standby_archive_delay", PGC_SIGHUP, WAL_STANDBY_SERVERS,
{"max_standby_archive_delay", PGC_SIGHUP, REPLICATION_STANDBY,
gettext_noop("Sets the maximum delay before canceling queries when a hot standby server is processing archived WAL data."),
NULL,
GUC_UNIT_MS
@ -1545,7 +1547,7 @@ static struct config_int ConfigureNamesInt[] =
},
{
{"max_standby_streaming_delay", PGC_SIGHUP, WAL_STANDBY_SERVERS,
{"max_standby_streaming_delay", PGC_SIGHUP, REPLICATION_STANDBY,
gettext_noop("Sets the maximum delay before canceling queries when a hot standby server is processing streamed WAL data."),
NULL,
GUC_UNIT_MS
@ -1556,7 +1558,7 @@ static struct config_int ConfigureNamesInt[] =
},
{
{"wal_receiver_status_interval", PGC_SIGHUP, WAL_STANDBY_SERVERS,
{"wal_receiver_status_interval", PGC_SIGHUP, REPLICATION_STANDBY,
gettext_noop("Sets the maximum interval between WAL receiver status reports to the primary."),
NULL,
GUC_UNIT_S
@ -1841,7 +1843,7 @@ static struct config_int ConfigureNamesInt[] =
},
{
{"vacuum_defer_cleanup_age", PGC_SIGHUP, WAL_REPLICATION,
{"vacuum_defer_cleanup_age", PGC_SIGHUP, REPLICATION_MASTER,
gettext_noop("Number of transactions by which VACUUM and HOT cleanup should be deferred, if any."),
NULL
},
@ -1901,7 +1903,7 @@ static struct config_int ConfigureNamesInt[] =
},
{
{"wal_keep_segments", PGC_SIGHUP, WAL_REPLICATION,
{"wal_keep_segments", PGC_SIGHUP, REPLICATION_MASTER,
gettext_noop("Sets the number of WAL files held for standby servers."),
NULL
},
@ -1969,7 +1971,7 @@ static struct config_int ConfigureNamesInt[] =
{
/* see max_connections */
{"max_wal_senders", PGC_POSTMASTER, WAL_REPLICATION,
{"max_wal_senders", PGC_POSTMASTER, REPLICATION_MASTER,
gettext_noop("Sets the maximum number of simultaneously running WAL sender processes."),
NULL
},
@ -1979,7 +1981,7 @@ static struct config_int ConfigureNamesInt[] =
},
{
{"wal_sender_delay", PGC_SIGHUP, WAL_REPLICATION,
{"wal_sender_delay", PGC_SIGHUP, REPLICATION_MASTER,
gettext_noop("WAL sender sleep time between WAL replications."),
NULL,
GUC_UNIT_MS
@ -1990,7 +1992,7 @@ static struct config_int ConfigureNamesInt[] =
},
{
{"replication_timeout", PGC_SIGHUP, WAL_REPLICATION,
{"replication_timeout", PGC_SIGHUP, REPLICATION_MASTER,
gettext_noop("Sets the maximum time to wait for WAL replication."),
NULL,
GUC_UNIT_MS
@ -2954,7 +2956,7 @@ static struct config_string ConfigureNamesString[] =
},
{
{"synchronous_standby_names", PGC_SIGHUP, WAL_REPLICATION,
{"synchronous_standby_names", PGC_SIGHUP, REPLICATION_MASTER,
gettext_noop("List of names of potential synchronous standbys."),
NULL,
GUC_LIST_INPUT

View File

@ -184,32 +184,41 @@
#archive_timeout = 0 # force a logfile segment switch after this
# number of seconds; 0 disables
# - Streaming Replication - Server Settings
#synchronous_standby_names = '' # standby servers that provide sync rep
# comma-separated list of application_name from standby(s);
# '*' = all
#------------------------------------------------------------------------------
# REPLICATION
#------------------------------------------------------------------------------
# - Master Server -
# These settings are ignored on a standby server
#max_wal_senders = 0 # max number of walsender processes
# (change requires restart)
#wal_sender_delay = 1s # walsender cycle time, 1-10000 milliseconds
#wal_keep_segments = 0 # in logfile segments, 16MB each; 0 disables
#vacuum_defer_cleanup_age = 0 # number of xacts by which cleanup is delayed
#replication_timeout = 60s # in milliseconds, 0 is disabled
#replication_timeout = 60s # in milliseconds; 0 disables
#synchronous_standby_names = '' # standby servers that provide sync rep
# comma-separated list of application_name
# from standby(s); '*' = all
# - Standby Servers -
# These settings are ignored on a master server
#hot_standby = off # "on" allows queries during recovery
# (change requires restart)
#hot_standby_feedback = off # info from standby to prevent query conflicts
#max_standby_archive_delay = 30s # max delay before canceling queries
# when reading WAL from archive;
# -1 allows indefinite delay
#max_standby_streaming_delay = 30s # max delay before canceling queries
# when reading streaming WAL;
# -1 allows indefinite delay
#wal_receiver_status_interval = 10s # replies at least this often, 0 disables
#wal_receiver_status_interval = 10s # send replies at least this often
# 0 disables
#hot_standby_feedback = off # send info from standby to prevent
# query conflicts
#------------------------------------------------------------------------------

View File

@ -67,8 +67,9 @@ enum config_group
WAL_SETTINGS,
WAL_CHECKPOINTS,
WAL_ARCHIVING,
WAL_REPLICATION,
WAL_STANDBY_SERVERS,
REPLICATION,
REPLICATION_MASTER,
REPLICATION_STANDBY,
QUERY_TUNING,
QUERY_TUNING_METHOD,
QUERY_TUNING_COST,