fatmanverse commented on code in PR #11487:
URL: https://github.com/apache/seatunnel/pull/11487#discussion_r4322401507
##########
seatunnel-connectors-v2/connector-cdc/connector-cdc-base/src/main/java/org/apache/seatunnel/connectors/cdc/base/source/IncrementalSource.java:
##########
@@ -118,17 +117,62 @@ public abstract class IncrementalSource<T, C extends
SourceConfig>
protected IncrementalSource(ReadonlyConfig options, List<CatalogTable>
catalogTables) {
this.readonlyConfig = options;
- this.catalogTables = updateCatalogTableMetadata(catalogTables);
this.startupConfig = getStartupConfig(readonlyConfig);
this.stopConfig = getStopConfig(readonlyConfig);
this.stopMode = stopConfig.getStopMode();
+ validateSnapshotOnlyConfig(readonlyConfig);
+ this.catalogTables = updateCatalogTableMetadata(catalogTables);
this.incrementalParallelism =
readonlyConfig.get(SourceOptions.INCREMENTAL_PARALLELISM);
this.configFactory = createSourceConfigFactory(readonlyConfig);
this.dataSourceDialect = createDataSourceDialect(readonlyConfig);
this.deserializationSchema =
createDebeziumDeserializationSchema(readonlyConfig);
this.offsetFactory = createOffsetFactory(readonlyConfig);
}
+ /**
Review Comment:
Done in d28296a. The `stop.mode` and `startup.timestamp` checks are now
`Conditions.extension` guards in `MySqlIncrementalSourceFactory#optionRule`
(under `startup.mode = snapshot-only`), the `startup.specific-offset.*` case is
covered by the existing `MySqlSpecificOffsetGuards`, and this imperative check
is removed from `IncrementalSource`.
--
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]