Remove createDictionary from ColumnIndexCreationInfo#18101
Merged
Jackie-Jiang merged 1 commit intoapache:masterfrom Apr 6, 2026
Merged
Conversation
The createDictionary field in ColumnIndexCreationInfo was redundant because dictionary creation is determined by DictionaryIndexConfig, not by the stats/creation-info data class. It was also incorrectly set in SegmentIndexCreationDriverImpl as dictionaryIndexConfig.isDisabled() (inverted logic). - Remove createDictionary field and primary constructor parameter from ColumnIndexCreationInfo; keep old constructor as @deprecated - Remove isCreateDictionary() accessor - Remove deprecated shouldUseVarLengthDictionary pass-through in SegmentIndexCreationDriverImpl and DictionaryIndexType - Update all callers to use the new constructor Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
xiangfu0
approved these changes
Apr 4, 2026
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #18101 +/- ##
============================================
- Coverage 63.85% 63.82% -0.03%
Complexity 1573 1573
============================================
Files 3167 3167
Lines 192099 192089 -10
Branches 29604 29604
============================================
- Hits 122657 122604 -53
- Misses 59788 59819 +31
- Partials 9654 9666 +12
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
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.
Description
ColumnIndexCreationInfohad acreateDictionaryboolean field that was redundant and incorrectly used:SegmentIndexCreationDriverImpl, it was set asdictionaryIndexConfig.isDisabled()— inverted logic:isDisabled()returnstruewhen the dictionary is disabled, socreateDictionarywould betruewhen dictionary is disabled andfalsewhen enabled.DictionaryIndexConfig, not by this stats/creation-info data class, so the field serves no purpose.Changes
_createDictionaryfield,isCreateDictionary()accessor, and thecreateDictionaryconstructor parameter fromColumnIndexCreationInfo; keep old 5-arg constructor as@Deprecatedfor backward compatibilitycreateDictionary = dictionaryIndexConfig.isDisabled()assignment inSegmentIndexCreationDriverImplshouldUseVarLengthDictionary(String, Set, DataType, ColumnStatistics)pass-through inSegmentIndexCreationDriverImplandDictionaryIndexTypeForwardIndexHandler,BaseDefaultColumnHandler,ColumnMetadataTest) to use the new constructorTest Plan
ColumnMetadataTestupdated and passcreateDictionaryfield was not used to make any runtime decisions in the code paths examined🤖 Generated with Claude Code