[hibernate-issues] [Hibernate-JIRA] Resolved: (HHH-2699) Workaround for bug in PostgreSQL JDBC driver

Diego Pires Plentz (JIRA) noreply at atlassian.com
Sun Nov 11 14:52:30 EST 2007


     [ http://opensource.atlassian.com/projects/hibernate/browse/HHH-2699?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Diego Pires Plentz resolved HHH-2699.
-------------------------------------

      Assignee: Diego Pires Plentz
    Resolution: Rejected

> Workaround for bug in PostgreSQL JDBC driver
> --------------------------------------------
>
>                 Key: HHH-2699
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-2699
>             Project: Hibernate3
>          Issue Type: Improvement
>    Affects Versions: 3.2.3
>         Environment: Hibernate 3.2.3, PostgreSQL 8.2.4 (Mac OS X), JDBC driver 8.2 Build 505 (JDBC 3)
>            Reporter: Matt Solnit
>            Assignee: Diego Pires Plentz
>
> The following line (103) in org/hibernate/connection/DriverManagerConnectionProvider.java:
>     if (isolation!=null) pooled.setTransactionIsolation( isolation.intValue() );
> causes an exception when using the PostgreSQL JDBC driver, because it does not allow you to change the transaction isolation level once a connection is in use.  However, their implementation does not handle the fact that the isolation level is really not being changed in this case (because it is being set to the existing value).
> The following change would work around this issue:
>     if ( isolation!=null && pooled.getTransactionIsolation()!=isolation.intValue() ) pooled.setTransactionIsolation( isolation.intValue() );
> P.S.  I know the DriverManagerConnectionProvider is not for production use, but we use it in development :-).

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the hibernate-issues mailing list