dramaticlly commented on code in PR #18935:
URL: https://github.com/apache/iceberg/pull/18935#discussion_r4619693778


##########
api/src/main/java/org/apache/iceberg/types/Types.java:
##########
@@ -1158,6 +1158,12 @@ private Map<Integer, NestedField> lazyFieldsById() {
   public static final class FileType extends NestedType {
     public static final String NAME = "file";
     public static final int NUM_NESTED_FIELDS = 6;
+    public static final int URI_ID_OFFSET = 1;

Review Comment:
   If this is the only place require the knowledge on which field to skip stats 
for file type(I believe so), I would define the private list of field index 
instead of importing the public static constants, like in 
https://github.com/apache/iceberg/blob/13135ae08148b010276fc9c5eb1cfbf2e6e8289c/core/src/main/java/org/apache/iceberg/StatsUtil.java#L61-L66.
 
   
   So we dont need to expose additional public static content in FileTypes and 
keep encapsulation boundary clear. While there's the downside that the index 
change will not be direct visible here, but we can have test to cover this and 
catch the problem.



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


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to