pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Robert Haas <robertmhaas@gmail.com>
Cc: Kyotaro HORIGUCHI <horiguchi.kyotaro@lab.ntt.co.jp>
Cc: Andres Freund <andres@anarazel.de>
Cc: Michael Paquier <michael@paquier.xyz>
Cc: Justin Pryzby <pryzby@telsasoft.com>
Cc: pgsql-hackers@postgresql.org <pgsql-hackers@postgresql.org>
Subject: Re: ENOSPC FailedAssertion("!(RefCountErrors == 0)"
Date: Wed, 18 Jul 2018 14:05:17 -0400
Message-ID: <7342.1531937117@sss.pgh.pa.us> (raw)
In-Reply-To: <CA+TgmobXLXNeyod0wrmFp1xeusJJtTCzZPizqwHsfr=hVKS2DA@mail.gmail.com>
References: <20436.1531751966@sss.pgh.pa.us>
	<4993.1531773411@sss.pgh.pa.us>
	<14892.1531872065@sss.pgh.pa.us>
	<20180718.124220.08087886.horiguchi.kyotaro@lab.ntt.co.jp>
	<10690.1531924381@sss.pgh.pa.us>
	<CA+TgmobXLXNeyod0wrmFp1xeusJJtTCzZPizqwHsfr=hVKS2DA@mail.gmail.com>

Robert Haas <robertmhaas@gmail.com> writes:
> On Wed, Jul 18, 2018 at 10:33 AM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>>> So couldn't we use TopTransactionResourceOwner instead of
>>> AuxProcessResrouceOwner? I feel a bit uneasy that bootstrap and
>>> standalone-backend have *AuxProcess*ResourceOwner.

>> Since the aux processes aren't running transactions, I didn't think
>> that TopTransactionResourceOwner was appropriate.  There's also
>> a problem for bootstrap and standalone backend cases: those do run
>> transactions and therefore create/destroy TopTransactionResourceOwner,
>> leaving nothing behind for ShutdownXLOG to use if it tries to use
>> that.  We need an extra resowner somewhere.

> FallbackResourceOwner?  DefaultResourceOwner? SessionResourceOwner?

Those names all suggest (to me anyway) that this resowner exists in
all, or at least most, processes.  That's not the situation as of this
patch, although I could imagine an alternate universe where it's true;
for example, if we decided there were a reason for normal backends to
have a session-lifespan resowner.  But even then, it might be better
to distinguish that from aux processes' use of resowners.

(I'm not really convinced that it'd be a good idea for normal backends
to have a session-lifespan resowner; that could mask bugs involving
trying to acquire resources outside a transaction.)

			regards, tom lane




view thread (15+ messages)

Message-ID: <7342.1531937117@sss.pgh.pa.us>
Permalink:  ../7342.1531937117@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/7342.1531937117@sss.pgh.pa.us

 · 

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: tgl@sss.pgh.pa.us, robertmhaas@gmail.com, horiguchi.kyotaro@lab.ntt.co.jp, andres@anarazel.de, michael@paquier.xyz, pryzby@telsasoft.com
  Subject: Re: ENOSPC FailedAssertion("!(RefCountErrors == 0)"
  In-Reply-To: <7342.1531937117@sss.pgh.pa.us>

* 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