Akka HTTP does not response everytime under heavy load

Hey guys,

I use Akka streams for backend services, which is are sometime under quite heavy load but do what they should do (the cummunication is based Kafka topics).
For health checks I use a very simple Akka HTTP server which offers a status of the specific service (database connection, …). This check is failing sometimes (a retry is always successful). This behavior correlates with higher load.

Is that maybe a timeout problem?
Is that possible to give akka http another thread pool? (I use the same actorsystem for both).

Thank you
Sigurd

That’s most likely caused by blocking on the main dispatcher. Try using jstack <pid> on the command line to see what dispatcher threads are doing when it happens.

If you are a Lightbend subscriber you can also use the Thread Starvation Detector to analyze situations like that automatically.