• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Connecting with a servlet to Server via RMI failing

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi.

I am relatively new to servlets and not very experienced with RMI, so I hope you can help me a little bit to get started.

I have got a server-program called Jeherazade, which is distributing some methods via RMI and is working fine. When I try to connect to the server by a command-line client-program, that's working too. But when I try to connect to the server through a servlet, that's running on the same machine as the client-program and the server-program, it's failing.

The method in the servlet is the following (the same in the client, where it's working):



This is resulting in the following exception:

ERROR: Failed to bind Jeherazade via RMI to Servlet:
java.rmi.UnmarshalException: error unmarshalling return; nested exception is:
java.lang.ClassNotFoundException: jeherazade.JeherazadeRMIImpl_Stub (no security manager: RMI class loader disabled)

I am using Tomcat 5.5 . The servlet itself and the stub JeherazadeRMIImpl_Stub.class are located in the same directory. I read on other pages, that one should try to set a SecurityManager by



But when I do that, Tomcat crashes.

In the catalina-log it says:



In the localhost-log it says:



I hope you can help me....
 
Markus Pöstinger
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am so dumb. I wrote that the Stub is located in the same directory. Of course that is totally wrong, because it has to be located in jeherazade/...Stub when being a part of package jeherazade. Now all is working fine.
reply
    Bookmark Topic Watch Topic
  • New Topic