found this :
http://jroller.com/rreyelts/date/20040909
After running some tests with the JVM, I've come to the conclusion that Sun's JDK
1.4 allocates about 256K of address space per thread. I also ran some tests with JDK 1.5,
which seem to indicate that it was allocating about 1M of address space per thread. Those
numbers come from an assumption of a 2G address space per process under Windows, and the
following statistics for the maximum number of threads I could create:
JDK1.4
-Xmx750 = 4580 threads.
-Xmx1000 = 3608 threads.
-Xmx1500M = 1663 threads
JDK1.5
-Xmx750M = 1129 threads
-Xmx1000M = 880 threads
-Xmx1500M = 384 threads
As you can see, the maximum number of threads I can create decreases as the heap size gets
larger. This is because the JVM immediately reserves the address space specified for the
maximum heap size - That's probably because it needs that memory to be contiguous.
Hence the reaon why when I reduce the heap I get more done ...
So I have restarted my JBoss 5 with 1024 Heap, 256 Permsize and limited the Thread size to
128K (-Xss128k). I have run my 5 users scenario (which didn't work previously) and
I'm currently running the 20.
My 2 cents : it could just be that JBoss 5 creates far more threads than JBoss 4.2.3 used
to.
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4185691#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...