0 Replies Latest reply on Aug 27, 2006 4:43 AM by David Libke

    After clean deploy, No Classloaders Found For: is thrown

    David Libke Newbie

      After a clean server start and EAR deployment, when I request the servlet its get method call a delegate factory to get a delegate and then the delegate to get a service. The delegate object throws a ClassNotFoundException because No Classloaders Found For: class. The three classes are in the same package, which is named in the War's META-INF/MANIFEST.MF class-path.

      The following is the message on the returned page:

      HTTP Status 500 -

      type Exception report

      message

      description The server encountered an internal error () that prevented it from fulfilling this request.

      exception

      javax.servlet.ServletException: TimerMgr; doGet(); Error: Caught com.aroundtoit.common.exception.BusinessDelegateException, message = BusDelegate; getServiceObj(int); Error: Caught java.lang.ClassNotFoundException, message = No ClassLoaders found for: com.aroundtoit.delegate.TimerMgmtBDImp, cause = null, cause = null
      com.aroundtoit.web.TimerMgr.doGet(TimerMgr.java:53)
      javax.servlet.http.HttpServlet.service(HttpServlet.java:697)
      javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
      org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
      note The full stack trace of the root cause is available in the Apache Tomcat/5.5.17 logs.

      Apache Tomcat/5.5.17

      The end of the deployment log, some print statements to show the classloaders used to load the factory and delegate along with the servlet followed by the stack trace for the exception:

      03:25:53,873 INFO [ProxyFactory] Bound EJB Home 'personMgmtBean' to jndi 'ejb/personMgmt'
      03:25:53,966 INFO [ProxyFactory] Bound EJB Home 'organizationMgmtBean' to jndi 'ejb/organizationMgmt'
      03:25:53,974 INFO [EJBDeployer] Deployed: file:/Users/dlibke/Applications/jboss-4.0.4.GA/server/default/tmp/deploy/tmp22949framework.ear-contents/framework-EJBModule.jar
      03:25:54,404 INFO [TomcatDeployer] deploy, ctxPath=/framework-WebModule, warUrl=.../tmp/deploy/tmp22949framework.ear-contents/framework-WebModule-exp.war/
      03:25:56,488 INFO [EARDeployer] Started J2EE application: file:/Users/dlibke/Applications/jboss-4.0.4.GA/server/default/deploy/framework.ear
      03:26:14,147 INFO [STDOUT]

      BusDelegateFactory classloader = org.jboss.mx.loading.UnifiedClassLoader3@e662ee{ url=file:/Users/dlibke/Applications/jboss-4.0.4.GA/server/default/tmp/deploy/tmp22949framework.ear ,addedOrder=43}
      03:26:14,147 INFO [STDOUT]

      Servlet classloader = WebappClassLoader
      delegate: false
      repositories:
      /WEB-INF/classes/
      ----------> Parent Classloader:
      java.net.FactoryURLClassLoader@2e712
      03:26:14,207 INFO [STDOUT]

      BusDelegate; getServiceObj(int); Business Delegate ClassLoader = org.jboss.mx.loading.UnifiedClassLoader3@e662ee{ url=file:/Users/dlibke/Applications/jboss-4.0.4.GA/server/default/tmp/deploy/tmp22949framework.ear ,addedOrder=43}
      03:26:14,212 ERROR [STDERR] java.lang.ClassNotFoundException: No ClassLoaders found for: com.aroundtoit.delegate.TimerMgmtBDImp
      03:26:14,213 ERROR [STDERR] at org.jboss.mx.loading.LoadMgr3.beginLoadTask(LoadMgr3.java:306)
      03:26:14,215 ERROR [STDERR] at org.jboss.mx.loading.RepositoryClassLoader.loadClassImpl(RepositoryClassLoader.java:511)
      03:26:14,215 ERROR [STDERR] at org.jboss.mx.loading.RepositoryClassLoader.loadClass(RepositoryClassLoader.java:405)
      03:26:14,215 ERROR [STDERR] at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
      03:26:14,215 ERROR [STDERR] at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
      03:26:14,215 ERROR [STDERR] at java.lang.Class.forName0(Native Method)
      03:26:14,215 ERROR [STDERR] at java.lang.Class.forName(Class.java:242)
      03:26:14,215 ERROR [STDERR] at com.aroundtoit.delegate.BusDelegate.getServiceObj(BusDelegate.java:209)
      03:26:14,215 ERROR [STDERR] at com.aroundtoit.delegate.BusDelegate.getService(BusDelegate.java:100)
      03:26:14,216 ERROR [STDERR] at com.aroundtoit.web.TimerMgr.doGet(TimerMgr.java:41)
      03:26:14,216 ERROR [STDERR] at javax.servlet.http.HttpServlet.service(HttpServlet.java:697)
      03:26:14,216 ERROR [STDERR] at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
      03:26:14,216 ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
      03:26:14,216 ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      03:26:14,216 ERROR [STDERR] at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
      03:26:14,216 ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      03:26:14,216 ERROR [STDERR] at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      03:26:14,217 ERROR [STDERR] at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
      03:26:14,217 ERROR [STDERR] at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
      03:26:14,217 ERROR [STDERR] at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
      03:26:14,217 ERROR [STDERR] at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
      03:26:14,217 ERROR [STDERR] at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
      03:26:14,218 ERROR [STDERR] at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
      03:26:14,218 ERROR [STDERR] at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
      03:26:14,218 ERROR [STDERR] at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
      03:26:14,218 ERROR [STDERR] at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
      03:26:14,220 ERROR [STDERR] at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
      03:26:14,220 ERROR [STDERR] at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
      03:26:18,052 ERROR [STDERR] at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
      03:26:18,053 ERROR [STDERR] at java.lang.Thread.run(Thread.java:613)


      I am baffled, I have had ClassNotFoundExceptions due to classpath issues generally solved with the inclusion of the jars in the Manifest file. This is my first issue with a classloader not found. But to make matters worst, this code ran on JBoss 3.2.5 without this exception.

      Any help would be appreciated.

      Dave