Sha256: 2f4ee39cbeda02e4d982042c0b581ca81b1d95b5dae3509f315edc7c82803499
Contents?: true
Size: 1.03 KB
Versions: 18
Compression:
Stored size: 1.03 KB
Contents
require "sidekiq" require "sentry-ruby" require "sentry/integrable" require "sentry/sidekiq/version" require "sentry/sidekiq/configuration" require "sentry/sidekiq/error_handler" require "sentry/sidekiq/sentry_context_middleware" module Sentry module Sidekiq extend Sentry::Integrable register_integration name: "sidekiq", version: Sentry::Sidekiq::VERSION if defined?(::Rails::Railtie) class Railtie < ::Rails::Railtie config.after_initialize do next unless Sentry.initialized? && defined?(::Sentry::Rails) Sentry.configuration.rails.skippable_job_adapters << "ActiveJob::QueueAdapters::SidekiqAdapter" end end end end end Sidekiq.configure_server do |config| config.error_handlers << Sentry::Sidekiq::ErrorHandler.new config.server_middleware do |chain| chain.add Sentry::Sidekiq::SentryContextServerMiddleware end end Sidekiq.configure_client do |config| config.client_middleware do |chain| chain.add Sentry::Sidekiq::SentryContextClientMiddleware end end
Version data entries
18 entries across 18 versions & 1 rubygems