danny0405 commented on code in PR #13415:
URL: https://github.com/apache/hudi/pull/13415#discussion_r2138946846


##########
hudi-client/hudi-client-common/src/main/java/org/apache/hudi/table/action/compact/HoodieCompactor.java:
##########
@@ -250,36 +253,41 @@ public List<WriteStatus> compact(HoodieCompactionHandler 
compactionHandler,
         Path newFilePath = new Path(oldFilePath.getParent(), newFileName);
         FileUtil.copy(fs,oldFilePath, fs, newFilePath, false, fs.getConf());
         */
+        }
       }
-    }
 
-    // Compacting is very similar to applying updates to existing file
-    Iterator<List<WriteStatus>> result;
-    result = executionHelper.writeFileAndGetWriteStats(compactionHandler, 
operation, instantTime, scanner, oldDataFileOpt);
-    scanner.close();
+      // Compacting is very similar to applying updates to existing file
+      Iterator<List<WriteStatus>> result;
+      result = executionHelper.writeFileAndGetWriteStats(compactionHandler, 
operation, instantTime, scanner, oldDataFileOpt);
+      scanner.close();

Review Comment:
   isn't the scanner already been closed here?



-- 
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]

Reply via email to