From: Radosław Smogura <rsmogura@softperience.eu>
To: pgsql-jdbc@postgresql.org
Cc: Johann 'Myrkraverk' Oskarsson <johann@2ndquadrant.com>
Subject: Re: Possible oversight in org.postgresql.xa.PGXAConnection.commitPrepared(Xid xid)
Date: Tue, 5 Jul 2011 08:12:59 +0200
Message-ID: <201107050812.59178.rsmogura@softperience.eu> (raw)
In-Reply-To: <x6hb713ds1.fsf@2ndquadrant.com>
References: <4E0AEFDB.30701@enterprisedb.com>
<4E0C655E.8000307@enterprisedb.com>
<x6hb713ds1.fsf@2ndquadrant.com>
"Johann 'Myrkraverk' Oskarsson" <johann@2ndquadrant.com> Tuesday 05 of July
2011 00:02:38
> Heikki Linnakangas <heikki.linnakangas@enterprisedb.com> writes:
> > Well, if the transaction has been rolled back, it's clearly not in
> > prepared state anymore, so XAER_RMERR seems appropriate and the TM
> > shouldn't get upset about that. However, the situation is more
> > ambiguous if the TM issues COMMIT PREPARED and the connection is
> > broken before receiving a reply. It will retry, and if the the
> > COMMIT succeeded the first time, the TM will get XAER_RMERR on the
> > second call. That's more serious.
>
> There is no reason to return an error on rollback if the transaction
> is unknown. If the DBMS server does not remember the transaction the
> transaction manager can assume it has already been rolled back. That
> is why it is appropriate to silently ignore 42704 or rollback. The
> following patch does this.
>
> This patch fixes a failure in a testsuite from Atomikos.
I may be wrong, but may VACUUM remove transactions statuses? What will happen
in this situation if transaction will be prepared, commited or rolledback?
Regards,
Radek
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-jdbc@postgresql.org
Cc: rsmogura@softperience.eu, johann@2ndquadrant.com
Subject: Re: Possible oversight in org.postgresql.xa.PGXAConnection.commitPrepared(Xid xid)
In-Reply-To: <201107050812.59178.rsmogura@softperience.eu>
References: <4E0AEFDB.30701@enterprisedb.com> <4E0C655E.8000307@enterprisedb.com> <x6hb713ds1.fsf@2ndquadrant.com> <201107050812.59178.rsmogura@softperience.eu>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox