mirror of
https://github.com/prometheus/prometheus.git
synced 2026-05-06 04:46:13 +02:00
Address PR feedback: clarify comment
Signed-off-by: Charles Korn <charles.korn@grafana.com>
This commit is contained in:
parent
fb3935e8f9
commit
6087c555ed
@ -1839,8 +1839,9 @@ func (ev *evaluator) rangeEvalTimestampFunctionOverVectorSelector(vs *parser.Vec
|
||||
|
||||
return ev.rangeEval(nil, func(v []parser.Value, _ [][]EvalSeriesHelper, enh *EvalNodeHelper) (Vector, storage.Warnings) {
|
||||
if vs.Timestamp != nil {
|
||||
// This is a special case only for "timestamp" since the offset
|
||||
// needs to be adjusted for every point.
|
||||
// This is a special case for "timestamp()" when the @ modifier is used, to ensure that
|
||||
// we return a point for each time step in this case.
|
||||
// See https://github.com/prometheus/prometheus/issues/8433.
|
||||
vs.Offset = time.Duration(enh.Ts-*vs.Timestamp) * time.Millisecond
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user