-
Type: Task
-
Resolution: Won't Fix
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: Sharding
-
None
-
Sharding
-
Sharding 18 (08/05/16)
_rangeDeleterTaskExecutor is currently initialized by ShardingState::_initializeRangeDeleterTaskExecutor().
We want to make this a public function, and have it take "NetworkInterface* netPtr" as a parameter with which to initialize the task executor.
This shiny new public function will get called above this code: https://github.com/mongodb/mongo/blob/master/src/mongo/db/db.cpp#L712-L738, which calls the regular sharding initialization code.
Now in testing we can set up a task executor with a mock network interface. In ShardingStateTest::setUp, we want to call our shiny new function above this code https://github.com/mongodb/mongo/blob/master/src/mongo/db/s/sharding_state_test.cpp#L135-L139
And finally we want to test the task executor, so make a test to give it a silly task – e.g. pass in a variable by reference that gets set to some value --, wait for it to finish, check it did what you wanted.
- has to be done before
-
SERVER-24367 Implement CollectionRangeDeleter task lifetime management
- Closed