You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jun 20, 2023. It is now read-only.
Caused by: java.net.SocketTimeoutException: Read timed out
at java.net.SocketInputStream.socketRead0(Native Method)
at java.net.SocketInputStream.socketRead(SocketInputStream.java:116)
at java.net.SocketInputStream.read(SocketInputStream.java:171)
at java.net.SocketInputStream.read(SocketInputStream.java:141)
at org.apache.http.impl.io.SessionInputBufferImpl.streamRead(SessionInputBufferImpl.java:139)
at org.apache.http.impl.io.SessionInputBufferImpl.fillBuffer(SessionInputBufferImpl.java:155)
at org.apache.http.impl.io.SessionInputBufferImpl.readLine(SessionInputBufferImpl.java:284)
at org.apache.http.impl.conn.DefaultHttpResponseParser.parseHead(DefaultHttpResponseParser.java:140)
at org.apache.http.impl.conn.DefaultHttpResponseParser.parseHead(DefaultHttpResponseParser.java:57)
at org.apache.http.impl.io.AbstractMessageParser.parse(AbstractMessageParser.java:261)
at org.apache.http.impl.DefaultBHttpClientConnection.receiveResponseHeader(DefaultBHttpClientConnection.java:165)
at org.apache.http.impl.conn.CPoolProxy.receiveResponseHeader(CPoolProxy.java:167)
at org.apache.http.protocol.HttpRequestExecutor.doReceiveResponse(HttpRequestExecutor.java:272)
at org.apache.http.protocol.HttpRequestExecutor.execute(HttpRequestExecutor.java:124)
at org.apache.http.impl.execchain.MainClientExec.execute(MainClientExec.java:271)
at org.apache.http.impl.execchain.ProtocolExec.execute(ProtocolExec.java:184)
at org.apache.http.impl.execchain.RetryExec.execute(RetryExec.java:88)
at org.apache.http.impl.execchain.RedirectExec.execute(RedirectExec.java:110)
at org.apache.http.impl.client.InternalHttpClient.doExecute(InternalHttpClient.java:184)
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:82)
at org.apache.http.impl.client.CloseableHttpClient.execute(CloseableHttpClient.java:107)
at io.searchbox.client.http.JestHttpClient.executeRequest(JestHttpClient.java:132)
at io.searchbox.client.http.JestHttpClient.execute(JestHttpClient.java:67)
at io.searchbox.client.http.JestHttpClient.execute(JestHttpClient.java:60)
In other words I think we need to configure maxConnectionIdleTime, and other related values correctly.
My questions:
What is the default value of maxConnectionIdleTime?
Should connTimeout necessarily be greater than maxConnectionIdleTime (the SO post suggests it)? Our application has connTimeout set to 5 ms (Is this too small?), and no value at all for maxConnectionIdleTime. Also readTimeout is 1000 ms.
Is there any guidance on how to go about setting these values, and the significance of each?
Feel free to resolve this if there isn't enough information provided, I'm in the starting stage of debugging this so not sure what I should be looking at.
The text was updated successfully, but these errors were encountered:
hi @vaditya04 ,I have the same problem with you ,When my application is idle for some time, the JestClient is throwing SocketTImeoutException.After adding the maxConnectionIdleTime configuraition, "llegalStateException: Expected the service to be RUNNING, but the service has FAILED" comes up.
I debugged my app, foud the Exception is from com.google.common.util.concurrent.AbstractService(checkCurrentState method).
Through further debugging,I foud the real reason is from com.google.common.util.concurrent.AbstractService.startAsync method,in this method ,it calls doStart, which cause a "java.lang.NoSuchMethodError: com.google.common.util.concurrent.MoreExecutors.directExecutor()Ljava/util/concurrent/Executor;"
At last, I found the result is due to jar package conflicts. With jest:5.3.3,we need guava:21.0, while in my maven project, what we truly used is guava:15.0. When I fixed this problem, my app is running successfully, and the SocketTImeoutException hasn't appeared for some time .
We're facing recurring errors in production of this kind. My working theory is based on this SO post https://stackoverflow.com/questions/48236832/jestclient-is-throwing-sockettimeoutexception-after-being-idle-for-sometime?rq=1
In other words I think we need to configure maxConnectionIdleTime, and other related values correctly.
My questions:
What is the default value of maxConnectionIdleTime?
Should connTimeout necessarily be greater than maxConnectionIdleTime (the SO post suggests it)? Our application has connTimeout set to 5 ms (Is this too small?), and no value at all for maxConnectionIdleTime. Also readTimeout is 1000 ms.
Is there any guidance on how to go about setting these values, and the significance of each?
Feel free to resolve this if there isn't enough information provided, I'm in the starting stage of debugging this so not sure what I should be looking at.
The text was updated successfully, but these errors were encountered: