David-Banquet opened a new pull request, #3477: URL: https://github.com/apache/iceberg-rust/pull/3477
## Which issue does this PR close? - Closes #941. ## What changes are included in this PR? Follow-up to #3102, as discussed in #941. The Glue catalog only uses `warehouse` to derive the location of a new table whose Glue database has no `LocationUri`. `GlueCatalogBuilder::load` still refused a missing or empty warehouse before any call to Glue, so a read-only client, or one that always creates tables in databases with a location, could not load the catalog without one. Java's `GlueCatalog` accepts it and only fails in `defaultWarehouseLocation`. - `load` no longer checks `warehouse`. - `get_default_table_location` returns a `Result` and fails with `DataInvalid` when the namespace has no location and the warehouse is empty. `create_table` propagates it, so the error now happens there, as in Java. - The doc comment of `GLUE_CATALOG_PROP_WAREHOUSE` says what it is used for. ## Are these changes tested? Yes, with unit tests: - `test_load_without_warehouse` replaces `test_load_rejects_missing_or_empty_warehouse`: loading with no warehouse, or an empty one, succeeds. - `test_get_default_table_location_without_warehouse`: with no warehouse, a namespace with a location still gets `<location>/<table>`, and one without a location gets `DataInvalid`. `cargo clippy -p iceberg-catalog-glue --all-targets -- -D warnings` is clean, and the `iceberg-catalog-glue` and `iceberg-catalog-loader` unit tests pass. ## AI Disclosure Written with the help of Claude Code. I reviewed the change and the tests. -- 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]
