Re: XAResource implementation
От | Heikki Linnakangas |
---|---|
Тема | Re: XAResource implementation |
Дата | |
Msg-id | 47275A50.2050201@enterprisedb.com обсуждение исходный текст |
Ответ на | Re: XAResource implementation (joël Winteregg <joel.winteregg@gmail.com>) |
Ответы |
Re: XAResource implementation
|
Список | pgsql-jdbc |
joël Winteregg wrote: > Hello Heikki, > > Thanks for your answer. Yes, i'm using the following jdbc driver > version: 8.2-506.jdbc4.jar > > Do you have any other idea ? Should I tune something for the jdbc > driver ? Hmm. Looking at the logs on that forum, apparently Atomikos calls XAResource.start(TMJOIN) using a different connection: XAResourceTransaction 127.0.0.1.tm0000100044127.0.0.1.tm1: about to switch to XAResource org.postgresql.xa.PGXAConnection@364641 [thread: main] on: 07-10-28 12:37:53,333 XAResourceTransaction 127.0.0.1.tm0000100044127.0.0.1.tm1: switched to XAResource org.postgresql.xa.PGXAConnection@364641 [thread: main] on: 07-10-28 12:37:53,333 ... XAResource.start ( 127.0.0.1.tm0000100044127.0.0.1.tm1 , XAResource.TMNOFLAGS ) called on resource testDS1 represented by XAResource instance org.postgresql.xa.PGXAConnection@364641 [thread: main] on: 07-10-28 12:37:53,335 ... XAResource.end ( 127.0.0.1.tm0000100044127.0.0.1.tm1 , XAResource.TMSUCCESS ) called on resource testDS1 represented by XAResource instance org.postgresql.xa.PGXAConnection@364641 [thread: main] on: 07-10-28 12:37:53,434 ... XAResourceTransaction 127.0.0.1.tm0000100044127.0.0.1.tm1: about to switch to XAResource org.postgresql.xa.PGXAConnection@b6548 [thread: main] on: 07-10-28 12:37:53,441 XAResourceTransaction 127.0.0.1.tm0000100044127.0.0.1.tm1: switched to XAResource org.postgresql.xa.PGXAConnection@b6548 [thread: main] on: 07-10-28 12:37:53,442 ... Note how the PGXAConnection instance used above changes from PGXAConnection@364641 to PGXAConnection@b6548. Unfortunately that's the kind of transaction interleaving that we don't support. You said you tried setExclusiveConnectionMode(true), but I think there's something wrong with that. If I'm reading the Atomikos source code right, in exclusive connection mode it should use ExclusiveExternalXAPooledConnectionImp, but in your case it's using ExternalXAPooledConnectionImp, which according to the source code is used when not in exclusive connection mode. Are you sure you set that parameter in the right place? -- Heikki Linnakangas EnterpriseDB http://www.enterprisedb.com
В списке pgsql-jdbc по дате отправления: