How can I disable logging in Restlet 2.0?

前端 未结 6 750
梦如初夏
梦如初夏 2021-01-21 16:20

I simply want to disable Restlet\'s logging to stdout/stderr in my project and forward all Restlet logging through the SLF4J facade provided by org.restlet.ext.slf4j. Is there a

6条回答
  •  滥情空心
    2021-01-21 16:58

    Something seems wrong here: If you have the org.restlet.ext.slf4j.jar, slf4j-api.jar, logback-core.jar, and logback-classic.jar linked in, you already have all you need to disable logging to sdout and stderr. Just modify the config file (logback.xml) so as not to append to them.

    With this configuration, restlet is using slf4j "natively" and the usual slf4j configuration applies.

    Also, the org.restlet.ext.slf4j.jar eliminates the need for the jul-to-slf4j.jar, which would incur a serious performance hit anyway.

提交回复
热议问题