@@ -0,0 +1,1102 @@
+package org.datavaultplatform.broker.exceptions;%0A%0Aimport org.springframework.core.annotation.AnnotationUtils;%0Aimport org.springframework.http.HttpStatus;%0Aimport org.springframework.http.ResponseEntity;%0Aimport org.springframework.web.bind.annotation.ControllerAdvice;%0Aimport org.springframework.web.bind.annotation.ExceptionHandler;%0Aimport org.springframework.web.bind.annotation.ResponseStatus;%0A%0Aimport javax.servlet.http.HttpServletRequest;%0A%0A/**%0A * User: Robin Taylor%0A * Date: 01/07/2016%0A * Time: 09:11%0A */%0A%0A@ControllerAdvice%0Apublic class GlobalExceptionHandler %7B%0A%0A    // Note - Add methods for more specific Exceptions here.%0A%0A    @ExceptionHandler(value = Exception.class)%0A    public ResponseEntity%3CString%3E defaultExceptionHandler(HttpServletRequest req, Exception e) throws Exception %7B%0A        // If the exception is annotated with @ResponseStatus rethrow it and let the framework handle it.%0A        if (AnnotationUtils.findAnnotation(e.getClass(), ResponseStatus.class) != null)%0A            throw e;%0A%0A        return new ResponseEntity%3C%3E(e.getMessage(), HttpStatus.INTERNAL_SERVER_ERROR);%0A%0A    %7D%0A%0A%7D%0A

Add GlobalExceptionHandler