# AuthenticateRequest Took a Long Time to Execute

**URL:** <https://community.dynatrace.com/t/authenticaterequest-took-a-long-time-to-execute/19515>\
**Category:** Dynatrace API\
**Tags:** services-classic, dynatrace-api\
**Created:** [June 8, 2020, 11:57am UTC](https://community.dynatrace.com/t/authenticaterequest-took-a-long-time-to-execute/19515 "2020-06-08T11:57:13Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![josh\_monreal](https://avatars.discourse-cdn.com/v4/letter/j/e274bd/32.png) [@josh\_monreal](https://community.dynatrace.com/u/josh_monreal)\
**Post date:** [June 8, 2020, 11:57am UTC](https://community.dynatrace.com/t/authenticaterequest-took-a-long-time-to-execute/19515/1 "2020-06-08T11:57:13Z")

</div>

The REST API application that we have connects to a WCF web service to get some information. Overall the performance between the two is seamless, however there are random requests that takes a long time to be completed. An example is this one.

 ![25301-1591617259746.png](https://global.discourse-cdn.com/dynatrace/original/3X/9/5/95ddc22f31b106c6d0ba649e1deea12541aa23f7.png)

From what I can understand here, the HandleRequest inside AuthenticateRequest (I think this is located in the Global.asax file) took **25.4** seconds to run. Why was this the case? Is this more of an IIS issue?

---

<div class="post-metadata">

**Author:** ![ChadTurner](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/chadturner/32/161_2.png) [@ChadTurner](https://community.dynatrace.com/u/ChadTurner)\
**Post date:** [June 8, 2020, 12:20pm UTC](https://community.dynatrace.com/t/authenticaterequest-took-a-long-time-to-execute/19515/2 "2020-06-08T12:20:48Z")

</div>

are you able to check out the method hotspots? This will help us understand why there is a long execution time, was it the network, host, cpu, wait time and so on.

---

<div class="post-metadata">

**Author:** ![josh\_monreal](https://avatars.discourse-cdn.com/v4/letter/j/e274bd/32.png) [@josh\_monreal](https://community.dynatrace.com/u/josh_monreal)\
**Post date:** [June 8, 2020, 2:22pm UTC](https://community.dynatrace.com/t/authenticaterequest-took-a-long-time-to-execute/19515/3 "2020-06-08T14:22:36Z")

</div>

Hi [@Chad T.](https://answers.dynatrace.com/users/36422/view.html), I was able to identify the method that was causing the slowness using the method hotspots. Thank you for the help!

---

<div class="post-metadata">

**Author:** ![ChadTurner](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/chadturner/32/161_2.png) [@ChadTurner](https://community.dynatrace.com/u/ChadTurner)\
**Post date:** [June 8, 2020, 2:28pm UTC](https://community.dynatrace.com/t/authenticaterequest-took-a-long-time-to-execute/19515/4 "2020-06-08T14:28:33Z")

</div>

Happy to hear that! you’re very welcome! Feel Free to reward points as desired 🙂

---

<div class="post-metadata">

**Author:** ![josh\_monreal](https://avatars.discourse-cdn.com/v4/letter/j/e274bd/32.png) [@josh\_monreal](https://community.dynatrace.com/u/josh_monreal)\
**Post date:** [June 8, 2020, 2:42pm UTC](https://community.dynatrace.com/t/authenticaterequest-took-a-long-time-to-execute/19515/5 "2020-06-08T14:42:18Z")

</div>

I only have **11 points** but I gave all to you. 🙂

---

<div class="post-metadata">

**Author:** ![ChadTurner](https://dub1.discourse-cdn.com/dynatrace/user_avatar/community.dynatrace.com/chadturner/32/161_2.png) [@ChadTurner](https://community.dynatrace.com/u/ChadTurner)\
**Post date:** [June 8, 2020, 2:50pm UTC](https://community.dynatrace.com/t/authenticaterequest-took-a-long-time-to-execute/19515/6 "2020-06-08T14:50:02Z")

</div>

Well thank you for being so generous Josh! Every little bit counts! Stay Safe and Stay Healthy!
