package
22.11.9
Repository: https://github.com/cs-si/safescale.git
Documentation: pkg.go.dev

# Functions

AbortedError creates an ErrAborted error If err != nil, 'err' will become the cause of the abortion that can be retrieved using Error.Cause().
AbortedErrorWithCauseAndConsequences creates an ErrAborted error.
AddConsequence adds an error 'err' to the list of consequences.
AlteredNothingError creates an ErrAlteredNothing error.
AlteredNothingErrorWithCause creates an ErrAlteredNothing error.
Annotate ...
Cause returns the direct cause of an error if it implements the causer interface and that cause is not-nil in any other case, returns the unmodified error 'err'.
Consequences returns the list of consequences.
ConvertError converts an error to a fail.Error.
DuplicateError creates an ErrDuplicate error.
DuplicateErrorWithCause creates an ErrDuplicate error initialized with cause 'cause'.
ExecutionError creates an ErrExecution error.
ExecutionErrorWithCause creates an ErrExecution error.
ForbiddenError creates an ErrForbidden error.
ForbiddenErrorWithCause creates an ErrForbidden error.
FromGRPCStatus translates GRPC status to error.
No description provided by the author
No description provided by the author
InconsistentError creates an ErrInconsistent error.
InconsistentErrorWithCause creates an ErrInconsistent error.
InvalidInstanceContentError returns an instance of ErrInvalidInstanceContent.
InvalidInstanceContentErrorWithCause returns an instance of ErrInvalidInstanceContent.
InvalidInstanceError creates an ErrInvalidInstance error.
InvalidInstanceErrorWithCause creates an ErrInvalidInstance error.
InvalidParameterCannotBeEmptyStringError is a specialized *ErrInvalidParameter with message "cannot be empty string".
InvalidParameterCannotBeNilError is a specialized *ErrInvalidParameter with message "cannot be nil".
InvalidParameterError creates an ErrInvalidParameter error.
InvalidParameterErrorWithCauseAndConsequences creates an ErrInvalidParameter error.
InvalidRequestError creates an ErrInvalidRequest error.
InvalidRequestErrorWithCause creates an ErrInvalidRequest error.
IsError ...
IsGRPCError tells if 'err' is of GRPC kind.
NewError creates a new failure report.
NewErrorList creates a ErrorList.
No description provided by the author
NewErrorWithCause creates a new failure report with a cause.
NewErrorWithCauseAndConsequences creates a new failure report with a cause and a list of teardown problems 'consequences'.
NotAuthenticatedError creates an ErrNotAuthenticated error.
NotAuthenticatedErrorWithCause creates an ErrNotAuthenticated error.
NotAvailableError creates an ErrNotAvailable error.
NotAvailableErrorWithCause creates an ErrNotAvailable error initialized with a cause 'cause'.
NotFoundError creates an ErrNotFound error.
NotFoundErrorWithCause creates an ErrNotFound error initialized with cause 'cause'.
NotImplementedError creates an ErrNotImplemented report.
NotImplementedErrorWithCauseAndConsequences creates an ErrNotImplemented report.
OnExitConvertToGRPCStatus converts err to GRPC Status.
OnExitLogError logs error with level logrus.ErrorLevel.
OnExitLogErrorWithLevel logs error with the log level wanted.
OnExitTraceError logs error with level logrus.TraceLevel.
OnExitWrapError wraps the error with the message.
OnPanic captures panic error and fill the error pointer with a ErrRuntimePanic.
OverflowError creates an ErrOverflow error.
OverflowErrorWithCause creates an ErrOverflow error.
OverloadError creates an ErrOverload error.
OverloadErrorWithCause creates an ErrOverload error.
RootCause follows the chain of causes / wrapped errors and returns the last not-nil error.
RuntimePanicError creates an ErrRuntimePanic error.
RuntimePanicErrorWithCauseAndConsequences creates an ErrRuntimePanic error.
SilentOnPanic captures panic error and logs the error, is intended for functions that DON'T return errors.
StatusWrapErr ...
Success ..
SyntaxError creates an ErrSyntax error.
SyntaxErrorWithCause creates an ErrSyntax error initialized with cause 'cause'.
No description provided by the author
TimeoutError returns an ErrTimeout instance.
TimeoutErrorWithCauseAndConsequences returns an ErrTimeout instance.
ToGRPCStatus translates an error to a GRPC status.
UnknownError creates an ErrUnknown error.
UnknownErrorWithCause creates an ErrUnknown error.
WarningError returns an ErrWarning instance.
WarningErrorWithCauseAndConsequences return an ErrWarning instance.
Wrap creates a new error with a message 'msg' and a causer error 'cause'.

# Constants

No description provided by the author

# Structs

ErrAborted is used to signal abortion.
ErrAlteredNothing is used when an Alter() call changed nothing.
ErrDuplicate already exists error.
ErrExecution is used when code ErrExecution failed.
ErrForbidden when action is not allowed.
ErrInconsistent is used when data used is ErrInconsistent.
ErrInvalidInstance has to be used when a method is called from an instance equal to nil.
ErrInvalidInstanceContent has to be used when a property of an instance contains invalid property.
ErrInvalidParameter ...
ErrInvalidRequest ...
ErrNotAuthenticated when action is done without being authenticated first.
ErrNotAvailable resource not available error.
ErrNotFound resource not found error.
ErrNotImplemented ...
ErrorList ...
ErrOverflow is used when a limit is reached.
ErrOverload when action cannot be honored because provider is overloaded (ie too many requests occurred in a given time).
ErrRuntimePanic ...
ErrSyntax ...
ErrTimeout defines a ErrTimeout error.
ErrUnknown is used when situation is unknown.
ErrUnqualified is a generic Error type that has no particular signification.
ErrWarning defines an ErrWarning error.

# Interfaces

Error defines the interface of a SafeScale error.
ErrorLike interface.
Status interface.