Routed provider networks nova inventory update fails

Bug #1836037 reported by Lajos Katona on 2019-07-10
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
neutron
Medium
Lajos Katona

Bug Description

The patch https://review.opendev.org/663980 introduced a serious misreading of placement API.
The lines https://review.opendev.org/#/c/663980/2/neutron/services/segments/plugin.py@220 assumes that "Show resource provider inventory" (see: https://developer.openstack.org/api-ref/placement/?expanded=show-resource-provider-inventory-detail#show-resource-provider-inventory) returns a dict with like
{'IPV4_ADDRESS': {'allocation_ratio': 42....}}
but if we read the documentation the truth is that the response is a dict like:
{'allocation_ratio': 42....}

The other fix in that patch is good as it is (https://review.opendev.org/#/c/663980/2/neutron/services/segments/plugin.py@255) for "Update resource provider inventories" (see: https://developer.openstack.org/api-ref/placement/?expanded=update-resource-provider-inventories-detail#update-resource-provider-inventories)

Changed in neutron:
assignee: nobody → Lajos Katona (lajos-katona)

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

Changed in neutron:
status: New → In Progress
Changed in neutron:
importance: Undecided → Medium

Reviewed: https://review.opendev.org/670105
Committed: https://git.openstack.org/cgit/openstack/neutron/commit/?id=12ab7c4cb149147e3e7886233f4ba99c3484f923
Submitter: Zuul
Branch: master

commit 12ab7c4cb149147e3e7886233f4ba99c3484f923
Author: elajkat <email address hidden>
Date: Wed Jul 10 17:20:22 2019 +0200

    segments: fix rp inventory update

    The patch https://review.opendev.org/663980 made resource provider
    inventory update failing with the assumption that inventory update
    expects a dict with a key of the resource class, like resource provider
    inventories update.
    See the placement API-ref:
    https://developer.openstack.org/api-ref/placement/#update-resource-provider-inventory
    https://developer.openstack.org/api-ref/placement/#update-resource-provider-inventories

    Change-Id: I7de1a947b864eb5ac57ebaca895f827d2e667443
    Closes-Bug: #1836037
    Related-Bug: #1828543

Changed in neutron:
status: In Progress → Fix Released

This issue was fixed in the openstack/neutron 15.0.0.0b1 development milestone.

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

Other bug subscribers