Skip to content

Commit b22fb25

Browse files
authored
[Improve][CDC][MySQL] Ennable binlog watermark compare (#4293)
1 parent a55f741 commit b22fb25

File tree

1 file changed

+2
-7
lines changed
  • seatunnel-connectors-v2/connector-cdc/connector-cdc-mysql/src/main/java/org/apache/seatunnel/connectors/seatunnel/cdc/mysql/source/reader/fetch/scan

1 file changed

+2
-7
lines changed

seatunnel-connectors-v2/connector-cdc/connector-cdc-mysql/src/main/java/org/apache/seatunnel/connectors/seatunnel/cdc/mysql/source/reader/fetch/scan/MySqlSnapshotFetchTask.java

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -75,13 +75,8 @@ public void execute(FetchTask.Context context) throws Exception {
7575

7676
// optimization that skip the binlog read when the low watermark equals high
7777
// watermark
78-
79-
// TODO make binlogBackfillRequired configable.
80-
// TODO we need store the data in disk to ensure no memory overflow
81-
// final boolean binlogBackfillRequired =
82-
//
83-
// backfillBinlogSplit.getStopOffset().isAfter(backfillBinlogSplit.getStartupOffset());
84-
final boolean binlogBackfillRequired = false;
78+
final boolean binlogBackfillRequired =
79+
backfillBinlogSplit.getStopOffset().isAfter(backfillBinlogSplit.getStartupOffset());
8580
if (!binlogBackfillRequired) {
8681
dispatchBinlogEndEvent(
8782
backfillBinlogSplit,

0 commit comments

Comments
 (0)