Could you run the naming tests and tell me what you get?
testsuite/build.sh -Dtest=naming test
(for linux, I hope you can translate)
I was having a similar (I think) problem which Scott and others could not
reproduce. I added the InternalNamingClassReplacementUnitTestCase which
shows the problem I have in one step. Running the ejb link test twice also
demonstrates it.
Thanks
david jencks
On 2002.04.18 10:07:10 -0400 JL@esial wrote:
> Hello,
>
> I am running JBoss 3.1.0alpha(200204181002) on Win2k SP2 with jdk 1.4.
>
> I have a problem, and I do not know what it is related to, my application
> or JBoss. Let me explain:
> I have n CMP 2.x entity beans with local interfaces. For testing
> purposes, I use a stateless session bean to access those entity beans.
> This session bean itself is instanciated within a servlet.
>
> Here is the code used in the servlet init method:
>
> InitialContext jndiContext = new InitialContext();
> Object ref = jndiContext.lookup("ejb/ServiceBean");
> ServiceBeanHome home = (ServiceBeanHome) PortableRemoteObject.narrow(ref,
> ServiceBeanHome.class );
> target = home.create();
>
> My ejb-jar.xml is ok, my web.xml defines an ejb-ref which in turn is
> defined in jboss-web.xml. As a matter of fact, everything works fine on
> first deployment.
>
> The problem is that if I modify the ear file, and then redeploy it, I get
> a ClassCastException on PortableRemoteObject.narrow.
>
> I read a bug report a while ago (#516684) which was related to a problem
> looking like this one. There was a patch by David Jencks which consisted
> in using the remote interface ClassLoader to get the class descriptor
> instead of the one in the loading thread. But it does not work here, the
> problem remains.
>
> I tought it was related to my own code, but then why would it work on
> first deploy, and not after redeploy ?
>
> Could it be anything related to the ClassLoader ? Or is there anything
> else that needs to be configured inside JBoss when using servlets ?
>
> Thanks,
> Jerome.
>
>
> 2002-04-18 12:38:59,510 ERROR [STDERR] java.lang.ClassCastException
> 2002-04-18 12:38:59,510 ERROR [STDERR] at
>
>com.sun.corba.se.internal.javax.rmi.PortableRemoteObject.narrow(PortableRemoteObject.java:293)
> 2002-04-18 12:38:59,510 ERROR [STDERR] at
> javax.rmi.PortableRemoteObject.narrow(PortableRemoteObject.java:134)
> 2002-04-18 12:38:59,510 ERROR [STDERR] at
> mypackage.init(MyServlet.java:37)
> 2002-04-18 12:38:59,510 ERROR [STDERR] at
> org.mortbay.jetty.servlet.ServletHolder.getServlet(ServletHolder.java:261)
> 2002-04-18 12:38:59,510 ERROR [STDERR] at
> org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:308)
> 2002-04-18 12:38:59,510 ERROR [STDERR] at
> org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:595)
> 2002-04-18 12:38:59,510 ERROR [STDERR] at
> org.mortbay.http.HttpContext.handle(HttpContext.java:1357)
> 2002-04-18 12:38:59,510 ERROR [STDERR] at
> org.mortbay.http.HttpContext.handle(HttpContext.java:1309)
> 2002-04-18 12:38:59,510 ERROR [STDERR] at
> org.mortbay.http.HttpServer.service(HttpServer.java:744)
> 2002-04-18 12:38:59,510 ERROR [STDERR] at
> org.jboss.jetty.Jetty.service(Jetty.java:527)
> 2002-04-18 12:38:59,510 ERROR [STDERR] at
> org.mortbay.http.HttpConnection.service(HttpConnection.java:743)
> 2002-04-18 12:38:59,510 ERROR [STDERR] at
> org.mortbay.http.HttpConnection.handleNext(HttpConnection.java:916)
> 2002-04-18 12:38:59,510 ERROR [STDERR] at
> org.mortbay.http.HttpConnection.handle(HttpConnection.java:758)
> 2002-04-18 12:38:59,510 ERROR [STDERR] at
> org.mortbay.http.SocketListener.handleConnection(SocketListener.java:145)
> 2002-04-18 12:38:59,520 ERROR [STDERR] at
> org.mortbay.util.ThreadedServer.handle(ThreadedServer.java:287)
> 2002-04-18 12:38:59,520 ERROR [STDERR] at
> org.mortbay.util.ThreadPool$JobRunner.run(ThreadPool.java:715)
> 2002-04-18 12:38:59,520 ERROR [STDERR] at
> java.lang.Thread.run(Thread.java:536)
>
>
>
> * * *
>
> View thread online: http://jboss.org/forums/thread.jsp?forum=66&thread=13333
>
> _______________________________________________
> Jboss-development mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/jboss-development
>
>
_______________________________________________
Jboss-development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development