mirror of
https://github.com/prometheus/prometheus.git
synced 2026-05-05 04:16:15 +02:00
promql: Expose bug of not checking 1st histogram for CRH
avg_over_time already correctly checked the counter reset hint fo all histograms, but in sum_over_time, the 1st histogram was missed in the loop. This commit exposes the bug in a test. Signed-off-by: beorn7 <beorn@grafana.com>
This commit is contained in:
parent
edbc5cfa06
commit
ff49406cba
@ -1709,6 +1709,18 @@ eval instant at 14m histogram_count(avg_over_time(mixed[10m]))
|
||||
expect no_info
|
||||
{} 9.3
|
||||
|
||||
# In the following two tests, the first sample has hint "not_reset"
|
||||
# and the second has "reset". This tests if the conflict is detected
|
||||
# between the first two samples, too.
|
||||
eval instant at 11m histogram_count(sum_over_time(mixed[2m]))
|
||||
expect warn msg:PromQL warning: conflicting counter resets during histogram aggregation
|
||||
expect no_info
|
||||
{} 21
|
||||
|
||||
eval instant at 11m histogram_count(avg_over_time(mixed[2m]))
|
||||
expect warn msg:PromQL warning: conflicting counter resets during histogram aggregation
|
||||
expect no_info
|
||||
{} 10.5
|
||||
|
||||
# Test histogram_quantile annotations.
|
||||
load 1m
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user