iopipe / turtle

Turtle - functional composition for building lambda architectures in NodeJS
Apache License 2.0
153 stars 9 forks source link

Support context callback #57

Closed ewindisch closed 8 years ago

ewindisch commented 8 years ago

Passes a context variable to kernels, making it necessary for kernels to execute a context.done() or context.fail() upon completion.

This also means that functions passed in a waterfall/flow must also expect a callback. This makes the code more Node-friendly in some ways.

The map and tee functions are now asynchronous as well, using event emitters and a collector to retrieve results.

Signed-off-by: Eric Windisch eric@iopipe.com

ewindisch commented 8 years ago

@tizzo this is the WIP PR for async pipes. I'm behind on writing tests, having those will make me more comfortable with the merge. Thanks for your feedback last night!

ewindisch commented 8 years ago

The go version is ugly as sin, but it's working and passing tests.

ewindisch commented 8 years ago

Closes #60