Skip to content

Commit

Permalink
Fix iterable jobs cancellation (#6589)
Browse files Browse the repository at this point in the history
  • Loading branch information
fatkodima committed Jan 25, 2025
1 parent 57bdf45 commit e0ccdb0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/sidekiq/job/iterable.rb
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ def iterate_with_enumerator(enumerator, arguments)
if ::Process.clock_gettime(::Process::CLOCK_MONOTONIC) - state_flushed_at >= STATE_FLUSH_INTERVAL || is_interrupted
_, _, cancelled = flush_state
state_flushed_at = ::Process.clock_gettime(::Process::CLOCK_MONOTONIC)
if cancelled == 1
if cancelled
@_cancelled = true
logger.info { "Job cancelled" }
return true
Expand Down

0 comments on commit e0ccdb0

Please # to comment.