I'm using org.springframework.ws.server.endpoint.interceptor.PayloadLoggingInterceptor per one of the many Googled examples that I've found in an Eclipse Spring Web Service project. Everywhere that I've looked indicates that PayloadLoggingInterceptor will write log messages at DEBUG level, which it does in my app. I would like to use PayloadLoggingInterceptor in my Prod environment but I don't want to capture DEBUG level logging information for performance and file size reasons. Is it possible to configure PayloadLoggingInterceptor and log4j so that it logs at INFO or WARN level? All help is greatly appreciated.
In my web service configuration file I use the following bean:
<bean class="org.springframework.ws.server.endpoint.interceptor.PayloadLoggingInterceptor" />
My Log4j config:
<?xml version="1.0" encoding="UTF-8" ?>
If you take a look at the source of the PayloadLoggingInterceptor, then you can see that the logging is hardcoded to DEBUG level (see logMessagePayload method).
Link to the source code here.
However, nothing stops you from implementing your own version of this class, in which you have other log level - perhaps even a configurable one.