Make nova-network use FixedIP for timeouts

This makes nova-network manager use the FixedIP object when
disassociating addresses due to timeout.

Related to blueprint nova-network-objects

Change-Id: I909f710543239207f6d27230b527b4495a23f2cb
This commit is contained in:
Dan Smith 2014-01-16 17:03:41 -08:00
parent 542958fac7
commit 9776175fc3

View File

@ -358,9 +358,9 @@ class NetworkManager(manager.Manager):
now = timeutils.utcnow()
timeout = CONF.fixed_ip_disassociate_timeout
time = now - datetime.timedelta(seconds=timeout)
num = self.db.fixed_ip_disassociate_all_by_timeout(context,
self.host,
time)
num = fixed_ip_obj.FixedIP.disassociate_all_by_timeout(context,
self.host,
time)
if num:
LOG.debug(_('Disassociated %s stale fixed ip(s)'), num)