Skip to content
This repository has been archived by the owner on Sep 26, 2019. It is now read-only.

Commit

Permalink
Use Swift's get_logger
Browse files Browse the repository at this point in the history
Change-Id: Ifc78569a182e592ca390896f0373bd13be53d688
  • Loading branch information
tipabu committed Aug 30, 2017
1 parent b4c2590 commit be22c9d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions swift3/s3_token_middleware.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,15 +33,14 @@

import base64
import json
import logging

import requests
import six
from six.moves import urllib

from swift.common.swob import Request, HTTPBadRequest, HTTPUnauthorized, \
HTTPException
from swift.common.utils import config_true_value, split_path
from swift.common.utils import config_true_value, split_path, get_logger
from swift.common.wsgi import ConfigFileError

from swift3.utils import is_valid_ipv6
Expand Down Expand Up @@ -119,7 +118,8 @@ class S3Token(object):
def __init__(self, app, conf):
"""Common initialization code."""
self._app = app
self._logger = logging.getLogger(conf.get('log_name', __name__))
self._logger = get_logger(
conf, log_route=conf.get('log_name', __name__))
self._logger.debug('Starting the %s component', PROTOCOL_NAME)
self._timeout = float(conf.get('http_timeout', '10.0'))
if not (0 < self._timeout <= 60):
Expand Down

0 comments on commit be22c9d

Please sign in to comment.