Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( ErrJobNumberCounterNotFound = errors.New("job number counter not found") ErrJobNotFound = errors.New("job not found") ErrUnableToParseBody = errors.New("unable to read submitted body") ErrJobNumberNotProvided = errors.New("job number not provided") ErrJobNumberMustBeInt = errors.New("job number must be an integer") ErrSourceIDNotProvided = errors.New("source ID not provided") ErrTargetIDNotProvided = errors.New("target ID not provided") ErrJobTypeNotProvided = errors.New("job type not provided") ErrSourceTitleNotFound = errors.New("source title not found or empty") ErrSourceIDInvalid = errors.New("source ID is invalid") ErrTargetIDInvalid = errors.New("target ID is invalid") ErrJobTypeInvalid = errors.New("job type is invalid") ErrInternalServerError = errors.New("an unexpected error occurred") ErrSourceIDValidation = errors.New("source ID failed to validate") ErrTargetIDValidation = errors.New("target ID failed to validate") ErrJobAlreadyRunning = errors.New("job already running") ErrJobStateInvalid = errors.New("job state parameter is invalid") ErrTaskStateInvalid = errors.New("task state parameter is invalid") ErrJobStateNotAllowed = errors.New("state not allowed for this endpoint") ErrJobStateTransitionNotAllowed = errors.New("state change is not allowed") ErrTaskNotFound = errors.New("task not found") ErrOffsetInvalid = errors.New("offset parameter is invalid") ErrLimitInvalid = errors.New("limit parameter is invalid") ErrLimitExceeded = errors.New("limit parameter exceeds maximum allowed") ErrSourceIDZebedeeURIInvalid = errors.New("source ID URI path must start with '/', not end with '/', not contain query strings or hashbangs") ErrTargetIDDatasetIDInvalid = errors.New("target id must be lowercase alphanumeric with optional hyphen separators") ErrSourceDataTypeInvalid = errors.New("source data has incorrect type") StatusCodeMap = map[error]int{ ErrJobNotFound: http.StatusNotFound, ErrTaskNotFound: http.StatusNotFound, ErrUnableToParseBody: http.StatusBadRequest, ErrJobNumberNotProvided: http.StatusBadRequest, ErrJobNumberMustBeInt: http.StatusBadRequest, ErrSourceIDNotProvided: http.StatusBadRequest, ErrTargetIDNotProvided: http.StatusBadRequest, ErrJobTypeNotProvided: http.StatusBadRequest, ErrInternalServerError: http.StatusInternalServerError, ErrSourceTitleNotFound: http.StatusInternalServerError, ErrSourceIDValidation: http.StatusInternalServerError, ErrTargetIDValidation: http.StatusInternalServerError, ErrJobNumberCounterNotFound: http.StatusInternalServerError, ErrJobAlreadyRunning: http.StatusConflict, ErrSourceIDInvalid: http.StatusBadRequest, ErrTargetIDInvalid: http.StatusBadRequest, ErrJobTypeInvalid: http.StatusBadRequest, ErrSourceIDZebedeeURIInvalid: http.StatusBadRequest, ErrTargetIDDatasetIDInvalid: http.StatusBadRequest, ErrJobStateInvalid: http.StatusBadRequest, ErrTaskStateInvalid: http.StatusBadRequest, ErrOffsetInvalid: http.StatusBadRequest, ErrLimitInvalid: http.StatusBadRequest, ErrLimitExceeded: http.StatusBadRequest, ErrJobStateTransitionNotAllowed: http.StatusConflict, ErrSourceIDInvalid: http.StatusBadRequest, ErrTargetIDInvalid: http.StatusBadRequest, ErrJobTypeInvalid: http.StatusBadRequest, ErrJobStateNotAllowed: http.StatusBadRequest, } )
Predefined errors
Functions ¶
This section is empty.
Types ¶
Click to show internal directories.
Click to hide internal directories.