module Sidekiq::CircuitBreaker::Scope
Public Instance Methods
extract_scope(worker_class_name, msg, options)
click to toggle source
# File lib/sidekiq/circuit_breaker/scope.rb, line 4 def extract_scope(worker_class_name, msg, options) from_setup = begin scope = options.scope return scope if scope.is_a?(String) return unless scope.respond_to?(:call) options.scope.call(*msg['args']) end from_setup || worker_class_name end