# under the License.
import netaddr
-from oslo_db import exception as db_exc
from oslo_log import log as logging
from oslo_utils import uuidutils
import sqlalchemy as sa
if gw_info:
self._update_router_gw_info(context, router_db['id'],
gw_info, router=router_db)
- except Exception as e:
+ except Exception:
with excutils.save_and_reraise_exception():
- # NOTE(kevinbenton): db errors will be retried by the decorator
- # at the API layer so it's not a complete failure scenario.
- if not isinstance(e, (db_exc.DBDeadlock, db_exc.RetryRequest)):
- LOG.exception(_LE("An exception occurred while creating "
- "the router: %s"), router)
+ LOG.debug("Could not update gateway info, deleting router.")
self.delete_router(context, router_db.id)
return self._make_router_dict(router_db)