dotnet-etcd
dotnet-etcd copied to clipboard
new stable lease keep alive method
In everyday use of lease keepalive methods, we have encountered the following problems:
- The
CallEtcd
method only retries unreachable errors, but it does not cover all errors that can be retried, for example, the stream is closed if the etcd node is terminated - The
CallEtcd
method only retries_balancer._numNodes
times. This is not good for long life leases. Or for example, when k8srollingUpdate
strategy terminates etcd one by one. - sometimes the grpc stream is silently ended and grpc streams waits for a response longer than the lease ttl (it waits ping time if grpc pings enabled, infinity otherwise)
~~That PR not cover rare situation when parallels etcd calls move balancer connection by calling _balancer.GetConnection()
. And the keepAliveCall possible can retry on single etcd node _balancer._numNodes
times at row.~~
Now the method bypasses the nodes always sequentially