I used the datasource in a web container as below. No EJB, JMS, or concurrency is 
involved. In oracle-xa-ds.xml, the track-connection-by-tx is true. JBoss is 3.2.3

1. get the UserTransaction
   UserTransaction ut=...(from JNDI).
   ut.begin();
2. get Connection
   Connection con=... (from JNDI).
3. does some database updates.
4. commit
   con.close();
   ut.commit();

The first round is good. However, when it comes to second round, I got an exception at 
step 2.

XAException: tx=TransactionImpl:XidImpl [FormatId=257, GlobalId=jasonlaptop//27, 
BranchQual=] errorCode=XAER_PROTO
javax.transaction.xa.XAException
        at 
oracle.jdbc.xa.OracleXAResource.disallowLocalTxnMode(OracleXAResource.java:1047)
        at oracle.jdbc.xa.client.OracleXAResource.start(OracleXAResource.java:153)
        at 
org.jboss.resource.adapter.jdbc.xa.XAManagedConnection.start(XAManagedConnection.java:143)
        at org.jboss.tm.TransactionImpl.startResource(TransactionImpl.java:1148)
        at org.jboss.tm.TransactionImpl.enlistResource(TransactionImpl.java:636)
        at 
org.jboss.resource.connectionmanager.TxConnectionManager$TxConnectionEventListener.enlist(TxConnectionManager.java:455)
        at 
org.jboss.resource.connectionmanager.TxConnectionManager.managedConnectionReconnected(TxConnectionManager.java:343)
        at 
org.jboss.resource.connectionmanager.BaseConnectionManager2.allocateConnection(BaseConnectionManager2.java:483)
        at 
org.jboss.resource.connectionmanager.BaseConnectionManager2$ConnectionManagerProxy.allocateConnection(BaseConnectionManager2.java:814)
        at 
org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:102)
        

Is this because that my UserTransaction is not used correctly? Thanks

jason

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3841009#3841009

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3841009


-------------------------------------------------------
This SF.Net email sponsored by Black Hat Briefings & Training.
Attend Black Hat Briefings & Training, Las Vegas July 24-29 - 
digital self defense, top technical experts, no vendor pitches, 
unmatched networking opportunities. Visit www.blackhat.com
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to