stavalfi / jstream

Represent graphs, differently https://stavalfi.github.io/jstream/
2 stars 0 forks source link

Execute multiple different unrelated flows concurently #7

Closed stavalfi closed 5 years ago

stavalfi commented 5 years ago

Be able to express 2+ async flows (parallel tasks) that do not have any relationship between them (This should be similar to Promise.all).

Assumptions:

All the flows are different.

{
   "workflowName": "createSuperUser",
    "workflow": [
      "createUser",
      "updateServer"
    ]
}
stavalfi commented 5 years ago

A fast implementation is to warp it by unique "hidden" flow:

{
   "workflowName": "createSuperUser",
    "workflow": [
      "hiddenFlow_1",
      "createUser",
      "updateServer",
      "hiddenFlow_2",
      "hiddenFlow_3",
    ]
}
stavalfi commented 5 years ago

I decided to not let the user define multiple heads because the graph will be too complicated in that way.