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: pgsql-hackers@postgresql.org <pgsql-hackers@postgresql.org>
Subject: Re: Something is broken about connection startup
Date: Tue, 15 Nov 2016 15:57:39 -0500
Message-ID: <2757.1479243459@sss.pgh.pa.us> (raw)
In-Reply-To: <CA+TgmoY6Yci=2KnOe9jOzf1WW_ewxRu6VTdy8CGh5nGt=Kw48g@mail.gmail.com>
References: <16447.1478818294@sss.pgh.pa.us>
	<23418.1478819074@sss.pgh.pa.us>
	<12438.1478895332@sss.pgh.pa.us>
	<CA+TgmoZP63ddrFFuHiaO5gVM57a9hQE4RjhTLC6E8W_muNzU7g@mail.gmail.com>
	<29845.1479136671@sss.pgh.pa.us>
	<CA+TgmoYUzSOz=kzFbgZZyaZ+R23CJ3MP5W7MnJ3=iv5SUv-28g@mail.gmail.com>
	<30195.1479137192@sss.pgh.pa.us>
	<12785.1479159778@sss.pgh.pa.us>
	<CA+TgmoY6Yci=2KnOe9jOzf1WW_ewxRu6VTdy8CGh5nGt=Kw48g@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>

Robert Haas <robertmhaas@gmail.com> writes:
> On Mon, Nov 14, 2016 at 4:42 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> ... I'm inclined to hold my nose and stick a call into step (1) of the
>> main loop instead.

> Seems like a good idea.

>> Also, wherever we end up putting those calls, is it worth providing a
>> variant invalidation function that only kills the catalog snapshot when
>> it's the only one outstanding?  (If it isn't, the transaction snapshot
>> should be older, so there's no chance of advancing our xmin by killing
>> it.)  In principle this would save some catalog snapshot rebuilds for
>> inside-a-transaction-block cases, but I'm not sure it's worth sweating
>> that when we're doing client message exchange anyway.

> I think that would be a fairly worthwhile thing to do.

>> Lastly, I find myself disliking the separate CatalogSnapshotStale flag
>> variable.  The other special snapshots in snapmgr.c are managed by setting
>> the pointer to NULL when it's not valid, so I wonder why CatalogSnapshot
>> wasn't done that way.  Since this patch is touching almost every use of
>> that flag already, it wouldn't take much to switch it over.

> I think I had some reason why I did it that way, but I don't think it
> was anything important, so I don't object to you revising it.

I've pushed a patch incorporating those changes.  I can no longer
reproduce piculet's failure on branches back to 9.4.  Still need to
look at the secondary issues I mentioned upthread.

			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



view thread (10+ messages)

Message-ID: <2757.1479243459@sss.pgh.pa.us>
Permalink:  ../2757.1479243459@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/2757.1479243459@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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-hackers@postgresql.org
  Cc: tgl@sss.pgh.pa.us, robertmhaas@gmail.com
  Subject: Re: Something is broken about connection startup
  In-Reply-To: <2757.1479243459@sss.pgh.pa.us>
  References: <16447.1478818294@sss.pgh.pa.us> <23418.1478819074@sss.pgh.pa.us> <12438.1478895332@sss.pgh.pa.us> <CA+TgmoZP63ddrFFuHiaO5gVM57a9hQE4RjhTLC6E8W_muNzU7g@mail.gmail.com> <29845.1479136671@sss.pgh.pa.us> <CA+TgmoYUzSOz=kzFbgZZyaZ+R23CJ3MP5W7MnJ3=iv5SUv-28g@mail.gmail.com> <30195.1479137192@sss.pgh.pa.us> <12785.1479159778@sss.pgh.pa.us> <CA+TgmoY6Yci=2KnOe9jOzf1WW_ewxRu6VTdy8CGh5nGt=Kw48g@mail.gmail.com> <2757.1479243459@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