li3zhi4 commented on PR #11885: URL: https://github.com/apache/seatunnel/pull/11885#issuecomment-5364573735
Following up on Issue 1 from round 2 (the readiness-signal race): rather than settling for the accepted residual flake risk, I've now replaced the probabilistic timing margin with a **structural readiness gate** (commit `a396320c7`): **What changed:** - **`initial`**: before issuing the UPDATE, the test waits until the first bulk row (`id=1`, `'bulk'`) is visible in the **sink**. With `snapshot.split.size = 20` added to the job config, the 200-row table is read in 10 snapshot splits — so this sink-readiness signal can only fire **while the snapshot is still reading the remaining splits**. The UPDATE is therefore *guaranteed* to land inside the snapshot window and be picked up by the binlog phase. No timing margin involved: it is a data-visible proof that the snapshot phase is mid-flight. - **`earliest`**: I removed the post-snapshot UPDATE assertion entirely. Investigation showed `earliest` has **no snapshot phase** — its incremental split is created with `completedSnapshotSplitInfos=[]` and binlog replay starts from the earliest binlog position (`mysql-bin.000001 pos=4` in the observed run). Whether the UPDATE is captured then depends on enumerator stop-offset resolution timing versus the UPDATE, which is *not* a deterministic contract — asserting it would itself be a race. The test still asserts RUNNING and FINISHED for `earliest`, and the data-capture contract (post-snapshot changes are not dropped) is deterministically covered by the `initial` case. - `latest`/`specific`/`timestamp`: unchanged (no snapshot window; the UPDATE not being read is expected; RUNNING/FINISHED asserted). **Verification (local):** `initial`+`earliest` 2/2, `latest`+`specific`+`timestamp` 3/3, existing `specific`-stop regression 2/2 — 7/7 green. `spotless:check` ✅, compile ✅. This supersedes my earlier "accept the residual flake risk" stance: the race is now structurally closed for the `initial` case that exercises the data-loss scenario, and the `earliest` case no longer asserts a non-deterministic outcome. Happy to take another look if you'd like any adjustment. -- 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]
