lparallel icon indicating copy to clipboard operation
lparallel copied to clipboard

blackbird style attach function for promises

Open sirherrbatka opened this issue 8 years ago • 0 comments

So, blackbird has very useful (though uncommon) feature called attach: http://orthecreedence.github.io/blackbird/#attach It is nice because it bridges two distinctive approaches into one api, so we can write code like this:

handling event in the event loop launching asynchronus task with lparallel, future is returned, we can't block event loop so we are just attaching closure that will post response back to the event loop handling response on the event loop

without creating annoyence for simpler use cases

sirherrbatka avatar Mar 28 '17 17:03 sirherrbatka