Sha256: 12079c6ff6de5f7460cbe6b3de3d4dd093a97999174cf55a4d032a50af5072b5

Contents?: true

Size: 484 Bytes

Versions: 8

Compression:

Stored size: 484 Bytes

Contents

# encoding: utf-8

if Sidekiq::VERSION < '3'
  module RuntimeerrorNotifier
    class Sidekiq
      def call(worker, msg, queue)
        begin
          yield
        rescue Exception => e
          ::RuntimeerrorNotifier::Notifier.notification(msg, e)
          raise
        end
      end
    end
  end
else
  Sidekiq.configure_server do |config|
    config.error_handlers << Proc.new do |e, context|
      ::RuntimeerrorNotifier::Notifier.notification(context, e)
    end
  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
runtimeerror_notifier-0.0.27 lib/runtimeerror_notifier/sidekiq.rb
runtimeerror_notifier-0.0.26 lib/runtimeerror_notifier/sidekiq.rb
runtimeerror_notifier-0.0.25 lib/runtimeerror_notifier/sidekiq.rb
runtimeerror_notifier-0.0.24 lib/runtimeerror_notifier/sidekiq.rb
runtimeerror_notifier-0.0.23 lib/runtimeerror_notifier/sidekiq.rb
runtimeerror_notifier-0.0.22 lib/runtimeerror_notifier/sidekiq.rb
runtimeerror_notifier-0.0.21 lib/runtimeerror_notifier/sidekiq.rb
runtimeerror_notifier-0.0.20 lib/runtimeerror_notifier/sidekiq.rb