Yes, I agree there's some missing overview docs regarding Cap'n Proto RPC. The web page is not very detailed.
FWIW, I recently wrote an overview/tour of KJ: https://github.com/capnproto/capnproto/blob/master/kjdoc/tour.md But that doesn't cover Cap'n Proto itself. > If I use the setupAsyncIo and TwoPartyServer, do I need to use the > TwoPartyClient, or can that stay an EzClient? The protocols are the same, so you could use EzClient on the client side and TwoPartyServer on the server. However, I would recommend avoiding the EZ interfaces entirely. Over time I've come to regret having created them, as they are too inflexible for many use cases. -Kenton On Tue, Jun 8, 2021 at 1:25 PM Björn Schäpers <bjo...@hazardy.de> wrote: > Thanks, I will look into that. > > Yes I know the code is documented, without that I wouldn't have come this > far. > But what is missing, at least for me, is the bigger picture, i.e. how to > combine > all these rpc related classes, and what I need to implement and what not. > > If I use the setupAsyncIo and TwoPartyServer, do I need to use the > TwoPartyClient, or can that stay an EzClient? > > Regards, > Björn. > > Am 08.06.2021 um 04:38 schrieb Kenton Varda: > > 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 <bjo...@hazardy.de > > <mailto:bjo...@hazardy.de>> 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 capnproto+unsubscr...@googlegroups.com > > <mailto:capnproto%2bunsubscr...@googlegroups.com>. > > 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 capnproto+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/capnproto/CAJouXQmia_ADOJrREK_-FqwPpr25Ke-i5twqCbkU-UCF8XH%3DHw%40mail.gmail.com.