Eliminate timeouts on admin API's

Hello,

We are using Akka-HTTP timeouts within our systems, such as request-timeout and idle-timeout.
We have some admin pages (for internal debug purposes) where we want to disable all timeouts that are configured in production.

so I have a few questions:

  1. For those admin pages we are using withoutRequestTimeout, does it also disable the idle-timeout? if it affects request-timeout only, is there something else we can use to eliminate the idle-timeout as well?
  2. Is there a way to have two separate paths, one for admin and the other for production, with different timeout configurations?

Thank you!

Hi, @timeout,

thanks for the question.

The idle-timeout applies to the whole TCP connection and currently does not take running requests into account, so, no, this currently cannot be changed per request.

I guess what we might want is more fine-grained timeout handling so that you could have different kind of timeouts:

  • a request timeout like the one we have right now that covers “start of request to start of response”
  • another kind of request timeout than spans from receiving the request to sending out the last bits of the response
  • an idle timeout that covers real idle times between requests
  • a last resort idle timeout (like the one we have now) that would be set to values higher than all of the other ones that would cover connections that would be otherwise left open

One rough workaround for now could be to set high values for the idle-timeout regardless of the connection. Could that work for you? Are you concerned about resource usage of idle connections?

Johannes