akka/akka-http

Add onRequestTimeout Directive

Offen

#2.015 geöffnet am 15.05.2018

 (3 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)Scala (598 Forks)batch import
1 - triagedhelp wantedt:routing

Repository-Metriken

Stars
 (1.311 Sterne)
PR-Merge-Metriken
 (Durchschn. Merge 1T 10h) (2 gemergte PRs in 30 T)

Beschreibung

It would be nice if we had a directive that allowed us to side-effect when a server request timeout occurs. Currently we can do something on withRequestTimeoutResponse, but that requires us to supply a response rather than let the timeout handling happen elsewhere. An example of when this is desirable would be when an external request results in client requests or other streams being run that need to be consumed to supply a response to the request. In this case it's desirable to consume/killswitch those streams when the request times out.

Contributor Guide