Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var AccessDeniedError = newServiceError(model.ErrorCode_ACCESS_DENIED, "Access denied", codes.PermissionDenied)
View Source
var AlreadyExistsError = newServiceError(model.ErrorCode_ALREADY_EXISTS, "Already Exists", codes.FailedPrecondition)
RecordValidationError @fixme
View Source
var AuthenticationFailedError = newServiceError(model.ErrorCode_AUTHENTICATION_FAILED, "Authentication failed", codes.Unauthenticated)
View Source
var BackendConnectionAuthenticationError = newServiceError(model.ErrorCode_BACKEND_ERROR, "Backend error", codes.FailedPrecondition)
View Source
var ExternalBackendCommunicationError = newServiceError(model.ErrorCode_EXTERNAL_BACKEND_COMMUNICATION_ERROR, "External Backend communication error", codes.Internal)
View Source
var ExternalBackendError = newServiceError(model.ErrorCode_EXTERNAL_BACKEND_ERROR, "External Backend error", codes.Internal)
View Source
var InternalError = newServiceError(model.ErrorCode_INTERNAL_ERROR, "Internal error", codes.Internal)
View Source
var LogicalError = newServiceError(model.ErrorCode_RECORD_VALIDATION_ERROR, "Logical Error", codes.FailedPrecondition)
View Source
var PropertyNotFoundError = newServiceError(model.ErrorCode_PROPERTY_NOT_FOUND, "Property not found", codes.FailedPrecondition)
View Source
var RecordNotFoundError = newServiceError(model.ErrorCode_RECORD_NOT_FOUND, "record not found", codes.NotFound)
View Source
var RecordValidationError = newServiceError(model.ErrorCode_RECORD_VALIDATION_ERROR, "Record Validation failed", codes.FailedPrecondition)
View Source
var ReferenceViolation = newServiceError(model.ErrorCode_REFERENCE_VIOLATION, "Reference violation", codes.FailedPrecondition)
View Source
var ResourceNotFoundError = newServiceError(model.ErrorCode_RESOURCE_NOT_FOUND, "resource not found", codes.NotFound)
View Source
var ResourceValidationError = newServiceError(model.ErrorCode_RESOURCE_VALIDATION_ERROR, "resource Validation failed", codes.FailedPrecondition)
View Source
var UnableToLocatePrimaryKey = newServiceError(model.ErrorCode_UNABLE_TO_LOCATE_PRIMARY_KEY, "unable to locate primary key", codes.FailedPrecondition)
View Source
var UniqueViolation = newServiceError(model.ErrorCode_UNIQUE_VIOLATION, "Unique violation", codes.FailedPrecondition)
View Source
var UnsupportedOperation = newServiceError(model.ErrorCode_UNSUPPORTED_OPERATION, "Unsupported Operation", codes.FailedPrecondition)
Functions ¶
This section is empty.
Types ¶
type ServiceError ¶
type ServiceError interface { Code() model.ErrorCode Error() string ProtoError() *model.Error WithMessage(msg string) ServiceError WithDetails(details string) ServiceError WithErrorFields(errors []*model.ErrorField) ServiceError GetDetails() string Is(err error) bool GetGrpcErrorCode() codes.Code GetFullMessage() string }
Click to show internal directories.
Click to hide internal directories.