Thread delay in ApplicationHandler.handle() method
https://github.com/jersey/jersey/blob/5140ca13c57b4818600b79361c2f3347d934e8a7/core-server/src/main/java/org/glassfish/jersey/server/ApplicationHandler.java#L702
Issue was seen on Jersey 2.17, Some of the threads takes longer time to respond in this method, time delay caused by this is measured from newRelic tool and it was amounting to 11 Sec. But same request also completed with in 3 sec (complete request). We were unable to find the RC for this.
Issue happened in load testing scenario, but single user request and response time seems to be good, issue is in-consistent.


Just came across this thread while trying to find the resolution for the exact same issue we are facing in our application. We are using Jersey Version 2.23.1. The newrelic report shows ApplicationHandler.handle() is taking a huge time.
Same issue we are facing and it is happening very randomly. Couldn't able to find out the solution have tried upgrading the dropwizard version but didn't help. Please update if you guys get any solution.
After analysing thread dump we came to know that thrid party library blocking lots of threads because of that we were facing this issue. In our case it was LightStep library. After remove those code we haven't get any such spikes which used to frequently happened in our system.