# Frequent "Connection timed out" errors when calling Management API

**URL:** <https://community.auth0.com/t/frequent-connection-timed-out-errors-when-calling-management-api/70375>\
**Category:** Get Help\
**Created:** [September 28, 2021, 8:32am UTC](https://community.auth0.com/t/frequent-connection-timed-out-errors-when-calling-management-api/70375 "2021-09-28T08:32:35Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![jonathan.rau](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/jonathan.rau/32/12921_2.png) [@jonathan.rau](https://community.auth0.com/u/jonathan.rau)\
**Post date:** [September 28, 2021, 8:32am UTC](https://community.auth0.com/t/frequent-connection-timed-out-errors-when-calling-management-api/70375/1 "2021-09-28T08:32:35Z")

</div>

Hi there!

We are building a service to manage users and organizations using the Management API. However, our calls to the Management API fail sporadically as the connection times out:

```auto
2021-09-27 10:23:57.562 WARN 1 --- [or-http-epoll-1] r.netty.http.client.HttpClientConnect : [id:53e822b5-2, L:/172.17.0.2:60426 - R:<domain>.eu.auth0.com/104.18.244.88:443] The connection observed an error

io.netty.channel.unix.Errors$NativeIoException: readAddress(..) failed: Connection timed out

2021-09-27 10:23:57.564 ERROR 1 --- [nio-8080-exec-1] o.a.c.c.C.[.[.[/].[dispatcherServlet] : Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception [Request processing failed; nested exception is org.springframework.web.reactive.function.client.WebClientRequestException: readAddress(..) failed: Connection timed out; nested exception is io.netty.channel.unix.Errors$NativeIoException: readAddress(..) failed: Connection timed out] with root cause

io.netty.channel.unix.Errors$NativeIoException: readAddress(..) failed: Connection timed out

```

(I have replaced the domain with a placeholder)

This usually happens, when the service has not been used for a while and subsequent requests are usually served in a reasonable time (~500ms). We are currently on the free plan and are trying out the organization feature. Are those timeouts related to auth0 using a serverless architecture in the backend, that needs to warm up? Can we expect the performance to be better when switching to a paid plan?

---

<div class="post-metadata">

**Author:** ![konrad.sopala](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/konrad.sopala/32/13516_2.png) [@konrad.sopala](https://community.auth0.com/u/konrad.sopala)\
**Post date:** [September 28, 2021, 12:24pm UTC](https://community.auth0.com/t/frequent-connection-timed-out-errors-when-calling-management-api/70375/2 "2021-09-28T12:24:41Z")

</div>

Hey there!

What you’re asking about our architecture is definitely not the reason. I would actually start researching this from diving deeper into why you have so high response times ~500 ms.

---

<div class="post-metadata">

**Author:** ![jonathan.rau](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/jonathan.rau/32/12921_2.png) [@jonathan.rau](https://community.auth0.com/u/jonathan.rau)\
**Post date:** [September 28, 2021, 3:45pm UTC](https://community.auth0.com/t/frequent-connection-timed-out-errors-when-calling-management-api/70375/3 "2021-09-28T15:45:12Z")

</div>

Thanks for the quick response. There is a small typo in the original post as the response times of the subsequent requests are below 500ms (\< not ~). I apologize for that.

We’ve investigated our code a little further. By examining the log statements from today, we found out, that the client\_credentials exchange is causing the timeout and not the call to the Management API. This might just be related to the [current incident](https://status.auth0.com/incidents/vwq8f1rcsdtf). So we will keep observing the response times in the upcoming days and I will come back to this issue when I have more insights.

---

<div class="post-metadata">

**Author:** ![konrad.sopala](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/konrad.sopala/32/13516_2.png) [@konrad.sopala](https://community.auth0.com/u/konrad.sopala)\
**Post date:** [September 30, 2021, 1:16pm UTC](https://community.auth0.com/t/frequent-connection-timed-out-errors-when-calling-management-api/70375/4 "2021-09-30T13:16:04Z")

</div>

Perfect! Let us know if you have any other questions down the road!

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [October 15, 2021, 1:16pm UTC](https://community.auth0.com/t/frequent-connection-timed-out-errors-when-calling-management-api/70375/5 "2021-10-15T13:16:27Z")

</div>

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.
