Skip to content

feat(delayed_job): add opt-in ActiveJob reporting through sentry-rails - #3173

Open
solnic wants to merge 1 commit into
chore/2936-migrate-sentry-resque-to-aj-first-integrationfrom
chore/2935-migrate-sentry-delayed_job-to-aj-first-integration
Open

solnic wants to merge 1 commit into
chore/2936-migrate-sentry-resque-to-aj-first-integrationfrom
chore/2935-migrate-sentry-delayed_job-to-aj-first-integration

Conversation

@solnic

@solnic solnic commented Nov 3, 2026 •

Copy link
Copy Markdown
Collaborator

sentry-delayed_job can now leave ActiveJob jobs running on delayed_job to the sentry-rails ActiveJob integration. The default doesn't change: ActiveJob::QueueAdapters::DelayedJobAdapter is listed in config.rails.skippable_job_adapters, so sentry-delayed_job keeps reporting those jobs. Rails apps opt in by removing it:

Sentry.init do |config|
  config.rails.skippable_job_adapters.delete("ActiveJob::QueueAdapters::DelayedJobAdapter")
end

The choice is made once, when the Rails app boots. Once opted in, sentry-rails reports those jobs. Sentry::DelayedJob::ActiveJobExtension, registered for :delayed_job, adds the delayed_job data:

  • the Active-Job context and the delayed_job.queue and delayed_job.id tags
  • the auto.queue.delayed_job origin
  • Sentry::DelayedJob as the capturing integration

sentry-delayed_job still captures errors raised before the job starts, such as a job class that can no longer be loaded, and skips exceptions sentry-rails already captured. Plain delayed_job jobs are unchanged.

The README and gemspec now say sentry-delayed_job is in maintenance mode: plain delayed_job support keeps getting fixes, and new background-job features go into sentry-rails.


Closes #2935

@solnic
solnic added this pull request to stack #3137 November 3, 2026 14:07
@solnic
solnic force-pushed the chore/2935-migrate-sentry-delayed_job-to-aj-first-integration branch from 1816a94 to f632aa9 Compare November 3, 2026 14:46
@solnic
solnic marked this pull request as ready for review November 3, 2026 15:35

@cursor cursor Bot left a comment •

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Stale Bugbot comment from a previous run.

@solnic
solnic force-pushed the chore/2935-migrate-sentry-delayed_job-to-aj-first-integration branch from f632aa9 to a136f92 Compare November 4, 2026 08:15

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

There are 2 total unresolved issues (including 1 from previous review).

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit a136f92. Configure here.

@solnic
solnic force-pushed the chore/2935-migrate-sentry-delayed_job-to-aj-first-integration branch from 6d86b9f to c33fc6b Compare November 4, 2026 10:22
@solnic
solnic force-pushed the chore/2935-migrate-sentry-delayed_job-to-aj-first-integration branch from c33fc6b to dc77d48 Compare November 4, 2026 10:27
@solnic
solnic force-pushed the chore/2935-migrate-sentry-delayed_job-to-aj-first-integration branch 2 times, most recently from 5bb39bd to 43be990 Compare November 4, 2026 11:10
@solnic
solnic force-pushed the chore/2935-migrate-sentry-delayed_job-to-aj-first-integration branch from 43be990 to 7641210 Compare November 4, 2026 11:40
@solnic
solnic force-pushed the chore/2935-migrate-sentry-delayed_job-to-aj-first-integration branch from 7641210 to 62bf3e6 Compare November 4, 2026 11:56
@solnic
solnic force-pushed the chore/2935-migrate-sentry-delayed_job-to-aj-first-integration branch from 62bf3e6 to 2fd0531 Compare November 4, 2026 12:19
@solnic
solnic force-pushed the chore/2935-migrate-sentry-delayed_job-to-aj-first-integration branch from 2fd0531 to 66f3514 Compare November 4, 2026 12:40
@solnic
solnic force-pushed the chore/2935-migrate-sentry-delayed_job-to-aj-first-integration branch from 66f3514 to 0b04868 Compare November 4, 2026 12:42
@solnic
solnic force-pushed the chore/2935-migrate-sentry-delayed_job-to-aj-first-integration branch from 0b04868 to 7ea3852 Compare November 4, 2026 13:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Migrate sentry-delayed_job to AJ-first integration

1 participant