forked from TrueCloudLab/frostfs-s3-gw
[#103] Return 504 http code on timeout errors
Signed-off-by: Denis Kirillov <d.kirillov@yadro.com>
This commit is contained in:
parent
8fcaf76f41
commit
462589fc0c
9 changed files with 128 additions and 92 deletions
|
@ -52,6 +52,10 @@ func transformToS3Error(err error) error {
|
|||
return errors.GetAPIError(errors.ErrAccessDenied)
|
||||
}
|
||||
|
||||
if errorsStd.Is(err, layer.ErrGatewayTimeout) {
|
||||
return errors.GetAPIError(errors.ErrGatewayTimeout)
|
||||
}
|
||||
|
||||
return errors.GetAPIError(errors.ErrInternalError)
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue