2019-11-05 11:30:11 +08:00
|
|
|
package cloudos
|
|
|
|
|
|
|
|
import "fmt"
|
|
|
|
|
2019-11-05 11:32:55 +08:00
|
|
|
// S3SDKError -
|
2019-11-05 11:30:11 +08:00
|
|
|
type S3SDKError struct {
|
|
|
|
Code string // The error code returned from S3 to the caller
|
|
|
|
Message string // The detail error message from S3
|
|
|
|
RawMessage string // The raw messages from S3
|
|
|
|
StatusCode int // HTTP status code
|
|
|
|
}
|
|
|
|
|
|
|
|
// Error implements interface error
|
|
|
|
func (e S3SDKError) Error() string {
|
|
|
|
return fmt.Sprintf("s3: service returned error: StatusCode=%d, ErrorCode=%s, ErrorMessage=\"%s\"",
|
|
|
|
e.StatusCode, e.Code, e.Message)
|
|
|
|
}
|