There are several different timeouts that you can hit with sync job submissions. Yours is coming from Spray-can server. You can configure it through your conf
file:
spray.can.server {
idle-timeout = <set desired timeout>
request-timeout = <set desired timeout>
}
You can set both values to infinite
to disable these timeouts at all.
In general, there are at least 3 common different timeouts that I've observed and that can return your request before job completion:
- Akka-based ask timeout. Will return a JSON response with "ERROR" status, if sync job was not completed before X sec. Default in SJS is 10sec but you can overwrite it by passing
timeout=Y
argument to your POST /jobs
request.
- Spray-can server timeouts:
idle-timeout
, request-timeout
. Will return default Spray response, making it harder to catch. They default to 60 and 40 secs respectively.
- Yet another timeout may come from your client REST library... Some of them configure their defaults to disable any timeout on this layer, some of them may take into account the server's timeouts and configure their own behavior according to that... For example, C++ REST SDK library kicks in WinHTTP timeout of 30 secs once you disable timeout #2 above, with #2 in place it will wait for 40 sec...