Open chbatey opened 6 years ago
That sounds like a reasonable workaround until we have 'proactive' rediscovery in akka-discovery :+1:
I think that would be good, and I think it would be enough with that Future that I talked about previously and then the client can be recreated with a new discovery from the outside. Later that could be handled by managed call api.
From https://github.com/grpc/grpc/blob/master/doc/connectivity-semantics-and-api.md it looks like we can observe transitions between TRANSIENT_FAILURE and CONNECTING and count a few of those before failing the future. Resetting the counter when changed to READY.
I'll also do the close() to return a Future while doing this
A gRPC channel is a long lived, expensive object that handles reconnects / closing of connections when idle.
It doesn't have a " fully broken", it looks to keep retrying (with exponential backoff) forever in the
TRANSIENT_FAILURE
state.Should we interpret being in this state too long as an error and re-create the channel with a ServiceDiscovery lookup?
WDYT @patriknw @raboof ?