Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

frontend: update query pruning #10026

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Commits on Nov 29, 2024

  1. frontend: add new query pruning

    The current method of excluding/including sub query results in PromQL
    by comparing to -Inf or +Inf is no longer valid after
    prometheus/prometheus#15245
    due to comparison of native histograms to a float with < or > result
    in Jeanette's warning, not empty set.
    
    The new method uses logical AND operation to intersect the sub query with
    either a const vector() or an empty vector(). E.g.
    
    subquery and on() (vector(1)==1)
    subquery and on() (vector(-1)==1)
    
    which become:
    
    subquery
    (vector(-1)==1)
    
    Note that although in theory (vector(-1)==1) could be dropped in some
    cases, it depends on the context and out of scope for this PR.
    
    Signed-off-by: György Krajcsovits <[email protected]>
    krajorama committed Nov 29, 2024
    Configuration menu
    Copy the full SHA
    f6c554a View commit details
    Browse the repository at this point in the history