Re: JDBC XA Support and Sample code? - Mailing list pgsql-jdbc

From Garber, Mikhail
Subject Re: JDBC XA Support and Sample code?
Date
Msg-id 5B6EE82A8CF89149BA864458DB6053470386CE0F20@EX-SEA5-A.ant.amazon.com
Whole thread Raw
In response to Re: JDBC XA Support and Sample code?  (Heikki Linnakangas <heikki@enterprisedb.com>)
List pgsql-jdbc
> It's typically used together with an application server that
> also acts as the transaction manager, and manages the
> connections and transactions for you. In that case, you don't
> need to do anything special; if you use two database
> connections or other resource managers in a transaction, the
> application server will perform two-phase commit using the XA
> driver behind the scenes.



Just FYI, I used Postgres XA driver against two databases using Spring and BTM transaction manager. My configuration
wasbased on what is in BTM documentation. It worked just fine. I was not able to "break" it. 


> -----Original Message-----
> From: pgsql-jdbc-owner@postgresql.org
> [mailto:pgsql-jdbc-owner@postgresql.org] On Behalf Of Heikki
> Linnakangas
> Sent: Thursday, December 06, 2007 9:55 AM
> To: Jignesh K. Shah
> Cc: pgsql-jdbc@postgresql.org
> Subject: Re: [JDBC] JDBC XA Support and Sample code?
>
> Jignesh K. Shah wrote:
> > I am new to the XA world of PostgreSQL. What's the story of XA in
> > PostgreSQL JDBC Driver? Also are there examples on how to use the
> > "Experimental" XA driver in postgresql-jdbc?
>
> As Kris pointed out, it's not experimental.
>
> It's typically used together with an application server that
> also acts as the transaction manager, and manages the
> connections and transactions for you. In that case, you don't
> need to do anything special; if you use two database
> connections or other resource managers in a transaction, the
> application server will perform two-phase commit using the XA
> driver behind the scenes.
>
> The tricky part is configuring the application
> server/transaction manager to use the XA-enabled
> PGXADataSource. That's different on each product. It would be
> nice to get a sample config file and tutorial on Glassfish,
> hint hint ;-)
>
> --
>    Heikki Linnakangas
>    EnterpriseDB   http://www.enterprisedb.com
>
> ---------------------------(end of
> broadcast)---------------------------
> TIP 1: if posting/reading through Usenet, please send an appropriate
>        subscribe-nomail command to majordomo@postgresql.org
> so that your
>        message can get through to the mailing list cleanly
>

pgsql-jdbc by date:

Previous
From: Heikki Linnakangas
Date:
Subject: Re: JDBC XA Support and Sample code?
Next
From: "Henry B. Hotz"
Date:
Subject: Re: JDBC and GSSAPI/Krb5