You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Bill Barker <re...@verizon.net> on 2002/09/11 07:13:04 UTC

Re: server.xml and configuring connection pools (URGENT: please look)

The "acceptCount" is nearly useless (unless you *really* know what you are
doing), since it only sets the TCP/IP "backlog" (which is one of those
things, that if you don't know what it is, you don't need it :).

There is a one-to-one mapping of socket connections to threads, so setting
"maxProcessors" to 20 means that Tomcat will only accept 20 socket
connections.  This could be from 20 different IPs, or much less if some
clients aren't using keep-alive.  On the other hand increasing the number of
threads doesn't really cost you anything, since the unused ones are blocked
until a request comes in.

What the "acceptCount" is doing for you is allowing each client to stack up
100 different requests in the queue.  I don't know of any client that would
even think of trying something like this, which is why it's not that useful.

"Donie Kelly" <do...@tecnomen.ie> wrote in message
news:4135D07B3996D1118F3100805F8B0B0E0418A331@apollo.tecnomen.ie...
> Hi all
> Simple problem I guess. I'm trying to limit tomcat to 20 threads max but
> still accept connections using the acceptCount parameter of Connector in
> server.xml.
>
> My problem is that the application will accept up to 20 connections and
give
> connection refused for everything else. What am I doing wrong? I thought I
> would have to make 120 active connections before I would get connection
> refused?
>
> My config is below....
> Thanks
> Donie
>
> <Connector className="org.apache.catalina.connector.http.HttpConnector"
> port="80" minProcessors="5" maxProcessors="20"
>                enableLookups="true" redirectPort="443" acceptCount="100"
> debug="0" connectionTimeout="60000"/>





--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>