[jacorb-developer] JACORB CORBA call did not timeout when made on TAO server that was just initializing

Nick Cross jacorb at goots.org
Wed Apr 9 10:27:39 CEST 2014


I don't know hence asking ;-)

Thanks

On 09/04/14 02:12, Alka Nand wrote:
> Nick,
>
> Thanks for the reply. I will try but the problem is that it does not
> happen easily. This was the first time we had this problem. Do you think
> this issue has been fixed in the newer version?
>
> Thanks
> alka
>
>
> On Tue, Apr 8, 2014 at 5:35 PM, Nick Cross <jacorb at goots.org
> <mailto:jacorb at goots.org>> wrote:
>
>
>     Can you reproduce the problem with the current version and submit a
>     test case please?
>
>     Thanks
>
>     Nick
>
>
>     On 08/04/14 16:03, Alka Nand wrote:
>
>         I am running JACORB 3.0 and my jacorb client pings the TAO
>         server every
>         4 minutes. This particular "narrow" may have coincided with a
>         restart of
>         the TAO server in which it may not have properly initialized.
>         The TAO
>         server finished initializing and seemed to be in a good state
>         but the
>         call did not timeout. The thread was stuck on that call. I then
>         reset
>         the TAO server and that caused the call to finally bail out with a
>            COMM_FAILURE. I am also copying the code I have for setting
>         up the
>         timeout. I have the timeout set for 1 minute.
>
>         Any help is very much appreciate
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err: 2014-04-07
>         16:55:32.577 SEVERE Failed to write GIOP message due to
>         COMM_FAILURE, in
>         ClientGIOPConnection to 172.28.xx.xx:1632 (19181ae)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err:
>         org.jacorb.orb.etf.__ConnectionBase.to_COMM___FAILURE(ConnectionBase.java:__152)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err:
>         org.jacorb.orb.iiop.__IIOPConnection.__handleCommFailure(__IIOPConnection.java:79)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err:
>         org.jacorb.orb.etf.__StreamConnectionBase.flush(__StreamConnectionBase.java:228)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err:
>         org.jacorb.orb.giop.__GIOPConnection.sendMessage(__GIOPConnection.java:1062)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err:
>         org.jacorb.orb.giop.__GIOPConnection.sendRequest(__GIOPConnection.java:988)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err:
>         org.jacorb.orb.giop.__ClientConnection.sendRequest(__ClientConnection.java:309)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err:
>         org.jacorb.orb.giop.__ClientConnection.sendRequest(__ClientConnection.java:290)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err:
>         org.jacorb.orb.Delegate.___invoke_internal(Delegate.java:__1327)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err:
>         org.jacorb.orb.Delegate.__invoke_internal(Delegate.java:__1152)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err:
>         org.jacorb.orb.Delegate.__invoke(Delegate.java:1140)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err:
>         org.jacorb.orb.Delegate.__invokeBuiltin(Delegate.java:__2031)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err:
>         org.jacorb.orb.Delegate.is_a(__Delegate.java:1894)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err:
>         org.omg.CORBA.portable.__ObjectImpl._is_a(ObjectImpl.__java:130)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err:
>         com.tellabs.ems.sb_if.emsne.__SessionMgr.NESessionFactory___IHelper.narrow(NESessionFact
>
>         ory_IHelper.java:59)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err:
>         com.tellabs.ems.idlneadapter.__EMSSession.establishSession(__EMSSession.java:840)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err:
>         com.tellabs.ems.idlneadapter.__IPTVNEMonitorThread.monitorNE(__IPTVNEMonitorThread.java:
>
>         298)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err:
>         com.tellabs.ems.idlneadapter.__IPTVNEMonitorThread.run(__IPTVNEMonitorThread.java:134)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err:
>         java.lang.Thread.run(Thread.__java:724)
>
>         Thread-72;Mon Apr 07 16:55:32 CDT 2014;System.err: 2014-04-07
>         16:55:32.596 SEVERE Underlying transport connection closed due
>         to errors
>         during sendMessage(), in ClientGIOPConnection to
>         172.28.xx.xx:1632 (19181ae)
>
>
>
>         Code to set Timeout
>
>
>                                   long relativeExpiry = 60L * 10000000L;
>         //60
>         seconds, 1 min
>
>                   //objref =
>         _myORB.string_to_object("__corbaloc:ssliop:1.2 at 172.28.xx.__xx:1632/NESessionFactory");
>
>         tempObjref = _myORB.string_to_object("__corbaloc:ssliop:1.2@"
>         +_ipAdd+":"
>         +  _port + "/NESessionFactory");
>
>                          //Set RelativeRoundtripTimeoutPolicy
>
>                          objref = setTimeoutPolicy(tempObjref,
>         relativeExpiry);
>
>                          neSessionFactory =
>         NESessionFactory_IHelper.__narrow(objref);
>
>
>
>
>               private org.omg.CORBA.Object
>         setTimeoutPolicy(org.omg.__CORBA.Object
>         objref, long relativeExpiry)
>
>               {
>
>                   //Set RelativeRoundtripTimeoutPolicy
>
>                   //This policy specifies how much time is allowed to
>         deliver a
>         request and its reply.
>
>                   //This value is set in 100 nanosecond units. It does
>         not have a
>         default value.
>
>                   //If it is not set, a request has unlimited time to
>         complete.
>
>         //1 millisec =(10000 units) since 1 unit is 100 ns
>
>         //1 sec =  1000 * 10000 = 1000 millisec
>
>         //Policy p = new
>         org.jacorb.orb.policies.__RelativeRoundtripTimeoutPolicy__(1000
>         * 10000);
>
>                   JDiagnostic.log("__setTimeoutPolicy:: Timeout = " +
>         relativeExpiry);
>
>                   org.omg.CORBA.Object newObjref = null;
>
>                   try
>
>                   {
>
>                     Any relativeRoundtripTimeoutValue = _myORB.create_any();
>
>                     TimeTHelper.insert(__relativeRoundtripTimeoutValue,
>         relativeExpiry);
>
>                     Policy[] policies = new Policy[1];
>
>                     policies[0] =
>         _myORB.create_policy(RELATIVE___RT_TIMEOUT_POLICY_TYPE.value,
>         relativeRoundtripTimeoutValue)__;
>
>                     newObjref = objref._set_policy_override(__policies,
>         SetOverrideType.ADD_OVERRIDE);
>
>                   }
>
>                   catch(UserException ex)
>
>                   {
>
>                     //Catch InvalidPolicies, SystemException and PolicyError
>
>                     traceException("run() FAIL\t setting
>         RELATIVE_RT_TIMEOUT_POLICY___TYPE policy override on neSession
>         Object: " +
>         ex);
>
>                     ex.printStackTrace();
>
>                     //Cannot throw an Exception so just Continue....
>
>                   }
>
>                   catch(Exception ex)
>
>                   {
>
>                     //Catch InvalidPolicies, SystemException and PolicyError
>
>                     traceException("run()General Exception FAIL\t setting
>         RELATIVE_RT_TIMEOUT_POLICY___TYPE policy override on neSession
>         Object:" + ex);
>
>                     ex.printStackTrace();
>
>                     //Cannot throw an Exception so just Continue....
>
>                   }
>
>                   return newObjref;
>
>               }
>
>
>         Thanks
>
>         alka nand
>
>         Staff Engineer
>
>         Tellabs
>
>
>         --
>
>
>
>
>
> --
>
> alka
>



More information about the jacorb-developer mailing list