janhoy commented on PR #2503:
URL: https://github.com/apache/solr/pull/2503#issuecomment-5131225160

   Follow-up after a QA pass of the fix (4c8006706c7):
   
   - **Target selection now uses projected weight**: the duplicate-replica 
pre-pass picked the target node by its *current* weight, while 
`computePlacements()` uses `calcRelevantWeightWithReplica()` — the projected 
weight with the replica added. In multi-AZ clusters the old selection could 
move a duplicate into an already-over-represented AZ. The pre-pass now mirrors 
placement semantics.
   - **New test** `testBalancingAvoidMultiReplicaOnNodeAcrossAZs` verifies a 
duplicate moves to the under-represented AZ rather than an empty node in the 
same AZ.
   - Verified no explicit weight recomputation is needed after the pre-pass: 
node weights are computed on demand, and the `TreeSet` for the weight-based 
balancing loop is built after the pre-pass completes.
   - All 54 placement unit tests pass (beasted with `-Dtests.iters=5`), plus 
the end-to-end `BalanceReplicasTest`.
   
   Noted for possible follow-up (pre-existing, untouched): the balancing loop's 
move-acceptance condition can accept a move that makes the combined weight 
strictly worse when non-conserved weight terms (e.g. AZ skew) are involved.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to