protected ResponseEntity handleHttpRequestMethodNotSupported()

in src/main/java/com/epam/grid/engine/controller/ControllerAdvisor.java [116:127]


    protected ResponseEntity<Object> handleHttpRequestMethodNotSupported(
            final HttpRequestMethodNotSupportedException exception,
            final HttpHeaders headers,
            final HttpStatus status,
            final WebRequest request) {
        final HttpServletRequest webRequest = ((ServletWebRequest) request).getRequest();
        log.error(LOGGING_MSG_HTTP_REQUEST_METHOD_NOT_SUPPORTED,
                webRequest.getMethod(),
                webRequest.getRequestURI(),
                exception);
        return new ResponseEntity<>(exception.getMessage(), status);
    }