Re: Regarding BGworkers - Mailing list pgsql-hackers

From Michael Paquier
Subject Re: Regarding BGworkers
Date
Msg-id CAB7nPqT6oOVwWCaRGamXkfp1=_=o3joQrRyNmU94dXTF3KivJg@mail.gmail.com
Whole thread Raw
In response to Re: Regarding BGworkers  (Robert Haas <robertmhaas@gmail.com>)
Responses Re: Regarding BGworkers  (Amit Kapila <amit.kapila@huawei.com>)
List pgsql-hackers



On Fri, Aug 2, 2013 at 1:22 AM, Robert Haas <robertmhaas@gmail.com> wrote:
On Sun, Jul 28, 2013 at 1:26 AM, Amit kapila <amit.kapila@huawei.com> wrote:
> 2. Shouldn't function
> do_start_bgworker()/StartOneBackgroundWorker(void) be moved to bgworker.c
>    as similar functions AutoVacWorkerMain()/PgArchiverMain() are in their respective files.

Yes, perhaps so.  Other votes?
StartOneBackgroundWorker uses StartWorkerNeeded and HaveCrashedWorker, and IMO, we should not expose that outside the postmaster. On the contrary, moving do_start_bgworker would be fine, as it uses nothing exclusive to the postmaster as far as I saw, and it would also make it more consistent with the other features.

Regards,
--
Michael

pgsql-hackers by date:

Previous
From: David Gudeman
Date:
Subject: Re: pass-through queries to foreign servers
Next
From: Alvaro Herrera
Date:
Subject: Re: new "row-level lock" error messages