• Post Reply Bookmark Topic Watch Topic
  • New Topic

RMI Client

 
Ajit Kumar
Ranch Hand
Posts: 81
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi All,
I have written an RMI app.
- The server is running and the client is able to call methods from the server object.
- I terminated the server application.
- From the client side the error is detected and an appropriate message is displayed.
- I brought the server up.
- The client is still giving an error message.
Any ideas on how can i resume with calling rmi server object methods once the server comes up?
is restarting the client the only option?
thanks
 
asad ali
Greenhorn
Posts: 20
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
One way to handle your request is to lookup for the server again when the client receives the 'server not found error'. Your client executes the methods on the server by using the stub. When your server goes down, the stub becomes invalid. If you lookup for the server again, the client will receive a valid stub value.
 
Suneel Setlur
Ranch Hand
Posts: 202
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
As Asad said... perform a lookup again. You can create a button and on click you lookup.
Suneel
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!