Aren't they part of a thread pool?

You don't want to initialize a thread every time a request comes; instead,
you better have them ready and waiting to serve incoming petitions. They
won't eat into your memory until they're used, and they share the same
memory.

Actually, for a production server I think 46 is not too much; just compute
your peak traffic and the time it takes to serve them. E.g., if you expect
40 requests/sec and each one takes 2 secs to fulfill, 80 threads in the
pool would be a good bet.

To find out how long it takes to serve a request, do a load test on your
pages. Take into account that it takes longer when the traffic is high.

Cheers,

Alex.

James Diggans wrote:

> I have tomcat running through mod_jk along with Apache. When tomcat is
> launched it does so flawlessly but launches FORTY SIX 'java' threads,
> each taking ~10MB of what gtop declares 'resident' memory (yes, 460MB
> total). Now I realize these are probably sharing a memory space (since
> I dont HAVE 460MB of RAM or swap) but is there a reason it's starting
> 46 threads? And can anyone tell me where I can configure this? It
> seems ...... high.
>
> Regards,
> - j
>
> ----------------------------------------------------------------------
> --------------
> James C. Diggans
> Excelsior Technologies, Inc.           At what point did we stop
> [EMAIL PROTECTED]         being citizens and start
> http://www.excelsior-web.com       being mere 'consumers'?
> ----------------------------------------------------------------------
> --------------
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, email: [EMAIL PROTECTED]


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

Reply via email to