Re: pg_receivewal and SIGTERM

From: Christoph Berg <myon(at)debian(dot)org>
To: Daniel Gustafsson <daniel(at)yesql(dot)se>
Cc: PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: pg_receivewal and SIGTERM
Date: 2022-08-16 11:36:15
Message-ID: YvuBL1tvlSNiFQUB@msg.df7cb.de
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Re: Daniel Gustafsson
> Do you think pg_recvlogical should support SIGTERM as well? (The signals which
> it does trap should be added to the documentation which just now says "until
> terminated by a signal" but that's a separate thing.)

Ack, that makes sense, added in the attached updated patch.

> pqsignal(SIGINT, sigint_handler);
> + pqsignal(SIGTERM, sigint_handler);
> Tiny nitpick, I think we should rename sigint_handler to just sig_handler as it
> does handle more than sigint.

I went with sigexit_handler since pg_recvlogical has also a
sighup_handler and "sig_handler" would be confusing there.

Christoph

Attachment Content-Type Size
0001-pg_receivewal-pg_recvlogical-Exit-cleanly-on-SIGTERM.patch text/x-diff 3.5 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bharath Rupireddy 2022-08-16 11:40:54 Re: pg_receivewal and SIGTERM
Previous Message Peter Eisentraut 2022-08-16 11:23:27 Move NON_EXEC_STATIC from c.h