Remove "default base location" arg from CatalogEntity.setStorageConfigurationInfo() - #5276
Open
dimas-b wants to merge 2 commits into
Open
Remove "default base location" arg from CatalogEntity.setStorageConfigurationInfo()#5276dimas-b wants to merge 2 commits into
CatalogEntity.setStorageConfigurationInfo()#5276dimas-b wants to merge 2 commits into
Conversation
ayushtkn
approved these changes
Aug 12, 2026
nandorKollar
previously approved these changes
Aug 13, 2026
flyingImer
reviewed
Aug 13, 2026
| RealmConfig realmConfig, StorageConfigInfo storageConfigModel, String defaultBaseLocation) { | ||
| RealmConfig realmConfig, StorageConfigInfo storageConfigModel) { | ||
| if (storageConfigModel != null) { | ||
| String defaultBaseLocation = properties.get(DEFAULT_BASE_LOCATION_KEY); |
Collaborator
There was a problem hiding this comment.
This makes the setter read mutable builder state, so the builder is order-sensitive now: call setStorageConfigurationInfo before setDefaultBaseLocation and it throws "Must specify default base location" even though the caller does set it.
Would it make sense to assemble the storage config in build() too?
Contributor
Author
There was a problem hiding this comment.
Good point. Will update.
…igurationInfo()` * The old `defaultBaseLocation` argument of the "set" method was NOT actually used to set the default base location in the Catalog object builder. * The old `defaultBaseLocation` argument was used for validation, but nothing guaranteed that the caller passed in the right value. * Remove the `defaultBaseLocation` argument * Get the default base location value from current `properties` (which is the source of truth for this value). * Note: most callers on this builder method already set the default base location before invoking `setStorageConfigurationInfo()` * Keep the exception if `setStorageConfigurationInfo()` is invoked without first setting the default base location.
dimas-b
force-pushed
the
default-loc-validation
branch
from
August 13, 2026 23:31
aed86fb to
95b42ac
Compare
nandorKollar
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.
The old
defaultBaseLocationargument of the "set" method was NOT actually used to set the default base location in the Catalog object builder.The old
defaultBaseLocationargument was used for validation, but nothing guaranteed that the caller passed in the right value.Remove the
defaultBaseLocationargumentGet the default base location value from current
properties(which is the source of truth for this value).Note: most callers on this builder method already set the default base location before invoking
setStorageConfigurationInfo()Keep the exception if
setStorageConfigurationInfo()is invoked without first setting the default base location.This is a follow-up to #4422
Checklist
CHANGELOG.md(if needed)site/content/in-dev/unreleased(if needed)