Hibernate/JTA/PostgreSQL - Mailing list pgsql-jdbc

From Jimmy Wan
Subject Hibernate/JTA/PostgreSQL
Date
Msg-id 54D41E91F26CF6488C7088C89D9160F868BA94@21ctexg01.21technologies.com
Whole thread Raw
Responses Re: Hibernate/JTA/PostgreSQL  (joël Winteregg <joel.winteregg@gmail.com>)
List pgsql-jdbc
Hello, I've been trying to simultaneously debug an issue with
connections
being left in the <IDLE in transaction> state. My software stack looks
something like this:

Custom J2EE Code & Jackrabbit JCR
Hibernate 3.2.0
Tranql 1.4.1/Tranql Connectors 1.4
Geronimo 2.0.2
PostgreSQL JDBC 8.2-504, 8.2-506, 8.2-507
(been upgrading to no avail)
PostgreSQL on the backend (8.2.4 on Windows or 8.2.3 on Linux)

I've also got a unit test environment that looks something like this:
Custom J2EE Code & Jackrabbit JCR
Hibernate 3.2.0
Tranql 1.4.1/Tranql Connectors 1.4
Embedded OpenEJB 1.0
PostgreSQL JDBC 8.2-504, 8.2-506, 8.2-507
(been upgrading to try and fix my problems to no avail)
PostgreSQL 8.2 on the backend.

I saw the following note to the postgresql-jdbc list:
http://archives.postgresql.org/pgsql-jdbc/2006-10/msg00060.php

Ludovic, I was wondering if your analysis for PostgreSQL evaluation
for compatibility with BTM was complete. Also, I was wondering
whether you could elaborate on the following statement about
Hibernate and JTA:

In particular, the following passage:
"I'm not 100% sure about this but the fact that you cannot mix local
and global transactions will prevent Hibernate applications to work
when built with JTA. There are many cases where these features that
look not that important at first are quite critical."

I had been under the assumption (misunderstanding?) that using the
JTASessionContext for Hibernate would force it to employ XA
transactions, but when stepping through the Hibernate code, I saw
that none of my Hibernate operations resulted in the enlistment of
XA resources.

I'm about to throw in the towel wrt using XA (we don't really need
to synchronize across multiple datasources).

I still consider myself an XA novice, so any pointers are helpful.

pgsql-jdbc by date:

Previous
From: "Woody Woodring"
Date:
Subject: Connection attempt hangs when server is unresponsive
Next
From: "Jignesh K. Shah"
Date:
Subject: JDBC XA Support and Sample code?