Skip to content

Integration with Sidekiq

Arthur Nogueira Neves edited this page Aug 6, 2020 · 2 revisions

Marginalia has built-in Sidekiq integration. If you were using custom middleware before, you can remove it and use the gem-provided instrumentation.

Enable the Sidekiq instrumentation:

# In config/initializers/sidekiq.rb
Marginalia::SidekiqInstrumentation.enable!

Add the sidekiq_job component to your annotations:

# In config/initializers/marginalia.rb
Marginalia::Comment.components = %i[
  controller_with_namespace
  action
  sidekiq_job
]
Clone this wiki locally