Author: markt
Date: Fri Feb 20 23:14:39 2009
New Revision: 746412

URL: http://svn.apache.org/viewvc?rev=746412&view=rev
Log:
Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=45074
Add poller & sendfile  thread config options to APR
Add warning to docs re Windows based on Remy's comment in the status file.

Modified:
    tomcat/tc6.0.x/trunk/   (props changed)
    tomcat/tc6.0.x/trunk/STATUS.txt
    tomcat/tc6.0.x/trunk/java/org/apache/coyote/http11/Http11AprProtocol.java
    tomcat/tc6.0.x/trunk/webapps/docs/apr.xml
    tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml

Propchange: tomcat/tc6.0.x/trunk/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Feb 20 23:14:39 2009
@@ -1 +1 @@
-/tomcat/trunk:601180,606992,612607,630314,652744,653247,673796,673820,683982,684001,684081,684234,684269-684270,685177,687503,687645,690781,691392,691805,692748,695053,695311,696780,696782,698012,698227,698236,698613,699427,699634,701355,709294,709811,709816,710063,710066,710125,710205,711126,711600,712461,712467,718360,719602,719626,719628,720046,720069,721040,723404,723738,726052,727303,728032,728768,728947,729057,729567,729569,729571,729809,729815,729934,730250,730590,731651,732859,732863,734734,740675,740684
+/tomcat/trunk:601180,606992,612607,630314,652744,653247,673796,673820,683982,684001,684081,684234,684269-684270,685177,687503,687645,689402,690781,691392,691805,692748,695053,695311,696780,696782,698012,698227,698236,698613,699427,699634,701355,709294,709811,709816,710063,710066,710125,710205,711126,711600,712461,712467,718360,719602,719626,719628,720046,720069,721040,723404,723738,726052,727303,728032,728768,728947,729057,729567,729569,729571,729809,729815,729934,730250,730590,731651,732859,732863,734734,740675,740684

Modified: tomcat/tc6.0.x/trunk/STATUS.txt
URL: 
http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/STATUS.txt?rev=746412&r1=746411&r2=746412&view=diff
==============================================================================
--- tomcat/tc6.0.x/trunk/STATUS.txt (original)
+++ tomcat/tc6.0.x/trunk/STATUS.txt Fri Feb 20 23:14:39 2009
@@ -38,15 +38,6 @@
    0: remm (looks risky, very minor problem), fhanik - minor problem
   -1: 
 
-* Fix https://issues.apache.org/bugzilla/show_bug.cgi?id=45074
-  http://svn.apache.org/viewvc?rev=689402&view=rev
-  +1: jfclere, funkman, fhanik
-   0: markt: The OP was using linux so I assume they saw some benefit.
-             If this is goign to be applied, the docs should be
-             updated as well.
-  -0: remm: configuring this is useless (esp on Windows, only the default 
behavior gives acceptable performance)
-  -1: 
-
 * Handle session suffix rewrite at JvmRouteBinderValve with parallel requests 
from same client
   http://svn.apache.org/viewvc?rev=693378&view=rev
   +1: pero, fhanik, markt, jim

Modified: 
tomcat/tc6.0.x/trunk/java/org/apache/coyote/http11/Http11AprProtocol.java
URL: 
http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/java/org/apache/coyote/http11/Http11AprProtocol.java?rev=746412&r1=746411&r2=746412&view=diff
==============================================================================
--- tomcat/tc6.0.x/trunk/java/org/apache/coyote/http11/Http11AprProtocol.java 
(original)
+++ tomcat/tc6.0.x/trunk/java/org/apache/coyote/http11/Http11AprProtocol.java 
Fri Feb 20 23:14:39 2009
@@ -242,9 +242,15 @@
     public void setPollerSize(int pollerSize) { 
endpoint.setPollerSize(pollerSize); }
     public int getPollerSize() { return endpoint.getPollerSize(); }
 
+    public void setPollerThreadCount(int pollerThreadCount) { 
endpoint.setPollerThreadCount(pollerThreadCount); }
+    public int getPollerThreadCount() { return 
endpoint.getPollerThreadCount(); }
+    
     public int getSendfileSize() { return endpoint.getSendfileSize(); }
     public void setSendfileSize(int sendfileSize) { 
endpoint.setSendfileSize(sendfileSize); }
     
+    public void setSendfileThreadCount(int sendfileThreadCount) { 
endpoint.setSendfileThreadCount(sendfileThreadCount); }
+    public int getSendfileThreadCount() { return 
endpoint.getSendfileThreadCount(); }
+
     public boolean getDeferAccept() { return endpoint.getDeferAccept(); }
     public void setDeferAccept(boolean deferAccept) { 
endpoint.setDeferAccept(deferAccept); }
 

Modified: tomcat/tc6.0.x/trunk/webapps/docs/apr.xml
URL: 
http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/webapps/docs/apr.xml?rev=746412&r1=746411&r2=746412&view=diff
==============================================================================
--- tomcat/tc6.0.x/trunk/webapps/docs/apr.xml (original)
+++ tomcat/tc6.0.x/trunk/webapps/docs/apr.xml Fri Feb 20 23:14:39 2009
@@ -181,6 +181,13 @@
       8192 keepalive connections.</p>
     </attribute>
 
+    <attribute name="pollerThreadCount" required="false">
+      <p>Number of threads used to poll kept alive connections. On Windows the
+      default is chosen so that the sockets managed by each thread is
+      less than 1024. For Linux the default is 1. Changing the default on
+      Windows is likely to have a negative performance impact.</p>
+    </attribute>
+
     <attribute name="useSendfile" required="false">
       <p>Use kernel level sendfile for certain static files. The default value 
is true.</p>
     </attribute>
@@ -189,11 +196,18 @@
       <p>Amount of sockets that the poller responsible for sending static 
files asynchronously can hold 
       at a given time. Extra connections will be closed right away without any 
data being sent 
       (resulting in a zero length file on the client side). Note that in most 
cases, sendfile is a call
-      that will return right away (being taken care of "synchonously" by the 
kernel), and the sendfile
+      that will return right away (being taken care of "synchronously" by the 
kernel), and the sendfile
       poller will not be used, so the amount of static files which can be sent 
concurrently is much larger
       than the specified amount. The default value is 1024.</p>
     </attribute>
 
+    <attribute name="sendFileThreadCount" required="false">
+      <p>Number of threads used service sendfile sockets. On Windows the
+      default is chosen so that the sockets managed by each thread is
+      less than 1024. For Linux the default is 1. Changing the default on
+      Windows is likely to have a negative performance impact.</p>
+    </attribute>
+
     </attributes>
     
     </subsection>

Modified: tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml
URL: 
http://svn.apache.org/viewvc/tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml?rev=746412&r1=746411&r2=746412&view=diff
==============================================================================
--- tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml (original)
+++ tomcat/tc6.0.x/trunk/webapps/docs/changelog.xml Fri Feb 20 23:14:39 2009
@@ -306,6 +306,11 @@
         configurable. (markt)
       </add>
       <fix>
+        <bug>45074</bug>: Add configuration parameters to enable the tuning
+        of sendfile and poller thread count in the APR HTTP connector. Patch
+        provided by Alex Barclay. (jfclere/markt)
+      </fix>
+      <fix>
         <bug>45528</bug>: Add detection for invalid SSL configuration to 
prevent
         infinite logging loop on start-up. (markt)
       </fix>



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to