RussellSpitzer commented on code in PR #18935:
URL: https://github.com/apache/iceberg/pull/18935#discussion_r4620822026
##########
api/src/main/java/org/apache/iceberg/Schema.java:
##########
@@ -603,20 +626,33 @@ private List<NestedField> reassignIds(List<NestedField>
columns, TypeUtil.GetID
if (getID == null) {
return columns;
}
- Type res =
- TypeUtil.assignIds(
- StructType.of(columns),
- oldId -> {
- int newId = getID.get(oldId);
- if (newId != oldId) {
- idsToReassigned.put(oldId, newId);
- idsToOriginal.put(newId, oldId);
- }
- return newId;
- });
+
+ TypeUtil.GetID tracked =
Review Comment:
Yeah it's because we have a few weird callers that (metadata/partition
things) which will change the field ids and we need a way to map them back to
their real id's so that we can apply filters to them.
We could alternatively just break if we see a file when calling this. It
doesn't come up very much. Currently the only non-direct api call of this that
I think matters is the Position_Deletes metadata table.
--
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]