Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit740766d

Browse files
committed
config: Split "Worker Processes" out of "Asynchronous Behavior"
Having all the worker related GUCs in the same section as IO controlling GUCsdoesn't really make sense. Create a separate section for them.Reviewed-by: Tom Lane <tgl@sss.pgh.pa.us>Discussion:https://postgr.es/m/x3tlw2jk5gm3r3mv47hwrshffyw7halpczkfbk3peksxds7bvc@lguk43z3bsyq
1 parentc366d2b commit740766d

File tree

4 files changed

+16
-5
lines changed

4 files changed

+16
-5
lines changed

‎doc/src/sgml/config.sgml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2618,7 +2618,13 @@ include_dir 'conf.d'
26182618
</para>
26192619
</listitem>
26202620
</varlistentry>
2621+
</variablelist>
2622+
</sect2>
26212623

2624+
<sect2 id="runtime-config-resource-worker-processes">
2625+
<title>Worker Processes</title>
2626+
2627+
<variablelist>
26222628
<varlistentry id="guc-max-worker-processes" xreflabel="max_worker_processes">
26232629
<term><varname>max_worker_processes</varname> (<type>integer</type>)
26242630
<indexterm>

‎src/backend/utils/misc/guc_tables.c

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -683,6 +683,7 @@ const char *const config_group_names[] =
683683
[RESOURCES_KERNEL]=gettext_noop("Resource Usage / Kernel Resources"),
684684
[RESOURCES_BGWRITER]=gettext_noop("Resource Usage / Background Writer"),
685685
[RESOURCES_ASYNCHRONOUS]=gettext_noop("Resource Usage / Asynchronous Behavior"),
686+
[RESOURCES_WORKER_PROCESSES]=gettext_noop("Resource Usage / Worker Processes"),
686687
[WAL_SETTINGS]=gettext_noop("Write-Ahead Log / Settings"),
687688
[WAL_CHECKPOINTS]=gettext_noop("Write-Ahead Log / Checkpoints"),
688689
[WAL_ARCHIVING]=gettext_noop("Write-Ahead Log / Archiving"),
@@ -1962,7 +1963,7 @@ struct config_bool ConfigureNamesBool[] =
19621963
},
19631964

19641965
{
1965-
{"parallel_leader_participation",PGC_USERSET,RESOURCES_ASYNCHRONOUS,
1966+
{"parallel_leader_participation",PGC_USERSET,RESOURCES_WORKER_PROCESSES,
19661967
gettext_noop("Controls whether Gather and Gather Merge also run subplans."),
19671968
gettext_noop("Should gather nodes also run subplans or just gather tuples?"),
19681969
GUC_EXPLAIN
@@ -3234,7 +3235,7 @@ struct config_int ConfigureNamesInt[] =
32343235
{
32353236
{"max_worker_processes",
32363237
PGC_POSTMASTER,
3237-
RESOURCES_ASYNCHRONOUS,
3238+
RESOURCES_WORKER_PROCESSES,
32383239
gettext_noop("Maximum number of concurrent worker processes."),
32393240
NULL,
32403241
},
@@ -3496,7 +3497,7 @@ struct config_int ConfigureNamesInt[] =
34963497
},
34973498

34983499
{
3499-
{"max_parallel_maintenance_workers",PGC_USERSET,RESOURCES_ASYNCHRONOUS,
3500+
{"max_parallel_maintenance_workers",PGC_USERSET,RESOURCES_WORKER_PROCESSES,
35003501
gettext_noop("Sets the maximum number of parallel processes per maintenance operation."),
35013502
NULL
35023503
},
@@ -3506,7 +3507,7 @@ struct config_int ConfigureNamesInt[] =
35063507
},
35073508

35083509
{
3509-
{"max_parallel_workers_per_gather",PGC_USERSET,RESOURCES_ASYNCHRONOUS,
3510+
{"max_parallel_workers_per_gather",PGC_USERSET,RESOURCES_WORKER_PROCESSES,
35103511
gettext_noop("Sets the maximum number of parallel processes per executor node."),
35113512
NULL,
35123513
GUC_EXPLAIN
@@ -3517,7 +3518,7 @@ struct config_int ConfigureNamesInt[] =
35173518
},
35183519

35193520
{
3520-
{"max_parallel_workers",PGC_USERSET,RESOURCES_ASYNCHRONOUS,
3521+
{"max_parallel_workers",PGC_USERSET,RESOURCES_WORKER_PROCESSES,
35213522
gettext_noop("Sets the maximum number of parallel workers that can be active at one time."),
35223523
NULL,
35233524
GUC_EXPLAIN

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

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -198,6 +198,9 @@
198198
#effective_io_concurrency = 1# 1-1000; 0 disables prefetching
199199
#maintenance_io_concurrency = 10# 1-1000; 0 disables prefetching
200200
#io_combine_limit = 128kB# usually 1-32 blocks (depends on OS)
201+
202+
# - Worker Processes -
203+
201204
#max_worker_processes = 8# (change requires restart)
202205
#max_parallel_workers_per_gather = 2# limited by max_parallel_workers
203206
#max_parallel_maintenance_workers = 2# limited by max_parallel_workers

‎src/include/utils/guc_tables.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,7 @@ enum config_group
6565
RESOURCES_KERNEL,
6666
RESOURCES_BGWRITER,
6767
RESOURCES_ASYNCHRONOUS,
68+
RESOURCES_WORKER_PROCESSES,
6869
WAL_SETTINGS,
6970
WAL_CHECKPOINTS,
7071
WAL_ARCHIVING,

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp