I’ve always thought that continuations are the right answer to many if no all the network-programming problems.
What are continuations?
A continuation represent the state of execution of a function: all the local variables and the instruction pointer (the last line executed).
(Update: At least: there can be many kind of continuations. Other than the local variables, it’s possible to store…