Project

Profile

Help

Issue #456

closed

no id in _href in a response body when retrive all event listeners

Added by igulina@redhat.com about 9 years ago. Updated almost 4 years ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
Normal
Category:
-
Sprint/Milestone:
-
Start date:
Due date:
Estimated time:
Severity:
1. Low
Version:
2.4 Beta
Platform Release:
2.7.0
OS:
Triaged:
Yes
Groomed:
No
Sprint Candidate:
No
Tags:
Pulp 2
Sprint:
Quarter:

Description

Description of problem:

Here https://pulp-dev-guide.readthedocs.org/en/latest/integration/rest-api/event/crud.html#retrieve-all-event-listeners

According docs _href in a response body should contain id of an event listener.
In fact, it doesn't.

Version-Release number of selected component (if applicable):

rpm -qa pulp-server

pulp-server-2.4.0-0.20.beta.el6.noarch

How reproducible:
always

Steps to Reproduce:

curl -k -X GET https://admin:admin@localhost/pulp/api/v2/events/

[{"_href": "/pulp/api/v2/events/", "notifier_config": {"url": "http://localhost/api"}, "_ns": "event_listeners", "event_types": ["repo.sync.start"], "_id": {"$oid": "53a1ba0fb7e943519221158a"}, "id": "53a1ba0fb7
e943519221158a", "notifier_type_id": "http"}]

curl -i -H "Accept: application/json" -X POST -k -u admin:admin -d '{"notifier_type_id" : "http", "notifier_config" : {"url" : "http://localhost/api"},"event_types" : ["repo.sync.finish

", "repo.publish.finish"]}' 'https://localhost/pulp/api/v2/events/'

HTTP/1.1 201 Created
Date: Thu, 19 Jun 2014 14:11:45 GMT
Server: Apache/2.2.15 (Red Hat)
Location: /pulp/api/v2/events/53a2efa1b7e943519470c186/
Content-Length: 303
Connection: close
Content-Type: application/json

{"_href": "/pulp/api/v2/events/53a2efa1b7e943519470c186/", "notifier_config": {"url": "http://localhost/api"}, "_ns": "event_listeners", "event_types": ["repo.sync.finish", "repo.publish.finish"], "_id": {"$oid"
: "53a2efa1b7e943519470c186"}, "id": "53a2efa1b7e943519470c186", "notifier_type_id": "http"}

curl -k -X GET https://admin:admin@localhost/pulp/api/v2/events/

[{"_href": "/pulp/api/v2/events/", "notifier_config": {"url": "http://localhost/api"}, "_ns": "event_listeners", "event_types": ["repo.sync.start"], "_id": {"$oid": "53a1ba0fb7e943519221158a"}, "id": "53a1ba0fb7
e943519221158a", "notifier_type_id": "http"}, {"_href": "/pulp/api/v2/events/", "notifier_config": {"url": "http://localhost/api"}, "_ns": "event_listeners", "event_types": ["repo.sync.finish", "repo.publish.fin
ish"], "_id": {"$oid": "53a2efa1b7e943519470c186"}, "id": "53a2efa1b7e943519470c186", "notifier_type_id": "http"}]

Expected results:
[{"_href": "/pulp/api/v2/events/53a1ba0fb7e943519221158a/", "notifier_config": {"url": "http://localhost/api"}, "_ns": "event_listeners", "event_types": ["repo.sync.start"], "_id": {"$oid": "53a1ba0fb7e943519221158a"}, "id": "53a1ba0fb7
e943519221158a", "notifier_type_id": "http"}, {"_href": "/pulp/api/v2/events/53a2efa1b7e943519470c186/", "notifier_config": {"url": "http://localhost/api"}, "_ns": "event_listeners", "event_types": ["repo.sync.finish", "repo.publish.fin
ish"], "_id": {"$oid": "53a2efa1b7e943519470c186"}, "id": "53a2efa1b7e943519470c186", "notifier_type_id": "http"}]

+ This bug was cloned from Bugzilla Bug #1111255 +

Also available in: Atom PDF