You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hudi.apache.org by "chenshzh (via GitHub)" <gi...@apache.org> on 2023/02/13 04:21:28 UTC

[GitHub] [hudi] chenshzh commented on a diff in pull request #6121: [HUDI-4406] Support Flink compaction/clustering write error resolvement to avoid data loss

chenshzh commented on code in PR #6121:
URL: https://github.com/apache/hudi/pull/6121#discussion_r1103982916


##########
hudi-flink-datasource/hudi-flink/src/main/java/org/apache/hudi/sink/clustering/ClusteringCommitSink.java:
##########
@@ -119,7 +119,16 @@ private void commitIfNecessary(String instant, List<ClusteringCommitEvent> event
       return;
     }
 
-    if (events.stream().anyMatch(ClusteringCommitEvent::isFailed)) {
+    // here we should take the write errors under consideration
+    // as some write errors might cause data loss when clustering
+    List<WriteStatus> statuses = events.stream()

Review Comment:
   Agree that `isFailed` indicates the execution failure always to be rollbacked. 
   
   So in the updated we will judge whether to rollback write status errors when the config `FlinkOptions.IGNORE_FAILED` false.
   
   Pls take a review.



-- 
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: commits-unsubscribe@hudi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org