Skip to content

Remote end closed connection without response #3077

@selimt

Description

@selimt

Occasionally we are getting the following traceback:

Traceback (most recent call last):
  File "/usr/local/lib/python3.10/site-packages/elastic_transport/_node/_http_urllib3.py", line 167, in perform_request
    response = self.pool.urlopen(
  File "/usr/local/lib/python3.10/site-packages/urllib3/connectionpool.py", line 841, in urlopen
    retries = retries.increment(
  File "/usr/local/lib/python3.10/site-packages/urllib3/util/retry.py", line 449, in increment
    raise reraise(type(error), error, _stacktrace)
  File "/usr/local/lib/python3.10/site-packages/urllib3/util/util.py", line 38, in reraise
    raise value.with_traceback(tb)
  File "/usr/local/lib/python3.10/site-packages/urllib3/connectionpool.py", line 787, in urlopen
    response = self._make_request(
  File "/usr/local/lib/python3.10/site-packages/urllib3/connectionpool.py", line 534, in _make_request
    response = conn.getresponse()
  File "/usr/local/lib/python3.10/site-packages/urllib3/connection.py", line 565, in getresponse
    httplib_response = super().getresponse()
  File "/usr/lib64/python3.10/http/client.py", line 1375, in getresponse
    response.begin()
  File "/usr/lib64/python3.10/http/client.py", line 318, in begin
    version, status, reason = self._read_status()
  File "/usr/lib64/python3.10/http/client.py", line 287, in _read_status
    raise RemoteDisconnected("Remote end closed connection without"
urllib3.exceptions.ProtocolError: ('Connection aborted.', RemoteDisconnected('Remote end closed connection without response'))
elastic-transport==9.1.0
elasticsearch==9.1.1
urllib3==2.5.0
celery=5.5.3

After the retry, this goes away but I am curious as to why this happens. ES node logs don't show anything out of the ordinary.

The ES requests are submitted through Celery workers so not sure if it is a bad interaction between Celery and urllib3.

I know it is not a timeout error since the the request returns after a short time:

[2025-09-17 19:23:19,693: INFO/ForkPoolWorker-78] POST http://data-elasticsearch.service.consulcp:9200/catalog-qa-rolodex_swblt/_refresh [status:N/A duration:0.870s]

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions