users@jax-rpc.java.net

Possible bug in JAX-RPC-implementation

From: Lars Preben S. Arnesen <l.p.arnesen_at_USIT.UIO.NO>
Date: Sun, 23 Feb 2003 12:56:06 +0100

I tried to deploy the jax-rpc hello world example with the Resin
servlet engine, but it failed with a ClassCastException. I posted a
request for help on the resin-interest list. The answeres encouraged
me to report this as a bug.




[2003/02/20 16:27:01] java.lang.ClassCastException
java.lang.ClassCastException
        at
com.sun.xml.rpc.server.http.JAXRPCContextListener.contextInitialized(JAX
RPCContextListener.java:52)
        at
com.caucho.server.http.Application.init(Application.java:1832)
        at
com.caucho.server.http.VirtualHost.startApplication(VirtualHost.java:119
2)
        at
com.caucho.server.http.VirtualHost.cron(VirtualHost.java:1340)
        at
com.caucho.server.http.ServletServer.cron(ServletServer.java:1887)
        at
com.caucho.server.http.ServletServer.handleCron(ServletServer.java:1721)
        at com.caucho.util.Cron$CronThread.evaluateCron(Cron.java:199)
        at com.caucho.util.Cron$CronThread.run(Cron.java:163)




[Scott Ferguson <ferg_at_caucho.com>]

>Greetings,
>
>
>> classLoader = (URLClassLoader) Thread.currentThread().getContextClassLoader();
>> if (classLoader == null) {
>> classLoader = (URLClassLoader) getClass().getClassLoader();
>> }
>>
Wow. That's a major Sun bug.




[Florin Herinean <fherinean_at_publity.de>]

That should be submited as a bug to Sun. The code is assuming too much about
what the classloader should be, with no checking at all ! If you run their
code into an embedded system, then you cannot make any assumptions about the
nature of the classloader.


--
Lars Preben S. Arnesen