subscription-service/src/main/java/com/mantolin/adidascodingchallenge/subscriptionservice/exception/CustomizedResponseEntityExceptionHandler.java
/**
     * Any unspecified exception handler
     * 
     * @param ex
     * @param request
     * @return ResponseEntity
     */
Any unspecified exception handler

@param ex
@param request
@return ResponseEntity
Any unspecified exception handler @param ex @param request @return ResponseEntity
@ExceptionHandler(Exception.class)
    public final ResponseEntity<Object> handleAllExceptions(Exception ex, WebRequest request) {
        ErrorDetails errorDetails = new ErrorDetails(new Date(), ex.getMessage(), request.getDescription(false));
        return new ResponseEntity<Object>(errorDetails, HttpStatus.INTERNAL_SERVER_ERROR);
    }
@ ExceptionHandler ( Exception . class ) public final ResponseEntity < Object > handleAllExceptions ( Exception ex , WebRequest request ) { ErrorDetails errorDetails = new ErrorDetails ( new Date ( ) , ex . getMessage ( ) , request . getDescription ( false ) ) ; return new ResponseEntity < Object > ( errorDetails , HttpStatus . INTERNAL_SERVER_ERROR ) ; }
Any unspecified exception handler
Any unspecified exception handler