I am trying to implement a Client/Server plugin combo and am recieving a NotBoundException when requesting the service through the IClientAccess object. There is not a lot of documentation on this, but I noticed in the Mail plugin that the service name is prefixed with “servoy.”
What is the proper naming convention for binding an rmi service through servoy?
sean
the best naming to use is your url in reversed order (do not use “servoy” !), example:
www.mycompanyname.com whould result in the rmi lookupname:
com.mycompanyname.MyRMIObjectName
I still haven’t been able to successfully bind an RMI service through Servoy. When starting up servoy server, I get an exception report in the terminal:
java.rmi.server.ExportException: object already exported
My plugin is a simple HelloWorld-type plugin that extends UnicastRemoteObject. I tested the client/server combo independant of Servoy and everything worked fine.
I cannot figure out how the object could already be bound. This exception is thrown when I restart the Servoy server and even when I restart the machine. As I said before, it also works fine when I bind it to 1099 myself. Any Ideas?..
Thanks,
Sean
I have no idea (do you call registerRMIService twice?), the in which way does your plugin differ from opensource mail plugin (source is in the jar file)
I noticed the MailServer plugin does not subclass UnicastRemoteObject. The test plugin that I wrote does. So I changed my plugin to only implement the interface that extends Remote and recompiled the stub and skeleton classes and it worked. RMI is pretty new to me and I don’t really know the significance of extending UnicastRemoteObject. (Maybe the object exports itself from the constructor and so the call to register it is redundant - I noticed that the constructor declares to throw a remote exception)
Thanks,
Sean