BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Do i have to use 'synchronized' for server methods?

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> JBuilder CORBA/RMI
View previous topic :: View next topic  
Author Message
Michael Justin
Guest





PostPosted: Fri Aug 20, 2004 11:14 am    Post subject: Do i have to use 'synchronized' for server methods? Reply with quote



Hello newsgroup,

in my RMI server object, i use a HashTable to manage session objects
which allow to set/get a session-ID, some 'session values' and other
things for each connected client.

Do i have to make the getSessionValue / setSessionValue methods
synchronized or does RMI synchronize the access to these server methods
somehow "automagically"?

Thanks in advance!

Mike
Back to top
Michael Justin
Guest





PostPosted: Wed Sep 08, 2004 5:07 pm    Post subject: Re: Do i have to use 'synchronized' for server methods? Reply with quote



Brenton Camac wrote:

Quote:
If multiple RPC requests arrive at the RMI server concurrently for the
same RMI object then there will be concurrent invocations on that
object.

Instead of one remote RMI object on the server which is shared by all
clients, i could create a factory method in the server which creates one
server-side RMI object for every client. So this object would be used
exclusively by the client who creates and holds a reference to it? Could
be simple to implement and use.

Michael

Back to top
Mo Tahmasebi
Guest





PostPosted: Tue Jan 04, 2005 10:06 pm    Post subject: Re: Do i have to use 'synchronized' for server methods? Reply with quote



Sorry guys but I did not get the reply to this question! Could you let me
know the answer too?

Thanks
Mo

"Michael Justin" <michael.justin (AT) postkasten (DOT) de> wrote

Quote:
Hello newsgroup,

in my RMI server object, i use a HashTable to manage session objects
which allow to set/get a session-ID, some 'session values' and other
things for each connected client.

Do i have to make the getSessionValue / setSessionValue methods
synchronized or does RMI synchronize the access to these server methods
somehow "automagically"?

Thanks in advance!

Mike



Back to top
Paul Furbacher [TeamB]
Guest





PostPosted: Fri Jan 07, 2005 4:07 am    Post subject: Re: Do i have to use 'synchronized' for server methods? Reply with quote

Mo Tahmasebi wrote:

Quote:
Sorry guys but I did not get the reply to this question! Could you
let me know the answer too?

The best thing to do is to check the archives
to see whether anyone answered the question.
If not, it could be that no one really has
a good answer.


--


Paul Furbacher (TeamB)

Save time, search the archives:
http://www.borland.com/newsgroups/ngsearch.html

Is it in Joi Ellis's Faq-O-Matic?
http://www.visi.com/~gyles19/fom-serve/cache/1.html

Finally, please send responses to the newsgroup only.
That means, do not send email directly to me.
Thank you.

Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> JBuilder CORBA/RMI All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.