Re: Use standard SIGHUP and SIGTERM handlers in autoprewarm module - Mailing list pgsql-hackers

From Bharath Rupireddy
Subject Re: Use standard SIGHUP and SIGTERM handlers in autoprewarm module
Date
Msg-id CALj2ACUNmtr4NYhOUZGS7KOQCsJXobARiu0YM9M4sgShOpBVdw@mail.gmail.com
Whole thread Raw
In response to Re: Use standard SIGHUP and SIGTERM handlers in autoprewarm module  (Fujii Masao <masao.fujii@oss.nttdata.com>)
Responses Re: Use standard SIGHUP and SIGTERM handlers in autoprewarm module  (Fujii Masao <masao.fujii@oss.nttdata.com>)
List pgsql-hackers
On Fri, Nov 27, 2020 at 12:26 PM Fujii Masao
<masao.fujii@oss.nttdata.com> wrote:
>
> >  > > When I read the patch again, I found that, with the patch, the shutdown
> >  > > of worker_spi causes to report the following FATAL message.
> >  > >
> >  > >      FATAL:  terminating connection due to administrator command
> >  > >
> >  > > Isn't this message confusing because it's not a connection? If so,
> >  > > we need to update ProcessInterrupts() so that the proper message is
> >  > > reported like other bgworkers do.
> >  > >
> >  >
> >  > This is also true for all the bgworker that use the die() handler. How about doing it the way bgworker_die()
doesin ProcessInterrupts()? This would give meaningful information. Thoughts? If okay, I can make a separate patch. 
> >  >
> >
> > Attaching the patch that improved the message for bg workers in ProcessInterrupts(). For instance, now it looks
like*FATAL:  terminating background worker "worker_spi" due to administrator command* or *FATAL:  terminating
backgroundworker "parallel worker" due to administrator command *and so on for other bg workers.* 
> > *
> >
> > Please review the patch.
>
> Thanks for the patch! It looks good to me.
>

Thanks!

With Regards,
Bharath Rupireddy.
EnterpriseDB: http://www.enterprisedb.com



pgsql-hackers by date:

Previous
From: Bharath Rupireddy
Date:
Subject: Re: Multi Inserts in CREATE TABLE AS - revived patch
Next
From: Tom Lane
Date:
Subject: Re: Improving spin-lock implementation on ARM.