]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commitdiff
Lower severity of log trace for DB integrity error
authorarmando-migliaccio <amigliaccio@nicira.com>
Fri, 15 Nov 2013 02:22:26 +0000 (18:22 -0800)
committerarmando-migliaccio <amigliaccio@nicira.com>
Fri, 15 Nov 2013 02:24:17 +0000 (18:24 -0800)
LOG.exception is not appropriate, since a concurrent
port creation can occur and it has been dealt with
in the except block.

This avoids spooking users who are on the hunt for
real bugs.

Supports fix for 1239637

Change-Id: I9489702ee63db0b004fe41195fa4727af261d514

neutron/plugins/ml2/plugin.py

index 4f7e556903cfabd40bbd0fbf717baeaf2e2f11da..973a9fe14d342e5408d487ec6f02a82053b28005 100644 (file)
@@ -425,7 +425,7 @@ class Ml2Plugin(db_base_plugin_v2.NeutronDbPluginV2,
             except os_db.exception.DBError as e:
                 if isinstance(e.inner_exception, sql_exc.IntegrityError):
                     msg = _("A concurrent port creation has occurred")
-                    LOG.exception(msg)
+                    LOG.warning(msg)
                     continue
                 else:
                     raise