internal void OnHeartbeat()
 {
     try
     {
         interactive?.OnHeartbeat(false);
         subscription?.OnHeartbeat(false);
     } catch (Exception ex)
     {
         multiplexer.OnInternalError(ex, EndPoint);
     }
 }
Пример #2
0
 void ISocketCallback.OnHeartbeat()
 {
     try
     {
         bridge.OnHeartbeat(true); // all the fun code is here
     }
     catch (Exception ex)
     {
         OnInternalError(ex);
     }
 }
Пример #3
0
 internal void OnHeartbeat()
 {
     // don't overlap operations on an endpoint
     if (Interlocked.CompareExchange(ref _heartBeatActive, 1, 0) == 0)
     {
         try
         {
             interactive?.OnHeartbeat(false);
             subscription?.OnHeartbeat(false);
         }
         catch (Exception ex)
         {
             Multiplexer.OnInternalError(ex, EndPoint);
         }
         finally
         {
             Interlocked.Exchange(ref _heartBeatActive, 0);
         }
     }
 }