geruh opened a new pull request, #1429: URL: https://github.com/apache/iceberg-rust/pull/1429
## Which issue does this PR close? Fixes two bugs in the `GlueCatalogs` table creation that caused inconsistency with Iceberg core and PyIceberg implementations: * `StorageDescriptor.Location` incorrectly set to metadata file path instead of table base location * `iceberg.field.optional` parameter logic inverted - was setting it to field.required instead of !field.required Iceberg ref: * location: https://github.com/apache/iceberg/blob/main/aws/src/main/java/org/apache/iceberg/aws/glue/IcebergToGlueConverter.java#L280 * field.optional: https://github.com/apache/iceberg/blob/main/aws/src/main/java/org/apache/iceberg/aws/glue/IcebergToGlueConverter.java#L377 ## What changes are included in this PR? ### Location #### Before: ``` { "StorageDescriptor": { "Location": "s3://bucket/table/metadata/00000-uuid.metadata.json" }, "Parameters": { "metadata_location": "s3://bucket/table/metadata/00000-uuid.metadata.json" } } ``` #### After: ``` { "StorageDescriptor": { "Location": "s3://bucket/table" }, "Parameters": { "metadata_location": "s3://bucket/table/metadata/00000-uuid.metadata.json" } } ``` ### Schema (with required field) #### Rust Schema ``` NestedField::required(1, "foo", Type::Primitive(PrimitiveType::String)).into(), ``` #### Before: ``` { "Name": "foo", "Type": "string", "Parameters": { "iceberg.field.current": "true", "iceberg.field.id": "2", "iceberg.field.optional": "true" <--- } } ``` #### After: ``` { "Name": "foo", "Type": "string", "Parameters": { "iceberg.field.current": "true", "iceberg.field.id": "2", "iceberg.field.optional": "false" <--- } } ``` ## Are these changes tested? * Repaired the existing test * Tested manually with GlueCatalog. -- 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: issues-unsubscr...@iceberg.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org For additional commands, e-mail: issues-h...@iceberg.apache.org