Commit be53214c authored by Marc Gravell's avatar Marc Gravell

don't include negative mbeats

parent 2631e1ed
...@@ -369,7 +369,11 @@ void add(string lk, string sk, string v) ...@@ -369,7 +369,11 @@ void add(string lk, string sk, string v)
} }
add("Last-Heartbeat", "last-heartbeat", (lastBeat == 0 ? "never" : ((unchecked(now - lastBeat) / 1000) + "s ago")) + (BridgeCouldBeNull.IsBeating ? " (mid-beat)" : "")); add("Last-Heartbeat", "last-heartbeat", (lastBeat == 0 ? "never" : ((unchecked(now - lastBeat) / 1000) + "s ago")) + (BridgeCouldBeNull.IsBeating ? " (mid-beat)" : ""));
add("Last-Multiplexer-Heartbeat", "last-mbeat", bridge.Multiplexer.LastHeartbeatSecondsAgo + "s ago"); var mbeat = bridge.Multiplexer.LastHeartbeatSecondsAgo;
if (mbeat >= 0)
{
add("Last-Multiplexer-Heartbeat", "last-mbeat", mbeat + "s ago");
}
add("Last-Global-Heartbeat", "global", ConnectionMultiplexer.LastGlobalHeartbeatSecondsAgo + "s ago"); add("Last-Global-Heartbeat", "global", ConnectionMultiplexer.LastGlobalHeartbeatSecondsAgo + "s ago");
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment