The logic relies on checking the numBalancerRounds returned from the balancerStatus command. However, this number is just a in-memory value of the balancer task for that mongod process. This value is not shared across the replica set. For example, if a primary was running for a while, it can have the numRounds as 600, but if it fail overs to another node that is running the balancer for the first time, the counter can be reset to 1. This means that this condition to wait for balancer round to be greater than last known round number can wait for unnecessary number of rounds.
_should_wait_for_balancer_round logic is not robust to config server failover
- Votes:
-
0 Vote for this issue
- Watchers:
-
2 Start watching this issue
- Created:
- Updated:
- Resolved: