• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Small Question on UnicastRemoteObject

 
Amit Bathla
Ranch Hand
Posts: 51
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In context of RMI
The static method UnicastRemoteObject.exportObject exports the supplied remote object to receive incoming remote method invocations on an anonymous TCP port and returns the stub for the remote object to pass to clients. As a result of the exportObject call, the runtime may begin to listen on a new server socket or may use a shared server socket to accept incoming remote calls for the remote object.


Could anyone please tell me the the meaning of Shared here ?

Regards
Amit
 
Nitesh Kant
Bartender
Posts: 1638
IntelliJ IDE Java MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
This simply means that the RMI runtime may choose to have a single server socket (essentially the port) to receive requests for multiple exported object.
At runtime, since both the stubs on client and server side are RMI specific, so RMI can safely pass information as to whether the socket is shared and if shared, which server object does a request must go.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic