Feature/acksync response writer (#1267)

This implements a "detached" mechanism to get an ack from the runner
once it actually starts to run a function. In this scenario the response
returned back is just a 202 if we placed the function in a specific
time-frame. If we hit some errors or we fail to place the fn in time we
return back different errors.
This commit is contained in:
Andrea Rosa
2018-11-09 18:25:43 +00:00
committed by Tolga Ceylan
parent 2df6c8d349
commit 182db94fad
17 changed files with 453 additions and 58 deletions

View File

@@ -156,6 +156,16 @@ var (
error: errors.New("Async functions are not supported on this server"),
}
ErrDetachUnsupported = err{
code: http.StatusNotImplemented,
error: errors.New("Detach call functions are not supported on this server"),
}
ErrCallHandlerNotFound = err{
code: http.StatusInternalServerError,
error: errors.New("Unable to find the call handle"),
}
// TODO consider removal. see rationale at uses, or remove if none.
ErrContainerExitedEarly = err{
code: http.StatusBadGateway,