0 Replies Latest reply on Feb 3, 2015 10:18 AM by chintan_jboss

    Jboss AS 5.0.1 Classloading issue

    chintan_jboss

      Hi,

       

      I am getting ClassNotFoundException for one of my applcation class while deploying MY-APPLICATION.war file.  Here is scenarios:

       

      Scenario 1: if I bundle my set of application classes in JAR (i.e. application.jar) file and put that into $SERVER_HOME/lib then WAR file deploys successfully.

       

      Scenario 2: if I put application.jar inside WEB-INF/lib, i dont see that it is loaded during deployment. I have enabled logging for classloader and it doesn't list out application.jar being loaded.

       

      I also added jboss-classloading.xml in WEB-INF with that also it doesn't load jars from WEB-INF/lib or WEB-INF/classes.

      <classloading xmlns="urn:jboss:classloading:1.0"
                    name="HIOS-MAIN-UI.war"
                    domain="HIOS-MAIN-UI.war"
                    parent-domain="DefaultDomain"
                    export-all="NON_EMPTY" 
                    import-all="true"> 
      </classloading>
      

       

      It always tries to find class in BaseClassLoader.  I am struggling a lot to resolve this issue. can some one please help?

       

      Thanks

      chintan