dev@glassfish.java.net

Can we have "delegate=false" in EJBClassloader (related bug: 6314912)?

From: <Jason.Huang_at_Sun.COM>
Date: Thu, 08 Mar 2007 16:22:55 +0800

Hi,

One of my customer run into the same problem described in bug: 6314912.
According to the bug page(http://sunsolve/search/document.do?assetkey=1-1-6314912-1).
The bug is fixed in SJSAS 9.0 by renaming the packages under "com.sun...".

For high performance, they want to install SJSAS EE.
After installing SJSAS 8.2 EE included in JES 5, however the fix is not shipped with the latest version.
In the appserv-rt.jar, there're still the packages naming org.apache.common.... :-( .

Who knows When the fix will be shipped with SJSAS EE edition?

As for workaround, for web application we can do this as a workaround:
<sun-web-app><class-loader delegate="false"/></sun-web-app>

For general J2EE application, calling Digester.setUseContextClassLoader(true); could be a workaround.
However, if the customer don't want to modify the code? Or if the source is not available? Or if no setUseContextClassLoader() method provided in Digester?
How to cope with it...
 
I wonder if we could have the same or similar method as in web layer to customize the class loading process in the EJBClassloader(Applciation level).
That is, the EJB Classloader looks in the local class loader before delegating to its parent.

If this is possible, that could be more helpful for the customers while making SJSAS more competitive.
Also we need not spend so much time on renaming the third party packages we use.


Thanks
-Jason