I’m trying to implement a consensus system and want to use capnp internally (I’m not going to end up using the pipe-lining features, but was looking for a well engineered, minimally buggy library).
There are two things that I can’t quite work out.
- How to get a capability(service) for a remote server, (as in how are the uri’s specified).
- What errors can be thrown when doing an rpc, thus allowing me to automatically retry if the network dies/server dies.
Uri: So I just noticed that there was a line later on in the example for a python client connecting
However I’d imagine that the
insecure part of the uri should be replaced by the id of the service?
Automatically retrying: The main issue with this is that I can’t see what errors could be thrown by the rpc, thus which are recoverable.
Specifically I need this to be resistant to node failures, so if a capability errors out, then I presume that I need to re-fetch that capability from the uri/sturdy-ref.
I’d expect the errors to be thrown in cases where the network had failed, however would those just be the errors of the underlying socket?
It has been quite cool to work with so far and I would love to use this in my project!