Skip to content

Conversation

@tarun-google
Copy link
Contributor

Brings back #34212

support and fallbacks added for AfterSynchronizedProcessingTime in RunnerV2

GitHub Actions Tests Status (on master branch)

Build python source distribution and wheels
Python tests
Java tests
Go tests

See CI.md for more information about GitHub Actions CI or the workflows README to see a list of phrases to trigger workflows.

@tarun-google tarun-google marked this pull request as ready for review September 25, 2025 16:13
@tarun-google
Copy link
Contributor Author

Run Yaml_Xlang_Direct PreCommit

@github-actions
Copy link
Contributor

Checks are failing. Will not request review until checks are succeeding. If you'd like to override that behavior, comment assign set of reviewers

@tarun-google
Copy link
Contributor Author

Run Yaml_Xlang_Direct PreCommit

@tarun-google
Copy link
Contributor Author

Run Prism_Python PreCommit 3.12

@tarun-google
Copy link
Contributor Author

Run Python_Transforms PreCommit 3.9

@tarun-google
Copy link
Contributor Author

@github-actions
Copy link
Contributor

Stopping reviewer notifications for this pull request: review requested by someone other than the bot, ceding control. If you'd like to restart, comment assign set of reviewers

Copy link
Contributor

@ahmedabu98 ahmedabu98 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@chamikaramj chamikaramj merged commit a0831e0 into apache:master Oct 2, 2025
103 of 105 checks passed
return any(t.has_ontime_pane() for t in self.triggers)

def get_continuation_trigger(self):
return Repeatedly(
Copy link
Collaborator

@shunping shunping Oct 2, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you explain why the continuation trigger of a AfterEach trigger is a repeatedly trigger? @tarun-google

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@shunping With continuation trigger concept, we are injecting a new trigger after the GroupBy window. Which gets evaluated every time there is a new pane of data released by first trigger. For example if the initial trigger is AfterProcessingTime(5), which trigger only once after 5 sec. we are adding a new trigger after GroupBy when this trigger happens, which is pass by layer. A lot of our triggers are one time.

But the point with AfterEach(condition1, condition2,..) is it is not a one time trigger. it triggers every time there is a condition met. So, if we just write the continuation trigger AfterAny() then it triggers only once. we want continuation trigger for AfterEach to trigger every time the condition is met, not once.

Reference:

  1. Java impl for AfterEach continuation trigger and its definition
  2. Definition of AfterAny

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yea, it's not an exact science. There's no real correctness criteria for continuation trigger except "don't hold up data that is already triggered". And the only reason we don't make all of them Repeatedly(Always) is for the corner case of aligned processing time where the user might be surprised if a downstream aggregation had many more outputs because it fired right away instead of waiting for everything aligned to the same processing time. TBH even then it is sort of meh.

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants