Re: MVCC catalog access - Mailing list pgsql-hackers

From Michael Paquier
Subject Re: MVCC catalog access
Date
Msg-id CAB7nPqT-+=xuchi-vzu39x9kGd5RoRT0eSb4JYKte-nqsdMT-Q@mail.gmail.com
Whole thread Raw
In response to Re: MVCC catalog access  (Robert Haas <robertmhaas@gmail.com>)
Responses Re: MVCC catalog access  (Robert Haas <robertmhaas@gmail.com>)
List pgsql-hackers



On Tue, May 28, 2013 at 10:39 PM, Robert Haas <robertmhaas@gmail.com> wrote:
IMHO, we should press forward with this approach.  Considering that
these are pretty extreme test cases, I'm inclined to view the
performance loss as acceptable.  We've never really viewed DDL as
something that needs to be micro-optimized, and there is ample
testimony to that fact in the existing code and in the treatment of
prior patches in this area.  This is not to say that we want to go
around willy-nilly making it slower, but I think there will be very
few users for which the number of microseconds it takes to create or
drop an SQL object is performance-critical, especially when you
consider that (1) the effect will be quite a bit less when the objects
are tables, since in that case the snapshot cost will tend to be
drowned out by the filesystem cost and (2) people who don't habitually
keep hundreds and hundreds of connections open - which hopefully most
people don't - won't see the effect anyway.   Against that, this
removes the single largest barrier to allowing more concurrent DDL, a
feature that I suspect will make a whole lot of people *very* happy.
+1.
So, I imagine that the next step would be to add a new Snapshot validation
level in tqual.h. Something like SnapshotMVCC? Then replace SnapshotNow
by SnapshotMVCC where it is required.

I am also seeing that SnapshotNow is used in places where we might not want to
have it changed. For example autovacuum code path when we retrieve database
or table list should not be changed, no?
--
Michael

pgsql-hackers by date:

Previous
From: Jeff Davis
Date:
Subject: Re: removing PD_ALL_VISIBLE
Next
From: Andres Freund
Date:
Subject: Re: all_visible replay aborting due to uninitialized pages