Silence swiftclient logging

swiftclient doesn't use oslo_log and logs ERROR with TRACE for
response exceptions like 404. This isn't desirable for heat which
relies on 404s to know a delete is complete.

This change sets the swiftclient logging level to CRITICAL in the
client plugin.

Change-Id: Ie11a6d19068169424ee883ce428aad306d647f0d
Partial-Bug: #1606404
This commit is contained in:
Steve Baker 2016-07-26 04:13:44 +00:00
parent cd125f328e
commit 299d1f591d
1 changed files with 6 additions and 0 deletions

View File

@ -14,6 +14,7 @@
import datetime
import email.utils
import hashlib
import logging
import random
import time
@ -32,6 +33,11 @@ MAX_EPOCH = 2147483647
CLIENT_NAME = 'swift'
# silence the swiftclient logging
sc_logger = logging.getLogger("swiftclient")
sc_logger.setLevel(logging.CRITICAL)
class SwiftClientPlugin(client_plugin.ClientPlugin):
exceptions_module = exceptions