Merge "proxy: Downgrade some client problems to info"
This commit is contained in:
commit
fe284ab15e
@ -1312,7 +1312,7 @@ class GetOrHeadHandler(object):
|
||||
_('Trying to read during GET'))
|
||||
raise
|
||||
except ChunkWriteTimeout:
|
||||
self.app.logger.warning(
|
||||
self.app.logger.info(
|
||||
_('Client did not read from proxy within %ss') %
|
||||
self.app.client_timeout)
|
||||
self.app.logger.increment('client_timeouts')
|
||||
@ -1327,7 +1327,7 @@ class GetOrHeadHandler(object):
|
||||
if end - begin + 1 == self.bytes_used_from_backend:
|
||||
warn = False
|
||||
if not req.environ.get('swift.non_client_disconnect') and warn:
|
||||
self.app.logger.warning('Client disconnected on read of %r',
|
||||
self.app.logger.info('Client disconnected on read of %r',
|
||||
self.path)
|
||||
raise
|
||||
except Exception:
|
||||
|
@ -1244,7 +1244,7 @@ class TestFuncs(BaseTest):
|
||||
client_chunks = list(app_iter)
|
||||
self.assertEqual(client_chunks, [b'abcd1234', b'efgh5678'])
|
||||
|
||||
def test_disconnected_warning(self):
|
||||
def test_disconnected_logging(self):
|
||||
self.app.logger = mock.Mock()
|
||||
req = Request.blank('/v1/a/c/o')
|
||||
|
||||
@ -1271,7 +1271,7 @@ class TestFuncs(BaseTest):
|
||||
'some-path', {})
|
||||
app_iter = handler._make_app_iter(req, node, source)
|
||||
app_iter.close()
|
||||
self.app.logger.warning.assert_called_once_with(
|
||||
self.app.logger.info.assert_called_once_with(
|
||||
'Client disconnected on read of %r', 'some-path')
|
||||
|
||||
self.app.logger = mock.Mock()
|
||||
|
Loading…
x
Reference in New Issue
Block a user