We have an issue about the Log Level of the running applications of a JakartaEE 10 project (that does NOT use the Spring framework): using the OGM library (3.2.36 with Bolt Driver), auto-generated queries make reference to Cypher paths that do not already exist, in turn producing WARN logs that saturates the disk (several GBs at day). We would like to set the Log Level to ERROR.
We read the guide but the only reference to the Log Level was: " Neo4j-OGM uses SLF4J to log statements. In production, you can set the log level in a file called logback.xml to be found at the root of the classpath. Please see the Logback manual for further details".
We firstly tried to add the logback.xml to the root classpath but its configurations have been ignored by the Logger (whose class was org.slf4j.impl.Slf4jLogger which is not an implementation of the ch.qos.logback.classic.Logger class).
Then we also tried to explicitly include logback (version 1.4.6) Maven dependency follow the logback guide but without success (we noted that the dependency "ch.qos.logback" was not retrieved by maven neither provided by the JakartaEE 10 certified server, Wildfly 27.0.0.Final, providing the version 2.0.6 of slf4j).
Which is the simplest way to change the Log Level to ERROR?
Hi Gerrit,
thank you for your kind answer but we are not using Quarkus or other frameworks; only the JakartaEE specifications in a Maven project.
We tried to configurate the logging level of the java.util.logging.Logger and also its implementation org.slf4j.impl.Slf4jLogger (offered by the application server) for the BoltRequest and BoltResponse classes but without success. Could you explain what do you mean with "use SLF4j as a facade" with an example (we know the design pattern but we cannot find the method for changing the log level not even after a cast)?