adutra commented on issue #13115: URL: https://github.com/apache/iceberg/issues/13115#issuecomment-2935085503
A similar issue has been reported for Polaris so I'm investigating this: https://github.com/apache/polaris/issues/1771 Here are my findings so far: * ✅ `catalog.loadTable("snapshots")` throws `NoSuchTableException` (expected) with message: `Invalid table identifier: snapshots` * ⛔ `catalog.loadTable("ns1", "snapshots")` throws unexpected errors: * In Iceberg tests: throws `BadRequestException` with message: `Malformed request: <h1>Bad Message 400</h1><pre>reason: Ambiguous URI empty segment</pre>` * thrown by the Jetty server used in tests * translates to HTTP 400 hence `BadRequestException` * In Polaris: throws a Jax-RS `NotFoundException` * thrown by Resteasy `ClassRoutingHandler` * translates to HTTP 404 hence decoded as `NoSuchTableException`, but with a weird message: `Unable to find matching target resource method` * due to empty namespace when attempting to load table `ns1` so `paths.table(identifier)` yields `v1/quickstart_catalog/namespaces//tables/test` * fix is easy, should go in `RESTSessionCatalog#loadTable` * ⚠️ `catalog.loadTable("ns1", "ns2", "snapshots")` throws `NoSuchTableException` (expected) but with wrong table name: `ns1.ns2` * due to this line (should be `identifier` instead of `baseIdentifier`): https://github.com/apache/iceberg/blob/a3dcfd19fd1b2a709f7bdf013b83836953d49c6f/core/src/main/java/org/apache/iceberg/BaseMetastoreCatalog.java#L106 @nastra @vox-vox-vox do you agree with the above findings? If so I can provide a fix quickly. -- 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