| Class | NewRelic::Agent::Samplers::DelayedJobSampler |
| In: |
lib/new_relic/agent/samplers/delayed_job_sampler.rb
|
| Parent: | NewRelic::Agent::Sampler |
This sampler records the status of your delayed job table once a minute. It assumes jobs are cleared after being run, and failed jobs are not (otherwise the failed job metric is useless).
In earlier versions it will break out the queue length by priority. In later versions of DJ where distinct queues are supported, it breaks it out by queue name.
| FAILED_QUERY | = | 'failed_at is not NULL'.freeze |
| LOCKED_QUERY | = | 'locked_by is not NULL'.freeze |
| QUEUE_QUERY_CONDITION | = | 'run_at <= ? and failed_at is NULL'.freeze |