I am trying to deploy two webapps through the embedded Tomcat in JBoss 4.0.2 These webapps are based on WebWork and each has it's own xwork.xml file under WEB-INF/classes. WebWork reads in these files using Thread.currentThread().getContextClassLoader()
I've looked over all the Classloader documentation including the http://wiki.jboss.org/wiki/Wiki.jsp?page=JBossClassLoadingUseCases, but no matter what I do, the second webapp still loads in the file from the first app.
In my tomcat jboss-service.xml I have
<attribute name="Java2ClassLoadingCompliance">false</attribute> <attribute name="UseJBossWebLoader">false</attribute>
<jboss-web> <class-loading java2ClassLoadingCompliance="false"> <loader-repository> app1:loader=app1.war <loader-repository-config>java2ParentDelegation=false</loader-repository-config> </loader-repository> </class-loading> <virtual-host>ext.americanprofile.com</virtual-host> </jboss-web>
I should add that whenever I use the JBoss UCL, the situation I described above happens. If I turn off the UCL, my webapp says it cannot find the "xwork.xml" file in the classpath, even though I have verified that the file exists in WEB-INF/classes