class ValidationHandler {

    public boolean isToValidate(HttpServerRequest request) {
        final Logger log = RequestLoggerFactory.getLogger(ValidationHandler.class, request);

        boolean doValidate = supportedMethods.contains(request.method().name()) &&
                isJsonRequest(request) &&
                !(request.headers().names().contains(VALID_HEADER)) &&
                !(request.params().names().contains(EXPAND_PARAM));
        if (!doValidate) {
            return false;
        }

        // Exclude Hooks from validation
        if(request.uri().contains(HOOKS_ROUTE_URI_PART) || request.uri().contains(HOOKS_LISTENERS_URI_PART)){
            return false; // do not validate
        }

        List<Map<String, String>> validationResources = validationResourceManager.getValidationResource().getResources();
        try {
            for (Map<String, String> validationResource : validationResources) {
                if (doesRequestValueMatch(request.method().name(), validationResource.get(ValidationResource.METHOD_PROPERTY))
                        && doesRequestValueMatch(request.uri(), validationResource.get(ValidationResource.URL_PROPERTY))) {
                    return true;
                }
            }
        } catch (PatternSyntaxException patternException) {
            log.error(patternException.getMessage() + " " + patternException.getPattern());
        }
        return false;
    }

    public  ValidationHandler(ValidationResourceManager validationResourceManager, ResourceStorage storage, HttpClient httpClient, String schemaRoot);

}