This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

SCJD RMI Query

 
Marcelo Ortega
Ranch Hand
Posts: 528
Eclipse IDE Hibernate Java
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
A client gets a reference (a handle) to a remote object via the method Name.lookup().
But how can that remote object (server) obtain a reference to the client which invoked one of its methods?

Best regards,
Marzo.
 
David George
Greenhorn
Posts: 10
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I think can not.The server can not invoke the client's method - on my opinion.
 
Andrew Monkhouse
author and jackaroo
Marshal Commander
Pie
Posts: 11833
181
C++ Firefox Browser IntelliJ IDE Java Mac Oracle
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Marzo,

What are you trying to achieve here?

You can find out the IP address of the client, however if there is more than one client at that particular address then the information cannot be used to uniquely identify the client.

You can create your own unique identifiers for each client (that wont mean anything to the client - they will just mean something to you).

You can also have the clients register themselves as observers of your server, in which case you could have the server call client methods.

But these are all very different issues, so more information on what you are trying to achieve is needed .

Regards, Andrew
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic