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

Commit98e2d58

Browse files
committed
Improve log message about termination of background workers.
Previously the shutdown of a background worker that uses die() asSIGTERM signal handler produced the log message "terminatingconnection due to administrator command". This log message wasconfusing because a background worker is not a connection.This commit improves that log message to "terminating backgroundworker XXX due to administrator command" (XXX is replaced withthe name of the background worker). This is the same log messageas another SIGTERM signal handler bgworker_die() for a backgroundworker reports.Author: Bharath RupireddyReviewed-by: Fujii MasaoDiscussion:https://postgr.es/m/3f292fbb-f155-9a01-7cb2-7ccc9007ab3f@oss.nttdata.com
1 parent7e5e1bb commit98e2d58

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

‎src/backend/tcop/postgres.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3072,6 +3072,11 @@ ProcessInterrupts(void)
30723072
errmsg("terminating connection due to conflict with recovery"),
30733073
errdetail_recovery_conflict()));
30743074
}
3075+
elseif (IsBackgroundWorker)
3076+
ereport(FATAL,
3077+
(errcode(ERRCODE_ADMIN_SHUTDOWN),
3078+
errmsg("terminating background worker \"%s\" due to administrator command",
3079+
MyBgworkerEntry->bgw_type)));
30753080
else
30763081
ereport(FATAL,
30773082
(errcode(ERRCODE_ADMIN_SHUTDOWN),

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp