diff options
author | Jenkins <jenkins@review.openstack.org> | 2015-05-15 14:36:22 +0000 |
---|---|---|
committer | Gerrit Code Review <review@openstack.org> | 2015-05-15 14:36:22 +0000 |
commit | 88277a07d304a1f88fc08d44917852a46e2bd857 (patch) | |
tree | 7b5bd595d55b2247a196c6995f9c1d5daeacafb9 | |
parent | 059fa75a496613e77c370ca50592e771e5d8ca5e (diff) | |
parent | 7918c9aca607f18e2f9c308d329e758bc334e04f (diff) | |
download | oslo-db-88277a07d304a1f88fc08d44917852a46e2bd857.tar.gz |
Merge "Avoid excessing logging of RetryRequest exception" into stable/kilo1.7.2
-rw-r--r-- | oslo_db/api.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/oslo_db/api.py b/oslo_db/api.py index 616cac5..0ba07e8 100644 --- a/oslo_db/api.py +++ b/oslo_db/api.py @@ -139,7 +139,11 @@ class wrap_db_retry(object): raise e if remaining != -1: remaining -= 1 - LOG.exception(_LE('DB error.')) + # RetryRequest is application-initated exception + # and not an error condition in case retries are + # not exceeded + if not isinstance(e, exception.RetryRequest): + LOG.exception(_LE('DB error.')) # NOTE(vsergeyev): We are using patched time module, so # this effectively yields the execution # context to another green thread. |