-
Notifications
You must be signed in to change notification settings - Fork 70
Design
Dexecutor Works with 5 components, of which 2 has to be provided by client (Executor Service, Task Provider), 1 (Graph) is internally created, and the rest of the 2 (Traversar [for printing the graph] and Validator [for validating the constructed graph]) are optional (Uses system default if not provided by client)
A graph is a collection of nodes with edges describing relationship among them
A node has a set of incoming and outgoing edges
Graph is used by Dexecutor to represent task relationship and dependencies among tasks, to do this Dexecutor uses very minimal information (Unique ID) to construct nodes.
After the graph construction is done, when it comes to tasks execution, Dexecutor would consult TaskProvider to fetch the task and execute at that time.
Execution Engine is where the tasks would run, Default implementation works with Java's Executor Service, However it can be easily extended to run in any (distributed) environment,
A Validator validates the graph for correctness after its construction, for example checking for cyclic relationship.
A Traversar comes handy if would like to see how the graph is constructed, for example you would do level order traversal to print the graph
Clients would be directly/indirectly interacting with this components through Dexecutor API
Here is little more detailed one