thswlsqls opened a new pull request, #18035: URL: https://github.com/apache/iceberg/pull/18035
Closes #18034 ## Summary - `NessieIcebergClient.listNamespaces(Namespace)` read two commits in one call: the parent existence check was pinned to the hash the client cached when it first resolved the ref, while the child listing below it asked for the branch HEAD. A client behind that HEAD got `NoSuchNamespaceException` for a namespace another client had just created. - The existence check now uses `withReference(api.getContent())`, matching `loadNamespaceMetadata()` in the same class. - The three other `api.getContent().reference(getReference())` calls here (`createNamespace`, `dropNamespace`, `updateProperties`) are left alone: they are pre-checks run right before a commit against that same hash, so pinning it there is intended. - The check was added by #12901 (fix for #12875). ## Testing done - Added `TestMultipleClients#listNestedNamespacesFromAnotherClient`: one client creates `db1` and `db1.sub1`, a second client on the older ref hash lists `db1` and must see `db1.sub1`. It fails without the production change (API v1 and v2) and passes with it. - `./gradlew :iceberg-nessie:check` — 488 tests passed, 0 failures, 30 skipped, including `TestBranchVisibility`, which covers the hash-pinned path where `withReference` falls back to `builder.reference(...)`. `:iceberg-nessie` is not REVAPI-published. --- **AI Disclosure** - Model: Claude Opus 5 - Platform/Tool: Claude Code - Human Oversight: [unknown - human to fill in] - Prompt Summary: Make `listNamespaces(Namespace)` check the parent namespace at the HEAD of the ref instead of the client's cached hash, matching `loadNamespaceMetadata()`, and add a regression test to `TestMultipleClients`. Leave the other three hash-pinned pre-commit checks in the class untouched. -- 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]
