Skip to content

Commit

Permalink
feat:Mysql-CDC supports configuring parameter scan.incremental.snapsh…
Browse files Browse the repository at this point in the history
…ot.backfill.skip,Postgres-CDC supports scan.incremental.snapshot.backfill.skip and scan.incremental.close-idle-reader.enabled parameters
  • Loading branch information
zhourui999 committed Aug 19, 2024
1 parent 0a11857 commit b986dcb
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -176,10 +176,12 @@ public static MySqlSource<CdcSourceRecord> buildMySqlSource(
mySqlConfig
.getOptional(MySqlSourceOptions.HEARTBEAT_INTERVAL)
.ifPresent(sourceBuilder::heartbeatInterval);

mySqlConfig
.getOptional(MySqlSourceOptions.SCAN_INCREMENTAL_CLOSE_IDLE_READER_ENABLED)
.ifPresent(sourceBuilder::closeIdleReaders);
mySqlConfig
.getOptional(MySqlSourceOptions.SCAN_INCREMENTAL_SNAPSHOT_BACKFILL_SKIP)
.ifPresent(sourceBuilder::skipSnapshotBackfill);

String startupMode = mySqlConfig.get(MySqlSourceOptions.SCAN_STARTUP_MODE);
// see
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,12 @@ public static JdbcIncrementalSource<CdcSourceRecord> buildPostgresSource(
postgresConfig
.getOptional(PostgresSourceOptions.HEARTBEAT_INTERVAL)
.ifPresent(sourceBuilder::heartbeatInterval);
postgresConfig
.getOptional(PostgresSourceOptions.SCAN_INCREMENTAL_CLOSE_IDLE_READER_ENABLED)
.ifPresent(sourceBuilder::closeIdleReaders);
postgresConfig
.getOptional(PostgresSourceOptions.SCAN_INCREMENTAL_SNAPSHOT_BACKFILL_SKIP)
.ifPresent(sourceBuilder::skipSnapshotBackfill);

String startupMode = postgresConfig.get(PostgresSourceOptions.SCAN_STARTUP_MODE);

Expand Down

0 comments on commit b986dcb

Please sign in to comment.