struct
CQL::Performance::LatencyHistogram
- CQL::Performance::LatencyHistogram
- Struct
- Value
- Object
Overview
Fixed-size log-linear histogram of durations: whole microseconds below SUB_BUCKETS get a
bucket each, every power of two above splits into SUB_BUCKETS, sub-microsecond samples
land in bucket 0 and samples of RANGE or more in OVERFLOW_INDEX.
Defined in:
performance/utilities.crConstructors
Instance Method Summary
- #initialize
-
#percentile(q : Float64, count : Int64, min : Time::Span, max : Time::Span) : Time::Span
Upper bound of the bucket holding rank
ceil(q * count), clamped to min..max. -
#record(duration : Time::Span) : Nil
Counts duration in its bucket in O(1), without allocating.
-
#reset : Nil
Clears every bucket.
Constructor Detail
Instance Method Detail
def percentile(q : Float64, count : Int64, min : Time::Span, max : Time::Span) : Time::Span
#
Upper bound of the bucket holding rank ceil(q * count), clamped to min..max.
def record(duration : Time::Span) : Nil
#
Counts duration in its bucket in O(1), without allocating.