5 releases
0.1.4 | Mar 1, 2022 |
---|---|
0.1.3 | Mar 1, 2022 |
0.1.2 | Mar 1, 2022 |
0.1.1 | Mar 1, 2022 |
0.1.0 | Mar 1, 2022 |
#1373 in Asynchronous
46KB
776 lines
Execution Engine MkII
The EE is split into 2 main parts
- Executor - This is responsible for driving the workflows to completion and should contain all the objects required for each workflow to be executed, think of this as a runtime.
- Reactor - The reactor is responsible for notifying the executor when a future can make progress, this is done via the Waker API.
When a workflow is sent to the EE, the flow is as follows:
- Spawn a new task which will perform all of the work associated with executing a wf to completion
- Deserialize the workflow into a Job, the Job type should describe the entity as accurately as possible
- Drive the workflow forward, this uses an event based stream to do so
When a workflow reaches a point where it cannot make progress (e.g. waiting for Bots to Lock or waiting for an Activity to complete) it should yield execution using the underlying mechanics of Rust's async/await.
Dependencies
~21–36MB
~674K SLoC