mirror of
https://github.com/mperham/sidekiq.git
synced 2022-11-09 13:52:34 -05:00
Retry all, fixes #686
This commit is contained in:
parent
f333186ecf
commit
f235f600db
2 changed files with 7 additions and 1 deletions
|
@ -342,6 +342,12 @@ module Sidekiq
|
|||
def initialize
|
||||
super 'retry'
|
||||
end
|
||||
|
||||
def retry_all
|
||||
while size > 0
|
||||
each(&:retry)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
|
|
|
@ -172,7 +172,7 @@ module Sidekiq
|
|||
end
|
||||
|
||||
post "/retries/all/retry" do
|
||||
Sidekiq::RetrySet.new.each { |job| job.retry }
|
||||
Sidekiq::RetrySet.new.retry_all
|
||||
redirect "#{root_path}retries"
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue