Hi.
I encountered this error: https://jira.springsource.org/browse/SPR-10395 while trying out Hibernate-4.2 and I wonder if it's a Spring bug or Hibernate-bug?
In short, when using Spring-3.2.2 + Hibernate-4.2.0 and calling jdbcTemplate.query() inside a Spring-managed transation using JpaTransactionManager (with Hibernate) an Exception is thrown:
Code:
Caused by: java.sql.SQLException: PooledConnection has already been closed.
at org.apache.tomcat.jdbc.pool.DisposableConnectionFacade.invoke(DisposableConnectionFacade.java:86)
at com.sun.proxy.$Proxy19.commit(Unknown Source)
at org.hibernate.engine.transaction.internal.jdbc.JdbcTransaction.doCommit(JdbcTransaction.java:112)
Downgrading to Hibernate-4.1.9.Final works.