This is an automated email from the ASF dual-hosted git repository.

danny0405 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/hudi.git


The following commit(s) were added to refs/heads/master by this push:
     new c9448f962c7 [HUDI-6267] Init deletedFileResult with false to avoid NPE 
(#8812)
c9448f962c7 is described below

commit c9448f962c7d48b41e814970295ecf9b8bc553b6
Author: dengweisysu <[email protected]>
AuthorDate: Fri May 26 18:59:03 2023 +0800

    [HUDI-6267] Init deletedFileResult with false to avoid NPE (#8812)
---
 .../java/org/apache/hudi/table/action/clean/CleanActionExecutor.java  | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git 
a/hudi-client/hudi-client-common/src/main/java/org/apache/hudi/table/action/clean/CleanActionExecutor.java
 
b/hudi-client/hudi-client-common/src/main/java/org/apache/hudi/table/action/clean/CleanActionExecutor.java
index d1db5f4695c..f579224ff9b 100644
--- 
a/hudi-client/hudi-client-common/src/main/java/org/apache/hudi/table/action/clean/CleanActionExecutor.java
+++ 
b/hudi-client/hudi-client-common/src/main/java/org/apache/hudi/table/action/clean/CleanActionExecutor.java
@@ -95,12 +95,12 @@ public class CleanActionExecutor<T, I, K, O> extends 
BaseActionExecutor<T, I, K,
       String partitionPath = partitionDelFileTuple.getLeft();
       Path deletePath = new 
Path(partitionDelFileTuple.getRight().getFilePath());
       String deletePathStr = deletePath.toString();
-      Boolean deletedFileResult = null;
+      boolean deletedFileResult = false;
       try {
         deletedFileResult = deleteFileAndGetResult(fs, deletePathStr);
 
       } catch (IOException e) {
-        LOG.error("Delete file failed: " + deletePathStr);
+        LOG.error("Delete file failed: " + deletePathStr, e);
       }
       final PartitionCleanStat partitionCleanStat =
           partitionCleanStatMap.computeIfAbsent(partitionPath, k -> new 
PartitionCleanStat(partitionPath));

Reply via email to