pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
To: Mike Palmiotto <mike.palmiotto@crunchydata.com>
To: Justin Pryzby <pryzby@telsasoft.com>
Cc: Alvaro Herrera <alvherre@2ndquadrant.com>
Cc: Michael Paquier <michael@paquier.xyz>
Cc: Andres Freund <andres@anarazel.de>
Cc: Yuli Khodorkovskiy <yuli.khodorkovskiy@crunchydata.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-hackers <pgsql-hackers@postgresql.org>
Subject: Re: Auxiliary Processes and MyAuxProc
Date: Thu, 19 Mar 2020 11:35:41 +0100
Message-ID: <bc2a012a-c652-33a9-1fd7-5eaa0944ec2e@2ndquadrant.com> (raw)
In-Reply-To: <CAMN686GXRr2nZECF-zP5jz_uC6kxS7wnmNfQMjgf4hQLX6m7fA@mail.gmail.com>
References: <20200317215218.GC26184@telsasoft.com>
	<20200318010433.GA17520@alvherre.pgsql>
	<CAMN686GixjieQhS9DtRvvAX9q73Px25yWuyWZRWeHh81ZE4XvA@mail.gmail.com>
	<20200318141720.GH26184@telsasoft.com>
	<CAMN686EB6MJDC2eMy1TES_Mz=UYree6GRFy-U5ob+ONtKDa_GQ@mail.gmail.com>
	<CAMN686GXRr2nZECF-zP5jz_uC6kxS7wnmNfQMjgf4hQLX6m7fA@mail.gmail.com>

On 2020-03-18 17:07, Mike Palmiotto wrote:
> On Wed, Mar 18, 2020 at 11:26 AM Mike Palmiotto
> <mike.palmiotto@crunchydata.com> wrote:
>>
>> On Wed, Mar 18, 2020 at 10:17 AM Justin Pryzby <pryzby@telsasoft.com> wrote:
>>> Also, I saw this was failing tests both before and after my rebase.
>>>
>>> http://cfbot.cputube.org/
>>> https://ci.appveyor.com/project/postgresql-cfbot/postgresql/builds/31535161
>>> https://ci.appveyor.com/project/postgresql-cfbot/postgresql/builds/31386446
>>
>> Good catch, thanks. Will address this as well in the next round. Just
>> need to set up a Windows dev environment to see if I can
>> reproduce/fix.
> 
> While I track this down, here is a rebased patchset, which drops
> MySubprocessType and makes use of the MyBackendType.

While working on (My)BackendType, I was attempting to get rid of 
(My)AuxProcType altogether.  This would mostly work except that it's 
sort of wired into the pgstats subsystem (see NumBackendStatSlots). 
This can probably be reorganized, but I didn't pursue it further.

Now, I'm a sucker for refactoring, but I feel this proposal is going 
into a direction I don't understand.  I'd prefer that we focus around 
building out background workers as the preferred subprocess mechanism. 
Building out a second generic mechanism, again, I don't understand the 
direction.  Are we hoping to add more of these processes?  Make it 
extensible?  The net lines added/removed by this patch series seems 
pretty neutral.  What are we getting at the end of this?

More specifically, I don't agree with the wholesale renaming of 
auxiliary process to subprocess.  Besides the massive code churn, the 
old naming seemed pretty good to distinguish them from background 
workers, the new naming is more ambiguous.

Btw., if I had a lot of time I would attempt to rewrite walreceiver and 
perhaps the autovacuum system as background workers and thus further 
reduce the footprint of the aux process system.

-- 
Peter Eisentraut              http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services





view thread (38+ messages)  latest in thread

Message-ID: <bc2a012a-c652-33a9-1fd7-5eaa0944ec2e@2ndquadrant.com>
Permalink:  ../bc2a012a-c652-33a9-1fd7-5eaa0944ec2e@2ndquadrant.com/
Also on:    postgresql.org/message-id/bc2a012a-c652-33a9-1fd7-5eaa0944ec2e@2ndquadrant.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: peter.eisentraut@2ndquadrant.com, mike.palmiotto@crunchydata.com, pryzby@telsasoft.com, alvherre@2ndquadrant.com, michael@paquier.xyz, andres@anarazel.de, yuli.khodorkovskiy@crunchydata.com, tgl@sss.pgh.pa.us
  Subject: Re: Auxiliary Processes and MyAuxProc
  In-Reply-To: <bc2a012a-c652-33a9-1fd7-5eaa0944ec2e@2ndquadrant.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox