]
Kevin Conner commented on JBESB-2787:
-------------------------------------
The recursion is caused by a bug in the hibernate code, triggered by a NamingException.
The getUserTransaction() method calls itself when it catches the NamingException.
protected UserTransaction getUserTransaction() {
log.trace( "Attempting to locate UserTransaction via JNDI [{}]",
getUserTransactionName() );
try {
...
}
catch ( NamingException ne ) {
throw new TransactionException( "Could not find
UserTransaction in JNDI [" + getUserTransaction() + "]", ne );
}
}
The JNDI lookup is also being made over RMI.
jbpm.esb causes AS 5 server to sometimes hang upon shutdown.
-------------------------------------------------------------
Key: JBESB-2787
URL:
https://jira.jboss.org/jira/browse/JBESB-2787
Project: JBoss ESB
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: Process flow
Affects Versions: 4.7
Reporter: Daniel Bevenius
Fix For: 4.7
Attachments: as5HangOnShutdown.txt
The application server does not close down, well it hangs for a long while before
finishing.
Console log (a few mins after the thread dump)
=============================================
16:54:33,395 WARN [arjLoggerI18N] [com.arjuna.ats.arjuna.coordinator.BasicAction_40] -
Abort called on already aborted atomic action 7f000001:a6d0:4a82d3c0:3cb
16:54:33,395 ERROR [STDERR] Exception in thread "JbpmJobExector:127.0.0.1:1"
16:54:33,395 ERROR [STDERR] java.lang.StackOverflowError
16:54:33,400 ERROR [STDERR] at java.lang.Class.isPrimitive(Native Method)
16:54:33,400 ERROR [STDERR] at
java.lang.Class.getEnclosingMethodInfo(Class.java:923)
16:54:33,400 ERROR [STDERR] at java.lang.Class.getEnclosingClass(Class.java:1077)
16:54:33,400 ERROR [STDERR] at java.lang.Class.getSimpleBinaryName(Class.java:1216)
16:54:33,401 ERROR [STDERR] at java.lang.Class.getSimpleName(Class.java:1108)
16:54:33,401 ERROR [STDERR] at
org.jboss.classloader.spi.base.BaseClassLoader.toString(BaseClassLoader.java:926)
16:54:33,401 ERROR [STDERR] at java.lang.String.valueOf(String.java:2615)
16:54:33,401 ERROR [STDERR] at
java.lang.StringBuilder.append(StringBuilder.java:116)
16:54:33,401 ERROR [STDERR] at
sun.rmi.server.LoaderHandler.loadClass(LoaderHandler.java:138)
16:54:33,401 ERROR [STDERR] at
java.rmi.server.RMIClassLoader$2.loadClass(RMIClassLoader.java:620)
16:54:33,401 ERROR [STDERR] at
org.jboss.system.JBossRMIClassLoader.loadClass(JBossRMIClassLoader.java:91)
16:54:33,401 ERROR [STDERR] at
java.rmi.server.RMIClassLoader.loadClass(RMIClassLoader.java:247)
16:54:33,401 ERROR [STDERR] at
sun.rmi.server.MarshalInputStream.resolveClass(MarshalInputStream.java:197)
16:54:33,401 ERROR [STDERR] at
java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1544)
16:54:33,401 ERROR [STDERR] at
java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1466)
16:54:33,401 ERROR [STDERR] at
java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1699)
16:54:33,401 ERROR [STDERR] at
java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1305)
16:54:33,401 ERROR [STDERR] at
java.io.ObjectInputStream.readArray(ObjectInputStream.java:1634)
16:54:33,401 ERROR [STDERR] at
java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1299)
16:54:33,401 ERROR [STDERR] at
java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1908)
16:54:33,402 ERROR [STDERR] at
java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1832)
16:54:33,402 ERROR [STDERR] at
java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1719)
16:54:33,402 ERROR [STDERR] at
java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1305)
16:54:33,402 ERROR [STDERR] at
java.io.ObjectInputStream.readObject(ObjectInputStream.java:348)
16:54:33,402 ERROR [STDERR] at
sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:215)
16:54:33,402 ERROR [STDERR] at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:126)
16:54:33,402 ERROR [STDERR] at org.jnp.server.NamingServer_Stub.lookup(Unknown
Source)
16:54:33,402 ERROR [STDERR] at
org.jnp.interfaces.NamingContext.lookup(NamingContext.java:726)
16:54:33,402 ERROR [STDERR] at
org.jnp.interfaces.NamingContext.lookup(NamingContext.java:686)
16:54:33,402 ERROR [STDERR] at
javax.naming.InitialContext.lookup(InitialContext.java:351)
16:54:33,402 ERROR [STDERR] at
org.hibernate.transaction.JTATransactionFactory.getUserTransaction(JTATransactionFactory.java:162)
16:54:33,402 ERROR [STDERR] at
org.hibernate.transaction.JTATransactionFactory.getUserTransaction(JTATransactionFactory.java:172)
16:54:33,402 ERROR [STDERR] at
org.hibernate.transaction.JTATransactionFactory.getUserTransaction(JTATransactionFactory.java:172)
16:54:33,402 ERROR [STDERR] at
org.hibernate.transaction.JTATransactionFactory.getUserTransaction(JTATransactionFactory.java:172)
...
16:54:33,996 INFO [ConnectionFactoryBindingService] Unbound ConnectionManager
'jboss.jca:service=DataSourceBinding,name=JbpmDS' from JNDI name
'java:JbpmDS'
16:54:34,044 INFO [QuartzScheduler] Scheduler DefaultQuartzScheduler_$_NON_CLUSTERED
shutting down.
16:54:34,044 INFO [QuartzScheduler] Scheduler DefaultQuartzScheduler_$_NON_CLUSTERED
paused.
16:54:34,045 INFO [SimpleThreadPool] There are still 35 worker threads active. See
javadoc runInThread(Runnable) for a possible explanation
16:54:34,045 INFO [QuartzScheduler] Scheduler DefaultQuartzScheduler_$_NON_CLUSTERED
shutdown complete.
16:54:34,528 INFO [TransactionManagerService] Stopping transaction recovery manager
16:54:34,530 INFO [TransactionManagerService] Destroying TransactionManagerService
16:54:34,685 INFO [HypersonicDatabase] Database standalone closed clean
16:54:38,218 INFO [DefaultEndpointRegistry] remove:
jboss.ws:context=Quickstart_webservice_consumer2,endpoint=OrderProcessorWS
16:54:38,402 INFO [HypersonicDatabase] Database standalone closed clean
16:54:38,661 INFO [H2Database] Database standalone closed clean
16:54:48,022 INFO [ServerImpl] Shutdown complete
Shutdown complete
Halting VM
Complete log will be attached with a thread dump.
I found this jira:
http://opensource.atlassian.com/projects/hibernate/browse/HHH-3481
The version of hibernate that is shipped with AS 5.1.0.GA is 3.3.1. Perhaps an upgrade to
3.3.2 will take care of the issue with the hang, though I still think
that we will in that case get an exception. Should the jbpm.esb/jbpm-service.xml's
JbpmService depend on the TransactionManager?:
<mbean code="org.jboss.soa.esb.services.jbpm.configuration.JbpmService"
name="jboss.esb:service=JbpmService">
<depends>jboss.esb:service=JBPMDatabaseInitializer</depends>
<depends>jboss:service=TransactionManager</depends>
</mbean>
Lets say the TransactionManager sometimes gets deployed before the jbpm.esb, then this
would probably trigger this issue. Sort of difficult to test this as this does not happen
every time.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: