You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@seatunnel.apache.org by "DanielLeens (via GitHub)" <gi...@apache.org> on 2026/09/10 15:36:02 UTC

[PR] [Test][E2E] Stabilize Postgres CDC committed offset setup [seatunnel]

DanielLeens opened a new pull request, #12261:
URL: https://github.com/apache/seatunnel/pull/12261

   ## Purpose
   
   Stabilize the PostgreSQL CDC committed-offset E2E setup without weakening its assertions or extending its timeout.
   
   During the last five-day CI audit, the same `PostgresCDCIT.testPostgresCdcSnapshotOnlyAndCommittedOffsetStartupModes` assertion timed out in unrelated PRs and forks:
   
   - apache/seatunnel#12203: [DanielLeens job 102392094932](https://github.com/DanielLeens/seatunnel/actions/runs/34207958769/job/102392094932)
   - apache/seatunnel#12152: [CryoThrust job 101517171106](https://github.com/CryoThrust/seatunnel/actions/runs/34042200157/job/101517171106)
   
   Both failures waited 30 seconds for the replication slot to reach a WAL position sampled only after the seed row was already visible in the JDBC sink. The source and sink share the same PostgreSQL database, so that global position can include WAL generated by the sink table. The source slot commits offsets for captured source mutations and therefore is not required to reach that later sink-generated WAL position.
   
   ## Change
   
   - Record the WAL position immediately before each seed source mutation, including retry updates.
   - Require the replication slot committed LSN to advance strictly beyond the latest mutation-start marker.
   - Keep the existing sink visibility, asynchronous failure, timeout, and post-restart anti-replay assertions unchanged.
   
   This PR is intentionally separate from apache/seatunnel#11864, which addresses production committed-offset recovery after savepoint; this change only corrects the E2E seed synchronization condition.
   
   ## Verification
   
   - `./mvnw spotless:apply -DskipTests -nsu`
   - `./mvnw -pl seatunnel-e2e/seatunnel-connector-v2-e2e/connector-cdc-postgres-e2e spotless:apply -DskipTests -nsu`
   - `git diff --check`
   - Independent Maintainer Review: APPROVE
   
   Docker/E2E was not run locally; the GitHub `all-connectors-it-7` matrix is the authoritative runtime validation.


-- 
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: commits-unsubscribe@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [Test][E2E] Stabilize Postgres CDC committed offset setup [seatunnel]

Posted by "DanielLeens (via GitHub)" <gi...@apache.org>.
DanielLeens commented on PR #12261:
URL: https://github.com/apache/seatunnel/pull/12261#issuecomment-5714489216

   Status correction from the author: this PR does not fix the flake it was opened for, so please do not merge it as a stabilization.
   
   Its own CI (fork run `34974425990`, both `updated-modules-integration-test-part-1` legs) still fails `PostgresCDCIT#testPostgresCdcSnapshotOnlyAndCommittedOffsetStartupModes`, and at a different place than the one this PR changes:
   
   ```
   expected: <1> but was: <0> within 3 minutes.
   	at PostgresCDCIT.testPostgresCdcSnapshotOnlyAndCommittedOffsetStartupModes(PostgresCDCIT.java:629)
   ```
   
   That is the final phase: after `savepoint` + `restore` of the committed-offset job, the row inserted once the restored slot is active (`id = 15`) never reaches the sink. The seed-phase LSN wait this PR reworks has already passed by then. The same failure is on `dev` itself (`all-connectors-it-7 (11)` in push runs `34995029902` and `35063682504`) and on unrelated PRs (#12364, #12360), always at ~260 s, i.e. that 3 minute await.
   
   What the restored job's log shows in the failing run: the split restores with `lsn=LSN{0/227D970}, lastCommitLsn=LSN{0/227D970}`; the restored and freshly discovered row types are identical (no `RestoreTableSchemaEvent`); logical decoding on the slot starts twice 0.5 s apart (Debezium's WAL position search, then the real stream); checkpoints 5, 6, 7, ... keep completing every 5 s; `Committing offset` advances once, from `0/227D970` to `0/227FCC0` at checkpoint 6, and never again. So the source consumed WAL past the insert, but no row was written. Whether the event is dropped by the WAL resume position filter or lost further down is not visible, because the Zeta e2e container does not print `io.debezium` INFO logs.
   
   I am keeping this PR open only as the place to continue that investigation; the current diff should be treated as insufficient.
   


-- 
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: commits-unsubscribe@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [Test][E2E] Stabilize Postgres CDC committed offset setup [seatunnel]

Posted by "DanielLeens (via GitHub)" <gi...@apache.org>.
DanielLeens commented on PR #12261:
URL: https://github.com/apache/seatunnel/pull/12261#issuecomment-6138687071

   Closing as superseded by #12454, merged into `dev` as `0278a6a74746856488dd27713736f008e3115c11`. The current `dev` test seeds the committed offset with a completed savepoint/checkpoint, which is a stronger boundary than this branch’s LSN polling because the global WAL also contains filtered sink writes and is not itself a source checkpoint boundary. #12454 additionally covers the quiet-WAL DBZ-6204 recovery boundary and writes committed while the job is stopped. Resolving this merge conflict by preserving the older polling approach would regress that merged coverage.


-- 
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: commits-unsubscribe@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] [Test][E2E] Stabilize Postgres CDC committed offset setup [seatunnel]

Posted by "DanielLeens (via GitHub)" <gi...@apache.org>.
DanielLeens closed pull request #12261: [Test][E2E] Stabilize Postgres CDC committed offset setup
URL: https://github.com/apache/seatunnel/pull/12261


-- 
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: commits-unsubscribe@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org