0 Replies Latest reply on Jan 27, 2009 3:35 AM by Rajesh Chande

    Class Loading isolation - really works?

    Rajesh Chande Newbie

      I have following envionment:

      JBoss: 4.2.2GA
      JDK: 1.5.0_12

      I have a clustered environment with F5-Apache-JBoss working fine with @ 25 Web Applications deployed.

      When I tried deploying one new application I got the following errors.

      ###########
      2009/01/22 21:45:56 | 21:45:56,368 INFO [TomcatDeployer] deploy, ctxPath=/, warUrl=.../tmp/deploy/tmp20068ssa-exp.war/
      2009/01/22 21:45:56 | 21:45:56,688 ERROR [Digester] Digester.getParser:
      2009/01/22 21:45:56 | javax.xml.parsers.ParserConfigurationException: AElfred parser is namespace-aware
      2009/01/22 21:45:56 | at net.sf.saxon.aelfred.SAXParserFactoryImpl.newSAXParser(SAXParserFactoryImpl.java:37)
      2009/01/22 21:45:56 | at org.apache.tomcat.util.digester.Digester.getParser(Digester.java:704)
      2009/01/22 21:45:56 | at org.apache.tomcat.util.digester.Digester.getXMLReader(Digester.java:978)
      2009/01/22 21:45:56 | at org.apache.tomcat.util.digester.Digester.parse(Digester.java:1643)
      2009/01/22 21:45:56 | at org.apache.catalina.startup.TldConfig.tldScanStream(T
      
      
      2009/01/22 21:46:12 | 21:46:12,087 ERROR [TldConfig] Exception processing TLD META-INF/sql.tld in JAR at resource path /apps/jboss/4.2.2GA/server/prod-02/tmp/deploy/tmp32135ssa-exp.war/WEB-INF/lib/standard-1.0.6.jar in context
      2009/01/22 21:46:12 | java.lang.NullPointerException
      
      
      2009/01/22 21:46:17 | 21:46:17,133 ERROR [[/]] Exception starting filter struts2
       2009/01/22 21:46:17 | Unable to create SAX parser - Class: net.sf.saxon.aelfred.
       SAXParserFactoryImpl
       2009/01/22 21:46:17 | File: SAXParserFactoryImpl.java
       2009/01/22 21:46:17 | Method: newSAXParser
       2009/01/22 21:46:17 | Line: 34 - net/sf/saxon/aelfred/SAXParserFactoryImpl.java:
      34:-1
      2009/01/22 21:46:17 | at com.opensymphony.xwork2.config.providers.XmlConfigura
      tionProvider.loadConfigurationFiles(XmlConfigurationProvider.java:835)
      
      ###########


      I had to remove the saxon7.jar and standard-1.0.6.jar from the WEB-INF/lib folder of the WAR and then only the deployment worked fine.

      While setting up the JBoss initially so as to have J2EE compliance I have deploy//jbossweb-tomcat55.sar/META-INF/jboss-service.xml

      ##############
       <attribute name="Java2ClassLoadingCompliance">false</attribute> <!-- A flag indicating if the JBoss Loader should be used. This loader
       uses a unified class loader as the class loader rather than the tomcat
       specific class loader.
       The default is false to ensure that wars have isolated class loading
       for duplicate jars and jsp files.
      
      ##############


      so in this case why removing the jar files from WEB-INF/lib makes the deployment successful? ideally there should be no conflict of jar files if the above attribute is set to false?

      Please can someone explain the above why it happens so?