Project

Profile

Help

Story #2446

closed

As a user, I can use REST API to remove an importer from a repository.

Added by dkliban@redhat.com almost 8 years ago. Updated almost 5 years ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
Normal
Category:
-
Sprint/Milestone:
Start date:
Due date:
% Done:

100%

Estimated time:
Platform Release:
Groomed:
Yes
Sprint Candidate:
Yes
Tags:
Sprint:
Sprint 12
Quarter:

Description

As a result of this story the user will be able to make a DELETE request to /api/v3/importers/<pk> and receive back a 202 response that looks like this:

[
    {
        "_href": "/api/v3/tasks/adlfk-bala-23k5l7-lslser",
        "task_id": "adlfk-bala-23k5l7-lslser"
    }
]

The importer viewset should be extended to handle a DELETE. As a result of the request a pulp.app.tasks.importer.delete.apply_async_with_reservation() should be called and the AsyncResult should be used to instantiate an OperationPostponedResponse[0] object. The object should then be returned.

[0] http://docs.pulpproject.org/en/3.0/nightly/contributing/platform_api/app/response.html#pulp.app.response.OperationPostponedResponse

Also available in: Atom PDF