Skip to content

feat(precompute): separate idle and deadline closure - #484

Closed
zzylol wants to merge 1 commit into
fix/precompute-watermark-separationfrom
feat/precompute-window-close-policy
Closed

zzylol wants to merge 1 commit into
fix/precompute-watermark-separationfrom
feat/precompute-window-close-policy

Conversation

@zzylol

@zzylol zzylol commented Sep 3, 2026

Copy link
Copy Markdown
Contributor

Why

An idle timeout and an absolute freshness deadline are different policies. PR #480 represented both with one last-touch timestamp, so continuously active fixed-timestamp input could remain open indefinitely.

Before this PR

A pane tracked only its latest wall-clock touch. The single wall_clock_grace_period_ms setting implemented idle closure and could not bound the lifetime of an active pane.

After this PR

  • Track each pane first-touch and last-touch wall-clock times together.
  • Rename the idle setting to wall_clock_idle_grace_period_ms; accept the old YAML name as a compatibility alias.
  • Add the independent wall_clock_max_open_grace_period_ms absolute deadline.
  • Keep the absolute deadline disabled by default until the follow-up guarantees correction forwarding.
  • Advance only the closure watermark when either wall-clock policy fires.

For a one-second window with 5-second grace, idle closure fires six seconds after the latest touch, while the optional absolute deadline fires six seconds after the first touch even if the pane remains active.

Verification

  • cargo fmt -p data_plane -- --check
  • cargo test -p data_plane precompute_engine:: -- --nocapture (262 passed)

Includes regression coverage for the absolute deadline and legacy configuration deserialization.

Stacked on #483; retarget to main after #483 merges.

@zzylol
zzylol deleted the branch fix/precompute-watermark-separation September 3, 2026 18:30
@zzylol zzylol closed this Sep 3, 2026
@zzylol
zzylol deleted the feat/precompute-window-close-policy branch September 12, 2026 14:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant