Name: mc57594 Date: 02/28/97
I have a RMI server, and a RMI client. The client lives inside a Jeeves servlet, and
does a Naming.lookup() every time it gets invoked. This naming lookup fails if
the servlet has successfully called the RMI server before, and the server goes
down and come back up.
What is odd it that it fails twice ... then it clears up and can connect just fine.
Stack trace for both is identical:
rmi://pal-vod.corp/Database
Remote Exception(open DB): Error unmarshaling return header
java.rmi.UnmarshalException: Error unmarshaling return header
at sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:208)
at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:104)
at sun.rmi.registry.RegistryImpl_Stub.lookup(RegistryImpl_Stub.java:94)
at java.rmi.Naming.lookup(Naming.java:60)
at hippie.video.client.VideoServlet.generateText(VideoServlet.java:81)
at hippie.video.client.VideoServlet.service(VideoServlet.java:43)
at java.servlet.http.HttpServlet.service(HttpServlet.java:43)
at sun.server.http.Dispatcher.run(Dispatcher.java:216)
at java.lang.Thread.run(Thread.java)
rmi://pal-vod.corp/Database
Remote Exception(open DB): Error unmarshaling return header
java.rmi.UnmarshalException: Error unmarshaling return header
at sun.rmi.transport.StreamRemoteCall.executeCall(StreamRemoteCall.java:208)
at sun.rmi.server.UnicastRef.invoke(UnicastRef.java:104)
at sun.rmi.registry.RegistryImpl_Stub.lookup(RegistryImpl_Stub.java:94)
at java.rmi.Naming.lookup(Naming.java:60)
at hippie.video.client.VideoServlet.generateText(VideoServlet.java:81)
at hippie.video.client.VideoServlet.service(VideoServlet.java:43)
at java.servlet.http.HttpServlet.service(HttpServlet.java:43)
at sun.server.http.Dispatcher.run(Dispatcher.java:216)
at java.lang.Thread.run(Thread.java)
rmi://pal-vod.corp/Database
For this situation I either need it to restart cleanly, or to be able to have the RMI
object that the client has be useable across invocations of the server.
company - Sun Microsystems , email - ###@###.###
======================================================================
- duplicates
-
JDK-4032926 Naming.lookup() can't handle second lookups on the same url spec.
- Closed