-
-
Notifications
You must be signed in to change notification settings - Fork 750
Closed
Closed
Copy link
Description
The ensure_communicating transitions should be migrated to the WorkerState event mechanism as outlined in #5736 (comment)
- The
Worker._gather_depmethod is broken up into- A method
Worker._gather_remote_datawhich accepts an instruction indicating what keys to fetch, the remote worker address, etc. It performs the actual communication and returns a list of events about the outcome of the remote fetch (e.g. Success, DataMissing, RemoteBusy, Error, ...) - Handlers, e.g.
Worker(State)._handle_gather_remote_busythat deal with the result of the fetch attempt
- A method
- The
ensure_communicatingmethod is removed from the list ofhandle_commevery_cyclecallbacks - The logic of
ensure_communicatingis moved to a private method (perspectively a method of the new classWorkerState) - The new private method will not perform any transitions but rather return a list of recommendations and/or instructions as necessary
- This private method is then called as part of the transition system, e.g.
transition_flight_fetchunpause
- The implicit goal is to remove all invocations of
self.loop.add_callback(self.gather_dep, ...)and replace this with the new callback method
Subtasks
- update_who_has can remove workers #6342
- Refactor find_missing and refresh_who_has #6348
- Refactor busy_worker reinsertion #6379
- Cosmetic review of story() #6442
- Refactor gather_dep #6388
Blocked by
Related work
Metadata
Metadata
Assignees
Labels
No labels