-
Notifications
You must be signed in to change notification settings - Fork 992
Re-implement seperate threading for validator client duties #342
Description
Description
I've removed the threading for the request for duties. This is because at the start of an epoch, the duties will update in parallel, and process_duties may not see the updated duties when processing.
The current work-around is to make the duties request sequential, such that process_duties always runs after the duties have been updated.
This is not good, as the core timing thread is linked with the duties request thread. We want these separate, such that we can timeout and kill the duties thread, leaving the core timing and tokio driver thread unaffected.
The solution is to add a channel, to the tokio runtime, such that the duties thread tells the tokio runtime if duties have been modified (after an epoch or a re-org) and the tokio runtime can then re-process the new duties.