Skip to content

Commit 05b3694

Browse files
committed
Reduced logger down to warn and fixed up logging in tests
1 parent 2fc5fda commit 05b3694

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/main/java/graphql/GraphQL.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -492,15 +492,15 @@ private PreparsedDocumentEntry parseAndValidate(ExecutionInput executionInput, G
492492
log.debug("Parsing query: '{}'...", executionInput.getQuery());
493493
ParseResult parseResult = parse(executionInput, graphQLSchema, instrumentationState);
494494
if (parseResult.isFailure()) {
495-
log.error("Query failed to parse : '{}'", executionInput.getQuery());
495+
log.warn("Query failed to parse : '{}'", executionInput.getQuery());
496496
return new PreparsedDocumentEntry(toInvalidSyntaxError(parseResult.getException()));
497497
} else {
498498
final Document document = parseResult.getDocument();
499499

500500
log.debug("Validating query: '{}'", executionInput.getQuery());
501501
final List<ValidationError> errors = validate(executionInput, document, graphQLSchema, instrumentationState);
502502
if (!errors.isEmpty()) {
503-
log.error("Query failed to validate : '{}'", executionInput.getQuery());
503+
log.warn("Query failed to validate : '{}'", executionInput.getQuery());
504504
return new PreparsedDocumentEntry(errors);
505505
}
506506

src/test/resources/simplelogger.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ org.slf4j.simpleLogger.defaultLogLevel=info
99
# Logging detail level for a SimpleLogger instance named "xxxxx".
1010
# Must be one of ("trace", "debug", "info", "warn", or "error").
1111
# If not specified, the default logging detail level is used.
12-
org.slf4j.simpleLogger.log.graphql=debug
12+
org.slf4j.simpleLogger.log.graphql=info
1313

1414
# Set to true if you want the current date and time to be included in output messages.
1515
# Default is false, and will output the number of milliseconds elapsed since startup.

0 commit comments

Comments
 (0)