Re: nested transactions - Mailing list pgsql-hackers

From Bruce Momjian
Subject Re: nested transactions
Date
Msg-id 200211291624.gATGOZ315126@candle.pha.pa.us
Whole thread Raw
In response to Re: nested transactions  (Manfred Koizar <mkoi-pg@aon.at>)
List pgsql-hackers
Manfred Koizar wrote:
> One more argument for pg_subtrans being visible to all backends:  If
> an UPDATE is about to change a tuple touched by another active
> transaction, it waits for the other transaction to commit or abort.
> We must always wait for the main transaction, not the subtrans.

This issue kills the idea that we can get away with providing lookup to
the other backends _only_ while we are twiddling the clog bits.  Other
transactions are going to need to know if the XID they see on the tuple
is owned by an active backend.  This means we have to provide
child/master xid lookup during the transaction, meaning we may as well
use pg_clog or separate file, especially if we can get autovacuum for
7.4.  It kills the idea that somehow locking would work.

--  Bruce Momjian                        |  http://candle.pha.pa.us pgman@candle.pha.pa.us               |  (610)
359-1001+  If your life is a hard drive,     |  13 Roberts Road +  Christ can be your backup.        |  Newtown Square,
Pennsylvania19073
 


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: nested transactions
Next
From: Bruce Momjian
Date:
Subject: Re: How to compile postgres source code in VC++