From dcdd133f68f238e87637c845feb9bcbe11c5d837 Mon Sep 17 00:00:00 2001 From: Bolun Wen Date: Thu, 17 Dec 2020 10:21:52 -0500 Subject: [PATCH] issue-#156 logging status separately --- .../main/java/com/networknt/openapi/ValidatorHandler.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/openapi-validator/src/main/java/com/networknt/openapi/ValidatorHandler.java b/openapi-validator/src/main/java/com/networknt/openapi/ValidatorHandler.java index 70876ef5..860f8b43 100644 --- a/openapi-validator/src/main/java/com/networknt/openapi/ValidatorHandler.java +++ b/openapi-validator/src/main/java/com/networknt/openapi/ValidatorHandler.java @@ -84,7 +84,10 @@ public void handleRequest(final HttpServerExchange exchange) throws Exception { Status status = requestValidator.validateRequest(requestPath, exchange, openApiOperation); if(status != null) { setExchangeStatus(exchange, status); - if(config.logError) logger.error("ValidationError:" + status.toString()); + if(config.logError) { + logger.error("There is an Validation Error:"); + logger.error(status.toString()); + } return; }