如何删除 i18N RESTEASY 日志消息?

How do I remove i18N RESTEASY log messages?

我正在使用 netty 和 resteasy 来实现 REST 接口。我在我的日志文件中得到这些条目:

2016-09-14 13:29:31.116 DEBUG i18n getInvoker() - RESTEASY002315: PathInfo: /director/logmessage
2016-09-14 13:29:31.126 DEBUG i18n getInvoker() - RESTEASY002315:   PathInfo: /director/sendresult
2016-09-14 13:29:31.154 DEBUG i18n getInvoker() - RESTEASY002315: PathInfo: /director/logmessage
2016-09-14 13:29:31.161 DEBUG i18n getInvoker() - RESTEASY002315: PathInfo: /director/logmessage

i18n 包似乎在本地 java 发行版中:com.sun.imageio.plugins,我尝试如下更改 log4 jlevels:

<appender name="netty" class="org.apache.log4j.FileAppender">
    <param name="append" value="true" />
    <param name="file" value="atf_logs/atf_http.log" />
    <layout class="org.apache.log4j.PatternLayout">
        <param name="ConversionPattern" value="%d{yyyy-MM-dd HH:mm:ss.SSS} %-5p %c{1} %M() - %m%n" />
    </layout>
    <filter class="org.apache.log4j.varia.LevelRangeFilter">
        <param name="LevelMin" value="ERROR" />
        <param name="LevelMax" value="FATAL" />
    </filter>
</appender>

<logger name="com.sun.imageio.plugins" additivity="false">
    <level value="INFO" />
    <appender-ref ref="netty" />
</logger>

我也试过:

<logger name="org.jboss.resteasy.client.jaxrs.i18n" additivity="false">
    <level value="INFO" />
    <appender-ref ref="netty" />
</logger>

任何想法表示赞赏。

您可以尝试对 log4j 进行以下调整:

<logger name="org.jboss.resteasy.core" level="INFO" />
<logger name="org.jboss.resteasy.specimpl" level="INFO" />
<logger name="org.jboss.resteasy.plugins.server" level="INFO" />

查看此处了解更多信息http://docs.jboss.org/resteasy/docs/2.3.0.GA/userguide/html/Installation_Configuration.html#RESTEasyLogging