nastra commented on code in PR #16441:
URL: https://github.com/apache/iceberg/pull/16441#discussion_r3279490904
##########
core/src/main/java/org/apache/iceberg/StatsUtil.java:
##########
@@ -34,80 +34,67 @@
class StatsUtil {
private static final Logger LOG = LoggerFactory.getLogger(StatsUtil.class);
- // the number of reserved field IDs from the reserved field ID space as
defined in
- // https://iceberg.apache.org/spec/#reserved-field-ids
- static final int NUM_RESERVED_FIELD_IDS = 200;
- // the starting field ID of the reserved field ID space
- static final int RESERVED_FIELD_IDS_START = Integer.MAX_VALUE -
NUM_RESERVED_FIELD_IDS;
- // the number of supported stats per table column
+ private static final int FIRST_SUPPORTED_METADATA_FIELD_ID =
+ MetadataColumns.LAST_UPDATED_SEQUENCE_NUMBER.fieldId();
+ static final Set<Integer> SUPPORTED_METADATA_FIELD_IDS =
+ Sets.newHashSet(
+ MetadataColumns.LAST_UPDATED_SEQUENCE_NUMBER.fieldId(),
MetadataColumns.ROW_ID.fieldId());
static final int NUM_SUPPORTED_STATS_PER_COLUMN = 200;
- // the starting field ID of the stats space for data field IDs
+ static final int STATS_SPACE_FIELD_ID_START_FOR_METADATA_FIELDS = 9_000;
Review Comment:
not sure it's worth it. Adding a new field to the set technically requires a
spec change
--
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]