From 8fffaa7778e75625710adc9e458e7a549c525ce9 Mon Sep 17 00:00:00 2001 From: Abhishek Singh Chouhan Date: Tue, 12 Mar 2019 11:24:57 -0700 Subject: [PATCH] HBASE-22045 Mutable range histogram reports incorrect outliers --- .../org/apache/hadoop/metrics2/lib/MutableRangeHistogram.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hbase-hadoop2-compat/src/main/java/org/apache/hadoop/metrics2/lib/MutableRangeHistogram.java b/hbase-hadoop2-compat/src/main/java/org/apache/hadoop/metrics2/lib/MutableRangeHistogram.java index 4c800c42eda..4b73087ed5a 100644 --- a/hbase-hadoop2-compat/src/main/java/org/apache/hadoop/metrics2/lib/MutableRangeHistogram.java +++ b/hbase-hadoop2-compat/src/main/java/org/apache/hadoop/metrics2/lib/MutableRangeHistogram.java @@ -81,7 +81,7 @@ public abstract class MutableRangeHistogram extends MutableHistogram implements priorRange = ranges[i]; cumNum = val; } - long val = histogram.getCount(); + long val = snapshot.getCount(); if (val - cumNum > 0) { metricsRecordBuilder.addCounter( Interns.info(name + "_" + rangeType + "_" + ranges[ranges.length - 1] + "-inf", desc),