Improve message in the NetworkInUse exception

Bug #1953716 reported by Slawek Kaplonski
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
neutron
Fix Released
Medium
yatin

Bug Description

Message returned to the user while trying to delete network which still have some ports could have uuid of the ports which blocks network deletion. It could maybe list those ports in the error message.

It was reported as one of the pain points in the https://etherpad.opendev.org/p/pain-point-elimination

Tags: api
yatin (yatinkarel)
Changed in neutron:
assignee: Slawek Kaplonski (slaweq) → yatin (yatinkarel)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to neutron-lib (master)

Related fix proposed to branch: master
Review: https://review.opendev.org/c/openstack/neutron-lib/+/821806

yatin (yatinkarel)
Changed in neutron:
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to neutron-lib (master)

Reviewed: https://review.opendev.org/c/openstack/neutron-lib/+/821806
Committed: https://opendev.org/openstack/neutron-lib/commit/6a922e45b0be869a22f43609178e77ba0252f6ea
Submitter: "Zuul (22348)"
Branch: master

commit 6a922e45b0be869a22f43609178e77ba0252f6ea
Author: yatinkarel <email address hidden>
Date: Wed Dec 15 14:09:47 2021 +0530

    Allow to pass custom reason in NetworkInUse exception

    In order to pass custom reason like what ports are
    being used on the network, need to allow the Exception
    to except "reason" argument.

    Related-Bug: #1953716
    Change-Id: I264cda4ac8d5a737e172a62fa2761fd14fc746f3

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

Fix proposed to branch: master
Review: https://review.opendev.org/c/openstack/neutron/+/821935

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on neutron (master)

Change abandoned by "yatin <email address hidden>" on branch: master
Review: https://review.opendev.org/c/openstack/neutron/+/821935
Reason: pypi failures

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

Reviewed: https://review.opendev.org/c/openstack/neutron/+/821935
Committed: https://opendev.org/openstack/neutron/commit/7b61adbb4a0e3147e08e511cdf40a4073c00d099
Submitter: "Zuul (22348)"
Branch: master

commit 7b61adbb4a0e3147e08e511cdf40a4073c00d099
Author: yatinkarel <email address hidden>
Date: Thu Dec 16 11:38:20 2021 +0530

    List ports when attempt to delete network with ports

    When there is attempt to delete network with ports,
    a general error message is displayed that one or more
    ports are in use on the network. This patch proposes
    to also return the ports which are in use as part of
    the message.

    Also modify test_delete_network_if_port_exists unit
    test to check for port id and network id in Error
    message.

    Also bump required version of neutron-lib to 2.18.0
    as that's needed for custom message in NetworkInUse
    Exception.

    Depends-On: https://review.opendev.org/c/openstack/neutron-lib/+/821806

    Closes-Bug: #1953716
    Change-Id: Ib0b40402746c6a487a226b238907142384608d3c

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

This issue was fixed in the openstack/neutron 20.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.