From 5e64f501dbbb151ca8d92b9f35ffe0b7b8a9805f Mon Sep 17 00:00:00 2001 From: Andrew Choi Date: Fri, 3 Jul 2020 13:36:10 -0700 Subject: [PATCH] =?UTF-8?q?Avoid=20NaN=20in=20Commit=20Offset=20Failure=20?= =?UTF-8?q?Rate=20OffsetCommitServiceMetrics=20by=E2=80=A6=20(#292)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Avoid NaN in Commit Offset Failure Rate OffsetCommitServiceMetrics by initializing with a zero only when instantiating. Signed-off-by: Andrew Choi ❄️ --- .../monitor/services/metrics/OffsetCommitServiceMetrics.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/main/java/com/linkedin/xinfra/monitor/services/metrics/OffsetCommitServiceMetrics.java b/src/main/java/com/linkedin/xinfra/monitor/services/metrics/OffsetCommitServiceMetrics.java index 3e4ca58d..1fad2177 100644 --- a/src/main/java/com/linkedin/xinfra/monitor/services/metrics/OffsetCommitServiceMetrics.java +++ b/src/main/java/com/linkedin/xinfra/monitor/services/metrics/OffsetCommitServiceMetrics.java @@ -51,6 +51,8 @@ public OffsetCommitServiceMetrics(final Metrics metrics, final Map