]> review.fuel-infra Code Review - openstack-build/cinder-build.git/commitdiff
Remove WritableLogger wrapper
authorIgor Pugovkin <ipugovkin@mirantis.com>
Mon, 15 Jun 2015 09:10:41 +0000 (12:10 +0300)
committerIgor Pugovkin <ipugovkin@mirantis.com>
Mon, 15 Jun 2015 10:18:00 +0000 (13:18 +0300)
With Eventlet 0.17.2, we can directly pass the logger
instance. This allows us to deprecate/remove the WritableLogger
class from oslo.log.

Change-Id: Ib7d193435584fc3631740058ed34b4df4ab23ad6
Closes-Bug: #1440773

cinder/wsgi.py

index 1d1c4d0e39201657c104318b600a1ff37715f16e..16e0ce1c0c7604ef8c315b7ae6ee85194973fcab 100644 (file)
@@ -31,7 +31,6 @@ import eventlet.wsgi
 import greenlet
 from oslo_config import cfg
 from oslo_log import log as logging
-from oslo_log import loggers
 from oslo_utils import excutils
 from oslo_utils import netutils
 from paste import deploy
@@ -129,7 +128,6 @@ class Server(object):
         self.pool_size = pool_size or self.default_pool_size
         self._pool = eventlet.GreenPool(self.pool_size)
         self._logger = logging.getLogger("eventlet.wsgi.server")
-        self._wsgi_logger = loggers.WritableLogger(self._logger)
 
         if backlog < 1:
             raise exception.InvalidInput(
@@ -242,7 +240,7 @@ class Server(object):
             'site': self.app,
             'protocol': self._protocol,
             'custom_pool': self._pool,
-            'log': self._wsgi_logger,
+            'log': self._logger,
             'socket_timeout': self.client_socket_timeout,
             'keepalive': CONF.wsgi_keep_alive
         }