Skip to content

Commit

Permalink
Fix bug with get_records retry mentioned in issue NerdWalletOSS#31
Browse files Browse the repository at this point in the history
  • Loading branch information
Nathan Crowe committed Jul 30, 2024
1 parent 1a238c8 commit 5878e16
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/kinesis/consumer.py
Original file line number Diff line number Diff line change
Expand Up @@ -50,9 +50,10 @@ def loop(self):
# until we complete a successful get_records call
loop_status = min((
30,
(self.retries or 1) * 2
(self.retries * 2) or 1
))
log.debug("Retrying get_records (#%d %ds): %s", self.retries+1, loop_status, exc)
self.retries += 1
else:
log.error("Client error occurred while reading: %s", exc)
loop_status = False
Expand Down

0 comments on commit 5878e16

Please # to comment.