Bug 1480281 - [RFE] href not returned when ordering service from the service_templates subcollection
Summary: [RFE] href not returned when ordering service from the service_templates subc...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat CloudForms Management Engine
Classification: Red Hat
Component: API
Version: 5.8.0
Hardware: Unspecified
OS: Unspecified
high
medium
Target Milestone: GA
: 5.9.0
Assignee: Jillian Tullo
QA Contact: Martin Kourim
URL:
Whiteboard: api:rest:services
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-08-10 15:10 UTC by Martin Kourim
Modified: 2018-03-01 13:15 UTC (History)
5 users (show)

Fixed In Version: 5.9.0.2
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-03-01 13:15:53 UTC
Category: ---
Cloudforms Team: ---
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2018:0380 0 normal SHIPPED_LIVE Moderate: Red Hat CloudForms security, bug fix, and enhancement update 2018-03-01 18:37:12 UTC

Description Martin Kourim 2017-08-10 15:10:34 UTC
Description of problem:
When service is ordered from service catalog using the request on the service_templates subcollection, the data returned in response corresponds to the service_requests collection. However since no "href" is returned, it's hard to figure out that the response doesn't correspond to the originating subcollection (i.e. service_templates).

When the request is made on a resource under the service_templates subcollection, the correct "href" is returned.


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


How reproducible:
very


Steps to Reproduce:
Order catalog item from the service_templates subcollection:

POST /api/service_catalogs/62/service_templates
{
  "action": "order",
  "resources": [{
    "href": "https://<address>/api/service_catalogs/:catalog_id/service_templates/:template_id"
  }]
}

Response:
{
    "results": [
        {
            "id": 27,
            "description": "Provisioning Service [item_4D2Nq] from [item_4D2Nq]",
...
<= no "href" is present - it should point to "https://<address>/api/service_requests/27", otherwise it's difficult to find out what resource does the id belongs to.

Compared to:
POST /api/service_catalogs/62/service_templates/:template_id
{ "action": "order" }

Response:
{
    "href": "https://<address>/api/service_requests/28",
    "id": 28,
    "description": "Provisioning Service [item_4D2Nq] from [item_4D2Nq]",
...
<= here the "href" is present

Comment 2 Jillian Tullo 2017-10-04 19:16:46 UTC
https://github.com/ManageIQ/manageiq-api/pull/104

Comment 3 Martin Kourim 2017-10-19 14:20:40 UTC
Verified that href is returned when ordering service from the service_templates subcollection.

Comment 6 errata-xmlrpc 2018-03-01 13:15:53 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2018:0380


Note You need to log in before you can comment on or make changes to this bug.