storage: realize replica-scoped dyncfg overrides in storage workers - #38065
Open
DAlperin wants to merge 1 commit into
Open
storage: realize replica-scoped dyncfg overrides in storage workers#38065DAlperin wants to merge 1 commit into
DAlperin wants to merge 1 commit into
Conversation
antiguru
approved these changes
Aug 6, 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.
Motivation
Replica-scoped system parameters are realized as per-replica dyncfg overrides, but only the compute controller carries a per-replica dyncfg layer. On
clusterdthe compute worker applies pushed updates to its own workerConfigSetand to the shared persist-clientConfigSet, which covers persist-backed and process-global configs. A dyncfg that the storage worker reads from its ownConfigSet(in itsUpdateConfigurationhandler) never sees a replica-scoped override: the storage protocol delivers only environment-wide values, so scoping such a flag to a replica is silently inert.Description
Mirror the compute controller's per-replica dyncfg layer in the storage controller:
Instancestores per-replicaConfigUpdatesoverrides and specializesUpdateConfigurationcommands per replica, both at send time and when replaying history to new or reconnecting replicas. The history records base commands, so overrides are re-applied at replay rather than baked into the shared history.StorageController::update_replica_dyncfg_overrides, with the same replace-and-clear semantics as the compute controller's: instances absent from the pushed map have their overrides cleared.push_replica_dyncfg_overridesnow pushes the same override map to both controllers and re-pushes the environment-wide storage config afterward, so existing replicas observe changed overrides and removed overrides revert to environment-wide values (storage_configrenders the full dyncfg set).This unblocks scoping storage-realized flags (for example the upsert-v2 spill gate) to individual replicas.
Verification
Adds a unit test for the storage command specialization: an overridden replica's
UpdateConfigurationcarries the merged override, while replicas without an override receive the base command. This mirrors the existing compute-side specialization tests.