There is a topic talking about best practic
https://github.com/grpc/grpc-go/issues/682
But I am not sure at last, How to use grpcio in my program.
I am using tensorflow-serving which is base on GRPC. My client is based on python sdk grpcio-1.8.3. The client program is a Flask server with many APIs each of them holds identical channel and stub.
When the tensorflow-serving(the GRPC server) restart, the client program will failed into "Endpoint read failed" and would not recover any more.
But when I upgrade the grpcio to newer version, The bug seems fixed, so that the client can reconnect automatically.
And if the grpcio client, namely the Flask server holds one channel and stub globally, the error seems never appears.
But I am still not sure what is the best way to program with grpc client SDK like grpcio, stable and high performance. Because there are even no exception testings on those examples, not to mention about how to use multiple channels and stubs in one process.