sandynz commented on code in PR #29418:
URL: https://github.com/apache/shardingsphere/pull/29418#discussion_r1427861403
##########
kernel/data-pipeline/scenario/cdc/core/src/main/java/org/apache/shardingsphere/data/pipeline/cdc/CDCJobId.java:
##########
@@ -36,7 +36,7 @@ public final class CDCJobId implements PipelineJobId {
private final PipelineContextKey contextKey;
- private final List<String> schemaTableNames;
+ private final Set<String> schemaTableNames;
Review Comment:
Set is not sorted
##########
kernel/data-pipeline/scenario/cdc/core/src/main/java/org/apache/shardingsphere/data/pipeline/cdc/core/prepare/CDCJobPreparer.java:
##########
@@ -120,6 +120,9 @@ private void initInventoryTasks(final CDCJobItemContext
jobItemContext, final At
TransmissionProcessContext processContext =
jobItemContext.getJobProcessContext();
for (InventoryDumperContext each : new
InventoryTaskSplitter(jobItemContext.getSourceDataSource(), new
InventoryDumperContext(taskConfig.getDumperContext().getCommonContext()),
importerConfig)
.splitInventoryDumperContext(jobItemContext)) {
+ if (each.getCommonContext().getPosition() instanceof
FinishedPosition) {
+ continue;
+ }
Review Comment:
It might cause job progress persisting issue: progress lost
##########
kernel/data-pipeline/scenario/cdc/core/src/main/java/org/apache/shardingsphere/data/pipeline/cdc/api/CDCJobAPI.java:
##########
@@ -135,7 +136,7 @@ private YamlCDCJobConfiguration
getYamlCDCJobConfiguration(final StreamDataParam
YamlCDCJobConfiguration result = new YamlCDCJobConfiguration();
result.setJobId(PipelineJobIdUtils.marshal(new CDCJobId(contextKey,
param.getSchemaTableNames(), param.isFull())));
result.setDatabaseName(param.getDatabaseName());
- result.setSchemaTableNames(param.getSchemaTableNames());
+ result.setSchemaTableNames(new
ArrayList<>(param.getSchemaTableNames()));
Review Comment:
Sorting is needed
--
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]