I have a directed acyclic graph in networkx
. Each node represents a task and a nodes' predecessors are task dependencies (a given task cannot execute until its' dependencies have executed).
I'd like to 'execute' the graph in an asynchronous task queue, similar to what celery
offers (so that I can poll jobs for their status, retrieve results etc). Celery doesnt offer the ability to create DAG's (as far as I know) and having the ability to move on to a task
as soon as all dependencies are complete would be crucial (a DAG may have multiple paths and even if one task is slow/blocking, it may be possible to move on to other tasks etc).
Are there any simple examples as to how I could achieve this, or perhaps even integrate networkx
with celery
?