From 99b4374d6641d445dd361051ac3fc0d122bfb249 Mon Sep 17 00:00:00 2001 From: fhanik Date: Thu, 22 Jun 2006 17:09:14 +0000 Subject: [PATCH] must come up with a better sleep, this brings the nio connector up to the same speed as the io connector however, there is a risk for cpu contention on slow clients, fix will be coming git-svn-id: https://svn.apache.org/repos/asf/tomcat/tc6.0.x/trunk@416423 13f79535-47bb-0310-9956-ffa450edef68 --- java/org/apache/coyote/http11/InternalNioInputBuffer.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/java/org/apache/coyote/http11/InternalNioInputBuffer.java b/java/org/apache/coyote/http11/InternalNioInputBuffer.java index 2f229efbd..948226a09 100644 --- a/java/org/apache/coyote/http11/InternalNioInputBuffer.java +++ b/java/org/apache/coyote/http11/InternalNioInputBuffer.java @@ -551,7 +551,7 @@ public class InternalNioInputBuffer implements InputBuffer { return false; } timedOut = (readTimeout != -1) && ((System.currentTimeMillis()-start)>this.readTimeout); - if ( !timedOut && nRead == 0 ) try {Thread.sleep(25);}catch ( Exception x ) {} + //if ( !timedOut && nRead == 0 ) try {Thread.sleep(5);}catch ( Exception x ) {} }while ( nRead == 0 && (!timedOut) ); //else throw new IOException(sm.getString("iib.failedread")); return false; //timeout -- 2.11.0