Actions
Story #1111
closedAs an API user, I can purge completed task status records
Start date:
Due date:
% Done:
100%
Estimated time:
Platform Release:
2.8.0
Groomed:
Yes
Sprint Candidate:
Yes
Tags:
Pulp 2
Sprint:
Quarter:
Description
I suggest adding support for the DELETE method on this endpoint: https://pulp.readthedocs.org/en/latest/dev-guide/integration/rest-api/dispatch/task.html#listing-tasks
And require query args that limit it to final states. For example:
DELETE - https://mypulp/pulp/api/v2/tasks/?state=finished&state=error
If a request has no query args or specifies a non-final state, the response should be a 403.
Questions
- Should this be done asynchronously? Mongo is probably real fast at dropping records, but is it fast enough? I'd start with doing it synchronously if we can't answer the questions quickly.
- Can we safely delete tasks in the "cancelled" state? How can we know that the task isn't in the process of being cancelled? Maybe we can look at the "finish_time"?
Related issues
Actions
Story 1111: Purge completed task status records
https://pulp.plan.io/issues/1111
closes #1111