Skip to content

feat(control-plane): migrate latest ASAPPlanner IR into the physical compiler boundary #448

Description

@zzylol

Goal

Implement the public boundary documented in docs/developer_docs/control-plane/physical-compiler.md: consume the latest ASAPPlanner selected post-ASAP workload plan and compile one cross-validated bundle containing CollectorPlan projections and BackendPlan.

Why this is separate

The backend currently pins ASAPPlanner at cb70086. A compatibility audit against latest main at c58eadf found a whole-interface migration, not a safe dependency-only bump. cargo check -p control_plane reports broad API breakage when bumped directly.

Required mapping

  • SummaryExpr::KeepPreAsap and current pre-ASAP node vocabulary
  • SummaryAgg.family with the new SketchKind { category, algorithm, params } model
  • preserve Reduction::PerEntity vs Reduction::Reduce { by: [] }
  • preserve GroupingStrategy including shared multi-subpopulation layouts
  • attach SummaryMaintenanceMode::{DirectBuild, Incremental} in deployment policy
  • insert stage-boundary SummaryMerge without changing logical semantics
  • compile matching materialization identity, window, guarantee, transmission, and readout into CollectorPlan and BackendPlan
  • reject unsupported family/capability/topology combinations; never rewrite the selected statistic

Public API acceptance

Implement the documented PlannerAdapter, PhysicalCompiler, and CompiledPlanBundle boundary (or update the documentation in the same change if upstream public names differ). Cross-plan validation must prove every collector-produced materialization has a compatible backend declaration and every query route references a declared materialization.

Tests

  • deterministic compilation and fingerprints
  • complete-workload/shared materialization preservation
  • per-entity vs empty reduction
  • per-subpopulation vs shared grouping
  • direct-build vs incremental maintenance
  • unsupported topology/capability/guarantee errors
  • collector/backend window, family, params, and identity parity
  • stale/partial publication is not activated

This issue follows the docs ownership rule: ASAPPlanner owns logical mapping; ASAPQuery-backend owns deployment-specific physical compilation.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    area: control planePlanning, configuration, routing, and control-plane orchestrationarea: physical compilerCompilation from selected logical plans to executable backend and Collector plansenhancementNew feature or requestfeature: warm summariesASAP warm-tier materialization, readiness, and servingintegration: ASAPPlannerASAPPlanner API, IR, candidate, and selected-plan integration

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions