Multiple bindings for slf4j -- should I care?
Tom Zeller
tzeller at dragonacea.biz
Mon Mar 7 14:31:53 EST 2016
> It's all in my $JETTY_BASE/logs/2016_03_07_stderrout.log (or whatever date I run it). I see the following:
>
> SLF4J: Class path contains multiple SLF4J bindings.
> SLF4J: Found binding in [jar:file:/services/shib-idp/opt/shibboleth-identityprovider-3.2.1/jetty-base/tmp/jetty-localhost-8080-webapp-_idp-any-3975758343077119235.dir/webinf/WEB-INF/lib/logback-classic-1.1.3.jar!/org/slf4j/impl/StaticLoggerBinder.class]
> SLF4J: Found binding in [jar:file:/services/shib-idp/opt/shibboleth-identityprovider-3.2.1/jetty-base/lib/logging/logback-classic-1.1.3.jar!/org/slf4j/impl/StaticLoggerBinder.class]
> SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
I don’t know how to tell SLF4J to not complain about multiple bindings when using Logback for both a web app and the container, which seems like a common situation.
> 11:25:35,963 |-WARN in ch.qos.logback.classic.LoggerContext[default] - Resource [logback.xml] occurs multiple times on the classpath.
> 11:25:35,963 |-WARN in ch.qos.logback.classic.LoggerContext[default] - Resource [logback.xml] occurs at [jar:file:/services/shib-idp/opt/shibboleth-identityprovider-3.2.1/jetty-base/tmp/jetty-localhost-8080-webapp-_idp-any-3975758343077119235.dir/webinf/WEB-INF/lib/idp-core-3.2.1.jar!/logback.xml]
> 11:25:35,963 |-WARN in ch.qos.logback.classic.LoggerContext[default] - Resource [logback.xml] occurs at [file:/services/shib-idp/opt/shibboleth-identityprovider-3.2.1/jetty-base/resources/logback.xml]
These warnings about multiple logback.xml files are because we provide logback.xml in the idp-core JAR, which we should probably reconsider. I don’t remember exactly why we did that.
More information about the users
mailing list