Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bULhc-0007Q9-4n for pgsql-hackers@arkaria.postgresql.org; Mon, 01 Aug 2016 22:28:52 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1bULhb-0005nb-N1 for pgsql-hackers@arkaria.postgresql.org; Mon, 01 Aug 2016 22:28:51 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1bULhb-0005nU-80 for pgsql-hackers@postgresql.org; Mon, 01 Aug 2016 22:28:51 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1bULhY-0003Bs-7h for pgsql-hackers@postgresql.org; Mon, 01 Aug 2016 22:28:50 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id u71MSiUp019233; Mon, 1 Aug 2016 18:28:44 -0400 From: Tom Lane To: Andres Freund cc: Robert Haas , "pgsql-hackers@postgresql.org" Subject: Re: PostmasterContext survives into parallel workers!? In-reply-to: <20160801221829.kfa7hzqlzt47mwsb@alap3.anarazel.de> References: <14111.1470082717@sss.pgh.pa.us> <20160801221829.kfa7hzqlzt47mwsb@alap3.anarazel.de> Comments: In-reply-to Andres Freund message dated "Mon, 01 Aug 2016 15:18:29 -0700" Date: Mon, 01 Aug 2016 18:28:44 -0400 Message-ID: <19232.1470090524@sss.pgh.pa.us> X-Pg-Spam-Score: -2.2 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org Andres Freund writes: > On 2016-08-01 18:09:03 -0400, Robert Haas wrote: >> (Also vaguely on the list of things to clean up: can't we make it so >> that bgworkers aren't launched from inside a signal handler? Blech.) > Isn't pretty much everything on-demand below postmaster started from a > signal handler? I think it depends. As an example, maybe_start_bgworker is called from PostmasterMain, *and* from ServerLoop, *and* from reaper, *and* from sigusr1_handler. That's likely excessive, but it's what we've got at the moment. I'm pretty sure regular backends are only launched from ServerLoop, but for anything else it's uncertain. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers