rambleraptor commented on code in PR #17137:
URL: https://github.com/apache/iceberg/pull/17137#discussion_r3546218926
##########
open-api/rest-catalog-open-api.yaml:
##########
@@ -3120,6 +3120,13 @@ components:
AddSchemaUpdate:
allOf:
- $ref: '#/components/schemas/BaseUpdate'
+ description:
+ Adds a schema to the table. The field IDs in `schema` are assigned by
the client. The client
+ assigns them so that the schema stays consistent with the data files,
partition specs, and
+ sort orders it writes or co-commits, which reference fields by their
field ID
+ (`StructField.id`). Servers SHOULD preserve the field IDs submitted by
the client on
Review Comment:
I'd argue that this should be a MUST.
Let's say that I'm trying to add a new column and then immediately rename it
in the same update (yes, this is a silly example)
- AddSchemaUpdate adds the new column. User specifies this as ID 10, but
catalog ignores it and uses ID 20 instead
- In that same update, I attempt to add a new schema with AddSchemaUpdate.
In that schema, I attempt to rename the column on ID 10. But, the catalog has
already renamed it to ID 20.
--
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]