File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -665,8 +665,9 @@ internal void OnHeartbeat(bool ifConnectedOnly)
665665
666666 // This is an "always" check - we always want to evaluate a dead connection from a non-responsive sever regardless of the need to heartbeat above
667667 var totalTimeoutThisHeartbeat = asyncTimeoutThisHeartbeat + syncTimeoutThisHeartbeat ;
668- if ( ( totalTimeoutThisHeartbeat > 0 )
669- && tmp . LastReadSecondsAgo * 1_000 > ( tmp . BridgeCouldBeNull ? . Multiplexer . AsyncTimeoutMilliseconds * 4 ) )
668+ bool deadConnectionOnAsync = asyncTimeoutThisHeartbeat > 0 && tmp . LastReadSecondsAgo * 1_000 > ( tmp . BridgeCouldBeNull ? . Multiplexer . AsyncTimeoutMilliseconds * 4 ) ;
669+ bool deadConnectionOnSync = syncTimeoutThisHeartbeat > 0 && tmp . LastReadSecondsAgo * 1_000 > ( tmp . BridgeCouldBeNull ? . Multiplexer . TimeoutMilliseconds * 4 ) ;
670+ if ( deadConnectionOnAsync || deadConnectionOnSync )
670671 {
671672 // If we've received *NOTHING* on the pipe in 4 timeouts worth of time and we're timing out commands, issue a connection failure so that we reconnect
672673 // This is meant to address the scenario we see often in Linux configs where TCP retries will happen for 15 minutes.
You can’t perform that action at this time.
0 commit comments