Profile Image
herui1983

why so many thread waiting ?

why so many thread waiting ?


Report URL - https://fastthread.io/my-thread-report.jsp?p=c2hhcmVkLzIwMjMvMDkvMTEvdGhyZWFkZHVtcC50eHQtLTUtNDUtMzA=

    Please Sign In or to post your comment or answer

    Profile Image

    Ram Lakshmanan

    Hello Herui!

     

     Greetings. I reviewed your report and could observe following:

     

    a. 87 threads tomcat thread pool threads are waiting

     

     Below is the stack trace of such threads:

     

    at sun.misc.Unsafe.park(Native Method)
    at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175)
    at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2039)
    at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:442)
    at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:146)
    at org.apache.tomcat.util.threads.TaskQueue.take(TaskQueue.java:33)
    at org.apache.tomcat.util.threads.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1114)
    at org.apache.tomcat.util.threads.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1176)
    at org.apache.tomcat.util.threads.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:659)
    at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
    at java.lang.Thread.run(Thread.java:748)

     

    b. 78 SY-Executors threads are in WAITING state

     

     Below are it's stack trace:

     

    at sun.misc.Unsafe.park(Native Method)
    at java.util.concurrent.locks.LockSupport.park(LockSupport.java:175)
    at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:2039)
    at java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:442)
    at java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:1074)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1134)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
    at java.lang.Thread.run(Thread.java:748)

     

    Above are the two primary areas that you need to address. You might want to reduce the max thread pool size of these two thread pools. That can reduce your WAITING thread count.

     

     

     

    Got something else on mind? Post Your Question