[SERVER-43898] Add more unit tests for balancer_policy.cpp and balancer_chunk_selection_policy.cpp Created: 08/Oct/19  Updated: 29/Oct/23  Resolved: 19/Nov/19

Status: Closed
Project: Core Server
Component/s: Sharding
Affects Version/s: None
Fix Version/s: 4.3.1

Type: Task Priority: Major - P3
Reporter: Randolph Tan Assignee: Cheahuychou Mao
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Backwards Compatibility: Fully Compatible
Sprint: Sharding 2019-11-18, Sharding 2019-12-02
Participants:

 Description   

Based from gcov, picked only stuff worth testing

Zone ranges overlaps while balancing

https://github.com/mongodb/mongo/blob/946189b0389432037c248835c8f2924d7a0c8e5d/src/mongo/db/s/balancer/balancer_chunk_selection_policy_impl.cpp#L106

Zone min key does not align with an actual chunk min key

https://github.com/mongodb/mongo/blob/946189b0389432037c248835c8f2924d7a0c8e5d/src/mongo/db/s/balancer/balancer_chunk_selection_policy_impl.cpp#L442

Zone max key does not align with an actual chunk max key

https://github.com/mongodb/mongo/blob/946189b0389432037c248835c8f2924d7a0c8e5d/src/mongo/db/s/balancer/balancer_chunk_selection_policy_impl.cpp#L461

Chunks are already well balanced in the zone

https://github.com/mongodb/mongo/blob/f1a3b974c9b8f9519bbc317859a8ff9bde62e72a/src/mongo/db/s/balancer/balancer_policy.cpp#L564

Most overloaded shard has different tags

https://github.com/mongodb/mongo/blob/f1a3b974c9b8f9519bbc317859a8ff9bde62e72a/src/mongo/db/s/balancer/balancer_policy.cpp#L572



 Comments   
Comment by Githook User [ 19/Nov/19 ]

Author:

{'name': 'Cheahuychou Mao', 'username': 'cheahuychou', 'email': 'cheahuychou.mao@mongodb.com'}

Message: SERVER-43898 Add more unit tests for balancer_policy.cpp and balancer_chunk_selection_policy.cpp
Branch: master
https://github.com/mongodb/mongo/commit/80d1587acb9e445cad81848a0c4b90f01bb9e00a

Comment by Randolph Tan [ 09/Oct/19 ]

It was a mistake. It must be because help tickets have question type and it stayed as question when I switched to server ticket

Comment by Kaloian Manassiev [ 09/Oct/19 ]

What is the question here, renctan (because the ticket is of type question and also is in Needs Scheduling)?

Generated at Thu Feb 08 05:04:25 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.