OK, I have some ideas in my mind, but they are somewhat depending on your scenario, 
a. Create a geronimo service module as a customized shared lib component, it is just a jar file with a META-INF folder, which contains a geronimo-service.xml file, the content should be something like :
--->
<?xml version="1.0" encoding="UTF-8"?>
<module xmlns="http://geronimo.apache.org/xml/ns/deployment-1.2">
    <environment>
        <moduleId>
            <groupId>org.apache.geronimo</groupId>
            <artifactId>mysharedlib</artifactId>            
            <version>1.0</version>
        </moduleId>
        <hidden-classes>
            <filter>com.thoughtworks.xstream</filter>         
        </hidden-classes>
    </environment>
    <gbean name="SharedLib" class="org.apache.geronimo.system.sharedlib.SharedLib">
        <attribute name="classesDirs">var/shared/myclasses</attribute>
        <attribute name="libDirs">var/shared/mylib</attribute>
        <reference name="ServerInfo">
            <name>ServerInfo</name>
        </reference>
    </gbean>
</module>
<---
Then, places those jar files in the new folders, also change the dependency configuration in your applications. With this solution, I think JasonUtils should be able to initialize correctly. While the drawbacks are, your web application could not use the xstream classes from the shared lib either, as the filter string is configured. Removing the filter string will not make sure the xstream class is loaded from shared lib, as they are more than one parent classloader for your application.
b. You might also just configure a shared lib gbean in each your web application, with that, all the jar files will be added to your web applications classloaders, and with filter string, those xstream classes could only be loaded from web applications themselves, while the problems is that each web application will keep copies of those jar files in their own classes realm, which means they are not shareable.
Hope it helps :-) 

2011/7/13 ashwin nair <matrixnair@gmail.com>
Yes, that's what I was theorizing in my original post. The question is how do
I configure sharedlib to not load from its parent for those classes which is
already under its scope. Is there a GBEAN configuration I can apply to it?
If so I would be extremely thankful as I have spent enough time with this
already. :)

--
View this message in context: http://apache-geronimo.328035.n3.nabble.com/shared-lib-classloader-XStream-Jettison-issue-tp3150142p3164614.html
Sent from the Users mailing list archive at Nabble.com.



--
Ivan