[SERVER-4687] need to check draining and potentially other shard status before auto-migrates Created: 16/Jan/12  Updated: 10/Dec/14  Resolved: 12/Aug/14

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

Type: Bug Priority: Major - P3
Reporter: Greg Studer Assignee: Randolph Tan
Resolution: Duplicate Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
duplicates SERVER-14506 special top chunk logic can move max ... Closed
Operating System: ALL
Participants:

 Description   

While we reload shard information before running the balancer, we don't do the same for auto-migrates, and the logic for the target shard is different from the balancer policy.

There's also a secondary race condition in that it's possible for shard status to change after shard info reload and before the migration is triggered, but this is a much rarer event and will generally be caught while waiting for draining.



 Comments   
Comment by Randolph Tan [ 12/Aug/14 ]

SERVER-14506 now refreshes shard metadata and also uses the same logic the balancer uses to select shards (checks draining, max size, etc.)

Generated at Thu Feb 08 03:06:42 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.