1 Reply Latest reply on Jan 29, 2005 2:24 PM by starksm64

    Hot deployment problems

      We are using verions 3.2.6 with jdk 5.0.

      In our application, hot deployment simply doesn't work. We are using the exploded .war directory approach with our classes in a jar file located in the WEB-INF/lib. To initiate a hot deployment we simple touch the web.xml file.

      However, parts of system becomes unusable. The following is a typical exception we get after a hot deployment:

      Caused by: java.lang.NullPointerException
      at org.jboss.mx.loading.LoadMgr3.beginLoadTask(L oadMgr3.java:143)
      at org.jboss.mx.loading.UnifiedClassLoader3.load ClassImpl(UnifiedClassLoader3.java:186)
      at org.jboss.mx.loading.UnifiedClassLoader3.load Class(UnifiedClassLoader3.java:136)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:299)
      at java.net.FactoryURLClassLoader.loadClass(URLClassLoader.java:580)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:299)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
      at org.apache.commons.logging.impl.LogFactoryImpl$1.run(LogFactoryImpl.java:460)
      at java.security.AccessController.doPrivileged(Native Method)
      at org.apache.commons.logging.impl.LogFactoryImpl.loadClass(LogFactoryImpl.java:454)
      at org.apache.commons.logging.impl.LogFactoryImpl.getLogConstructor(LogFactoryImpl.java:406

      We're using a lot of components (jms, hibernate etc). Can you give any guidance on how to figure out this problem?

      Dino

        • 1. Re: Hot deployment problems
          starksm64

          Which means that the type system involved is not contained to the war. The NPE is the result of some layer outside of the war holding onto the previous deployments class loader. Most likely its the commons logging layer shown here. The commons logging should not be contained in the war as this is used by other components including tomcat, and it has bugs in how it caches resources and cannot be loaded through multiple class loaders.

          Read the class loading section in chap2 of the admin/devl guide to get a better understanding of the issues involved with hot deployment. The following wiki page gives a good overview as well.

          http://www.jboss.org/wiki/Wiki.jsp?page=JBossClassLoadingUseCases