-
Type: New Feature
-
Resolution: Unresolved
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: Internal Code
-
Labels:
-
Service Arch
SERVER-40722 introduced a wrapper for task executors to ensure all outstanding callbacks are executed before the wrapper is destroyed (defined here). This wrapper simplifies draining all tasks scheduled by a subsystem (e.g., PrimaryOnlyService) before a particular execution point (e.g., the destructor of the subsystem).
This ticket should provide a similar wrapper for instances of out-of-line executor (e.g., ThreadPool). We can also deprecate waitForIdle in favor of using scoped executors.