Re: pg_receivewal and SIGTERM

From: Bharath Rupireddy <bharath(dot)rupireddyforpostgres(at)gmail(dot)com>
To: Christoph Berg <myon(at)debian(dot)org>, Bharath Rupireddy <bharath(dot)rupireddyforpostgres(at)gmail(dot)com>, Daniel Gustafsson <daniel(at)yesql(dot)se>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: pg_receivewal and SIGTERM
Date: 2022-08-19 12:04:56
Message-ID: CALj2ACWwfRu6piRq+6t9rTBCOnYJRL1p0Ke5ouOvbG_uEbDq6Q@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Aug 19, 2022 at 4:24 PM Christoph Berg <myon(at)debian(dot)org> wrote:
>
> Re: Bharath Rupireddy
> > <application>pg_receivewal</application> will exit with status 0 when
> > - terminated by the <systemitem>SIGINT</systemitem> signal. (That is the
> > + terminated by the <systemitem>SIGINT</systemitem> or
> > + <systemitem>SIGTERM</systemitem> signal. (That is the
> > normal way to end it. Hence it is not an error.) For fatal errors or
> > other signals, the exit status will be nonzero.
> >
> > Can we specify the reason in the docs why a SIGTERM causes (which
> > typically would cause a program to end with non-zero exit code)
> > pg_receivewal and pg_recvlogical exit with zero exit code? Having this
> > in the commit message would help developers but the documentation will
> > help users out there.
>
> We could add "because you want that if it's running as a daemon", but

+1 to add "some" info in the docs (I'm not sure about the better
wording though), we can try to be more specific of the use case if
required.

--
Bharath Rupireddy
RDS Open Source Databases: https://aws.amazon.com/rds/postgresql/

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Ranier Vilela 2022-08-19 12:04:57 Fix typo with logical connector (src/backend/commands/vacuumparallel.c)
Previous Message Bharath Rupireddy 2022-08-19 11:57:50 Re: pg_receivewal fail to streams when the partial file to write is not fully initialized present in the wal receiver directory