glassfish
  1. glassfish
  2. GLASSFISH-19035

[Perf] Performance degradation when using dynamic http thread pool

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 4.0_dev
    • Fix Version/s: 4.0_dev
    • Component/s: grizzly-kernel
    • Labels:
      None
    • Environment:

      Linux 2.2.16 OEL x64

      Description

      Seeing significant performance degradation when using dynamic http thread pool when running a JSP HTTP micro benchmark. The degradation has been traced to a hot ReentrantLock in SyncThreadPool implementation of thread pool. When FixedThreadPool is used, there is significant improvement in performance results compared to dynamic thread pool.

      Have tried a patch from Alexey replacing ReentrantLock with a Synchronized block, but that is not yielding much improvement.

      The benchmark is a simple war file with 3 JSPs doing HelloWorld, showing current date and maintaining a simple user session with hit count.

        Activity

        Hide
        oleksiys added a comment -

        fixed

        Show
        oleksiys added a comment - fixed
        Hide
        deep_singh added a comment - - edited

        Re-tried the Synchronized block change in dynamic thread pool on b62 with patch built with latest Grizzly 2.3-beta8 binaries. Found 17% improvement when compared to Reentrant lock and 7% improvement when compared to Glassfish 3.1.2 . This test was done with thread pool size min=1 max=8 on a 4 CPU machine and used JSP POST Reader test with 50 concurrent users.

        Show
        deep_singh added a comment - - edited Re-tried the Synchronized block change in dynamic thread pool on b62 with patch built with latest Grizzly 2.3-beta8 binaries. Found 17% improvement when compared to Reentrant lock and 7% improvement when compared to Glassfish 3.1.2 . This test was done with thread pool size min=1 max=8 on a 4 CPU machine and used JSP POST Reader test with 50 concurrent users.

          People

          • Assignee:
            oleksiys
            Reporter:
            deep_singh
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: