Thursday, 15 January 2015

multithreading - how to write a future that wait for an event -



multithreading - how to write a future that wait for an event -

i have client/server socket rpc things. know bit finagle , find isolation future elegant. question how write future in scala wait event (the server reply of client request). implementation utilize identified request lack way inquire future wait event without busy wait.

create promise instead of future , add together listener event fulfills promise. homecoming promise's future client (in twitter util future library it's promise itself, in scala 2.10 it's p.future).

multithreading events scala rpc future

No comments:

Post a Comment