weijietong commented on code in PR #10836:
URL: https://github.com/apache/paimon/pull/10836#discussion_r4465885466


##########
paimon-format/src/main/java/org/apache/parquet/hadoop/ParquetFileReader.java:
##########
@@ -229,6 +230,35 @@ private static final ParquetMetadata readFooter(
 
             // Regular file, or encrypted file with plaintext footer
             if (!encryptedFooterMode) {
+                // Try selective footer parsing first for better performance
+                // This is enabled when requested columns are specified in 
options
+                String requestedColumns =
+                        
options.getProperty(SelectiveFooterParser.REQUESTED_COLUMNS_KEY);
+                if (requestedColumns != null && fileDecryptor == null) {
+                    boolean includeStatistics =
+                            !"true"
+                                    .equals(
+                                            options.getProperty(
+                                                    
SelectiveFooterParser.SKIP_STATISTICS_KEY));
+                    boolean caseSensitive =
+                            !"false"
+                                    .equals(
+                                            options.getProperty(
+                                                    
SelectiveFooterParser.CASE_SENSITIVE_KEY));
+                    try {
+                        return SelectiveFooterParser.parse(

Review Comment:
   Thanks for the question. The short answer: ParquetFileReader is a vendored 
copy of a parquet-mr class and has no access to Paimon's option system, and 
more importantly, the boolean alone is not the decision — it cannot replace 
what the factory computes.



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