From 58b7d9a03934ece4d4ac2c36bfe16aa6a8859140 Mon Sep 17 00:00:00 2001 From: Michael Johnson Date: Sun, 17 Jun 2018 14:06:53 -0700 Subject: [PATCH] Stop logging API not found as ERROR Currently if the user requests and object that is not found the API will log this as an "ERRROR" level message. This patch changes this to be a debug message as lookup of objects that have been deleted is a normal occurrence. Change-Id: I4e0db4b05b8636c40a62928e0b462ae73236eea0 --- octavia/api/v2/controllers/base.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/octavia/api/v2/controllers/base.py b/octavia/api/v2/controllers/base.py index 6c7e3506f4..f9c143e468 100644 --- a/octavia/api/v2/controllers/base.py +++ b/octavia/api/v2/controllers/base.py @@ -58,8 +58,8 @@ class BaseController(rest.RestController): """Gets an object from the database and returns it.""" db_obj = repo.get(session, id=id, show_deleted=show_deleted) if not db_obj: - LOG.exception('%(name)s %(id)s not found', - {'name': data_model._name(), 'id': id}) + LOG.debug('%(name)s %(id)s not found', + {'name': data_model._name(), 'id': id}) raise exceptions.NotFound( resource=data_model._name(), id=id) return db_obj