Class NativeHistogramBuckets

java.lang.Object
io.prometheus.metrics.model.snapshots.NativeHistogramBuckets
All Implemented Interfaces:
Iterable<NativeHistogramBucket>

public class NativeHistogramBuckets extends Object implements Iterable<NativeHistogramBucket>
Immutable representation of native histogram buckets.

The bucket index defines the boundaries of the bucket, depending on the histogram's schema.

    base = 2^(2^-schema)
    lower bound = base^(index - 1)
    upper bound = base^index
  • Field Details

    • EMPTY

      public static final NativeHistogramBuckets EMPTY
    • bucketIndexes

      private final int[] bucketIndexes
    • counts

      private final long[] counts
  • Constructor Details

    • NativeHistogramBuckets

      private NativeHistogramBuckets(int[] bucketIndexes, long[] counts)
  • Method Details