|
@ -93,6 +93,7 @@ const ( |
|
|
ErrInvalidRequest |
|
|
ErrInvalidRequest |
|
|
ErrAuthNotSetup |
|
|
ErrAuthNotSetup |
|
|
ErrNotImplemented |
|
|
ErrNotImplemented |
|
|
|
|
|
ErrPreconditionFailed |
|
|
|
|
|
|
|
|
ErrExistingObjectIsDirectory |
|
|
ErrExistingObjectIsDirectory |
|
|
) |
|
|
) |
|
@ -342,7 +343,7 @@ var errorCodeResponse = map[ErrorCode]APIError{ |
|
|
Description: "Invalid Request", |
|
|
Description: "Invalid Request", |
|
|
HTTPStatusCode: http.StatusBadRequest, |
|
|
HTTPStatusCode: http.StatusBadRequest, |
|
|
}, |
|
|
}, |
|
|
ErrAuthNotSetup : { |
|
|
|
|
|
|
|
|
ErrAuthNotSetup: { |
|
|
Code: "InvalidRequest", |
|
|
Code: "InvalidRequest", |
|
|
Description: "Signed request requires setting up SeaweedFS S3 authentication", |
|
|
Description: "Signed request requires setting up SeaweedFS S3 authentication", |
|
|
HTTPStatusCode: http.StatusBadRequest, |
|
|
HTTPStatusCode: http.StatusBadRequest, |
|
@ -352,6 +353,11 @@ var errorCodeResponse = map[ErrorCode]APIError{ |
|
|
Description: "A header you provided implies functionality that is not implemented", |
|
|
Description: "A header you provided implies functionality that is not implemented", |
|
|
HTTPStatusCode: http.StatusNotImplemented, |
|
|
HTTPStatusCode: http.StatusNotImplemented, |
|
|
}, |
|
|
}, |
|
|
|
|
|
ErrPreconditionFailed: { |
|
|
|
|
|
Code: "PreconditionFailed", |
|
|
|
|
|
Description: "At least one of the pre-conditions you specified did not hold", |
|
|
|
|
|
HTTPStatusCode: http.StatusPreconditionFailed, |
|
|
|
|
|
}, |
|
|
ErrExistingObjectIsDirectory: { |
|
|
ErrExistingObjectIsDirectory: { |
|
|
Code: "ExistingObjectIsDirectory", |
|
|
Code: "ExistingObjectIsDirectory", |
|
|
Description: "Existing Object is a directory.", |
|
|
Description: "Existing Object is a directory.", |
|
|