File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

[RMI] question about Activation Framework

 
Jimmy Chen
Ranch Hand
Posts: 54
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
As I read through chapter 17 "Factories and the Activation Framework" in "JAVA RMI"(O'reilly), I find the author doesn't demostrate clearly how Activation deals when multiple clients requset the same server.

As previous chapters describe, the server distinguish requests from different clients use this method: getClientHost(). And we should use a
background thread to maintain and check the clients status.

So, I want to know if I still need to do so when using the Activation.
 
Nathan Pruett
Bartender
Posts: 4121
IntelliJ IDE Java Spring
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"Super Nova" -

Welcome to the JavaRanch! Please adjust your displayed name to meet the
JavaRanch Naming Policy. User names cannot be obviously fake and must constist of a first name and a last name.

You can change your user name here.

Thanks! and welcome to the JavaRanch!
 
Jimmy Chen
Ranch Hand
Posts: 54
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
changed it, is this ok?
 
Nathan Pruett
Bartender
Posts: 4121
IntelliJ IDE Java Spring
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes, your "new name" is fine thanks for the name change!

All the Activation Framework handles is the initial creation of the server. Any further method calls will be handled the same as other RMI calls, so if you need to distinguish calls from different clients and threads to keep track of their status, the Activation Framework isn't going to change this.

The only difference the Activation Framework may throw into this is if multiple clients perform the *initial* call to the server that creates it. This is the job of the RMID daemon, though, not your server class. I'd assume that the RMID daemon would be able to handle multiple client requests to initialize your server class correctly - but once those requests get into the method calls it's up to your class.
 
Jimmy Chen
Ranch Hand
Posts: 54
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you, I got it
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic