We have timeout error on worker clients who use ES
go client:
time="2021-08-02T16:04:45Z" level=error msg="error handling connection with queue: error saving bulk: error making bulk request dial tcp 20.96.122.135:9200: connect: connection timed out" queue=***
c# client:
FAILED TO CHECK ELASTIC INDEXES: Elasticsearch.Net.UnexpectedElasticsearchClientException: The operation was canceled. ---> System.OperationCanceledException: The operation was canceled.
at System.Net.Http.HttpClient.HandleFinishSendAsyncError(Exception e, CancellationTokenSource cts)
at System.Net.Http.HttpClient.FinishSendAsyncUnbuffered(Task`1 sendTask, HttpRequestMessage request, CancellationTokenSource cts, Boolean disposeCts)
at Elasticsearch.Net.HttpConnection.RequestAsync[TResponse](RequestData requestData, CancellationToken cancellationToken)
at Elasticsearch.Net.RequestPipeline.CallElasticsearchAsync[TResponse](RequestData requestData, CancellationToken cancellationToken)
at Elasticsearch.Net.Transport`1.RequestAsync[TResponse](HttpMethod method, String path, CancellationToken cancellationToken, PostData data, IRequestParameters requestParameters)
--- End of inner exception stack trace ---
at Elasticsearch.Net.Transport`1.RequestAsync[TResponse](HttpMethod method, String path, CancellationToken cancellationToken, PostData data, IRequestParameters requestParameters)
at ***.Handle(CancellationToken cancellationToken) in /src/***.cs:line 42
FAILED TO CHECK ELASTIC INDEXES: Elasticsearch.Net.UnexpectedElasticsearchClientException: The operation was canceled. ---> System.OperationCanceledException: The operation was canceled.
I don't understand what is occouring. Can you help us with it?
Tried without success: OS:
- sysctl -w net.ipv4.tcp_keepalive_time=20
- sysctl -w net.ipv4.tcp_keepalive_intvl=20
ES:
- xpack.watcher.bulk.size: 5mb
- xpack.http.default_connection_timeout: 60s