This is an automated email from the ASF dual-hosted git repository.

github-merge-queue[bot] pushed a commit to branch 
gh-readonly-queue/dev/pr-12997-48b23d0e2f163bf2aa15577a419d49f8a53636db
in repository https://gitbox.apache.org/repos/asf/seatunnel.git

commit 95f9fd5e51175849b741fa4a0d7288c9b1c5c712
Author: hutiefang76 <[email protected]>
AuthorDate: Tue Oct 27 11:53:42 2026 +0000

    [Fix][E2E] Wait for MySQL latest-stop completion before checking sink 
values (#12997)
---
 .../seatunnel/cdc/mysql/MysqlCDCStopModeSpecificIT.java       | 11 ++++++-----
 1 file changed, 6 insertions(+), 5 deletions(-)

diff --git 
a/seatunnel-e2e/seatunnel-connector-v2-e2e/connector-cdc-mysql-e2e/src/test/java/org/apache/seatunnel/connectors/seatunnel/cdc/mysql/MysqlCDCStopModeSpecificIT.java
 
b/seatunnel-e2e/seatunnel-connector-v2-e2e/connector-cdc-mysql-e2e/src/test/java/org/apache/seatunnel/connectors/seatunnel/cdc/mysql/MysqlCDCStopModeSpecificIT.java
index d464a45029..4ca07e1c2c 100644
--- 
a/seatunnel-e2e/seatunnel-connector-v2-e2e/connector-cdc-mysql-e2e/src/test/java/org/apache/seatunnel/connectors/seatunnel/cdc/mysql/MysqlCDCStopModeSpecificIT.java
+++ 
b/seatunnel-e2e/seatunnel-connector-v2-e2e/connector-cdc-mysql-e2e/src/test/java/org/apache/seatunnel/connectors/seatunnel/cdc/mysql/MysqlCDCStopModeSpecificIT.java
@@ -438,6 +438,12 @@ public class MysqlCDCStopModeSpecificIT extends 
TestSuiteBase implements TestRes
                         "UPDATE %s.%s SET f_varchar = 'latest-stop' WHERE id = 
21",
                         MYSQL_DATABASE, SOURCE_TABLE));
 
+        await().atMost(120, TimeUnit.SECONDS)
+                .untilAsserted(
+                        () -> Assertions.assertEquals("FINISHED", 
container.getJobStatus(jobId)));
+        Assertions.assertEquals(0, jobFuture.get(30, 
TimeUnit.SECONDS).getExitCode());
+
+        // Job completion above is the real sync point; the snapshot may still 
progress until then.
         if ("initial".equals(startupMode)) {
             await().atMost(60, TimeUnit.SECONDS)
                     .untilAsserted(
@@ -447,11 +453,6 @@ public class MysqlCDCStopModeSpecificIT extends 
TestSuiteBase implements TestRes
                                             queryVarcharById(21),
                                             "post-snapshot update must be 
synced"));
         }
-
-        await().atMost(120, TimeUnit.SECONDS)
-                .untilAsserted(
-                        () -> Assertions.assertEquals("FINISHED", 
container.getJobStatus(jobId)));
-        Assertions.assertEquals(0, jobFuture.get(30, 
TimeUnit.SECONDS).getExitCode());
     }
 
     private long getCurrentBinlogTimestamp() {

Reply via email to