about socket reuse in RMI

Peter B. Kessler Peter.Kessler at Sun.COM
Fri Jun 22 11:43:47 PDT 2007

hotspot-dev at openjdk.java.net is for discussions about the
HotSpot virtual machine under the Java platform libraries.
Your question seems to be about the RMI libraries, not the
virtual machine itself.  I would suggest asking on the

     core-libs-dev at openjdk.java.net

mailing list (cc'd) whose home page


says they cover the java.rmi package.

			... peter

zhang Jackie wrote:

> hi
> socket reuse in RMI confused me much for several reasons:
> In my opionion, one socket is boud some information about server and 
> port(right?), how such  socket can be reused to communicate to another 
> server,just change the IP address and port number? Is it possible to do 
> so in user space of linux? ServerSocket is used to accept new 
> connection, one ServerSocket instance can fit the need of application, 
> why reuse is needed. What the socket reuse of RMI means?
> Some one give me such a comment:
> *RMI will reuse sockets if the socket was created by the same socket 
> factory.  So, if two remote object's socket factories that are .equal() 
> then RMI will reuse a client's socket to talk with each RMI object.  It 
> will also reuse that socket for multiple calls to those remote objects. *
> So this is not socket factory reuse ,rather than socket reuse.
> I was confused greatly, Do everyone can give me a clear explanation 
> about this topic?
> thanks for any reply!

More information about the hotspot-dev mailing list