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

Re: Prepared transactions vs novice DBAs, again

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>, Jeff Davis <pgsql(at)j-davis(dot)com>, jd(at)commandprompt(dot)com, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Prepared transactions vs novice DBAs, again
Date: 2009-04-23 00:49:37
Message-ID: 603c8f070904221749mbe90992r9f747f192046c683@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-hackers
On Wed, Apr 22, 2009 at 5:44 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> Robert Haas <robertmhaas(at)gmail(dot)com> writes:
>> On Wed, Apr 22, 2009 at 2:58 PM, Heikki Linnakangas
>> <heikki(dot)linnakangas(at)enterprisedb(dot)com> wrote:
>>> It still does. A prepared xact is just like a idle-in-transaction backend as
>>> far as vacuum is concerned.
>
>> Is that really necessary? It's true that you can't vacuum away any
>> rows whose xmin is that of the prepared xact, but it seems like you
>> wouldn't need to keep rows just because they were *visible* to the
>> prepared xact.  Once prepared, it's no longer capable of reading them.
>
> I think we've already milked what we can from that, since a prepared
> xact is treated exactly like an open one with no snapshot.  The point
> is that whatever rows it's written are still in-doubt and cannot be
> frozen, so the wraparound horizon cannot advance past its XID.

But surely that's not "the same" as a backend which is
idle-in-transaction?  In that case I think you still need a snapshot?

...Robert

In response to

Responses

pgsql-hackers by date

Next:From: Tom LaneDate: 2009-04-23 00:58:07
Subject: Re: Prepared transactions vs novice DBAs, again
Previous:From: Grzegorz JaskiewiczDate: 2009-04-22 23:13:17
Subject: Re: GCC 4.4 compiler warnings

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