Re: Two-phase commit - Mailing list pgsql-hackers

From Oliver Jowett
Subject Re: Two-phase commit
Date
Msg-id 41662D2E.8010104@opencloud.com
Whole thread Raw
In response to Two-phase commit  (Heikki Linnakangas <hlinnaka@iki.fi>)
Responses Re: Two-phase commit
List pgsql-hackers
Heikki Linnakangas wrote:
> On Thu, 7 Oct 2004, Oliver Jowett wrote:
> 
>> Probably the next question is, do we want a database-side timeout on 
>> how long prepared txns can stay alive before being summarily rolled back?
> 
> 
> That sounds very dangerous to me. You could end up breaking global 
> atomicity if some other resource in the global transaction committed.

Right. You wouldn't enable it lightly..

> The transaction monitor can do timeouts if necessary, and a super user 
> has to resolve the in-doubt transactions if the TM crashes non-recoverably.

Some systems may prefer short-term availability over atomicity. Putting 
a human in the loop when doing recovery hurts your availability.

If pg_prepared_xacts had a time-of-preparation column, it would be 
possible to put the timeout policy in an external client. Perhaps that's 
a better solution?

-O


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Security implications of config-file-location patch
Next
From: Yann Michel
Date:
Subject: Re: plans for bitmap indexes?