Asyncrounous bi-directional json-rpc implementation