John Neffenger wrote:

> I was pleased to see that a connection timeout has been added to Tomcat
> 4.0 in the HttpConnector class.  A timeout was missing in Sun's JSDK
> through version 2.0 and in earlier versions of Tomcat.  Without a
> timeout, the servlet runner process accumulates dead connections on the
> Internet and, with the JSDK, eventually stops accepting new ones since
> its "max handlers" limit is reached.
>
> Dead connections happen all the time out on the Internet when clients
> make a connection but send in only a few HTTP GET request headers, or no
> headers at all, and then go away (because of modem disconnects,
> computers crashes, or anything else silently breaking the connection
> between the client and the server).  I suspect people didn't notice it
> because they tend to run servlets behind Apache, which does have a
> connection timeout:
>
>   http://httpd.apache.org/docs/mod/core.html#timeout
>
> We run Tomcat as standalone process, though.
>
> Will that connection timeout be a permanent feature in Tomcat starting
> with version 4.0?
>

Insofar as any of us can predict the future, I would say the answer to this is
definitely yes.  Among other things, the lack of a timeout creates a pretty easy
DOS attack against a Tomcat server -- simply open enough socket connections to
exhaust the configured pool size, and just sit there.

Over time, we will probably want to tweak how long the timeouts actually are,
based on the state of the interaction so far, but AFAIKT they will always be
needed.

>
> Thanks,
> John Neffenger
>

Craig McClanahan



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]

Reply via email to