You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
[BUG] Allocation and Rebalance Constraints of WeightFunction are incorrectly reset to default if indexBalanceFactor, shardBalanceFactor or preferPrimaryShardRebalanceBuffer is updated
#13429
Open
KunjueYu opened this issue
Apr 28, 2024
· 2 comments
In BalancedShardsAllocator, the update consumers of PREFER_PRIMARY_SHARD_REBALANCE and PREFER_PRIMARY_SHARD_BALANCE directly modifies the constraint config of existing weightFunction. However, if indexBalanceFactor, shardBalanceFactor or preferPrimaryShardRebalanceBuffer is updated, a new weightFunction is constructed, which will discard the preferPrimary Constraint configs of previous weightFunction.
set setting "PREFER_PRIMARY_SHARD_BALANCE" as true
set setting "SHARD_BALANCE_FACTOR_SETTING" as 0.5f (arbitrary value which differs from default value 0.45f)
the preferPrimary constraints of weight function will be incorrectly disabled.
Expected behavior
Updating indexBalanceFactor, shardBalanceFactor or preferPrimaryShardRebalanceBuffer will not reset preferPrimary constraints of weight function to default.
Additional Details
Plugins
Please list all plugins currently enabled.
Screenshots
If applicable, add screenshots to help explain your problem.
Host/Environment (please complete the following information):
OS: [e.g. iOS]
Version [e.g. 22]
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered:
Describe the bug
In BalancedShardsAllocator, the update consumers of PREFER_PRIMARY_SHARD_REBALANCE and PREFER_PRIMARY_SHARD_BALANCE directly modifies the constraint config of existing weightFunction. However, if indexBalanceFactor, shardBalanceFactor or preferPrimaryShardRebalanceBuffer is updated, a new weightFunction is constructed, which will discard the preferPrimary Constraint configs of previous weightFunction.
Related component
Cluster Manager
To Reproduce
Expected behavior
Updating indexBalanceFactor, shardBalanceFactor or preferPrimaryShardRebalanceBuffer will not reset preferPrimary constraints of weight function to default.
Additional Details
Plugins
Please list all plugins currently enabled.
Screenshots
If applicable, add screenshots to help explain your problem.
Host/Environment (please complete the following information):
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: