tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Bill Barker" <wbar...@wilshire.com>
Subject Re: Tomcat threading questions
Date Mon, 22 Dec 2003 06:41:53 GMT

"Neil Aggarwal" <neil@JAMMConsulting.com> wrote in message
news:000001c3c846$960790d0$0302a8c0@dell5100...
> Hello:
>
> I have a couple of questions about the way Tomcat uses threads:
>
> 1. If a thread does an infinite loop or other operation that
> would cause it to wait forever, will Tomcat kill it?
> If not, is there a way to do that?
> If so, how would we control the timeout?

Eventually the browser will drop the connection, and then if the Servlet
tries to write anything, then an IOException will be thrown.  However
allowing the following code on your server will DoS:
  while(true) {
     Thread.Sleep(1000);
  }


>
> 2. Is there a hard limit on the number of threads like in
> Apache or does it allocate up to maxProcessors no matter
> how large it may be?
>

The thread allocation is pretty similar to Apache/httpd.

> Thanks,
> Neil
>
>
> --
> Neil Aggarwal, JAMM Consulting, (972)612-6056, www.JAMMConsulting.com
> FREE! Valuable info on how your business can reduce operating costs by
> 17% or more in 6 months or less! => http://newsletter.JAMMConsulting.com




---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Mime
View raw message