I have doubt on Weblogic classloading and request your help.
I understood or otherwise from a web link on classloading that ewvery application has its own classloaders.
My EAR contains 4 WARS. Each war has a web-inf\lib and has libraries that are present in other web-in\lib too. Some of the libraries are also present in weblogic. I am at the moment playing with weblogic-application.xml and trying my hand on using <classloader-structure> tag.
My doubts are :
Is it okay to have the same libraries in different web-inf\lib?
Is <module-uri> referred in weblogic-application.xml same as <web-uri> specified in application.xml ?
I don't have the <classloader-structure> at the moment, but getting classcastexception. Wouldn't weblogic load either application libraries or weblogic's and sort the preference by itself?
The Exception is
Caused By: java.lang.ClassCastException: weblogic.xml.jaxp.RegistryDocumentBuilderFactory cannot be cast to javax.xml.parsers.DocumentBuilderFactory
The problem I faced and solved is listed in another topic "HqlToken and antlr". One of the suggestion was to use <classloader-structure>. So I spawned a new topic on this.
My thought was to load anite-stp-web.war and then any other wars. The expectation is there is one xmlparserapi.jar inside each of my web-inf\lib that contains javax.xml classes. I felt weblogic got confused with the javax.xml of its own libraries. The above solution is to come out of that problem.
One experiement I did was to remove the xmlParserAPIs-2.0.2.jar from my package, thereby relying on weblogic's parsers. That might have solved this particular problem and I got log4j classcastexception. When I applied the same prcedure, i recieved slf4j classcastexception. The same solution for slf4j did not work. After that there was a dead end. So I undid this experiment of using weblogic's libraries, and preferred to apply the solution suggested in 'HqlToken and antlr'. Does this give you an idea or way out please?