Take the 2-minute tour ×  I've been using the Databinder
Dispatch library in a client for a simple REST-ish API. I know
how to detect if I get an HTTP response with an error status:
Http x (request) {     case (200, _, _, content) =>
successResult(content())     case (404, _, _, _) =>
notFoundErrorResult     case (_, _, _, _) => genericErrorResult
But how can I distinguish an error response from a failure to
get any response at all, because of an invalid domain or failure
to connect? And is there any way to implement a timeout while
still using synchronous semantics? If there's anything relevant
in the API, I've missed it.  share|improve this question add
comment  3 Answers  There is also a more elegant way to
configure client using Http.configure method which receives
Builder => Builder function as an argument:  val http = Http.con
figure(_.setAllowPoolingConnection(true).setConnectionTimeoutInM
s(5000)) share|improve this answer add comment  The Periodic
Table tells us that >! sets up an exception listener