The PostCommit Java PVR Flink Batch job is flaky
The PostCommit Java PVR Flink Batch is failing over 50% of the time. Please visit https://github.com/apache/beam/actions/workflows/beam_PostCommit_Java_PVR_Flink_Batch.yml?query=is%3Afailure+branch%3Amaster to see all failed workflow runs. See also Grafana statistics: http://metrics.beam.apache.org/d/CTYdoxP4z/ga-post-commits-status?orgId=1&viewPanel=5&var-Workflow=PostCommit%20Java%20PVR%20Flink%20Batch
I investigated the flaky failure and found it is consistently associated with ParDoTest$StateTests.testSideInputNotReadyTimer, which was recently introduced as part of the side-inputs-in-timers work. The test relies on a delayed side input (Thread.sleep) and has already been excluded from Spark runners because side inputs in timers are not supported there.
I'm currently checking whether this is a Flink runner limitation, a runner bug, or test flakiness before proposing a fix.
Cause: #38363
#40324 set beam.test.parallelThreads=8 and Flink portable VR picked it also, so we now run up to 8 tests in one JVM with a 4g heap so each test starts a job server and loads jars which can OOM or hang for 20 mins so ViewTest is probably just the one that was running when that happened and spark already limits this to 1 thread @Abacn @reuvenlax