Hi Björn, Instead of Ez RPC, try using kj::setupAsyncIo() and capnp::TwoPartyClient / capnp::TwoPartyServer. These APIs give you more control. In particular, kj::setupAsyncIo() returns an kj::AsyncIoProvider which, among other things, provides a kj::Timer API which you can use for timeouts.
KJ's and Cap'n Proto's header files are well-commented. We consider the header comments to be the API reference documentation. -Kenton On Mon, Jun 7, 2021 at 9:08 PM Björn Schäpers <[email protected]> wrote: > Hi there, > > I've started using Cap'n Proto RPC. Until now I only have some tests to > ensure > Cap'n Proto behaves as expected for me. > > What is missing for me is waiting with a timeout, or I don't see it. I > want to > be able to shut the server down, and NEVER_DONE seems not right for that. > In my > tests I'm using poll with a sleep in a loop. > > Currently I'm using the Ez RPC, and to be honest the RPC System and > associates > are a bit overwhelming without documentation or good examples. > > Kind regards, > Björn. > > -- > You received this message because you are subscribed to the Google Groups > "Cap'n Proto" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/capnproto/d4160a10-c30c-d209-c12f-70b550e5ce0a%40hazardy.de > . > -- You received this message because you are subscribed to the Google Groups "Cap'n Proto" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/capnproto/CAJouXQ%3D4LVsQG5SNOu9JQ_LCe3sX_gU4ZFzJXPu80iSTugGYqA%40mail.gmail.com.
