pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Kevin Grittner <kgrittn@gmail.com>
To: Amit Kapila <amit.kapila16@gmail.com>
Cc: Andres Freund <andres@anarazel.de>
Cc: Noah Misch <noah@leadboat.com>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: Kevin Grittner <kgrittn@postgresql.org>
Cc: pgsql-hackers@postgresql.org <pgsql-hackers@postgresql.org>
Cc: pgsql-committers@postgresql.org <pgsql-committers@postgresql.org>
Subject: Re: [HACKERS] Re: pgsql: Avoid extra locks in GetSnapshotData if old_snapshot_threshold <
Date: Tue, 19 Apr 2016 10:11:57 -0500
Message-ID: <CACjxUsP_NWC8Tiv9LFhGaeEndo2qCXMdHmHwBO588eo-5nbeWw@mail.gmail.com> (raw)
In-Reply-To: <CAA4eK1JihZepuTasniqrHcsha0umwjeke_ay3AckpGMH4QdJ_g@mail.gmail.com>
References: <CACjxUsOAAbC=MbPguUtSYJdTBNDwnTAxkMhb5+Cm8MwhBSRuRA@mail.gmail.com>
	<20160412192801.wffn2vjyszyw4qa4@alap3.anarazel.de>
	<CACjxUsP=RaV1ue3ccbq4bA0LbN3e7cJJHYj_MCZr1XTKWAZzAQ@mail.gmail.com>
	<20160413171955.i53me46fqqhdlztq@alap3.anarazel.de>
	<CA+Tgmoako8yQh5HE8qK04_oCBkY3C-AncPkSjaVJvWoOuSqzuA@mail.gmail.com>
	<CACjxUsNvVsjJiFy=d2jXZYpo8Evq89YHVjFnLRv5fTF2F5OWPA@mail.gmail.com>
	<20160413192110.fogwesjti3kxycnu@alap3.anarazel.de>
	<20160413200148.bawmwjdmggbllhha@alap3.anarazel.de>
	<CACjxUsMMsSDQTDjdzKY9TwaurN_gNS3Du3kpE5zU5w_AagRmjw@mail.gmail.com>
	<20160416204452.GA1910190@tornado.leadboat.com>
	<20160416205630.puxsglckxi3sn5ec@alap3.anarazel.de>
	<CAA4eK1JihZepuTasniqrHcsha0umwjeke_ay3AckpGMH4QdJ_g@mail.gmail.com>
List-Unsubscribe:  <mailto:majordomo@postgresql.org?body=unsub%20pgsql-committers>

On Tue, Apr 19, 2016 at 9:57 AM, Amit Kapila <amit.kapila16@gmail.com> wrote:
> On Sun, Apr 17, 2016 at 2:26 AM, Andres Freund <andres@anarazel.de> wrote:
>>
>> On 2016-04-16 16:44:52 -0400, Noah Misch wrote:
>> > That is more controversial than the potential ~2% regression for
>> > old_snapshot_threshold=-1.  Alvaro[2] and Robert[3] are okay releasing
>> > that way, and Andres[4] is not.
>>
>> FWIW, I could be kinda convinced that it's temporarily ok, if there'd be
>> a clear proposal on the table how to solve the scalability issue around
>> MaintainOldSnapshotTimeMapping().
>
> It seems that for read-only workloads, MaintainOldSnapshotTimeMapping()
> takes EXCLUSIVE LWLock which seems to be a probable reason for a performance
> regression.  Now, here the question is do we need to acquire that lock if
> xmin is not changed since the last time value of
> oldSnapshotControl->latest_xmin is updated or xmin is lesser than equal to
> oldSnapshotControl->latest_xmin?
> If we don't need it for above cases, I think it can address the performance
> regression to a good degree for read-only workloads when the feature is
> enabled.

Thanks, Amit -- I think something along those lines is the right
solution to the scaling issues when the feature is enabled.  For
now I'm focusing on the back-patching issues and the performance
regression when the feature is disabled, but I'll shift focus to
this once the "killer" issues are in hand.

--
Kevin Grittner
EDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers



view thread (195+ messages)  latest in thread

Message-ID: <CACjxUsP_NWC8Tiv9LFhGaeEndo2qCXMdHmHwBO588eo-5nbeWw@mail.gmail.com>
Permalink:  ../CACjxUsP_NWC8Tiv9LFhGaeEndo2qCXMdHmHwBO588eo-5nbeWw@mail.gmail.com/
Also on:    postgresql.org/message-id/CACjxUsP_NWC8Tiv9LFhGaeEndo2qCXMdHmHwBO588eo-5nbeWw@mail.gmail.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 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-committers@postgresql.org
  Cc: kgrittn@gmail.com, amit.kapila16@gmail.com, andres@anarazel.de, noah@leadboat.com, robertmhaas@gmail.com, kgrittn@postgresql.org, pgsql-hackers@postgresql.org
  Subject: Re: [HACKERS] Re: pgsql: Avoid extra locks in GetSnapshotData if old_snapshot_threshold <
  In-Reply-To: <CACjxUsP_NWC8Tiv9LFhGaeEndo2qCXMdHmHwBO588eo-5nbeWw@mail.gmail.com>
  References: <CACjxUsOAAbC=MbPguUtSYJdTBNDwnTAxkMhb5+Cm8MwhBSRuRA@mail.gmail.com> <20160412192801.wffn2vjyszyw4qa4@alap3.anarazel.de> <CACjxUsP=RaV1ue3ccbq4bA0LbN3e7cJJHYj_MCZr1XTKWAZzAQ@mail.gmail.com> <20160413171955.i53me46fqqhdlztq@alap3.anarazel.de> <CA+Tgmoako8yQh5HE8qK04_oCBkY3C-AncPkSjaVJvWoOuSqzuA@mail.gmail.com> <CACjxUsNvVsjJiFy=d2jXZYpo8Evq89YHVjFnLRv5fTF2F5OWPA@mail.gmail.com> <20160413192110.fogwesjti3kxycnu@alap3.anarazel.de> <20160413200148.bawmwjdmggbllhha@alap3.anarazel.de> <CACjxUsMMsSDQTDjdzKY9TwaurN_gNS3Du3kpE5zU5w_AagRmjw@mail.gmail.com> <20160416204452.GA1910190@tornado.leadboat.com> <20160416205630.puxsglckxi3sn5ec@alap3.anarazel.de> <CAA4eK1JihZepuTasniqrHcsha0umwjeke_ay3AckpGMH4QdJ_g@mail.gmail.com> <CACjxUsP_NWC8Tiv9LFhGaeEndo2qCXMdHmHwBO588eo-5nbeWw@mail.gmail.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