• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How to identify client?

 
zknyy wolf
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"The unlock method simply removes the lock from the specified record. If an attempt is made to unlock a record that has not been locked by this connection, then no action is be taken."
how can I deal with it when I do it useing RMI .
Useing RMI I can not distinguish these client who has locked the record and who has not ,so when a client request unlock the record I don't know whether the record was locked by it.
in a word, I need a method to identify each client,like "client-ID".
thanks in advance.
 
Matt Ghiold
Ranch Hand
Posts: 213
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you do a search in the forums for lock and unlock you will find a trove of information about how this can be done.
Check out Peter's posts, they are very good on this subject.
 
John Smith
Ranch Hand
Posts: 2937
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Also, I found the Applying the Factory Pattern to RMI tutorial very useful. There are several approaches to identfy a client, but it seems that the most elegant way to do it is to use the object itself created by the RMI factory as an id.
Eugene.
[ January 22, 2003: Message edited by: Eugene Kononov ]
 
zknyy wolf
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Matt Ghiold and Eugene Kononov ,thank you.I try it.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic