Re: singe thread per connection
- From: "Peter Duniho" <NpOeStPeAdM@xxxxxxxxxxxxxxxx>
- Date: Fri, 11 Jul 2008 20:40:06 -0700
On Fri, 11 Jul 2008 19:29:24 -0700, Neil Coffey <neil.coffey@xxxxxxxxxxxxxxxxxxxxxxxx> wrote:
Peter Duniho wrote:
For that matter, I'm not convinced it would be good to have 500 threads.
It's not a great design for the purpose, but purely in terms of
numbers of threads, you'd probably get away with it on a modern OS.
(If you're running Windoze, check perfmon--
you'll quite possibly find you have hundreds of threads running just
with your box "ticking over".)
Hundreds maybe, but almost certainly distributed over a large number of processes.
On 32-bit Windows, the theoretical maximum number of threads per process is about 2000, with the practical maximum somewhat lower, and performance suffering significantly before that. Unix/Linux would be different...threads are much lighter-weight constructs on those OSs.
Of course, I'm not aware of any requirement that a Java thread be implemented exactly as an OS thread. So OS limitations may or may not apply in Java.
But my comment wasn't directed at the question of whether one would "get away with it". I was commenting on what would be a _good_ approach. I have the impression you agree with me on that point. :)
Pete
.
- Follow-Ups:
- Re: singe thread per connection
- From: Neil Coffey
- Re: singe thread per connection
- References:
- singe thread per connection
- From: Praki
- Re: singe thread per connection
- From: Peter Duniho
- Re: singe thread per connection
- From: Neil Coffey
- singe thread per connection
- Prev by Date: Re: Weak/Soft references?
- Next by Date: Re: How to separate words from the string in JSP?
- Previous by thread: Re: singe thread per connection
- Next by thread: Re: singe thread per connection
- Index(es):