commit and rollback don't throw exceptions when they should - Mailing list pgsql-jdbc

From Kevin Grittner
Subject commit and rollback don't throw exceptions when they should
Date
Msg-id 4ADDCCE1020000250002BBEA@gw.wicourts.gov
Whole thread Raw
Responses Re: commit and rollback don't throw exceptions when they should  (Oliver Jowett <oliver@opencloud.com>)
List pgsql-jdbc
Based on this:

http://java.sun.com/javase/6/docs/api/java/sql/Connection.html#commit%28%29

Connection.commit() and Connetion.rollback() in the PostgreSQL JDBC
driver don't throw exceptions when they should.  This was posted as
bug 5127 on the bugs list when it broke a user's connection pooling.
Are there any arguments that the PostgreSQL driver should not throw
and exception as stated on that javadoc page?:

- if a database access error occurs,
- this method is called while participating in a distributed
  transaction,
- if this method is called on a closed connection or
- this Connection object is in auto-commit mode

I could take a shot at a patch if nobody disagrees with making this
change.

-Kevin

pgsql-jdbc by date:

Previous
From: David Wall
Date:
Subject: JDBC with PG 8.4 bytea character escaping wire protocol
Next
From: Oliver Jowett
Date:
Subject: Re: commit and rollback don't throw exceptions when they should