wwadge/bonecp — pull request #12 by quaff (2013-07-23 06:31:33+00:00)
Title: Fixed connection leak, better than pull request #11

Prevent org.postgresql.util.PSQLException: Cannot change transaction read-only property in the middle of a transaction

when release connection to pool,bonecp will call setReadonly on connection,if there is a transaction and is not ended,postgresql(maybe other database) will throw exception.
org.postgresql.util.PSQLException: Cannot change transaction read-only property in the middle of a transaction

the resolution is try rollback to end transaction on the reuse connection