Repository navigation
Commit df5c833
[SPARK-56565][CONNECT][TESTS] Retry flaky python foreachBatch termination test
### What changes were proposed in this pull request?
This PR un-skips the Connect parity test `test_streaming_foreach_batch_graceful_stop` and applies the retry-timeout infrastructure introduced in SPARK-52843 (`eventually` and `timeout`). Additionally, it replaces the py4j-specific `_jvm.java.lang.Thread.sleep()` call with standard Python `time.sleep()`.
### Why are the changes needed?
This resolves [SPARK-56565](https://issues.apache.org/jira/browse/SPARK-56565). The test for `foreachBatch` graceful stop was previously skipped for Connect because it inherently relied on Py4J's pinned thread execution model and caused flaky timeout behaviors. With the new retry infrastructure, we can safely re-enable it for the Connect module.
### Does this PR introduce _any_ user-facing change?
No.
### How was this patch tested?
Verified by standard GitHub Actions on personal fork.
### Was this patch authored or co-authored using generative AI tooling?
No.
Closes #55481 from Feelitx/master.
Lead-authored-by: Felix <160706963+Feelitx@users.noreply.github.com>
Co-authored-by: Luqina <cuong.m9325@gmail.com>
Signed-off-by: Hyukjin Kwon <gurwls223@apache.org>1 parent 6f26070 commit df5c833
1 file changed
Lines changed: 12 additions & 4 deletions
Lines changed: 12 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
18 | | - | |
19 | | - | |
| 18 | + | |
20 | 19 | | |
21 | 20 | | |
| 21 | + | |
22 | 22 | | |
23 | 23 | | |
24 | 24 | | |
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
32 | | - | |
| 32 | + | |
| 33 | + | |
33 | 34 | | |
34 | | - | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
35 | 43 | | |
36 | 44 | | |
37 | 45 | | |
| |||
0 commit comments