Story #3035
closedAs a REST API user, I can determine which publication is associated with a publish task
0%
Updated by dkliban@redhat.com about 7 years ago
- Tracker changed from Issue to Story
- % Done set to 0
- Tags Pulp 3 added
Updated by jortel@redhat.com about 7 years ago
Let's consider adding a natural key to the publication. A name for example that the user can optionally specify. I imagine the user would name the publication based on version of build#. This gives the user something meaningful to use when selecting a publication to be associated to a distribution or to be deleted.
We could default the Publication._name_ to the task ID when not specified by the user.
Should be unique by (publisher_id, name)
We'd need to update the /Publisher/publish endpoint and add an optional "publication_name" parameter which would need to be passed to Publisher.publish().
Updated by dkliban@redhat.com about 7 years ago
This problem could be avoided if we treated publications the same way we treat other resources in Pulp's REST API.
The user currently performs a
POST to http://localhost:8000/api/v3/repositories/foo/publishers/example/bar/publish/
to create a publication. The user receives a 202 response with a reference to a task.
If instead the user performed a
POST to http://localhost:8000/api/v3/repositories/foo/publishers/example/bar/publications/
to create a publication and received a 201 with the created publication that references a task, the user would know which publication to associate with a distribution. The user would also know which task to monitor.
Updated by amacdona@redhat.com about 6 years ago
- Status changed from NEW to CLOSED - CURRENTRELEASE
The task returns created_resources, which includes any created publication.