Switch to new engine facade for L3RpcCallback

Partially-Implements blueprint: enginefacade-switch

Change-Id: Ida1bcb896c02f1ad04090a99296bc641bd21896d
This commit is contained in:
Rodolfo Alonso Hernandez 2019-05-24 16:58:38 +00:00
parent c3a05cc129
commit 5d35e7d360

View File

@ -263,7 +263,7 @@ class L3RpcCallback(object):
@db_api.retry_db_errors
def update_floatingip_statuses(self, context, router_id, fip_statuses):
"""Update operational status for a floating IP."""
with context.session.begin(subtransactions=True):
with db_api.CONTEXT_WRITER.using(context):
for (floatingip_id, status) in fip_statuses.items():
LOG.debug("New status for floating IP %(floatingip_id)s: "
"%(status)s", {'floatingip_id': floatingip_id,