Posted By:
Anonymous
Posted On:
Thursday, December 11, 2008 11:45 AM
Hi, I'm using this code to launch a rmi server but if I don't connect a client in the first minute, it shutdowns. I looked for the property to set this timeout time but didn't found it. Thx in advance for any help regarding this problem :) public static void main(String args[]) { if (System.getSecurityManager() == null) { System.setSecurityManager(new SecurityManager()); } try { ProxyImpl obj = new ProxyImpl(); Proxy stub = (Proxy) UnicastRemoteObject.exportObject(obj, 0); // Bind the remote object's stub in the registry Registry registry = LocateRegistry.createRegistry(2001); registry.rebind("Serveur", stub);
More>>
Hi,
I'm using this code to launch a rmi server but if I don't connect a client in the first minute, it shutdowns.
I looked for the property to set this timeout time but didn't found it.
Thx in advance for any help regarding this problem :)
public static void main(String args[]) {
if (System.getSecurityManager() == null) {
System.setSecurityManager(new SecurityManager());
}
try {
ProxyImpl obj = new ProxyImpl();
Proxy stub = (Proxy) UnicastRemoteObject.exportObject(obj, 0);
// Bind the remote object's stub in the registry
Registry registry = LocateRegistry.createRegistry(2001);
registry.rebind("Serveur", stub);
System.err.println("Server ready");
} catch (Exception e) {
System.err.println("Server exception: " + e.toString());
e.printStackTrace();
}
}
<<Less