mirror of
https://github.com/mperham/sidekiq.git
synced 2022-11-09 13:52:34 -05:00
Fix a few more Exception leaks
This commit is contained in:
parent
4883097866
commit
1d3401afd6
3 changed files with 5 additions and 5 deletions
|
@ -10,7 +10,7 @@ module Sidekiq
|
||||||
logger.info { "start" }
|
logger.info { "start" }
|
||||||
yield
|
yield
|
||||||
logger.info { "done: #{elapsed(start)} sec" }
|
logger.info { "done: #{elapsed(start)} sec" }
|
||||||
rescue
|
rescue Exception
|
||||||
logger.info { "fail: #{elapsed(start)} sec" }
|
logger.info { "fail: #{elapsed(start)} sec" }
|
||||||
raise
|
raise
|
||||||
end
|
end
|
||||||
|
|
|
@ -40,8 +40,8 @@ module Sidekiq
|
||||||
|
|
||||||
def call(worker, msg, queue)
|
def call(worker, msg, queue)
|
||||||
yield
|
yield
|
||||||
rescue => e
|
rescue Exception => e
|
||||||
raise unless msg['retry']
|
raise e unless msg['retry']
|
||||||
|
|
||||||
msg['queue'] = queue
|
msg['queue'] = queue
|
||||||
msg['error_message'] = e.message
|
msg['error_message'] = e.message
|
||||||
|
@ -72,7 +72,7 @@ module Sidekiq
|
||||||
# Goodbye dear message, you (re)tried your best I'm sure.
|
# Goodbye dear message, you (re)tried your best I'm sure.
|
||||||
logger.debug { "Dropping message after hitting the retry maximum: #{msg}" }
|
logger.debug { "Dropping message after hitting the retry maximum: #{msg}" }
|
||||||
end
|
end
|
||||||
raise
|
raise e
|
||||||
end
|
end
|
||||||
|
|
||||||
end
|
end
|
||||||
|
|
|
@ -22,7 +22,7 @@ module Sidekiq
|
||||||
|
|
||||||
def watchdog(last_words)
|
def watchdog(last_words)
|
||||||
yield
|
yield
|
||||||
rescue => ex
|
rescue Exception => ex
|
||||||
handle_exception(ex, { :context => last_words })
|
handle_exception(ex, { :context => last_words })
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue