GET /vnf_packages return type should be list and not dict

Bug #1871054 reported by Tushar Patil
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
tacker
Fix Released
Undecided
Prashant Bhole

Bug Description

Get /vnf_packages is returning list of vnf packages in dict. As per specs, it should be a list.

Actual
{
  "vnf_packages": [
    {
      "vnfSoftwareVersion": "1.0",
      "usageState": "NOT_IN_USE",
      "vnfProductName": "Sample VNF1",
      "vnfdVersion": "1.0",
      "onboardingState": "ONBOARDED",
      "operationalState": "ENABLED",
      "id": "e4b3cc73-f807-47e9-9fee-1be4ee37be54"
      ...........
      ...........
    },
    {
      "vnfSoftwareVersion": "1.0",
      "usageState": "NOT_IN_USE",
      "vnfProductName": "Sample VNF2",
      "vnfdVersion": "1.0",
      "onboardingState": "ONBOARDED",
      "operationalState": "ENABLED",
      "id": "bbbbbb73-f807-47e9-9fee-1be4ee37be54"
      ...........
      ...........
    }
  ]
}

Expected:
[
    {
      "vnfSoftwareVersion": "1.0",
      "usageState": "NOT_IN_USE",
      "vnfProductName": "Sample VNF1",
      "vnfdVersion": "1.0",
      "onboardingState": "ONBOARDED",
      "operationalState": "ENABLED",
      "id": "e4b3cc73-f807-47e9-9fee-1be4ee37be54"
      ...........
      ...........
    },
    {
      "vnfSoftwareVersion": "1.0",
      "usageState": "NOT_IN_USE",
      "vnfProductName": "Sample VNF2",
      "vnfdVersion": "1.0",
      "onboardingState": "ONBOARDED",
      "operationalState": "ENABLED",
      "id": "bbbbbb73-f807-47e9-9fee-1be4ee37be54"
      ...........
      ...........
    }

]

Changed in tacker:
assignee: nobody → Shubham Potale (shubhamp)
Revision history for this message
nitin uikey (nitinuikey) wrote :

As per process to fix this issue we need to provide micro version support in tacker as well as in python-tackerclient for command.
The list api was part of VNF package api which released in train cycle. But we can not instantiate, terminate and Heal VNF as these feature is not released yet and about to release in U cycle. The changes we have proposed will be useful after U release and that is why we think we should do these change without micro version support.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to tacker (master)

Fix proposed to branch: master
Review: https://review.opendev.org/720683

Changed in tacker:
status: New → In Progress
Changed in tacker:
assignee: Shubham Potale (shubhamp) → Tushar Patil (tpatil)
Changed in tacker:
assignee: Tushar Patil (tpatil) → Prashant Bhole (pbhole)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to tacker (master)

Reviewed: https://review.opendev.org/720683
Committed: https://git.openstack.org/cgit/openstack/tacker/commit/?id=70ac63d834ea82425f453329412c8352745a7fa0
Submitter: Zuul
Branch: master

commit 70ac63d834ea82425f453329412c8352745a7fa0
Author: Shubham <email address hidden>
Date: Fri Apr 3 17:55:48 2020 +0530

    Remove 'vnf_packages' key from vnf package list response

    As per ETSI GS NFV-SOL 005 V2.4.1 (2018-02) table 9.4.2.3.2-2, GET Vnf
    Packages should return list of all Vnf packages, but as per current
    implemention this api is returning dictionory with resource name as key
    i.e {'vnf_packages': [{vnf_package1}, {vnf_package2},...]}. Hence
    removing the resource key and returning api response as a list.

    As per process to fix this issue we need to provide micro version
    support in tacker as well as in python-tackerclient for command.
    The list api was part of VNF package api which released in train cycle.
    But we can not instantiate, terminate and Heal VNF as these feature is
    not released yet and about to release in U cycle. The changes we have
    proposed will be useful after U release and that is why we think we
    should do these change without micro version support.

    Closes-bug: #1871054
    Change-Id: I7f5105fc7a49f9d31fb32119c725dae0421cfde7

Changed in tacker:
status: In Progress → Fix Released
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.