The Consul TTL is off by twice from reality (#2501)

we use `ttl/2.0` when setting the value on the HTTPClient, but forgot to multiply the current value by 2.
This commit is contained in:
Alexander Kukushkin
2022-12-27 12:06:29 +01:00
committed by GitHub
parent e5d750e9b8
commit 2d79757309
+1 -1
View File
@@ -272,7 +272,7 @@ class Consul(AbstractDCS):
@property
def ttl(self):
return self._client.http.ttl
return self._client.http.ttl * 2 # we multiply the value by 2 because it was divided in the `set_ttl()` method
def set_retry_timeout(self, retry_timeout):
self._retry.deadline = retry_timeout