diff --git a/aioelasticsearch/transport.py b/aioelasticsearch/transport.py index eb6b8b3e..8fe11127 100644 --- a/aioelasticsearch/transport.py +++ b/aioelasticsearch/transport.py @@ -278,10 +278,11 @@ async def _perform_request( raise else: + self.connection_pool.mark_live(connection) + if method == 'HEAD': return 200 <= status < 300 - self.connection_pool.mark_live(connection) if data: data = self.deserializer.loads( data, headers.get('content-type'),