Skip to content

Conversation

nicktindall
Copy link
Contributor

@nicktindall nicktindall commented Oct 20, 2025

There was special handling for unassigned shards in WriteLoadConstraintDecider#canAllocate, this is handled generally in #136733, so is no longer necessary in the decider once we merge that.

The new approach is actually superior because it will prioritise allocation of unassigned shards to nodes that return YES over nodes that return NOT_PREFERRED. Although it probably makes no difference for the write load decider, because the write load decider won't intervene if we have no shard write load, which is probably most often the case for an unassigned shard.

Depends on #136733

@nicktindall nicktindall marked this pull request as ready for review October 20, 2025 22:50
@nicktindall nicktindall added >non-issue :Distributed Coordination/Allocation All issues relating to the decision making around placing a shard (both master logic & on the nodes) labels Oct 20, 2025
@nicktindall nicktindall requested a review from ywangd October 20, 2025 22:50
@elasticsearchmachine elasticsearchmachine added the Team:Distributed Coordination Meta label for Distributed Coordination team label Oct 20, 2025
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-distributed-coordination (Team:Distributed Coordination)

@ywangd
Copy link
Member

ywangd commented Oct 20, 2025

Do we know whether the Reconciler is OK with this change, i.e. it will not leave shard unassigned if the only option is NOT_PREFERRED?

@nicktindall
Copy link
Contributor Author

nicktindall commented Oct 20, 2025

Do we know whether the Reconciler is OK with this change, i.e. it will not leave shard unassigned if the only option is NOT_PREFERRED?

Actually good point, it is not. I will open a ticket to get that done

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

:Distributed Coordination/Allocation All issues relating to the decision making around placing a shard (both master logic & on the nodes) >non-issue Team:Distributed Coordination Meta label for Distributed Coordination team v9.3.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants