Skip to content

Close WorkerManager routing gaps for optional/unavailable segments and empty partitions #18223

@xiangfu0

Description

@xiangfu0

Motivation

pinot-query-planner/src/main/java/org/apache/pinot/query/routing/WorkerManager.java still has TODOs for several unsupported routing cases in the multi-stage engine:

  • optional segments
  • unavailable segments
  • partitions with no segments
  • workers whose assigned partitions all have no segments

These are correctness and resiliency gaps in stage assignment, especially for hybrid or partially unavailable tables.

Scope

  • Define expected routing behavior for each unsupported case.
  • Add planner and runtime tests for replicated and partitioned leaf stages.
  • Implement the missing routing and metadata handling, or fail with clearer behavior if a case must stay unsupported.

Notes

Observed on upstream/master on April 15, 2026.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething is not working as expectedjavaPull requests that update Java codemulti-stageRelated to the multi-stage query enginepriority: mediumImportant but not urgentqueryRelated to query processing

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions