Remove an external port when an error occurs during FIP creation.
Fixes bug 1048140 To remove an external port, we need to use the same context used when it is created. Change-Id: Ia89b086b420741e7e0e92625b62e46fcfe9dbbba
This commit is contained in:
parent
6f8939ee96
commit
aa100f9f66
@ -578,7 +578,8 @@ class L3_NAT_db_mixin(l3.RouterPluginBase):
|
||||
except Exception:
|
||||
LOG.exception("Floating IP association failed")
|
||||
# Remove the port created for internal purposes
|
||||
self.delete_port(context, external_port['id'], l3_port_check=False)
|
||||
self.delete_port(context.elevated(), external_port['id'],
|
||||
l3_port_check=False)
|
||||
raise
|
||||
|
||||
return self._make_floatingip_dict(floatingip_db)
|
||||
|
Loading…
x
Reference in New Issue
Block a user