Skip to content

Commit

Permalink
[fix] [mq] [#305] Typo in final loop error handler
Browse files Browse the repository at this point in the history
This was causing handling loop to unintentionally break on things
like connection failures.

Thanks to @J0sueTM for providing a minimal example to help identify
the problem!
  • Loading branch information
ptaoussanis committed May 30, 2024
1 parent 81f58d8 commit 9dd6720
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/taoensso/carmine/message_queue.clj
Original file line number Diff line number Diff line change
Expand Up @@ -701,9 +701,9 @@
loop-error-backoff?_ (atom false)
loop-error!
(fn [throwable]
(let [nce (nconsecutive-errors* :+=)]
(let [nce (nconsecutive-errors*)]
(timbre/error throwable "[Carmine/mq] Worker error, will backoff & retry."
{:qname qname, :thread-id thread-idx, :nconsecutive-errors nce}))
{:qname qname, :thread-id thread-idx, :nconsecutive-errors (inc nce)}))
(reset! loop-error-backoff?_ true))]

(when (> thread-idx 0)
Expand Down

0 comments on commit 9dd6720

Please sign in to comment.