dramaticlly commented on code in PR #18935:
URL: https://github.com/apache/iceberg/pull/18935#discussion_r4594196155
##########
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:
Sharing different perspective, since type is in API and we maintain the
logic about the field to metrics mode mapping MetricsConfig as single
authority, the direct name based look up in Metrics by file type does not sound
too terrible. To some extend, the `POSITION_DELETE_MODE` today is a special
case where we know the `file_path` and `pos` will have the full mode, but for
metadata columns. I would say `file.field(name).fieldId()` for iterating
uri/size/content_type subfield of FileType in limitFieldIds is not too bad.
--
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]