[
http://jira.jboss.com/jira/browse/JBMESSAGING-1200?page=all ]
Clebert Suconic updated JBMESSAGING-1200:
-----------------------------------------
Description:
First time the Session.executor is called, it will initialized a thread.
That thread will assume the parent's contextClassLoader, and it will hold it for the
entire life cycle of the executor.
This could be a problem on the application server, as the JCA adapter will cache the
session, reusing it between different applications.
When the session is used by another application, the executor's thread will have a
reference to the previously used JAR, and ThreadContextClassLoader is used on
ObjectInputStream operations. (ObjectInputStreamWithClassLoader).
To fix this, we need to cleanup to set and clear the ContextClassLoader on every
invocation.
was:
The Session.executor is holding the first ClassLoader reference on its
ThreadContextClassLoader.
This is also causing invalid classLoader usages when the first ClassLoader used was
undeployed, and could lead to other problems on ObjectMessages and StreamMessages. (things
like ClassNotFound becuase it's using the wrong classLoader on the executor).
Session.executor is leaking the first classLoader used
------------------------------------------------------
Key: JBMESSAGING-1200
URL:
http://jira.jboss.com/jira/browse/JBMESSAGING-1200
Project: JBoss Messaging
Issue Type: Bug
Affects Versions: 1.4.0.SP2
Reporter: Clebert Suconic
Assigned To: Clebert Suconic
Fix For: 1.4.1
First time the Session.executor is called, it will initialized a thread.
That thread will assume the parent's contextClassLoader, and it will hold it for the
entire life cycle of the executor.
This could be a problem on the application server, as the JCA adapter will cache the
session, reusing it between different applications.
When the session is used by another application, the executor's thread will have a
reference to the previously used JAR, and ThreadContextClassLoader is used on
ObjectInputStream operations. (ObjectInputStreamWithClassLoader).
To fix this, we need to cleanup to set and clear the ContextClassLoader on every
invocation.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira