Documentation ¶
Overview ¶
Package objerr provides error definitions used in 'objstore'.
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ( // ErrUnauthenticated is returned if we've sent a request to a cloud provider and received a response indicating // that we're unauthenticated i.e. 401 for Azure and typically a 403 for AWS. ErrUnauthenticated = errors.New("failed to authenticate, please check that valid credentials have been provided") // attempted an operation where we don't have the valid permissions. This is typically a result of not having the // correct RBAC permissions. ErrUnauthorized = errors.New("authenticated user does not have the permission to access this resource") )
var ErrEndpointResolutionFailed = errors.New("cloud endpoint domain name resolution failed, " +
"check account name/region and endpoint are all valid")
ErrEndpointResolutionFailed is returned if we've failed to resolve the cloud endpoint for some reason.
var ErrNoCredentialsFound = errors.New("could not find credentials for the supported authentication methods")
ErrNoValidCredentialsFound is returned if we have checked all of the supported authentication methods and could not create any credentials.
NOTE: This error specifically means that we couldn't find/create any credentials, if a credential is found and ends up being invalid, a different error will be returned.
var ErrUnsupportedOperation = errors.New("unsupported operation")
ErrUnsupportedOperation is returned when attempting to perform an operation which is unsupported for the current cloud provider.
Functions ¶
func HandleError ¶
HandleError converts the given error into a user friendly error where possible, returning the given error when not.
func IsNotFoundError ¶
IsNotFoundError return a boolean indicating whether the given error is a 'NotFoundError'.
func TryHandleError ¶
TryHandleError converts the given error into a user friendly error where possible, returning <nil> where not.
Types ¶
type NotFoundError ¶
NotFoundError indicates that something was not found.
func (*NotFoundError) Error ¶
func (e *NotFoundError) Error() string
Error implements the 'error' interface.