cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Torsten Curdt <tcu...@apache.org>
Subject ParanoidClassLoader
Date Wed, 24 Nov 2004 19:02:56 GMT
Guys,

I am trying to inject a classloader into cocoon
by using the ParanoidServlet.

In the web.xml I specified the ParanoidServlet
class and passed in my ClassLoader class (not
extending ParanoidClassLoader) as parameter.
Now when Cocoon comes up I see the
following:

...
24 Nov 2004 19:42:28 - org.apache.slide.common.Domain - INFO - Namespace 
configuration complete
24 Nov 2004 19:42:28 - org.apache.slide.security.SecurityImpl - INFO - 
Action aggregations loaded successfully
19:42:28.926 EVENT  Started SocketListener on 0.0.0.0:8888
19:42:29.135 WARN!!
org.mortbay.util.MultiException[java.lang.ClassNotFoundException: 
org.apache.cocoon.servlet.ParanoidServlet]
         at org.mortbay.http.HttpServer.start(HttpServer.java:640)
         at org.mortbay.jetty.Server.main(Server.java:429)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at Loader.invokeMain(Unknown Source)
         at Loader.run(Unknown Source)
         at Loader.main(Unknown Source)
[0]=java.lang.ClassNotFoundException: 
org.apache.cocoon.servlet.ParanoidServlet
         at java.net.URLClassLoader$1.run(URLClassLoader.java:199)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.net.URLClassLoader.findClass(URLClassLoader.java:187)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:289)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:235)
         at org.mortbay.http.ContextLoader.loadClass(ContextLoader.java:207)
         at org.mortbay.http.ContextLoader.loadClass(ContextLoader.java:171)
         at org.mortbay.http.HttpContext.loadClass(HttpContext.java:1408)
         at org.mortbay.jetty.servlet.Holder.start(Holder.java:165)
         at 
org.mortbay.jetty.servlet.ServletHolder.start(ServletHolder.java:198)
         at 
org.mortbay.jetty.servlet.ServletHandler.initializeServlets(ServletHandler.java:445)
         at 
org.mortbay.jetty.servlet.WebApplicationHandler.initializeServlets(WebApplicationHandler.java:150)
         at 
org.mortbay.jetty.servlet.WebApplicationContext.start(WebApplicationContext.java:458)
         at org.mortbay.http.HttpServer.start(HttpServer.java:663)
         at org.mortbay.jetty.Server.main(Server.java:429)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at Loader.invokeMain(Unknown Source)
         at Loader.run(Unknown Source)
         at Loader.main(Unknown Source)

This looks a bit strange to me:

   protected ClassLoader getClassLoader(File contextDir) {
    ...
    return ParanoidClassLoader.newInstance(
          urls, this.getClass().getClassLoader());
   }

IIUC there is a hardcoded reference to the ParanoidClassLoader
class. Or what else could be the problem? Any idea?

cheers
--
Torsten

Mime
View raw message