It should be possible to stop a df network once all messages have been processed.
We could either use a central "graph" object monitoring the whole network, consider using a management channel, or propagate an EOF event through the regular channels.
In that case, channels should provide open/close methods to count interested parties and send EOF down the stream once the counter reaches zero. Both operators and selectors need to handle EOF correctly. Selectors close only after all unguarded input channels report EOF.
Also, EOFs should be filterred out from the network output channels so that thay do not propagade beyond the network boundaries.
Multiple readers of a queue need all to receive EOF and PoisonPill
When maxForks>1 special care must be taken to close only after all forks finish - both operators and selectors
onEOF lifecycle event handler might be added to read channels to optionally overwrite EOF or to throw a custom exception
In case a central graph object is created, consider these:
Unify Kanban-flow and graph
Allow for multiple PGroups per graph
Introduce the notion of nodes, edges and graphs