Class BoundedHistogram
- java.lang.Object
-
- org.apache.jackrabbit.oak.index.indexer.document.flatfile.pipelined.BoundedHistogram
-
public class BoundedHistogram extends Object
A histogram that keeps a maximum number of buckets (entries). When the histogram is at the limit, it will reject new entries but keep updating the count of the existing entries. Therefore, the counts for the entries in the histogram are correct but if the histogram overflowed, it may be missing some entries.
-
-
Constructor Summary
Constructors Constructor Description BoundedHistogram(String name, int maxHistogramSize)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addEntry(String key)
ConcurrentHashMap<String,LongAdder>
getMap()
boolean
isOverflowed()
String
prettyPrint()
String
prettyPrintTopEntries(int numEntries)
-
-
-
Constructor Detail
-
BoundedHistogram
public BoundedHistogram(String name, int maxHistogramSize)
-
-