damccorm opened a new pull request, #41228: URL: https://github.com/apache/beam/pull/41228
## Summary - Fixes a flake in `:sdks:go:test:prismValidatesRunner` (`TestTriggerAfterSynchronizedProcessingTime` failing with `expected 2 collections, but got: 3` in https://github.com/apache/beam/actions/runs/43083145592 and https://github.com/apache/beam/actions/runs/43099848241). - Previously, `TriggerAfterSynchronizedProcessingTime` in Prism had `shouldFire` return `!ts.finished` without checking whether processing time had advanced past the initial clock time (or past the previous firing time when wrapped in `TriggerRepeatedly`). - In `TestTriggerAfterSynchronizedProcessingTime` (which uses `trigger.Repeat(trigger.AfterSynchronizedProcessingTime())` without advancing `TestStream` processing time), whenever `stage.Execute` channel-split the initial 3-element `TestStream` bundle into two bundles in Docker mode, `Repeat(AfterSynchronizedProcessingTime())` fired once on each split bundle in window `[0, 10000)`, emitting 3 panes total instead of 2. - Track `afterProcessingTimeState` in `TriggerAfterSynchronizedProcessingTime` so it requires processing time to advance past the initial `TestStream` clock time (`mtime.FromTime(time.Time{})`) before firing, and advances `firingTime` to `s.emNow + 1` on `reset` when repeated. ## Test Plan - `go test ./pkg/beam/runners/prism/...` - `go test -v ./test/integration/primitives -run "TestTrigger.*"` - `./gradlew :runners:prism:java:prismLoopbackValidatesRunnerTests --tests "org.apache.beam.sdk.transforms.GroupByKeyTest*" --tests "org.apache.beam.sdk.testing.TestStreamTest"` ### Verification - Triggered `beam_PreCommit_GoPrism.yml` workflow run on branch: [`43119696481`](https://github.com/apache/beam/actions/runs/43119696481) -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
