Skip to content

Upright::ProbeResult.cleanup_stale has same queue and priority as probe jobs #59

Description

@ttilberg

After integrating the recent changes from 0.3, I got an alert that my http probes were no longer reporting. I found that it was because there was a massive queue of cleanup jobs that made their way in via the newer Upright::ProbeResult.cleanup_stale job.

uptime(prod):003>   SolidQueue::Job.where(queue_name: "default").count
=> 610739
uptime(prod):004>   SolidQueue::ReadyExecution.count
=> 384871
uptime(prod):005>   SolidQueue::Job.where(queue_name: "default").group(:class_name).count
=> {"ActiveStorage::PurgeJob" => 596297, "Upright::ProbeCheckJob" => 14452}
uptime(prod):006>

This is my state about an hour after the cleanup_stale task fired off, and none of the probe checks have run.

I think it might be useful to schedule these cleanup tasks with lower priority or low-priority queue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions