Skip to content

refactor(query-engine): execute complete native-query DAGs #743

Description

@milindsrivastava1997

Goal

Make the native query DAG the authoritative execution representation for complete native PromQL queries, not only individual native leaves.

Depends on

Scope

  • Compile complete supported native queries into one request-specific DAG.
  • Represent scalar constants and binary arithmetic in the DAG.
  • Execute each leaf through the DAG and perform label matching, timestamp alignment, and arithmetic through DAG nodes.
  • Preserve existing PromQL output-label and fallback behavior.
  • Cover the work with end-to-end tests through handle_query_promql and handle_range_query_promql, real precompute ingestion fixtures, and the PromQL compliance suite.

Non-goals

  • Planner materialization redesign or user-YAML changes.
  • Cross-query optimization.
  • Changing supported PromQL semantics.

Acceptance criteria

  • Supported scalar and vector-vector binary native queries execute through one complete DAG.
  • Instant and range results preserve existing label matching and timestamp-alignment behavior.
  • Unsupported or invalid complete DAGs fail with actionable errors rather than silently falling back.
  • Native E2E correctness and PromQL differential suites remain green.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions