Repository navigation
Remove unused fields from CommonConstants - #20335
Open
Jackie-Jiang wants to merge 1 commit into
Open
Jackie-Jiang wants to merge 1 commit into
Jackie-Jiang wants to merge 1 commit into
Conversation
Jackie-Jiang
force-pushed
the
cleanup-common-constants
branch
2 times, most recently
from
November 20, 2026 21:40
5547cad to
6e28f90
Compare
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #20335 +/- ##
============================================
+ Coverage 71.23% 71.26% +0.02%
Complexity 1639 1639
============================================
Files 3594 3594
Lines 242224 242224
Branches 39244 39244
============================================
+ Hits 172560 172617 +57
+ Misses 56741 56674 -67
- Partials 12923 12933 +10
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Remove the deprecated fields whose deprecation has already shipped in a release, and the fields that describe no config the code reads. Unreferenced fields that complete a value set or name a config key that is still read stay. Code that hard-codes keys CommonConstants already defines now uses the constants: BaseControllerStarter, PinotLLCRealtimeSegmentManager, PinotMetricUtils and PredownloadSchedulerTest.
Jackie-Jiang
force-pushed
the
cleanup-common-constants
branch
from
November 21, 2026 05:28
6e28f90 to
72dee4b
Compare
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.
Summary
Remove fields in
CommonConstantsthat are deprecated or describe nothing the code reads.Deprecated fields whose deprecation has shipped in a release:
Accounting.CONFIG_OF_*keys (forRemovalsince 1.6.0). The same configs are still read throughAccounting.COMMON_PREFIX/BROKER_PREFIX/SERVER_PREFIXwith theAccounting.Keysnames.Helix.CONFIG_OF_ZOOKEEPR_SERVER(forRemovalsince 1.5.0), replaced byCONFIG_OF_ZOOKEEPER_SERVER.DEFAULT_PINOT_INSECURE_MODE,Broker.FALLBACK_REPLICA_GROUP_ID(replaced byFALLBACK_POOL_ID), andServer.CONFIG_OF_QUERY_EXECUTOR_OPCHAIN_EXECUTOR/DEFAULT_QUERY_EXECUTOR_OPCHAIN_EXECUTOR.MultiStageQueryRunnerop stats cache keys and defaults, no longer read since the op stats cache was removed. Removing the constants does not affect startup: nothing reads or validates these keys.Fields that describe nothing the code reads:
Broker.ROUTING_TABLE_CONFIG_PREFIX(pinot.broker.routing.table), left over from the old routing table builder.Broker.MULTI_STAGE_BROKER_REQUEST_HANDLER_TYPE(multistage). The broker only tellsgrpcapart from the defaultnettyhandler.Controller.PAGE_CACHE_WARMUP_QUERIES_DATA_DIR, which holdspinot.controller.page.cache.warmup.queries.dataDir. The controller readscontroller.page.cache.warmup.queries.dataDirthroughControllerConf.CONFIG_OF_PAGE_CACHE_WARMUP_QUERIES_DATA_DIR.Some unreferenced fields stay because they complete a value set or name a config that is still read, e.g.
BrokerResourceStateModel.ERROR, theHelix.*_INSTANCE_PREFIX_LENGTHset,STATS_REPORTING_MODE_LEGACY, and theServer.CONFIG_OF_*full keys of query executor and instance data manager configs.Code that hard-codes keys
CommonConstantsalready defines now uses the constants:BaseControllerStarterandPinotLLCRealtimeSegmentManagerread the metadata event notifier config throughMinion.METADATA_EVENT_OBSERVER_PREFIXinstead of their own private copies ofmetadata.event.notifier.PinotMetricUtilsreads the registry registration listeners throughMinion.METRICS_REGISTRY_REGISTRATION_LISTENERS_KEY.PredownloadSchedulerTestbuilds its configs with theServerandHelixkey constants.No config read at runtime changes. The binary compatibility check reports the removed public fields, which is expected for this change.
🤖 Generated with Claude Code