mirror of
https://github.com/postgres/postgres.git
synced 2025-07-27 12:41:57 +03:00
Don't count background workers against a user's connection limit.
Doing so doesn't seem to be within the purpose of the per user connection limits, and has particularly unfortunate effects in conjunction with parallel queries. Backpatch to 9.6 where parallel queries were introduced. David Rowley, reviewed by Robert Haas and Albe Laurenz.
This commit is contained in:
@ -258,7 +258,8 @@ CREATE DATABASE <replaceable class="PARAMETER">name</replaceable>
|
||||
The <literal>CONNECTION LIMIT</> option is only enforced approximately;
|
||||
if two new sessions start at about the same time when just one
|
||||
connection <quote>slot</> remains for the database, it is possible that
|
||||
both will fail. Also, the limit is not enforced against superusers.
|
||||
both will fail. Also, the limit is not enforced against superusers or
|
||||
background worker processes.
|
||||
</para>
|
||||
</refsect1>
|
||||
|
||||
|
@ -198,7 +198,10 @@ CREATE ROLE <replaceable class="PARAMETER">name</replaceable> [ [ WITH ] <replac
|
||||
<listitem>
|
||||
<para>
|
||||
If role can log in, this specifies how many concurrent connections
|
||||
the role can make. -1 (the default) means no limit.
|
||||
the role can make. -1 (the default) means no limit. Note that only
|
||||
normal connections are counted towards this limit. Neither prepared
|
||||
transactions nor background worker connections are counted towards
|
||||
this limit.
|
||||
</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
Reference in New Issue
Block a user