How does a single threaded engine such as noflo implement flow based programming?

272 views Asked by At

Paul Morrison says here

the core concept of FBP is of multiple component processes running asynchronously, communicating by means of streams of data chunks which run across what are now called bounded buffers.

So, how does a single threaded implementations such as noflojs built on node.js simulate multiple concurrent asynchronous processes? And can the same method be used in other single threaded languages?

1

There are 1 answers

0
HostileFork says dont trust SE On BEST ANSWER

Not entirely sure what the scope of the question is.

But I can tell you that Node.js is based on the Reactor Design Pattern.

It is possible to emulate this pattern in any single-threaded language implementation, assuming an adequate eventing model. But this means any long-running process must be delegated to, send an event back when ready...with the reactor just brokering the exchange.