Toggle Current Issue
ID: 1364 Reporter: tero.katajainen
Status:
New New
Resolution:
unresolved
Category: Orion Reported Version: 2.0.7
Last seen Version: 2.0.7 Fixed Version:
Platform: PC OS: Linux
Java version: 1.5 Severity: major
Visibility: Public Public
Summary: RMI Context not closing sockets
Description: I am using the com.evermind.server.rmi.RMIInitialContextFactory with dedicated.connection=true to access EJBs running on another server. For some reason the RMI connection sometimes hangs when the EJB server runs a call taking a long time. I've tried to get around this by closing the Context, this only works partially:

When the RMIInitialContextFactory gives a Context and this is closed, the underlying socket is not closed and I can see a TCP connection in ESTABLISHED state, which doesn't go away before I shut down the server or client. This repeats for each context that is closed. Eventually the system runs out of sockets.

How to repeat: Open a RMI Context with dedicated.connection=true to a remote Orion server and close the context. Use netstat to see the hanging connections.

Suggested fix: close the socket when calling context.close();



Collapse Public tero.katajainen 20070319 02:39:46
Modification: Issue created