< Previous by Date Date Index Next by Date >
< Previous in Thread Thread Index  

Re: [reSIProcate-users] How to detect TCP connection failure


Without the pong timeout, the on going receive on the TCP socket should eventually produce a socket error - sometimes up to 2 min after the last send attempt on the socket.  Keepalives help here to ensure we are constantly sending something.

If you need faster detection via the Keepalive Pong logic, then the other side must conform to RFC5626 and send a keepalive pong when it receives the ping.  This behaviour is enabled in resip only when RFC5626 (outbound) support is fully turned on.   More info on this is here:  http://www.resiprocate.org/DUM_Client_Outbound_Support

You do not need to call KeepAliveManager add.  This is called by DUM when you create a registration or a dialog to a destination (as long as the keepliave manager is enabled).

Scott

On Thu, Jan 28, 2016 at 11:59 AM, Jorge Bustamante <jbustamante@xxxxxxxxxxxxx> wrote:
Hi guys,

How can resiprocate detect open TCP connections that fail (e.g. network outage) and close connection (e.g. generate ConnectionTerminated event) accordingly?

I looked into KeepAliveManager, but somehow the KeepAliveTimeoutPong is never triggered. I have looked into KeepAliveManager.cxx and I blame it on supportsOutbound being false, but I don't see a way to set it to true, as the corresponding propagated value ffrom NetworkAssociation update(...) seem to always set it to false. 

Do I have to call KeepAliveManager::add(...) from application on every connection manually or there is some other way?

Regards,
Jorge Bustamante


This email is intended solely for the person or entity to which it is addressed and may contain confidential and/or privileged information. If you are not the intended recipient and have received this email in error, please notify BroadSoft, Inc. immediately by replying to this message, and destroy all copies of this message, along with any attachment, prior to reading, distributing or copying it.

_______________________________________________
resiprocate-users mailing list
resiprocate-users@xxxxxxxxxxxxxxx
List Archive: http://list.resiprocate.org/archive/resiprocate-users/