dev@grizzly.java.net

Most of test case failed on 4CPUs

From: Bongjae Chang <carryel_at_korea.com>
Date: Fri, 5 Jun 2009 17:59:56 +0900

Hi,

Today, I ran all test cases on 4CPUs, but most of them failed.

When I debugged, the problem was thread pool size again. :(

See the following source.

---
In Controller.java

private void initializeDefaults() {
   autoConfigureCore();
   if( threadPool == null ) {
      threadPool = new DefaultThreadPool();
   }
   if(threadPool instanceof ThreadPoolExecutor) {
      ((ThreadPoolExecutor)threadPool).setMaximumPoolSize(maxThreads);
      ((ThreadPoolExecutor)threadPool).setCorePoolSize(maxThreads);
   }
   ...
}
---

Current DefaultThreadPool is not instance of ThreadPoolExecutor which is based on JDK but FixedThreadPool!

I think that we need to fix above code or the threadPool should be created by appropriate max size like maxThreads.

Thanks.

--
Bongjae Chang