place parser jars in location identified by java.endorsed.dirs
restart JBOSS container with -Djava.endorsed.dirs to point to location of 
parser jars 
-Djava.endorsed.dirs=$CATALINA_HOME/endorsed

http://docs.jboss.org/jbossweb/3.0.x/class-loader-howto.html

hth
Martin 
______________________________________________ 
Verzicht und Vertraulichkeitanmerkung/Note de déni et de confidentialité
 
Diese Nachricht ist vertraulich. Sollten Sie nicht der vorgesehene Empfaenger 
sein, so bitten wir hoeflich um eine Mitteilung. Jede unbefugte Weiterleitung 
oder Fertigung einer Kopie ist unzulaessig. Diese Nachricht dient lediglich dem 
Austausch von Informationen und entfaltet keine rechtliche Bindungswirkung. 
Aufgrund der leichten Manipulierbarkeit von E-Mails koennen wir keine Haftung 
fuer den Inhalt uebernehmen.
Ce message est confidentiel et peut être privilégié. Si vous n'êtes pas le 
destinataire prévu, nous te demandons avec bonté que pour satisfaire informez 
l'expéditeur. N'importe quelle diffusion non autorisée ou la copie de ceci est 
interdite. Ce message sert à l'information seulement et n'aura pas n'importe 
quel effet légalement obligatoire. Étant donné que les email peuvent facilement 
être sujets à la manipulation, nous ne pouvons accepter aucune responsabilité 
pour le contenu fourni.




> Subject: [beanutils] Issue with ContextClassLoaderLocal class.
> From: [email protected]
> To: [email protected]
> Date: Tue, 24 May 2011 18:25:43 +0530
> 
> Hi,
>  
> We are working on migrating a J2EE application from WAS6.1 to JBoss EAP 5.0. 
> For unmarshalling of some custom XML we make use of commons-beanutils-1.8.3 
> within this application; and in the process, we have defined a custom type 
> converter for one of the XML tags.
> The registration of this converter happens in one EJB module within our EAR, 
> whereas theactual XML parsing occurs in another EJB module within the same 
> EAR.
> The org.apache.commons.beanutils.ContextClassLoaderLocal class ties 'global' 
> variables to a classloader instance in a map to ensure data isolation even if 
> the variable is referenced by multiple components running within a container.
> Here is the relevant code snippet from its get() method:
> 
>     ClassLoader contextClassLoader = 
> Thread.currentThread().getContextClassLoader();
>     if (contextClassLoader != null)
>     {
>         Object value = valueByClassLoader.get(contextClassLoader);
>         if ((value == null) && 
> !valueByClassLoader.containsKey(contextClassLoader))
>         {
>             value = initialValue();
>             valueByClassLoader.put(contextClassLoader, value);
>         }
>     return value;
>     }
> 
> After all that background information, here is the problem:
> During the converter registration process, a BeanUtilsBean instance is 
> maintained in the ContextClassLoaderLocal map against the classloader of the 
> registration EJB module.
> During the parsing process, this map is queried to retreive the same 
> BeanUtilsBean instance, using the classloader of the parsing EJB module as 
> the key. In Websphere Application server, the classloader instance for the 
> registration module and the parser module are both same; the correct 
> BeanUtilsBean instance is retreived and processing proceeds as expected. 
> However, in JBoss EAP 5.0, the two classloader instances are different so 
> that the parser module fails to retreive the value from the map.
> Is this a problem with beanutils' design or an issue with JBoss? Please let 
> me know if I am missing something or if additional details are required.
> Thanks in advance.
> N.Rammohan.
> =====-----=====-----=====
> Notice: The information contained in this e-mail
> message and/or attachments to it may contain 
> confidential or privileged information. If you are 
> not the intended recipient, any dissemination, use, 
> review, distribution, printing or copying of the 
> information contained in this e-mail message 
> and/or attachments to it are strictly prohibited. If 
> you have received this communication in error, 
> please notify us by reply e-mail or telephone and 
> immediately and permanently delete the message 
> and any attachments. Thank you
> 
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [email protected]
> For additional commands, e-mail: [email protected]
> 
                                          

Reply via email to