Skip to content

Core: Remove deprecated REST namespace encoding helpers - #17697

Merged
huaxingao merged 3 commits into
apache:mainfrom
dramaticlly:1.12deprecation-core-restutil
Aug 21, 2026
Merged

Core: Remove deprecated REST namespace encoding helpers#17697
huaxingao merged 3 commits into
apache:mainfrom
dramaticlly:1.12deprecation-core-restutil

Conversation

@dramaticlly

Copy link
Copy Markdown
Contributor

Removes REST API deprecated for removal in 1.12.0:

  • RESTUtil.NAMESPACE_JOINER / NAMESPACE_SPLITTER, superseded by namespaceToQueryParam(Namespace) / namespaceFromQueryParam(String)
  • RESTUtil.encodeNamespace(Namespace) / decodeNamespace(String), superseded by the two-arg overloads that take an explicit separator
  • RESTSessionCatalog.REST_PAGE_SIZE, superseded by RESTCatalogProperties.PAGE_SIZE
  • CatalogHandlers.loadTable(Catalog, TableIdentifier), superseded by the overload taking a SnapshotMode

Javadoc on namespaceToQueryParam and encodeNamespace no longer cross-links the removed single-arg encodeNamespace; the wording now describes the raw versus percent-encoded separator directly.

AI Disclosure

Model: Claude Opus 5 (1M context)
Platform/Tool: Claude Code
Human Oversight: reviewed
Prompt Summary: split #16449 into smaller self-contained PRs; verify each group compiles and tests green standalone

@dramaticlly

Copy link
Copy Markdown
ContributorAuthor

@gaborkaszab can you help take a look? for #13991 and #14060
@nastra can you check the deprecation align with your expectation in #10877

Comment threadcore/src/test/java/org/apache/iceberg/rest/TestRESTUtil.java Outdated
Comment thread.palantir/revapi.yml Outdated

@nastranastra left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM with 2 minor things

@nastra
nastra requested a review from singhpk234August 18, 2026 05:50

@uros-buros-b left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1, LGTM!

@singhpk234singhpk234 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM mostly, added a small suggestion and question for verbosity pov

Comment thread.palantir/revapi.yml Outdated
Comment threadcore/src/main/java/org/apache/iceberg/rest/RESTUtil.java Outdated
@dramaticlly
dramaticllyforce-pushed the 1.12deprecation-core-restutil branch from 40d5c7f to 8a4b607CompareAugust 18, 2026 17:55
@dramaticlly

Copy link
Copy Markdown
ContributorAuthor

LGTM mostly, added a small suggestion and question for verbosity pov

thanks @singhpk234 updated per your reply, ready for another look

@huaxingao

Copy link
Copy Markdown
Contributor

@dramaticlly Could you resolve the conflicts?

@dramaticlly
dramaticllyforce-pushed the 1.12deprecation-core-restutil branch from 8a4b607 to e906699CompareAugust 19, 2026 18:43
Removes REST API deprecated for removal in 1.12.0:
- RESTUtil.NAMESPACE_JOINER / NAMESPACE_SPLITTER, superseded by
namespaceToQueryParam(Namespace) / namespaceFromQueryParam(String)
- RESTUtil.encodeNamespace(Namespace) / decodeNamespace(String), superseded
by the two-arg overloads that take an explicit separator
- RESTSessionCatalog.REST_PAGE_SIZE, superseded by
RESTCatalogProperties.PAGE_SIZE
- CatalogHandlers.loadTable(Catalog, TableIdentifier), superseded by the
overload taking a SnapshotMode
Javadoc on namespaceToQueryParam and encodeNamespace no longer cross-links
the removed single-arg encodeNamespace; the wording now describes the raw
versus percent-encoded separator directly.
The deprecation notice said this constructor would be made private in
1.12.0. It had no callers anywhere in the repo, so making it private
would leave an unused private constructor; remove it instead. Removal
and privatization are indistinguishable to external callers.
Review feedback from nastra and singhpk234:
- Keep the decode separator in encodeAsOldClientAndDecodeAsNewServer
hardcoded as "%2E". The test only needs a separator that differs from
the legacy one; it does not have to be the one RESTCatalogAdapter
advertises.
- Use "Removed deprecated functionality scheduled for removal in 1.12.0"
as the revapi justification for all seven accepted breaks. The previous
text claimed every break was part of the namespace encoding API, which
was not true for REST_PAGE_SIZE, CatalogHandlers.loadTable and the
ResourcePaths constructor.
- Drop the javadoc note on namespaceToQueryParam(Namespace, String). The
separator is an explicit argument there, so warning that it differs from
encodeNamespace adds nothing.
- Keep the note on the no-arg namespaceToQueryParam, which hides the
separator, but point it at the surviving encodeNamespace(Namespace,
String) overload. The distinction it warns about is real:
namespaceToQueryParam joins raw levels, while encodeNamespace
URL-encodes each level.
@dramaticlly
dramaticllyforce-pushed the 1.12deprecation-core-restutil branch from e906699 to 3e57b51CompareAugust 19, 2026 23:41
@huaxingao
huaxingao merged commit c07a081 into apache:mainAug 21, 2026
38 checks passed
@huaxingao

Copy link
Copy Markdown
Contributor

Thanks @dramaticlly for the PR! Thanks everyone for the review!

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants

@dramaticlly@huaxingao@nastra@singhpk234@uros-b