Process Engine stalled after transaction problem

Hello everybody,

I have experienced some odd behaviour by the Process Engine in version 7.6 with JBoss EAP 6.4.

Here I have the job executor connection lost

WARN 	[job-executor-tp-threads - 1]	org.jboss.jca.core.connectionmanager.listener.AbstractConnectionListener	connectionErrorOccurred:331	-	
	IJ000305: Connection error occured: org.jboss.jca.core.connectionmanager.listener.TxConnectionListener@2004cd7c[state=NORMAL managed connection=org.jboss.jca.adapters.jdbc.xa.XAManagedConnection@22da93c9 connection handles=0 lastUse=1495825201135 trackByTx=true pool=org.jboss.jca.core.connectionmanager.pool.strategy.OnePool@41e18007 pool internal context=SemaphoreArrayListManagedConnectionPool@5a53d883[pool=OracleProcessEngineDS] xaResource=XAResourceWrapperImpl@6039523e[xaResource=org.jboss.jca.adapters.jdbc.xa.XAManagedConnection@22da93c9 pad=false overrideRmValue=false productName=Oracle productVersion=Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production

After a couple of these instead of start the process engine, the arjuna starts to throw warnings and the process engine gets stalled

WARN [Periodic Recovery] com.arjuna.ats.internal.jta.resources.arjunacore.XAResourceRecord restore_state:997 - ARJUNA016037: Could not find new XAResource to use for recovering non-serializable XAResource XAResourceRecord < resource:null, txid:< formatId=131077, gtrid_length=29, bqual_length=36, tx_uid=0:ffff0a20cb11:1f1c0050:589c7fc1:9742c, node_name=1, branch_uid=0:ffff0a20cb11:1f1c0050:589c7fc1:97430, subordinatenodename=null, eis_name=java:jboss/datasources/ProcessEngine >, heuristic: TwoPhaseOutcome.FINISH_OK, product: Oracle/Oracle Database 12c Enterprise Edition Release 12.1.0.2.0 - 64bit Production

And

Caused by: javax.transaction.SystemException: IJ000356: Failed to enlist: java.lang.Throwable: Unabled to enlist resource, see the previous warnings. tx=TransactionImple < ac, BasicAction: 0:ffff0a20cb11:754e153:5922f8bb:5d22f status: ActionStatus.ABORT_ONLY >

After that, the only way to make everything work again is restarting JBoss.

I could not find a simple way to reproduce it, however I found a similar open issue:
https://app.camunda.com/jira/browse/CAM-4563

This “feels” like something I’ve seen before called a “wedged transaction” (forgive me if that’s not precisely corrected, but the word “wedged” was definitely in there).

I believe we experienced this when processes were accessing external databases (MySQL in this case) via Hibernate.

I’m sorry I can’t provide more details, but your question had a familiar ring and so I thought I’d share this.