lib/sidekiq/throttled/queues_pauser.rb in sidekiq-throttled-0.10.0.beta vs lib/sidekiq/throttled/queues_pauser.rb in sidekiq-throttled-0.10.0
- old
+ new
@@ -63,10 +63,13 @@
# Returns queues list with paused queues being stripped out.
#
# @private
# @return [Array<String>]
def filter(queues)
- queues - @paused_queues.to_a
+ @mutex.synchronize { queues - @paused_queues.to_a }
+ rescue => e
+ Sidekiq.logger.error { "[#{self.class}] Failed filter queues: #{e}" }
+ queues
end
# Returns list of paused queues.
#
# @return [Array<String>]