HI could anyone tell me if the instance variables of remote objecte in (rmi) thread safe ie if 2 cleints symultaneously invoke a method of the object will the requests be queued or will they be threaded ??
Mark Savory
Ranch Hand
Joined: Feb 08, 2001
Posts: 122
posted
0
What type of remote object are you talking about? session ejb, entity ejb, CORBA object, rmi object..?
Brett Spell
Ranch Hand
Joined: Feb 24, 2001
Posts: 54
posted
0
Jamshed, Here's a link to the relevant section of the RMI specification: http://java.sun.com/j2se/1.3/docs/guide/rmi/spec/rmi-arch3.html Basically what it says is that multiple calls may or may not execute in a single thread, and that you're responsible for ensuring the thread safety of your code. So in other words, no, accessing instance variables within a method called remotely is not inherently thread-safe. ------------------ Brett Spell Author, Professional Java Programming