# Dynatrace Detected JAXBMessage Blocking

**URL:** <https://community.dynatrace.com/t/dynatrace-detected-jaxbmessage-blocking/32638>\
**Category:** Open Q&A\
**Tags:** distributed-traces-classic\
**Created:** [September 9, 2021, 3:53am UTC](https://community.dynatrace.com/t/dynatrace-detected-jaxbmessage-blocking/32638 "2021-09-09T03:53:33Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![zero\_ho](https://avatars.discourse-cdn.com/v4/letter/z/9de053/32.png) [@zero\_ho](https://community.dynatrace.com/u/zero_ho)\
**Post date:** [September 9, 2021, 3:53am UTC](https://community.dynatrace.com/t/dynatrace-detected-jaxbmessage-blocking/32638/1 "2021-09-09T03:53:33Z")

</div>

Dear Sir/Madam,

Customer has a JAX-WS SOAP-Based web service class called AppService serving many of the operation with their mobile app.&nbsp; There are not much internal/custom packages written and imported in this AppService class; most of the operations are with standard JDK libraries, JWS and Apache HTTP client only. Generally, the underlying operations are the mobile app send XHR requests to this AppService and the service return required values in SOAP message through different web methods (web services).

Customer observed from Dynatrace PurePath records that there was certain amount of PurePaths (with similar operations) having response time \> 40s. On Dynatrace it advised the method hotspot is with the doFilter operation (attached the PP example that take \>47s to complete).&nbsp; The method in problem only took 2.82s to complete and most of the time was with the parent doFilter action.&nbsp; The slow response time issue did not happen all the time and in fact majority of recorded response time of similar PurePath activities complete within 5s.&nbsp; Checked server CPU and memory were sufficient. Checked the process (i.e., Tomcat) thread count was good, and no&nbsp;long-lasting GC was detected at the time the slow PurePaths happened.

In the method hotspot details page it showed most of the time (\>90%) had been spent of Waiting. May I ask what components could introduce such delay. Per the stacktrace there are countdownlatch and acquire lock activities detected.&nbsp; These operations seem are not directly written in the AppService code but through the @WebMethod annotation. May I ask how Dynatrace would indicate which actual part of code/method play the biggest role on the delay/blocking.

Thank you very much.

Best Regards,

Zero ■■

 ![PurePath.jpg](https://global.discourse-cdn.com/dynatrace/original/1X/35d30202525a5aae32b7352813955be402864886.jpeg)  
 ![Hotspot.jpg](https://global.discourse-cdn.com/dynatrace/original/2X/c/ca2805213a71cede3594bb28146173fb542bcdf1.jpeg)

---

<div class="post-metadata">

**Author:** ![harald\_berger](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/harald_berger/32/31754_2.png) [@harald\_berger](https://community.dynatrace.com/u/harald_berger)\
**Post date:** [September 9, 2021, 9:38am UTC](https://community.dynatrace.com/t/dynatrace-detected-jaxbmessage-blocking/32638/2 "2021-09-09T09:38:47Z")

</div>

Hi,

The method hotspots show that most wait time is caused by writing the response to the client, because of the blocking nature of NioBlockingSelector.write(). This might be caused by slow clients or disconnected clients (broken connection)

regards

Harry

---

<div class="post-metadata">

**Author:** ![zero\_ho](https://avatars.discourse-cdn.com/v4/letter/z/9de053/32.png) [@zero\_ho](https://community.dynatrace.com/u/zero_ho)\
**Post date:** [September 10, 2021, 12:49am UTC](https://community.dynatrace.com/t/dynatrace-detected-jaxbmessage-blocking/32638/3 "2021-09-10T00:49:07Z")

</div>

Dear Harald,

Thanks for the sharing. If the slow clients or disconnected clients would be the case do you recognize any strategy on Dynatrace to monitor these kind of blocking or slow client events?

Because customer checked the network utiliation is not high. Throughput is also far below the limit. Any suggestion how we can reflect a slow client (e.g. slow server-to-client network connection) issue?

Thank you very much.

Best Regards,

Zero ■■

---

<div class="post-metadata">

**Author:** ![harald\_berger](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/harald_berger/32/31754_2.png) [@harald\_berger](https://community.dynatrace.com/u/harald_berger)\
**Post date:** [September 13, 2021, 4:23am UTC](https://community.dynatrace.com/t/dynatrace-detected-jaxbmessage-blocking/32638/4 "2021-09-13T04:23:47Z")

</div>

Hi,

It also might be possible that the client (browser) simply is closed and the response cannot be consumed anymore. Tomcat needs some time to recover from that.

Maybe the stuck thread detection of Tomcat helps here

> **[Stuck Thread Detection Valve - Apache Tomcat 8 Configuration Reference (8.5.100)...](https://tomcat.apache.org/tomcat-8.5-doc/config/valve.html#Stuck_Thread_Detection_Valve)**
>
> A Valve element represents a component that will be inserted into the request processing pipeline for the associated Catalina container (Engine, Host, or Context). Individual Valves have distinct processing capabilities, and are described...

Best

Harry

---

<div class="post-metadata">

**Author:** ![zero\_ho](https://avatars.discourse-cdn.com/v4/letter/z/9de053/32.png) [@zero\_ho](https://community.dynatrace.com/u/zero_ho)\
**Post date:** [September 20, 2021, 10:57am UTC](https://community.dynatrace.com/t/dynatrace-detected-jaxbmessage-blocking/32638/5 "2021-09-20T10:57:44Z")

</div>

Hi Harry,

Thanks for the sharing. So we will need to study the “extenal” stuck thread detection through Tomcat and observe the findings? It loosk to me Dynatrace does not grab this Tomcat metrics OOTB.

Best Regards,

Zero

---

<div class="post-metadata">

**Author:** ![harald\_berger](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/harald_berger/32/31754_2.png) [@harald\_berger](https://community.dynatrace.com/u/harald_berger)\
**Post date:** [September 20, 2021, 11:06am UTC](https://community.dynatrace.com/t/dynatrace-detected-jaxbmessage-blocking/32638/6 "2021-09-20T11:06:34Z")

</div>

Hi,

No, there is no OOTB for stuck thread JMX values. You have to create a custom plugin then.

Harry
