I configured server.xml like this: connectionTimeout="-1" disableUploadTimeout="false" connectionUploadTimeout="200" (maybe it is stupid to configure like this,if connectionTimeout=-1,can i make disableUploadTimeout=false?). It will cause : java.lang.IllegalArgumentException: timeout can't be negative at sun.nio.ch.SocketAdaptor.setSoTimeout(SocketAdaptor.java:361) at org.apache.coyote.http11.Http11NioProcessor.setSocketTimeout(Http11NioProcessor.java:251) ...... because of : if (!disableUploadTimeout) { //endpoint.getSoTimeout()=-1. setSocketTimeout(endpoint.getSoTimeout()); } ~~~~~~~~~~~~~~~~~~~~~~~~~ another thing: if i configure connectionTimeout="0". in NioBlockingSelector.read(ByteBuffer buf, NioChannel socket, long readTimeout),readTimeout = 0, in case socket.read(buf) == 0, it make timeout=true. if (readTimeout >= 0 && (keycount == 0)) timedout = (System.currentTimeMillis() - time) >= readTimeout; then throw the SocketTimeoutException(). thank you.
Created attachment 30519 [details] fix Attached the patch to fix the first issue. Might need to discuss why it was chose to make -1 the infiniti timeout. When in the socket class 0 is infiniti. I'm sure there is good reason. Just a thought.
Hi, Thanks for the report and the patch. It was applied to trunk and 7.0.x and will be included in 7.0.42 onwards. For the second problem you are facing Bug 55160. Instead of connectionUploadTimeout, connectionTimeout was set as readTimeout. Regards Violeta
excuse me, I think the second problem is different from the bug 55160. because when connectionTimeout="0" disableUploadTimeout="true". it will always throw socketTimeoutException if read ==0 (socket.read(buf)). Thank you very much for your fixing.
(In reply to Roger Wang from comment #3) > excuse me, I think the second problem is different from the bug 55160. > because when connectionTimeout="0" disableUploadTimeout="true". > it will always throw socketTimeoutException if read ==0 (socket.read(buf)). > Thank you very much for your fixing. Please open a new bug for this particular problem. Thanks Violeta