pg.ddx.io pgsql-bugs@postgresql.org mailing list archive
help / color / mirror / Atom feedIncorrect return code for error on call of commit during 2PC
3+ messages / 2 participants
[nested] [flat]
* Incorrect return code for error on call of commit during 2PC
@ 2014-12-08 11:26 Ondrej Chaloupka <ochaloup@redhat.com>
0 siblings, 0 replies; 3+ messages in thread
From: Ondrej Chaloupka @ 2014-12-08 11:26 UTC (permalink / raw)
To: pgsql-bugs
Hi,
it seems that PostgreSQL jdbc driver returns incorrect code during on call of commit during 2PC. Currently the driver returns XAER_RMERR.
I expect that it's this call
https://github.com/pgjdbc/pgjdbc/blob/master/org/postgresql/xa/PGXAConnection.java#L528
But the XA spec says for XAER_RMERR that
--
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs
^ permalink raw reply [nested|flat] 3+ messages in thread
* Incorrect return code for error on call of commit during 2PC
@ 2014-12-08 11:33 Ondrej Chaloupka <ochaloup@redhat.com>
2014-12-08 15:05 ` Re: Incorrect return code for error on call of commit during 2PC Tom Lane <tgl@sss.pgh.pa.us>
0 siblings, 1 reply; 3+ messages in thread
From: Ondrej Chaloupka @ 2014-12-08 11:33 UTC (permalink / raw)
To: pgsql-bugs
I'm sorry for spamming the mailing list with incomplete messages. It seems that my 'enter' function does not work correctly :)
it seems that PostgreSQL jdbc driver returns incorrect code during on call of commit during 2PC. Currently the driver returns XAER_RMERR.
I expect that it's this call
https://github.com/pgjdbc/pgjdbc/blob/master/org/postgresql/xa/PGXAConnection.java#L528
But the XA spec (http://pubs.opengroup.org/onlinepubs/009680699/toc.pdf) says for XAER_RMERR that
"An error occurred in committing the work performed on behalf of the transaction
branch and the branch’s work has been rolled back. Note that returning this error
signals a catastrophic event to a transaction manager since other resource
managers may successfully commit their work on behalf of this branch. This error
should be returned only when a resource manager concludes that it can never
commit the branch and that it cannot hold the branch’s resources in a prepared
state. Otherwise, [XA_RETRY] should be returned."
In case there is longer discussion about scenario hitting this issue and about handling this at RedHat bugzilla here:
https://bugzilla.redhat.com/show_bug.cgi?id=988724
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re: Incorrect return code for error on call of commit during 2PC
2014-12-08 11:33 Incorrect return code for error on call of commit during 2PC Ondrej Chaloupka <ochaloup@redhat.com>
@ 2014-12-08 15:05 ` Tom Lane <tgl@sss.pgh.pa.us>
0 siblings, 0 replies; 3+ messages in thread
From: Tom Lane @ 2014-12-08 15:05 UTC (permalink / raw)
To: Ondrej Chaloupka <ochaloup@redhat.com>; +Cc: pgsql-bugs
Ondrej Chaloupka <ochaloup@redhat.com> writes:
> it seems that PostgreSQL jdbc driver returns incorrect code during on call of commit during 2PC. Currently the driver returns XAER_RMERR.
This list is mainly for reporting bugs in the core Postgres software, so
I'm not sure how closely the JDBC developers follow it. You might have
better luck inquiring about this issue in the pgsql-jdbc list.
regards, tom lane
--
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs
^ permalink raw reply [nested|flat] 3+ messages in thread
end of thread, other threads:[~2014-12-08 15:05 UTC | newest]
Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2014-12-08 11:26 Incorrect return code for error on call of commit during 2PC Ondrej Chaloupka <ochaloup@redhat.com>
2014-12-08 11:33 Incorrect return code for error on call of commit during 2PC Ondrej Chaloupka <ochaloup@redhat.com>
2014-12-08 15:05 ` Tom Lane <tgl@sss.pgh.pa.us>
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