Project

Profile

Help

Issue #8988

`pulpcore-worker` startup should remove old worker records

Added by bmbouter 3 months ago. Updated 4 days ago.

Status:
NEW
Priority:
Low
Assignee:
-
Category:
-
Sprint/Milestone:
-
Start date:
Due date:
Estimated time:
Severity:
2. Medium
Version:
Platform Release:
OS:
Triaged:
Yes
Groomed:
No
Sprint Candidate:
No
Tags:
Sprint:
Sprint 106
Quarter:

Description

To reproduce

  1. Start a pulpcore-worker against an empty database
  2. Observe that the status API shows that worker
  3. kill -9 your worker
  4. Observe the status API after 30 seconds no longer shows your worker
  5. Start your pulpcore-worker again
  6. Go into shell_plus and observe this query shows 2 workers present: Workers.objects.count()

Expected result

In [1]: Worker.objects.count()
Out[1]: 1

Solution

Have workers that startup run a query that delete any workers that haven't issued a heartbeat in say 7 days. This does not need to be configurable. The 7 day idea is to make something that won't let records accumulate on the long term, but leave them in place for someone to look at the db post-mortem and still see them for investigation.

History

#1 Updated by dkliban@redhat.com 3 months ago

  • Priority changed from Normal to Low
  • Triaged changed from No to Yes
  • Sprint set to Sprint 100

#2 Updated by rchan 2 months ago

  • Sprint changed from Sprint 100 to Sprint 101

#3 Updated by ipanova@redhat.com about 2 months ago

  • Sprint changed from Sprint 101 to Sprint 102

#4 Updated by rchan about 2 months ago

  • Sprint changed from Sprint 102 to Sprint 103

#5 Updated by rchan about 1 month ago

  • Sprint changed from Sprint 103 to Sprint 104

#6 Updated by rchan 18 days ago

  • Sprint changed from Sprint 104 to Sprint 105

#7 Updated by rchan 4 days ago

  • Sprint changed from Sprint 105 to Sprint 106

Please register to edit this issue

Also available in: Atom PDF