Documentation
¶
Index ¶
Constants ¶
View Source
const ( // Database error codes ERROR_CODE_DATABASE_CONNECTION_FAILED = 1001 ERROR_CODE_DATABASE_PING_FAILED = 1002 ERROR_CODE_DATABASE_OPERATION_FAILED = 1003 ERROR_CODE_DATABASE_UNIQUE_KEY = 1004 ERROR_CODE_DATABASE_RECORD_NOT_FOUND = 1005 ERROR_CODE_DATABASE_INVALID_CONFIGURATION = 1006 )
Variables ¶
View Source
var ( ERROR_UNAUTHORISED = &Error{message: "unauthorised", code: http.StatusUnauthorized} ERROR_DATABASE = &Error{message: "database operation failed", code: http.StatusFailedDependency} ERROR_PERMISSION_DENIED = &Error{message: "permission denied", code: http.StatusForbidden} ERROR_DATABASE_UNIQUE_KEY = &Error{message: "unique key failed", code: http.StatusBadRequest} ERROR_DATABASE_RECORD_NOT_FOUND = &Error{message: "record not found", code: http.StatusNotFound} ERROR_INTERNAL_SERVER_ERROR = &Error{message: "internal server error", code: http.StatusInternalServerError} )
Functions ¶
func BAD_REQUEST_ERROR ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.