TheR1sing3un commented on code in PR #14208:
URL: https://github.com/apache/hudi/pull/14208#discussion_r2496958092


##########
hudi-hadoop-common/src/main/java/org/apache/hudi/common/util/ParquetUtils.java:
##########
@@ -109,12 +112,20 @@ public Set<Pair<String, Long>> 
filterRowKeys(HoodieStorage storage, StoragePath
   }
 
   public static ParquetMetadata readMetadata(HoodieStorage storage, 
StoragePath parquetFilePath) {
+    return readMetadata(storage, parquetFilePath, NO_FILTER);
+  }
+
+  public static ParquetMetadata readMetadataWithSkipRowGroups(HoodieStorage 
storage, StoragePath parquetFilePath) {
+    return readMetadata(storage, parquetFilePath, SKIP_ROW_GROUPS);

Review Comment:
   > Does this reduce both metadata scanned and the number of file system 
calls? Any numbers?
   
   I reviewed the source code of this part again. The optimization on the 
actual I/O is not obvious. Mainly, the processing logic for row groups has been 
reduced, that is, unnecessary function calls have been reduced. I made a micro 
benchmark and loaded a 2G parquet file containing 300 columns. The test showed 
that there was a performance improvement of 10x without loading the row group:
   <img width="1299" height="574" alt="image" 
src="https://github.com/user-attachments/assets/be3e040f-7516-402f-842b-8a3743e999a9";
 />
   <img width="208" height="56" alt="image" 
src="https://github.com/user-attachments/assets/ceb3e985-7033-49d8-af76-9bfc9fff807f";
 />
   



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