virajjasani commented on a change in pull request #787: HBASE-23245 :
MutableHistogram constructor changes and provide Histog…
URL: https://github.com/apache/hbase/pull/787#discussion_r342911949
##########
File path:
hbase-metrics/src/test/java/org/apache/hadoop/hbase/metrics/impl/TestHistogramImpl.java
##########
@@ -63,19 +63,19 @@ public void testSnapshot() {
Snapshot snapshot = histogram.snapshot();
assertEquals(100, snapshot.getCount());
- assertEquals(50, snapshot.getMedian());
+ assertEquals(49, snapshot.getMedian());
Review comment:
getMin()=0, getMax()=99. Hence, ideally getMedian() should be 49.
All these values are changed after fixing:
https://github.com/apache/hbase/pull/787/files#diff-ac08d4adf915ba5ccb72db551e2fef34R39
(which was incorrect before because without long conversion, the value is
numeric overload and results -4)
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services