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

Commit0aac73e

Browse files
committed
Copy-edit text for the pg_terminate_backend() "timeout" parameter.
Revert the pg_description entry to its v13 form, since those messagesusually remain shorter and don't discuss individual parameters. Nocatversion bump, since pg_description content does not impair backendcompatibility or application compatibility.Justin PryzbyDiscussion:https://postgr.es/m/20210612182743.GY16435@telsasoft.com
1 parent33c5099 commit0aac73e

File tree

3 files changed

+9
-10
lines changed

3 files changed

+9
-10
lines changed

‎doc/src/sgml/func.sgml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24998,7 +24998,7 @@ SELECT collation for ('foo' COLLATE "de_DE");
2499824998
milliseconds) and greater than zero, the function waits until the
2499924999
process is actually terminated or until the given time has passed. If
2500025000
the process is terminated, the function
25001-
returns <literal>true</literal>. On timeout a warning is emitted and
25001+
returns <literal>true</literal>. On timeout, a warning is emitted and
2500225002
<literal>false</literal> is returned.
2500325003
</para></entry>
2500425004
</row>

‎src/backend/storage/ipc/signalfuncs.c

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -187,12 +187,12 @@ pg_wait_until_termination(int pid, int64 timeout)
187187
}
188188

189189
/*
190-
*Signalto terminate a backend process. This is allowed if you are a member
191-
* of the role whose process is being terminated. If timeout input argument is
192-
*0 (whichisdefault), then this function just signals the backend and
193-
*doesn't wait. Otherwiseit waits untilgiven the timeout milliseconds or no
194-
*process has thegiven PID and returnstrue. On timeout, a warning is emitted
195-
* and false is returned.
190+
*Send a signalto terminate a backend process. This is allowed if you are a
191+
*memberof the role whose process is being terminated. Ifthetimeout input
192+
*argumentis0, then this function just signals the backend and returns
193+
*true. If timeout is nonzero, thenit waits untilno process has the given
194+
*PID; if theprocess ends within the timeout,true is returned, and if the
195+
*timeout is exceeded, a warning is emittedand false is returned.
196196
*
197197
* Note that only superusers can signal superuser-owned processes.
198198
*/
@@ -201,7 +201,7 @@ pg_terminate_backend(PG_FUNCTION_ARGS)
201201
{
202202
intpid;
203203
intr;
204-
inttimeout;
204+
inttimeout;/* milliseconds */
205205

206206
pid=PG_GETARG_INT32(0);
207207
timeout=PG_GETARG_INT64(1);

‎src/include/catalog/pg_proc.dat

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6186,8 +6186,7 @@
61866186
{ oid => '2171', descr => 'cancel a server process\' current query',
61876187
proname => 'pg_cancel_backend', provolatile => 'v', prorettype => 'bool',
61886188
proargtypes => 'int4', prosrc => 'pg_cancel_backend' },
6189-
{ oid => '2096',
6190-
descr => 'terminate a backend process and if timeout is specified, wait for its exit or until timeout occurs',
6189+
{ oid => '2096', descr => 'terminate a server process',
61916190
proname => 'pg_terminate_backend', provolatile => 'v', prorettype => 'bool',
61926191
proargtypes => 'int4 int8', proargnames => '{pid,timeout}',
61936192
prosrc => 'pg_terminate_backend' },

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp