Skip to content

Commit

Permalink
update
Browse files Browse the repository at this point in the history
Signed-off-by: Margulanz <[email protected]>
  • Loading branch information
margulanz committed Apr 16, 2023
1 parent d79a368 commit 2558bac
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions opensearchpy/connection_pool.py
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,6 @@ def mark_dead(self, connection, now=None):
"""
# allow inject for testing purposes
now = now if now else time.time()
print(id(connection), now)
try:
self.connections.remove(connection)
except ValueError:
Expand All @@ -188,7 +187,6 @@ def mark_dead(self, connection, now=None):
dead_count = self.dead_count.get(connection, 0) + 1
self.dead_count[connection] = dead_count
timeout = self.dead_timeout * 2 ** min(dead_count - 1, self.timeout_cutoff)
#time.sleep(.00001)
self.dead.put((now + timeout,id(connection),connection))
logger.warning(
"Connection %r has failed for %i times in a row, putting on %i second timeout.",
Expand Down

0 comments on commit 2558bac

Please sign in to comment.