14:03:04,783 ERROR [STDERR] javax.transaction.SystemException: TransactionImple.enlistResource - XAResource.start [com.arjuna.ats.internal.jta.transaction.arjunacore.couldnotregister] [com.arjuna.ats.internal.jta.transaction.arjunacore.couldnotregister] could not register transaction: < 131075, 27, 25, 49454553511011004849515658551004958529897491015052101585110045535110110048495156585510049585298974910150521015855101 >
14:03:04,783 ERROR [STDERR] at com.arjuna.ats.internal.jta.transaction.arjunacore.TransactionImple.enlistResource(TransactionImple.java:870)
14:03:04,783 ERROR [STDERR] .
This says that XAResource.start() threw an error, but you don't post what that error was.
Adrain, pls find the log file attached,
I'm a newbie to JCA/ JMS, basically I've an MDB that connects to node1 and picks the request and sends the response message back to same node1 and in case if that fails (due to network error or carsh) then the MDB should connect to another node (node2) to send the response message.
But since i'm using CMT and Transaction as REQUIRED, I would like to know if it is possible for the mdb to connect to node2 for sending the response message when it cant connect to node1? In this case how will the acknowledgment be sent from MDB to node1 to avoid request message redelivery?
Message was edited by: srinivaas venkat, Updated the log file
log.zip 4.6 K
The error message says it can't enlist the connection in the transaction because
something has set the transaction to rollback only.
10:07:42,812 ERROR [HornetQRASessionFactoryImpl] Could not create session
javax.resource.ResourceException: Transaction is not active: tx=TransactionImple < ac, BasicAction: -53edf53a:5e0:4ba99350:a3 status: ActionStatus.ABORT_ONLY
So you need to find out what is doing setRollbackOnly() on the transaction.
e.g. invoking a CMT EJB in the same transaction that throws a RuntimeException would do that.
Nothing in JCA ever sets the status of the transaction to rollback only.
Adrian, Thanks for your quick response,
After enabling trace I could see that the transaction was set to RollbackOnly when an exception occurs while connecting to node1 (because of the temporary network failure). I'm using Hornetq jca adapter to connect the mdb to queue nodes.
Is it because the execption thrown (after attempting to connect to node1) is a system exception that the transaction is set to rollbackOnly? If that is the case is it not possible to send the message to node2 even after getting an exception (while connecting to node1) with the transaction type set to REQUIRED?
If I use Transaction as NOT_SUPPORTED or BMT everything works fine but is it not possible with CMT/transaction as REQUIRED? Pls help!
I've also attached the log file showing the transaction rollback status before and after exception.
log.zip 4.4 K
It looks to me like hornetq is returning the wrong error code?
So you'd be better off moving your discussion to that forum.
XAER_RMERR is for a resource error inside the transaction, meaning
the transaction is in unknown state and can't be committed.
I think it should be using XAER_RMFAIL if the problem is a failure to enlist?
But ask in the transactions forum what the correct code should be,
since they are the ones that interpret them.