From ce538eb8bcc732b19589739cf2d4cf7da2e277dc Mon Sep 17 00:00:00 2001 From: gongysh Date: Mon, 19 Nov 2012 10:00:01 +0800 Subject: [PATCH] Delete floating port and floatingip in the same transaction Bug #1080516 Change-Id: Icb5b71e29af582cb0e381e22909f46b325063d71 --- quantum/db/l3_db.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/quantum/db/l3_db.py b/quantum/db/l3_db.py index 1886ead0b..035f10b6d 100644 --- a/quantum/db/l3_db.py +++ b/quantum/db/l3_db.py @@ -606,9 +606,9 @@ class L3_NAT_db_mixin(l3.RouterPluginBase): floatingip = self._get_floatingip(context, id) with context.session.begin(subtransactions=True): context.session.delete(floatingip) - self.delete_port(context.elevated(), - floatingip['floating_port_id'], - l3_port_check=False) + self.delete_port(context.elevated(), + floatingip['floating_port_id'], + l3_port_check=False) def get_floatingip(self, context, id, fields=None): floatingip = self._get_floatingip(context, id) -- 2.45.2