mirror of
https://github.com/openfaas/faas.git
synced 2025-06-23 07:13:23 +00:00
Accept 202 as valid code for /system/scale-function/<function>
Updated gateway to accept 202 as valid response code for /system/scale-function/<function> along with 200. Fixes: #faas-netes/245 Signed-off-by: Vivek Singh <vivekkmr45@yahoo.in>
This commit is contained in:
@ -140,7 +140,7 @@ func (s ExternalServiceQuery) SetReplicas(serviceName string, count uint64) erro
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if res.StatusCode != http.StatusOK {
|
if !(res.StatusCode == http.StatusOK || res.StatusCode == http.StatusAccepted) {
|
||||||
err = fmt.Errorf("error scaling HTTP code %d, %s", res.StatusCode, urlPath)
|
err = fmt.Errorf("error scaling HTTP code %d, %s", res.StatusCode, urlPath)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user