Class LoggingUtil

java.lang.Object
com.marklogic.client.util.LoggingUtil

public final class LoggingUtil extends Object
Provides public constants for configuring MarkLogic Java Client logging behaviour.

OkHttp Network Logging

The Java Client uses OkHttp for all HTTP communication with MarkLogic. Optional network traffic logging is controlled by two Java system properties:

When the output is set to LOGGER, log lines are written to the SLF4J logger category OKHTTP_NETWORK_LOGGER at INFO level. Configure this category in your logging framework to enable network diagnostics without enabling debug logging for unrelated client internals. For example, in logback.xml:


 <logger name="marklogic.okhttp.network" level="INFO"/>
 

Or in a Spring Boot application.properties file:


 logging.level.marklogic.okhttp.network=INFO
 

Security warning: Authorization and x-auth-token header values are automatically redacted from all log output. However, HEADERS and BODY levels may expose other sensitive data including MarkLogic document content. Never enable HEADERS or BODY in a production environment.

Since:
8.2.0