Read only archive ; use https://github.com/JacORB/JacORB/issues for new issues
Bug 1018 - JacORB hangs in endless connection retry loop
Summary: JacORB hangs in endless connection retry loop
Status: RESOLVED FIXED
Alias: None
Product: JacORB
Classification: Unclassified
Component: ORB (show other bugs)
Version: 3.6.1
Hardware: PC Windows NT
: P5 critical
Assignee: Phil Mesnier
URL:
Depends on:
Blocks:
 
Reported: 2015-08-28 10:24 UTC by FrVaBe
Modified: 2015-10-22 04:25 UTC (History)
1 user (show)

See Also:


Attachments
jacorb debug logfile (116.24 KB, text/plain)
2015-08-28 10:24 UTC, FrVaBe
Details

Note You need to log in before you can comment on or make changes to this bug.
Description FrVaBe 2015-08-28 10:24:47 UTC
Created attachment 469 [details]
jacorb debug logfile

We try to connect to a not responding corba service using JacORB 3.6.1. We set the properties jacorb.retries and jacorb.connection.client.pending_reply_timeout and hoped to get a failure after the number of specified retries.
Instead it seems that JacORB is ending in an endless loop, trying to connect to the service
 
(1) connect to nameservice (success)
(2) connect to corba service (timeout failure); retry
(3) goto (1) - we did not expect this
 
We use JacORB together with Apache CXF to establish the connection. The address we use there (in the JaxWsProxyFactoryBean) is something like "corbaname::<NameService>:<NameServicePort>#<ServiceName>". Meanwhile we used the "Ultra Corba Simulator" to connect to the service and the behaviour is as expected (exception after unsuccessful retries). 

When we use the SUN ORB we get an Exception as expected (even when using Apache CXF)

Jun 25, 2015 9:07:12 PM com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl <init>
WARNUNG: "IOP00410201: (COMM_FAILURE) Connection failure: socketType: IIOP_CLEAR_TEXT; hostname: <server>; port: <port>"
org.omg.CORBA.COMM_FAILURE:   vmcid: SUN  minor code: 201  completed: No
       at com.sun.corba.se.impl.logging.ORBUtilSystemException.connectFailure(ORBUtilSystemException.java:2200)
       at com.sun.corba.se.impl.logging.ORBUtilSystemException.connectFailure(ORBUtilSystemException.java:2221)
       at com.sun.corba.se.impl.transport.SocketOrChannelConnectionImpl.<init>(SocketOrChannelConnectionImpl.java:223)

Hint: In a private email conversation (after I reported the bug to the mailing list - http://lists.spline.inf.fu-berlin.de/pipermail/jacorb-developer/2015-June/000711.html) Nick Cross narrowed the problem to:

> Thanks for the log. As Phil and I suspected it is entering the
> getParsedIOR().useCorbaName() and looping continuously in there.
> 
> Phil is also taking a look at a related case so we will try to come up
> with a solution.
Comment 1 Phil Mesnier 2015-10-07 18:45:39 UTC
There is a second case to this problem, when some other service, such as the IMR throws a FORWARD_REQUEST that contains an unreachable target address.
Comment 2 Phil Mesnier 2015-10-22 04:25:25 UTC
Fixed by commit b1c67af0d4efb973e76aa2dcbce593b4eecef3d9