allocate_fixed_ip should cleanup with correct param

Bug #1350268 reported by jichenjc
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Undecided
jichenjc

Bug Description

in nova-network , when allocate_fixed_ip failed for some unknown reason

it will add
cleanup.append(fip.disassociate)

to cleanup the stuffs it did when handle exception
but the function is following in objects/fixed_ips.py
def disassociate(self, context):

so the cleanup function will not be executed correctly

try:
                        f()
                    except Exception:
                        LOG.warn(_('Error cleaning up fixed ip allocation. '
                                   'Manual cleanup may be required.'),
                                 exc_info=True)

jichenjc (jichenjc)
Changed in nova:
assignee: nobody → jichenjc (jichenjc)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nova (master)

Fix proposed to branch: master
Review: https://review.openstack.org/110598

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

Reviewed: https://review.openstack.org/110598
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=4dcfa79058a407eb7a6ce83f4d804df19ec95026
Submitter: Jenkins
Branch: master

commit 4dcfa79058a407eb7a6ce83f4d804df19ec95026
Author: jichenjc <email address hidden>
Date: Mon Jul 21 07:53:07 2014 +0800

    Add context as param to cleanup function

    In nova-network, when we start
    to cleanup the stuffs it did when handle exception
    but the function is following in objects/fixed_ips.py
    def disassociate(self, context):
    so the context param is lost and it can lead to problem.

    Change-Id: I66a1681f47fc69bf0fd92137ee27481659833bef
    Closes-Bug: #1350268

Changed in nova:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in nova:
milestone: none → juno-3
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: juno-3 → 2014.2
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.