Expand description
Propagation of label matchers between the operands of a PromQL binary expression.
ConstantsΒ§
- LABEL_
PRESERVING_ πRANGE_ FUNCTIONS - Rollup functions emitting at most one output series per input series, carrying the labels of
the matrix selector they wrap.
absent_over_timeis excluded: it synthesizes a series from the matchers when its input has none. - MATCH_
ALL_ πREGEX super::PromPlanner::matchers_to_expremits no filter for this, so copying it would only force a re-plan.
FunctionsΒ§
- has_
unique_ πaggregate_ output - Whether a partitioning aggregate proves the operand emits at most one series per combination of its output labels; ranking narrows its input, so it inherits the proof. Uniqueness per match signature additionally requires every output label to be a matching label, which the caller checks.
- matches_
every_ πvalue - partitions_
by_ πgrouping_ labels - Aggregations partitioning their input by the grouping labels, so that dropping input series by a grouping label drops exactly the matching output series and leaves the remaining aggregated values untouched.
- preserves_
filter π - Whether adding a matcher on
labelto the scanselector_matchersfinds leaves the operandβs output equal to the subset of its unfiltered output that satisfies the matcher. A filter may cross an aggregate only when it removes whole groups: in particular, a label retained by topk is not necessarily one of its partitioning labels. - propagate π
- Copies label matchers from one operand of
binaryto the other, so both scans discard non-joining series instead of the join. - ranks_
by_ πgrouping_ labels - Ranking operators supported by the planner; limitk and limit_ratio are not implemented.
- selector_
matchers π - Finds the scanned selector through label-preserving operations. Aggregate partitioning is checked separately for each propagated label.
- single_
matrix_ πargument - try_
propagate π Errcarries why the rewrite does not apply, forpropagateto log.- vector_
operand_ πis_ lhs