-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Lwt.Canceled support for MultiWorkerLwt
Summary: This is actually relatively simple. The general idea: 1. `MultiWorkerLwt.call` runs N worker controllers in parallel using `LwtUtils.iter_all` 2. Someone tries to cancel a thread which is running `MultiWorkerLwt.call` 3. Canceling the `iter_all` propagates the cancellation to each of the N worker controllers automatically 4. A worker controller which is sending a job or merging a job fails immediately (the worker process is idle) 5. A worker controller which is waiting for the worker process to finish a job handles the cancellation, signals all workers to cancel, and waits for its worker to finish being cancelled 6. `MultiWorkerLwt.call` waits for all worker controllers to finish being cancelled and then re-enables all the workers Reviewed By: avikchaudhuri Differential Revision: D8161600 fbshipit-source-id: e00fadc690cc73b610f46455260499c121f6087f
- Loading branch information
1 parent
9727a70
commit b729d93
Showing
2 changed files
with
26 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters