Remove the ADD_TRAILING_SLASH_TO_LOCATION feature flag - #5273
Open
iprithv wants to merge 2 commits into
Open
Conversation
iprithv
force-pushed
the
deprecate/add-trailing-slash-to-location
branch
from
August 11, 2026 12:16
f3b0e60 to
017d8d3
Compare
flyrain
reviewed
Aug 11, 2026
iprithv
force-pushed
the
deprecate/add-trailing-slash-to-location
branch
from
August 11, 2026 19:43
017d8d3 to
b9ec958
Compare
dimas-b
previously approved these changes
Aug 12, 2026
Polaris now always appends a trailing slash to table and namespace base locations. The feature flag is removed: leftover keys in polaris.features or catalog properties are harmless and ignored, and a production readiness warning is emitted at startup if the flag is explicitly set to false, since that is a user-visible behavior change. Overlap tests simulate legacy slash-less stored locations by rewriting the stored entity directly through the metastore instead of disabling the flag, preserving coverage of the optimized sibling check against pre-existing slash-less data. Fixes apache#5269
iprithv
force-pushed
the
deprecate/add-trailing-slash-to-location
branch
from
August 13, 2026 16:08
b9ec958 to
d437407
Compare
dimas-b
reviewed
Aug 13, 2026
flyingImer
reviewed
Aug 13, 2026
- Move the ADD_TRAILING_SLASH_TO_LOCATION removal note from "Breaking changes" to "Changes": a leftover config key is silently ignored and the service keeps working, so it is not a breaking change. - Collapse the three base-location slash-normalization sites in LocalIcebergCatalog onto StorageLocation.ensureTrailingSlash, which already performs this check and is used elsewhere in the file.
dimas-b
approved these changes
Aug 14, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #5269 & follow-up to the discussion on #5003 .
false(inpolaris.featuresdefaults or realm overrides), naming the exact config key.OPTIMIZED_SIBLING_CHECKdescription no longer references the flag: locations written by Polaris always end with a slash, and slash-less locations stored by older versions remain handled by the overlap check.User-visible behavior change
Operators who explicitly set
ADD_TRAILING_SLASH_TO_LOCATION=falsewill now get trailing slashes on new table/namespace locations regardless. This is the intended deprecation behavior: the flag's default has beentrue, and setting it tofalseonly weakens location-overlap detection (the trailing slash is what lets prefix matching distinguishns/tA/childfromns/tA_backup). The change is called out inCHANGELOG.mdand surfaced via the readiness warning.Note: the readiness check inspects
polaris.features(defaults + realm overrides); a value set via the catalog propertypolaris.config.add-trailing-slash-to-locationis not covered by the warning.QueryGenerator(added in fix(jdbc): handle trailing-slash mismatch in optimized sibling overlap check #5003). Slash-less rows written by older versions may still exist, so both forms must be queried until stored data is migrated. A migration to normalize stored locations (candidate for the migration framework from feat(persistence): replace EventEntity.REALM_SCOPED sentinel with nullable catalog_id #4981) and the subsequent query simplification are left as follow-ups.