I have a configured simple chunk-based XML jbatch job that has always run well even under heavy loads in Glassfish 4.1(Build 13) on CentOS 6. But I have recently created another installation with same Glassfish version on CentOS 7; virtually using default configurations.
The new installation has great difficulty running and completing jobs; with noticeably slow execution rate and failure to complete with following consistent error:
`[2018-05-14T06:05:28.079+0300] [glassfish 4.1] [SEVERE] [poolmgr.component_register_exception] [javax.enterprise.resource.resourceadapter.com.sun.enterprise.resource.rm] [tid: _ThreadID=209 _ThreadName=concurrent/batchDispatchExecutor-managedThreadFactory-Thread-5] [timeMillis: 1526267128079] [levelValue: 1000] [[
RAR5029:Unexpected exception while registering component javax.transaction.RollbackException at com.sun.jts.jta.TransactionImpl.registerSynchronization(TransactionImpl.java:305) at com.sun.enterprise.transaction.JavaEETransactionManagerSimplified.startJTSTx(JavaEETransactionManagerSimplified.java:439) at com.sun.enterprise.transaction.jts.JavaEETransactionManagerJTSDelegate.enlistLAOResource(JavaEETransactionManagerJTSDelegate.java:318) at com.sun.enterprise.transaction.JavaEETransactionManagerSimplified.enlistResource(JavaEETransactionManagerSimplified.java:356) at com.sun.enterprise.resource.rm.ResourceManagerImpl.registerResource(ResourceManagerImpl.java:152)
....
[2018-05-14T06:05:28.080+0300] [glassfish 4.1] [WARNING] [poolmgr.err_enlisting_res_in_getconn] [javax.enterprise.resource.resourceadapter.com.sun.enterprise.resource.pool] [tid: _ThreadID=209 _ThreadName=concurrent/batchDispatchExecutor-managedThreadFactory-Thread-5] [timeMillis: 1526267128080] [levelValue: 900] [[
RAR7132: Unable to enlist the resource in transaction. Returned resource to pool. Pool name: [ __TimerPool ]]]
[2018-05-14T06:05:28.080+0300] [glassfish 4.1] [WARNING] [poolmgr.get_connection_failure] [javax.enterprise.resource.resourceadapter.com.sun.enterprise.connectors] [tid: _ThreadID=209 _ThreadName=concurrent/batchDispatchExecutor-managedThreadFactory-Thread-5] [timeMillis: 1526267128080] [levelValue: 900] [[ RAR5117 : Failed to obtain/create connection from connection pool [ __TimerPool ]. Reason : com.sun.appserv.connectors.internal.api.PoolingException: javax.transaction.RollbackException]]
[2018-05-14T06:05:28.081+0300] [glassfish 4.1] [WARNING] [jdbc.exc_get_conn] [javax.enterprise.resource.resourceadapter.com.sun.gjc.spi] [tid: _ThreadID=209 _ThreadName=concurrent/batchDispatchExecutor-managedThreadFactory-Thread-5] [timeMillis: 1526267128081] [levelValue: 900] [[ RAR5114 : Error allocating connection : [Error in allocating a connection. Cause: javax.transaction.RollbackException]]]
[2018-05-14T06:05:28.081+0300] [glassfish 4.1] [WARNING] [] [com.ibm.jbatch.container.services.impl] [tid: _ThreadID=209 _ThreadName=concurrent/batchDispatchExecutor-managedThreadFactory-Thread-5] [timeMillis: 1526267128081] [levelValue: 900] [[ Did not find job instance status for executionId: 306]] ....`
The questions are: 1. Why is timerpool not releasing connections? 2. Executor service very slow?