]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commit
Fix neutron hang for IPv6 allocation pool update
authorsridhargaddam <sridhar.gaddam@enovance.com>
Mon, 15 Dec 2014 11:11:15 +0000 (11:11 +0000)
committersridhargaddam <sridhar.gaddam@enovance.com>
Mon, 15 Dec 2014 11:11:26 +0000 (11:11 +0000)
commitb38f1bfa7b4f662182f552530b43301b214baa8d
tree1cc2ef33935f8141ffd8406366d1e69e102fad19
parent817956e6ea725a42e2a1695e6992f68ffeac2d72
Fix neutron hang for IPv6 allocation pool update

While rebuilding IPAllocationPools, Neutron is using netaddr.iter_iprange
(a generator that produces IPAddress objects). For an IPv6 subnet, this is
a costly operation and is causing Neutron Server to hang. This patch
addresses the issue by replacing netaddr.iter_iprange with netaddr.IPRange
which provides the same functionality while calculating the IPSets.

Closes-Bug: #1401751
Change-Id: I2287e5348aab82e39cf1b6e2884d08237a09b06d
neutron/db/db_base_plugin_v2.py
neutron/tests/unit/test_db_plugin.py