Skip to content

Carry operator cache-reuse status to the frontend #5883

Closed

Description

@Xiao-zhen-Liu

Task Summary

Part of #5881 (design: #5880).

Carry whether an operator's results were reused from the cache to the frontend. A reused operator reports COMPLETED like any other finished operator: every place that checks operator state treats the two the same way, so no new state is added (settled in #5880). Reuse travels as one extra flag next to the metrics. Nothing sets the flag yet (the scheduler task #5884 does), so this changes no behavior on its own.

Scope

  • A reused_from_cache boolean on OperatorMetrics, false by default.
  • A logical operator counts as reused only when all of its physical operators are. A partially reused operator, such as a HashJoin whose build side is reused while its probe side runs, reports false; the per-port detail comes from the cache entries.
  • The operator statistics websocket event and the frontend OperatorStatistics type carry the flag.

Why this is safe. The flag is false unless something sets it, and nothing does yet, so every operator reports exactly what it reports today. Operator states are unchanged.

Notes. The flag is in a .proto file; generated protobuf code is not committed, so the change ships the .proto edit only.

Depends on. None.

Out of scope. Setting the flag, and the statistics of a region that did not run (#5884). Showing reuse in the UI (#5886).

Task Type

  • Refactor / Cleanup
  • DevOps / Deployment / CI
  • Testing / QA
  • Documentation
  • Performance
  • Other

Activity

  1. changed the title [-][Cache PR 2] Cache state and statistics handling[/-] [+]Add a completed-from-cache operator state and cached-region statistics handling[/+] on Jun 24, 2026
  2. changed the issue type fromtoon Jun 24, 2026
  3. changed the title [-]Add a completed-from-cache operator state and cached-region statistics handling[/-] [+]Carry operator cache-reuse status to the frontend and handle cached-region statistics[/+] on Aug 12, 2026
  4. changed the title [-]Carry operator cache-reuse status to the frontend and handle cached-region statistics[/-] [+]Carry operator cache-reuse status to the frontend[/+] on Sep 14, 2026
  5. added a commit that references this issue on Sep 21, 2026
    43f2649
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions