I needed to fix this; I felt some kitten was being killed somewhere
because of this. And it made baby Jesus cry.
This commit is contained in:
Javier Goizueta 2016-12-27 17:11:39 +01:00
parent 80b23c62c3
commit bdf9627586

View File

@ -55,8 +55,8 @@ class QPSService:
def retry(self, first_request_time, retry_count): def retry(self, first_request_time, retry_count):
elapsed = datetime.now() - first_request_time elapsed = datetime.now() - first_request_time
elapsed_miliseconds = (elapsed.total_seconds() * 1000.0) elapsed_milliseconds = (elapsed.total_seconds() * 1000.0)
if elapsed_miliseconds > (self._retry_timeout * 1000.0): if elapsed_milliseconds > (self._retry_timeout * 1000.0):
raise TimeoutException() raise TimeoutException()
# inverse qps * (1.5 ^ i) is an increased sleep time of 1.5x per # inverse qps * (1.5 ^ i) is an increased sleep time of 1.5x per