-
1. Re: JBoss default Xid generator
jhalliday Aug 9, 2012 5:53 AM (in response to girish_n)> the default Xid generator in JBoss generates same (non-unique) Xid for more than one Transaction.
No, it doesn't.
> default Xid generator in JBoss generates Xid from timestamp. On a millisecond scale it is possible that same Xid is generated more than once.
Wrong on both counts. They don't contain a timestamp for the start of the tx, because calling into the kernel to get the time is too expensive. They do contain the time the process was initialized, because that's a one off cost. They also contain a sequence number. Read Uid.java and stop talking nonsense.
-
2. Re: JBoss default Xid generator
girish_n Aug 9, 2012 6:46 AM (in response to jhalliday)When Does JBoss throw below exception?
SEVERE [com.sun.genericjmsra] (WorkManager(2)-95) After delivery failed javax.transaction.RollbackException: [com.arjuna.ats.internal
.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] Could not commit transaction.
javax.resource.ResourceException: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats
.internal.jta.transaction.arjunacore.commitwhenaborted] Could not commit transaction.
at org.jboss.ejb3.mdb.inflow.MessageInflowLocalProxy.after(MessageInflowLocalProxy.java:263)
at org.jboss.ejb3.mdb.inflow.MessageInflowLocalProxy.invoke(MessageInflowLocalProxy.java:140)
at $Proxy118.afterDelivery(Unknown Source)
at com.sun.genericra.inbound.async.InboundJmsResource.releaseEndpoint(InboundJmsResource.java:313)
at com.sun.genericra.inbound.async.WorkImpl.run(WorkImpl.java:115)
at org.jboss.resource.work.WorkWrapper.execute(WorkWrapper.java:205)
at org.jboss.util.threadpool.BasicTaskWrapper.run(BasicTaskWrapper.java:260)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:679)
Caused by: javax.transaction.RollbackException: [com.arjuna.ats.internal.jta.transaction.arjunacore.commitwhenaborted] [com.arjuna.ats.internal.jta.transacti
on.arjunacore.commitwhenaborted] Could not commit transaction.
at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.commitAndDisassociate(TransactionImple.java:1443)
at com.arjuna.ats.internal.jta.transaction.arjunacore.BaseTransaction.commit(BaseTransaction.java:137)
at com.arjuna.ats.jbossatx.BaseTransactionManagerDelegate.commit(BaseTransactionManagerDelegate.java:75)
at org.jboss.ejb3.mdb.inflow.MessageInflowLocalProxy.endTransaction(MessageInflowLocalProxy.java:464)
at org.jboss.ejb3.mdb.inflow.MessageInflowLocalProxy.finish(MessageInflowLocalProxy.java:343)
at org.jboss.ejb3.mdb.inflow.MessageInflowLocalProxy.after(MessageInflowLocalProxy.java:259)
... 9 more
-
3. Re: JBoss default Xid generator
jhalliday Aug 9, 2012 9:07 AM (in response to girish_n)What's that got to do with the Xid generator? That's the JCA tx inflow API you're using. Which means the Xid is being externally supplied and the subordinate tx mgr will use it verbatim as the spec requires.
-
4. Re: JBoss default Xid generator
girish_n Aug 12, 2012 11:47 PM (in response to jhalliday)Hi Jonathan, Thanks for the info.
I have few questions:
Who will call XAResource.start()? I believe it is JBoss -> Resource Adapter -> JMS Provider ?
Will JBoss pass null XID to start() in any case? If so when? How is JMS Provider expected to deal with it?