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
When rebalancing searchable snapshot indices, we first calculate the average number of primary shards that each node should has. In current implementation, the formula is as follows.
If a cluster has both search nodes and dedicated data nodes, this average number of shards calculated using the current formula may be lower than the actual number.. I think that the formula needs to be adjusted as follows:
Describe the bug
When rebalancing searchable snapshot indices, we first calculate the average number of primary shards that each node should has. In current implementation, the formula is as follows.
OpenSearch/server/src/main/java/org/opensearch/cluster/routing/allocation/allocator/RemoteShardsBalancer.java
Lines 247 to 251 in e8ee6db
If a cluster has both search nodes and dedicated data nodes, this average number of shards calculated using the current formula may be lower than the actual number.. I think that the formula needs to be adjusted as follows:
Related component
Search:Searchable Snapshots
To Reproduce
Expected behavior
RemoteShardsBalancer should rebalance shards as expected
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: