From: leon j. b. <lj...@ne...> - 2002-04-05 11:31:57
|
On Fri, Apr 05, 2002 at 12:30:46AM -0800, Oti wrote: > > I couldn't get more than 2000 threads created. Trying the same script > > with 3000 threads caused Jython to freeze. Using the GNOME System > > Monitor I noticed 20+ instances of JRE but they were all taking 0% > > CPU time.This makes me wonder if there is an upper limit to threads > > in Jython? Java threads in the JVMs I've used map to native operating system threads. Its not so much a memory issue as it is operating system resource. On Linux, where each thread is an actual lightweight process, it consumes a process descriptor, of which there is a finite limit set in one of the kernel header files (default is 4096, I think). If you bump this up, you will see that you can create more threads. Check your syslog messages to see if the kernel logs an error when your script starts failing. Regards, Leon. -- lj...@ne... :: +27.82.7890445 |