lvyanquan commented on code in PR #4087:
URL: https://github.com/apache/flink-cdc/pull/4087#discussion_r2951261588
##########
flink-cdc-connect/flink-cdc-source-connectors/flink-connector-mysql-cdc/src/main/java/org/apache/flink/cdc/connectors/mysql/source/assigners/MySqlHybridSplitAssigner.java:
##########
@@ -208,9 +206,7 @@ public void close() {
private MySqlBinlogSplit createBinlogSplit() {
final List<MySqlSchemalessSnapshotSplit> assignedSnapshotSplit =
- snapshotSplitAssigner.getAssignedSplits().values().stream()
- .sorted(Comparator.comparing(MySqlSplit::splitId))
- .collect(Collectors.toList());
+ new
ArrayList<>(snapshotSplitAssigner.getAssignedSplits().values());
Review Comment:
Assuming the shards saved by the Enumerator are `split3`, `split2`,
`split1`, they will be sorted in the original way as `split1`, `split2`,
`split3`.
If the Source Reader of a job has already obtained `split3` and `split2`
according to the original sorting method, and the job has been upgraded in
version, requesting the third shard according to the latest implementation
method will request `split3` again. Will there be compatibility issues with
this?
--
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]