Package pro.taskana.common.rest
Class TaskanaRestExceptionHandler
- java.lang.Object
-
- org.springframework.web.servlet.mvc.method.annotation.ResponseEntityExceptionHandler
-
- pro.taskana.common.rest.TaskanaRestExceptionHandler
-
@Order(-2147483648) @ControllerAdvice public class TaskanaRestExceptionHandler extends org.springframework.web.servlet.mvc.method.annotation.ResponseEntityExceptionHandlerThis class handles taskana exceptions.
-
-
Constructor Summary
Constructors Constructor Description TaskanaRestExceptionHandler()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected org.springframework.http.ResponseEntity<TaskanaErrorData>handleClassificationAlreadyExist(pro.taskana.classification.api.exceptions.ClassificationAlreadyExistException ex, org.springframework.web.context.request.WebRequest req)protected org.springframework.http.ResponseEntity<TaskanaErrorData>handleConcurrencyException(pro.taskana.common.api.exceptions.ConcurrencyException ex, org.springframework.web.context.request.WebRequest req)protected org.springframework.http.ResponseEntity<TaskanaErrorData>handleDomainNotFound(pro.taskana.common.api.exceptions.DomainNotFoundException ex, org.springframework.web.context.request.WebRequest req)protected org.springframework.http.ResponseEntity<TaskanaErrorData>handleDuplicateKey(org.springframework.dao.DuplicateKeyException ex, org.springframework.web.context.request.WebRequest req)protected org.springframework.http.ResponseEntity<TaskanaErrorData>handleGeneralException(Exception ex, org.springframework.web.context.request.WebRequest req)protected org.springframework.http.ResponseEntity<TaskanaErrorData>handleInvalidArgument(pro.taskana.common.api.exceptions.InvalidArgumentException ex, org.springframework.web.context.request.WebRequest req)protected org.springframework.http.ResponseEntity<TaskanaErrorData>handleInvalidOwner(pro.taskana.task.api.exceptions.InvalidOwnerException ex, org.springframework.web.context.request.WebRequest req)protected org.springframework.http.ResponseEntity<TaskanaErrorData>handleInvalidState(pro.taskana.task.api.exceptions.InvalidStateException ex, org.springframework.web.context.request.WebRequest req)protected org.springframework.http.ResponseEntity<TaskanaErrorData>handleInvalidWorkbasket(pro.taskana.workbasket.api.exceptions.InvalidWorkbasketException ex, org.springframework.web.context.request.WebRequest req)protected org.springframework.http.ResponseEntity<TaskanaErrorData>handleMaxUploadSizeExceededException(org.springframework.web.multipart.MaxUploadSizeExceededException ex, org.springframework.web.context.request.WebRequest req)protected org.springframework.http.ResponseEntity<TaskanaErrorData>handleNotAuthorized(pro.taskana.common.api.exceptions.NotAuthorizedException ex, org.springframework.web.context.request.WebRequest req)protected org.springframework.http.ResponseEntity<TaskanaErrorData>handleNotAuthorizedToQueryWorkbasket(pro.taskana.workbasket.api.exceptions.NotAuthorizedToQueryWorkbasketException ex, org.springframework.web.context.request.WebRequest req)protected org.springframework.http.ResponseEntity<TaskanaErrorData>handleTaskAlreadyExist(pro.taskana.task.api.exceptions.TaskAlreadyExistException ex, org.springframework.web.context.request.WebRequest req)protected org.springframework.http.ResponseEntity<TaskanaErrorData>handleTaskNotFound(pro.taskana.common.api.exceptions.NotFoundException ex, org.springframework.web.context.request.WebRequest req)protected org.springframework.http.ResponseEntity<TaskanaErrorData>handleWorkbasketAccessItemAlreadyExist(pro.taskana.workbasket.api.exceptions.WorkbasketAccessItemAlreadyExistException ex, org.springframework.web.context.request.WebRequest req)protected org.springframework.http.ResponseEntity<TaskanaErrorData>handleWorkbasketAlreadyExist(pro.taskana.workbasket.api.exceptions.WorkbasketAlreadyExistException ex, org.springframework.web.context.request.WebRequest req)protected org.springframework.http.ResponseEntity<TaskanaErrorData>handleWorkbasketInUse(pro.taskana.workbasket.api.exceptions.WorkbasketInUseException ex, org.springframework.web.context.request.WebRequest req)-
Methods inherited from class org.springframework.web.servlet.mvc.method.annotation.ResponseEntityExceptionHandler
handleAsyncRequestTimeoutException, handleBindException, handleConversionNotSupported, handleException, handleExceptionInternal, handleHttpMediaTypeNotAcceptable, handleHttpMediaTypeNotSupported, handleHttpMessageNotReadable, handleHttpMessageNotWritable, handleHttpRequestMethodNotSupported, handleMethodArgumentNotValid, handleMissingPathVariable, handleMissingServletRequestParameter, handleMissingServletRequestPart, handleNoHandlerFoundException, handleServletRequestBindingException, handleTypeMismatch
-
-
-
-
Method Detail
-
handleInvalidArgument
@ExceptionHandler(pro.taskana.common.api.exceptions.InvalidArgumentException.class) protected org.springframework.http.ResponseEntity<TaskanaErrorData> handleInvalidArgument(pro.taskana.common.api.exceptions.InvalidArgumentException ex, org.springframework.web.context.request.WebRequest req)
-
handleNotAuthorized
@ExceptionHandler(pro.taskana.common.api.exceptions.NotAuthorizedException.class) protected org.springframework.http.ResponseEntity<TaskanaErrorData> handleNotAuthorized(pro.taskana.common.api.exceptions.NotAuthorizedException ex, org.springframework.web.context.request.WebRequest req)
-
handleTaskNotFound
@ExceptionHandler(pro.taskana.common.api.exceptions.NotFoundException.class) protected org.springframework.http.ResponseEntity<TaskanaErrorData> handleTaskNotFound(pro.taskana.common.api.exceptions.NotFoundException ex, org.springframework.web.context.request.WebRequest req)
-
handleTaskAlreadyExist
@ExceptionHandler(pro.taskana.task.api.exceptions.TaskAlreadyExistException.class) protected org.springframework.http.ResponseEntity<TaskanaErrorData> handleTaskAlreadyExist(pro.taskana.task.api.exceptions.TaskAlreadyExistException ex, org.springframework.web.context.request.WebRequest req)
-
handleNotAuthorizedToQueryWorkbasket
@ExceptionHandler(pro.taskana.workbasket.api.exceptions.NotAuthorizedToQueryWorkbasketException.class) protected org.springframework.http.ResponseEntity<TaskanaErrorData> handleNotAuthorizedToQueryWorkbasket(pro.taskana.workbasket.api.exceptions.NotAuthorizedToQueryWorkbasketException ex, org.springframework.web.context.request.WebRequest req)
-
handleInvalidState
@ExceptionHandler(pro.taskana.task.api.exceptions.InvalidStateException.class) protected org.springframework.http.ResponseEntity<TaskanaErrorData> handleInvalidState(pro.taskana.task.api.exceptions.InvalidStateException ex, org.springframework.web.context.request.WebRequest req)
-
handleInvalidOwner
@ExceptionHandler(pro.taskana.task.api.exceptions.InvalidOwnerException.class) protected org.springframework.http.ResponseEntity<TaskanaErrorData> handleInvalidOwner(pro.taskana.task.api.exceptions.InvalidOwnerException ex, org.springframework.web.context.request.WebRequest req)
-
handleClassificationAlreadyExist
@ExceptionHandler(pro.taskana.classification.api.exceptions.ClassificationAlreadyExistException.class) protected org.springframework.http.ResponseEntity<TaskanaErrorData> handleClassificationAlreadyExist(pro.taskana.classification.api.exceptions.ClassificationAlreadyExistException ex, org.springframework.web.context.request.WebRequest req)
-
handleDuplicateKey
@ExceptionHandler(org.springframework.dao.DuplicateKeyException.class) protected org.springframework.http.ResponseEntity<TaskanaErrorData> handleDuplicateKey(org.springframework.dao.DuplicateKeyException ex, org.springframework.web.context.request.WebRequest req)
-
handleConcurrencyException
@ExceptionHandler(pro.taskana.common.api.exceptions.ConcurrencyException.class) protected org.springframework.http.ResponseEntity<TaskanaErrorData> handleConcurrencyException(pro.taskana.common.api.exceptions.ConcurrencyException ex, org.springframework.web.context.request.WebRequest req)
-
handleWorkbasketInUse
@ExceptionHandler(pro.taskana.workbasket.api.exceptions.WorkbasketInUseException.class) protected org.springframework.http.ResponseEntity<TaskanaErrorData> handleWorkbasketInUse(pro.taskana.workbasket.api.exceptions.WorkbasketInUseException ex, org.springframework.web.context.request.WebRequest req)
-
handleWorkbasketAlreadyExist
@ExceptionHandler(pro.taskana.workbasket.api.exceptions.WorkbasketAlreadyExistException.class) protected org.springframework.http.ResponseEntity<TaskanaErrorData> handleWorkbasketAlreadyExist(pro.taskana.workbasket.api.exceptions.WorkbasketAlreadyExistException ex, org.springframework.web.context.request.WebRequest req)
-
handleWorkbasketAccessItemAlreadyExist
@ExceptionHandler(pro.taskana.workbasket.api.exceptions.WorkbasketAccessItemAlreadyExistException.class) protected org.springframework.http.ResponseEntity<TaskanaErrorData> handleWorkbasketAccessItemAlreadyExist(pro.taskana.workbasket.api.exceptions.WorkbasketAccessItemAlreadyExistException ex, org.springframework.web.context.request.WebRequest req)
-
handleInvalidWorkbasket
@ExceptionHandler(pro.taskana.workbasket.api.exceptions.InvalidWorkbasketException.class) protected org.springframework.http.ResponseEntity<TaskanaErrorData> handleInvalidWorkbasket(pro.taskana.workbasket.api.exceptions.InvalidWorkbasketException ex, org.springframework.web.context.request.WebRequest req)
-
handleDomainNotFound
@ExceptionHandler(pro.taskana.common.api.exceptions.DomainNotFoundException.class) protected org.springframework.http.ResponseEntity<TaskanaErrorData> handleDomainNotFound(pro.taskana.common.api.exceptions.DomainNotFoundException ex, org.springframework.web.context.request.WebRequest req)
-
handleMaxUploadSizeExceededException
@ExceptionHandler(org.springframework.web.multipart.MaxUploadSizeExceededException.class) protected org.springframework.http.ResponseEntity<TaskanaErrorData> handleMaxUploadSizeExceededException(org.springframework.web.multipart.MaxUploadSizeExceededException ex, org.springframework.web.context.request.WebRequest req)
-
handleGeneralException
@ExceptionHandler(java.lang.Exception.class) protected org.springframework.http.ResponseEntity<TaskanaErrorData> handleGeneralException(Exception ex, org.springframework.web.context.request.WebRequest req)
-
-