bchociej / bobbin

easily spool up thread-like worker processes in node with bobbin
Other
4 stars 0 forks source link

high level data/control flow constructs #1

Open bchociej opened 9 years ago

bchociej commented 9 years ago

basically I want to plug caolan/async into this (or just mimic functionality as needed) to make data processing magically SMP-enabled:

async_bobbin.each(collection, function(item, callback) {
    // this iterator runs on the workers!
    callback(doSomething(item));
});

i think all or almost all of caolan/async could be adapted onto bobbin. (imagine async.auto applied to workers!) some kind of bridge/adapter/facade shouldn't be hard to make.

bchociej commented 9 years ago

async's "collections" operations all fall into one of 4 patterns that are readily adaptable, I think. the control flow constructs are the harder bits.