we have a client and a server. The client at some point of time, during one of the several communications with server gets exceptions: org.omg.CORBA.COMM_FAILURE: IOException: java.net.SocketException: Socket closed vmcid: 0x0 minor code: 0 completed: No at org.jacorb.orb.etf.ConnectionBase.to_COMM_FAILURE(ConnectionBase.java:143) at org.jacorb.orb.etf.StreamConnectionBase.read(StreamConnectionBase.java:109) at org.jacorb.orb.giop.GIOPConnection.getMessage(GIOPConnection.java:457) at org.jacorb.orb.giop.GIOPConnection.receiveMessages(GIOPConnection.java:517) at org.jacorb.orb.giop.MessageReceptor.doWork(MessageReceptor.java:71) at org.jacorb.util.threadpool.ConsumerTie.run(ConsumerTie.java:61) at java.lang.Thread.run(Thread.java:595) and [jacorb.giop.conn] ERROR : Failed to write GIOP message due to COMM_FAILURE org.omg.CORBA.COMM_FAILURE: IOException: java.net.SocketException: Broken pipe vmcid: 0x0 minor code: 0 completed: No at org.jacorb.orb.etf.ConnectionBase.to_COMM_FAILURE(ConnectionBase.java:143) at org.jacorb.orb.etf.StreamConnectionBase.flush(StreamConnectionBase.java:165) at org.jacorb.orb.giop.GIOPConnection.sendMessage(GIOPConnection.java:973) at org.jacorb.orb.giop.GIOPConnection.sendRequest(GIOPConnection.java:923) at org.jacorb.orb.giop.ClientConnection.sendRequest(ClientConnection.java:323) at org.jacorb.orb.giop.ClientConnection.sendRequest(ClientConnection.java:304) at org.jacorb.orb.Delegate.invoke_internal(Delegate.java:1024) at org.jacorb.orb.Delegate.invoke(Delegate.java:939) at org.omg.CORBA.portable.ObjectImpl._invoke(ObjectImpl.java:457) at org.omg.alu.oam.onebtscom.corba.services.ELEMENT_INTERFACE._ControlRegistrationStub.reRegisterAgent(Unknown Source) at com.alu.oam.onebtscom.adapterinterface.CancelRegistrationImpl.callCancelRegistrationOnNE(CancelRegistrationImpl.java:119) at com.alu.oam.onebtscom.adapterinterface.CancelRegistrationTaskQueue$WorkerThread.run(CancelRegistrationTaskQueue.java:280) [jacorb.giop.conn] ERROR : GIOP connection closed due to errors during sendMessage and this exception comes at java console of the client and is not caught in the client code even though client catches a generic exception on all server invocations. I get a brand new reference of the server from the naming service. The new instance of the server is on the IP and port, even then no further commmunication between the client and server is possible and the request processor thread executing the client code dies at the server invocation. I think that once a "Broken Pipe" happens, the socket is dead, and any further reuse by the orb is doomed to failure. As it is, once this error happens, only killing and restarting the client resolves the problem. Please help me regarding the issue. Regards, Abhishek
is this issue similar to Bug#: 708 and the same solution can be used here ?
Created attachment 366 [details] Patch to set do_close back to false before reconnecting This patch seems to help. It appears that do_close in GIOPConnection is set to true when the transport is being closed (so that other parts of the code stop waiting for it) but never set back to false when a reconnect is due.
After discussion with Andre Spiegel we believe this should be fixed now; please retest with current CVS head and reopen if still an issue (ideally supplying a runnable test case). *** This bug has been marked as a duplicate of bug 708 ***
*** Bug 880 has been marked as a duplicate of this bug. ***