Skip site navigation (1) Skip section navigation (2)

Re: Transaction Snapshot Cloning

From: Chris Browne <cbbrowne(at)acm(dot)org>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Transaction Snapshot Cloning
Date: 2008-01-11 22:53:21
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-hackers
simon(at)2ndquadrant(dot)com (Simon Riggs) writes:
> On Fri, 2008-01-11 at 20:39 +0000, Simon Riggs wrote:
>> On Fri, 2008-01-11 at 15:05 -0500, Tom Lane wrote:
>> Simon Riggs <simon(at)2ndquadrant(dot)com> writes:
>> > > If we had a function 
>> > > 	replace_serializable_snapshot(master_xid, txid_snapshot)
>> > > this would allow us to use the txid_snapshot values to replace our
>> > > transaction's serializable snapshot.
>> > 
>> > ... whereupon we'd get wrong answers.  Certainly you could not allow
>> > transaction xmin to go backwards, and I'm not sure what other
>> > restrictions there would be, but the whole thing gives me the willies.
> Sorry, forgot to add
> - global xmin isn't going backwards
> - neither is latest completed xid
> The xmin of the transaction will go backwards, but as long as we don't
> do anything prior to the setting of the cloned snapshot, what can go
> wrong? :-)

Note that we required that the "provider transaction" have the
attributes IsXactIsoLevelSerializable and XactReadOnly both being
true, so we have the mandates that the resultant backend process:

a) Is in read only mode, and
b) Is in serializable mode.

That's a pair of (possibly stretching-wide!) suspenders worth of
support from Evil...
(format nil "~S(at)~S" "cbbrowne" "")
Trying  to be happy  is like trying to build   a machine for which the
only specification is that it should run noiselessly.

In response to


pgsql-hackers by date

Next:From: Gavin SherryDate: 2008-01-11 23:19:45
Subject: Declarative partitioning grammar
Previous:From: Gokulakannan SomasundaramDate: 2008-01-11 21:10:17
Subject: Re: Some ideas about Vacuum

Privacy Policy | About PostgreSQL
Copyright © 1996-2018 The PostgreSQL Global Development Group