You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
KeepAliveStopped m_keepAliveInterval factor has been removed in Session.cs #2859
In 'KeepAliveStopped' the
keep alive time out has been change from return (m_keepAliveInterval * 2) * TimeSpan.TicksPerMillisecond <= delta;
to return (m_keepAliveInterval + kKeepAliveGuardBand) <= delta.TotalMilliseconds;
The factor '2' is missing in the new version. My Client application checks the 'KeepAliveStopped' function (getter) and detect the Keep alive has stopped only because my response is slightly longer than 6 seconds (default alive timer 5 sec + Guard band 1 sec). Before the value would be 5 sec * 2 = 1= sec. Why has this factor been removed? And replace with a constant of only 1 sec (private const int kKeepAliveGuardBand = 1000;) ?
The comment for this has also not been adjusted: /// <summary> /// Returns true if the session is not receiving keep alives. /// </summary> /// <remarks> /// Set to true if the server does not respond for 2 times the KeepAliveInterval. /// Set to false is communication recovers. /// </remarks>
I have not yet encountered problems due to this change, but from looking at it, I find it risky. As a minimum, I would prefer to see settable properties for the factor and for the offset, so that they can be changed programmatically.
Activity
mregen commentedon Nov 28, 2024
@AndreDrubig the factor has been removed to improve the response time for the session reconnect handler.
OPCLabs commentedon Nov 28, 2024
I have not yet encountered problems due to this change, but from looking at it, I find it risky. As a minimum, I would prefer to see settable properties for the factor and for the offset, so that they can be changed programmatically.
AndreDrubig commentedon Dec 3, 2024
@mregen Will you than still adjust the comment according to the new functionality?