Skip to content

[Bug] Pipeline worker no-progress can leave jobs wedged indefinitely #4342

Open

Description

@sachintandon

Summary

A background pipeline worker can stop advancing a job while the server remains available. The job last_processed_at then remains stale, there is no useful per-worker heartbeat to distinguish a worker stall from normal queueing, and recovery may depend on a server process restart. The underlying stall trigger is not yet established.

Expected behavior

  • Expose worker/task heartbeat and pending-work/progress metrics so a stalled pipeline is observable.
  • Ensure per-item exceptions record an error and advance retry/progress metadata before the item is retried or backed off.
  • Do not silently stop processing a job after a transient exception.

Please add regression tests for a failing item followed by successful retry and for stale-worker detection. Related historical reports include #825 and #3886, but this issue focuses on persistent worker no-progress and observability.

Activity

  1. github-actions commented on Nov 6, 2026

    @github-actions

    This issue is stale because it has been open for 30 days with no activity.

  2. Outvoker commented on Nov 12, 2026

    @Outvoker

    Reproduced on 0.22.5, which already includes #4354 and #4374, so neither of those fixes it.

    • 8 jobs (6 projects) were stuck in submitted with last_processed_at == submitted_at, the oldest for ~20 h. Other jobs submitted in the same window were provisioned normally.
    • One replica kept logging Updating lock_expires_at for items: [<those ids>] every ~20 s, but never Processing jobs item for them.
    • That replica also held DB sessions idle in transaction / ClientRead for 2.5–6.8 h. The last statement in each was SELECT fleets..., with no locks beyond AccessShareLock and nothing blocked behind them. So a jobs_submitted worker is hanging on an await after loading fleets, not on the DB.
    • process() in pipeline_tasks/base.py has no timeout, and the heartbeat keeps renewing the lock, so one hung await pins the job forever.
    • Deleting that replica fixed it: the other replicas provisioned all 8 jobs within ~25 s.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions