Missing Location in http header when creating new VNF Package Resource

Bug #1915109 reported by YaoYudie
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
tacker
Fix Released
Medium
Sheel Rana

Bug Description

From the standard, when creating new VNF Package Resource, it should return a "201 Created" response containing a representation of the individual VNF package resource and a "Location" HTTP header that points to the new "individual VNF package" resource.
But now , the "Location" HTTP header is missing in the response.

operation log:
root@ubuntu:~# curl -i -X POST http://172.22.39.3:9890/vnfpkgm/v1/vnf_packages -H "Content-type: application/json" -H "X-Auth-Token:$OS_AUTH_TOKEN" -d '{}'
HTTP/1.1 201 Created
Content-Length: 363
Content-Type: application/json
X-Openstack-Request-Id: req-16c1488c-b752-486a-832c-aa9e5a922166
Date: Tue, 09 Feb 2021 03:22:50 GMT

{"usageState": "NOT_IN_USE", "operationalState": "DISABLED", "id": "754edc97-a5cb-4e8f-9dcf-1b3aece0125c", "onboardingState": "CREATED", "userDefinedData": {}, "_links": {"self": {"href": "/vnfpkgm/v1/vnf_packages/754edc97-a5cb-4e8f-9dcf-1b3aece0125c"}, "packageContent": {"href": "/vnfpkgm/v1/vnf_packages/754edc97-a5cb-4e8f-9dcf-1b3aece0125c/package_content"}}}root@ubuntu:~#

YaoYudie (yaoyudie)
Changed in tacker:
assignee: nobody → YaoYudie (yaoyudie)
Changed in tacker:
assignee: YaoYudie (yaoyudie) → nobody
Yasufumi Ogawa (yasufum)
Changed in tacker:
importance: Undecided → High
importance: High → Medium
Changed in tacker:
assignee: nobody → Sheel Rana (ranasheel2000)
Revision history for this message
Yasufumi Ogawa (yasufum) wrote :

Any update?

Revision history for this message
Hiromu Asahina (h-asahina) wrote (last edit ):

To Sheel Rana,

https://review.opendev.org/c/openstack/tacker/+/810340

Hello, I recently pushed the above patch for this bug report.
I would like to take over this report if you don't mind.
If you've already made your patch, please tell me. I'll abandon my patch.
I would be grateful if you could kindly consider my suggestion.

Changed in tacker:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to tacker (master)

Reviewed: https://review.opendev.org/c/openstack/tacker/+/810340
Committed: https://opendev.org/openstack/tacker/commit/36ef500c4198415440056cf8dcb7d3d96f4466ab
Submitter: "Zuul (22348)"
Branch: master

commit 36ef500c4198415440056cf8dcb7d3d96f4466ab
Author: Hiromu Asahina <email address hidden>
Date: Wed Sep 22 05:16:34 2021 +0000

    Add Location to responses of Create VNF Package

    According to SOL005 v3.3.1 Table 9.4.2.3.1-1 [1], the HTTP response
    shall include a "Location" HTTP header that contains the resource URI of
    the individual VNF package resource.

    In order to realize the above, this patch adds a Location header, which
    includes a URL of a created VNF Package, to responses for `POST
    {apiRoot}/vnfpkgm/{apiMajorVersion}/vnf_packages` requests.

    Also, this patch removes unused arguments from methods in ViewBuilder.

    [1] https://www.etsi.org/deliver/etsi_gs/NFV-SOL/001_099/005/03.03.01_60/gs_NFV-SOL005v030301p.pdf

    Signed-off-by: Hiromu Asahina <email address hidden>
    Change-Id: I754afaaf910de0048f4f11e259c644b3e0baea99
    Closes-Bug: #1915109

Changed in tacker:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/tacker 7.0.0.0rc1

This issue was fixed in the openstack/tacker 7.0.0.0rc1 release candidate.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.