litiliu commented on code in PR #7671:
URL: https://github.com/apache/seatunnel/pull/7671#discussion_r1764615000
##########
seatunnel-translation/seatunnel-translation-flink/seatunnel-translation-flink-common/src/main/java/org/apache/seatunnel/translation/flink/sink/FlinkSink.java:
##########
@@ -91,17 +89,30 @@ public Optional<GlobalCommitter<CommitWrapper<CommT>,
GlobalCommT>> createGlobal
@Override
public Optional<SimpleVersionedSerializer<CommitWrapper<CommT>>>
getCommittableSerializer() {
- return
sink.getCommitInfoSerializer().map(CommitWrapperSerializer::new);
+ if (checkForCommitter())
+ return
sink.getCommitInfoSerializer().map(CommitWrapperSerializer::new);
+ else return Optional.empty();
}
@Override
public Optional<SimpleVersionedSerializer<GlobalCommT>>
getGlobalCommittableSerializer() {
- return
sink.getAggregatedCommitInfoSerializer().map(FlinkSimpleVersionedSerializer::new);
+ if (checkForCommitter())
Review Comment:
there should be a `{` behind the if clause, it makes reading easier.
--
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]