Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Do you guys handle the scenario of RMI server down in GUI side?

 
lambertlee Li
Ranch Hand
Posts: 52
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Let's say, if I unbind the object in RMI registry, when client try to look up the same object again, he will get "NotBoundException". How you guys handle this? catch it and swallow it or display an error message? I found if I am going to display an error message in GUI side, I end up with introducing a lot of throws clause in my method or constructor declaration. That is awkward. Could anyone give tips how to handle this gracefully?

Or will sun test this scenario when server done, see if client could still get the data out?
 
Jared Cope
Ranch Hand
Posts: 243
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by kaymen ji:
Let's say, if I unbind the object in RMI registry, when client try to look up the same object again, he will get "NotBoundException". How you guys handle this?


The interface that my client application uses to talk to the RMI database is actually something that wraps the DBAccess interface. When this situation arises, the client actually sees a business exception of type "ServerException". I have an exception dialog window that I designed to show a "user" type tab with a message to indicate what has happened, and then a "technical" type tab with the full stacktrace to determine what went wrong.

I think it is best to alert the user that something has gone wrong rather than just swallow the situation.

Cheers, Jared.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic