Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 0b039e3

Browse files
committed
Fix some inconsistencies with GUC categories
This commit addresses a few things around GUCs: - The TCP-related parameters (the four tcp_keepalives_* and client_connection_check_interval are listed in postgresql.conf.sample in a subsection called "TCP settings" of "CONNECTIONS AND AUTHENTICATION", but they did not have their own group name in guc.c. - enable_group_by_reordering, stats_fetch_consistency and recovery_prefetch had an inconsistent description, missing a dot at the end. - In postgresql.conf.sample, "Process title" should not have a section of its own, but it should be a subsection of "REPORTING AND LOGGING". This impacts the contents of pg_settings, which could be seen as a compatibility break, so no backpatch is done. This is similar to the cleanup done in a55a984. Author: Shinya Kato Discussion: https://postgr.es/m/5e0c9c608624eafbba910c344282cb14@oss.nttdata.com
1 parent ffbfde4 commit 0b039e3

File tree

4 files changed

+19
-12
lines changed

4 files changed

+19
-12
lines changed

doc/src/sgml/config.sgml

+7
Original file line numberDiff line numberDiff line change
@@ -896,6 +896,13 @@ include_dir 'conf.d'
896896
</para>
897897
</listitem>
898898
</varlistentry>
899+
</variablelist>
900+
</sect2>
901+
902+
<sect2 id="runtime-config-tcp-settings">
903+
<title>TCP Settings</title>
904+
905+
<variablelist>
899906

900907
<varlistentry id="guc-tcp-keepalives-idle" xreflabel="tcp_keepalives_idle">
901908
<term><varname>tcp_keepalives_idle</varname> (<type>integer</type>)

src/backend/utils/misc/guc.c

+10-8
Original file line numberDiff line numberDiff line change
@@ -778,6 +778,8 @@ const char *const config_group_names[] =
778778
gettext_noop("File Locations"),
779779
/* CONN_AUTH_SETTINGS */
780780
gettext_noop("Connections and Authentication / Connection Settings"),
781+
/* CONN_AUTH_TCP */
782+
gettext_noop("Connections and Authentication / TCP Settings"),
781783
/* CONN_AUTH_AUTH */
782784
gettext_noop("Connections and Authentication / Authentication"),
783785
/* CONN_AUTH_SSL */
@@ -1216,7 +1218,7 @@ static struct config_bool ConfigureNamesBool[] =
12161218
},
12171219
{
12181220
{"enable_group_by_reordering", PGC_USERSET, QUERY_TUNING_METHOD,
1219-
gettext_noop("enable reordering of GROUP BY key"),
1221+
gettext_noop("Enable reordering of GROUP BY key."),
12201222
NULL,
12211223
GUC_EXPLAIN
12221224
},
@@ -3460,7 +3462,7 @@ static struct config_int ConfigureNamesInt[] =
34603462
},
34613463

34623464
{
3463-
{"tcp_keepalives_idle", PGC_USERSET, CONN_AUTH_SETTINGS,
3465+
{"tcp_keepalives_idle", PGC_USERSET, CONN_AUTH_TCP,
34643466
gettext_noop("Time between issuing TCP keepalives."),
34653467
gettext_noop("A value of 0 uses the system default."),
34663468
GUC_UNIT_S
@@ -3471,7 +3473,7 @@ static struct config_int ConfigureNamesInt[] =
34713473
},
34723474

34733475
{
3474-
{"tcp_keepalives_interval", PGC_USERSET, CONN_AUTH_SETTINGS,
3476+
{"tcp_keepalives_interval", PGC_USERSET, CONN_AUTH_TCP,
34753477
gettext_noop("Time between TCP keepalive retransmits."),
34763478
gettext_noop("A value of 0 uses the system default."),
34773479
GUC_UNIT_S
@@ -3493,7 +3495,7 @@ static struct config_int ConfigureNamesInt[] =
34933495
},
34943496

34953497
{
3496-
{"tcp_keepalives_count", PGC_USERSET, CONN_AUTH_SETTINGS,
3498+
{"tcp_keepalives_count", PGC_USERSET, CONN_AUTH_TCP,
34973499
gettext_noop("Maximum number of TCP keepalive retransmits."),
34983500
gettext_noop("This controls the number of consecutive keepalive retransmits that can be "
34993501
"lost before a connection is considered dead. A value of 0 uses the "
@@ -3595,7 +3597,7 @@ static struct config_int ConfigureNamesInt[] =
35953597
},
35963598

35973599
{
3598-
{"tcp_user_timeout", PGC_USERSET, CONN_AUTH_SETTINGS,
3600+
{"tcp_user_timeout", PGC_USERSET, CONN_AUTH_TCP,
35993601
gettext_noop("TCP user timeout."),
36003602
gettext_noop("A value of 0 uses the system default."),
36013603
GUC_UNIT_MS
@@ -3640,7 +3642,7 @@ static struct config_int ConfigureNamesInt[] =
36403642
},
36413643

36423644
{
3643-
{"client_connection_check_interval", PGC_USERSET, CONN_AUTH_SETTINGS,
3645+
{"client_connection_check_interval", PGC_USERSET, CONN_AUTH_TCP,
36443646
gettext_noop("Sets the time interval between checks for disconnection while running queries."),
36453647
NULL,
36463648
GUC_UNIT_MS
@@ -4953,7 +4955,7 @@ static struct config_enum ConfigureNamesEnum[] =
49534955

49544956
{
49554957
{"stats_fetch_consistency", PGC_USERSET, STATS_CUMULATIVE,
4956-
gettext_noop("Sets the consistency of accesses to statistics data"),
4958+
gettext_noop("Sets the consistency of accesses to statistics data."),
49574959
NULL
49584960
},
49594961
&pgstat_fetch_consistency,
@@ -5044,7 +5046,7 @@ static struct config_enum ConfigureNamesEnum[] =
50445046

50455047
{
50465048
{"recovery_prefetch", PGC_SIGHUP, WAL_RECOVERY,
5047-
gettext_noop("Prefetch referenced blocks during recovery"),
5049+
gettext_noop("Prefetch referenced blocks during recovery."),
50485050
gettext_noop("Look ahead in the WAL to find references to uncached data.")
50495051
},
50505052
&recovery_prefetch,

src/backend/utils/misc/postgresql.conf.sample

+1-4
Original file line numberDiff line numberDiff line change
@@ -597,10 +597,7 @@
597597
# -1 disables, 0 logs all temp files
598598
#log_timezone = 'GMT'
599599

600-
601-
#------------------------------------------------------------------------------
602-
# PROCESS TITLE
603-
#------------------------------------------------------------------------------
600+
# - Process Title -
604601

605602
#cluster_name = '' # added to process titles if nonempty
606603
# (change requires restart)

src/include/utils/guc_tables.h

+1
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,7 @@ enum config_group
5656
UNGROUPED, /* use for options not shown in pg_settings */
5757
FILE_LOCATIONS,
5858
CONN_AUTH_SETTINGS,
59+
CONN_AUTH_TCP,
5960
CONN_AUTH_AUTH,
6061
CONN_AUTH_SSL,
6162
RESOURCES_MEM,

0 commit comments

Comments
 (0)