[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
[jetty-users] SLF4J for server & webapp logging
|
Hi,
I'd like to use SLF4J for both server logging and individual webapp logging. I'd like to use a different SLF4J binding for the server and the webapp.
I can do this by adding slf4j-api and a binding to the server's classpath and slf4j-api and a different binding to the WEB-INF/lib directory. However, I then get SLF4J warning me about multiple bindings on the classpath. Looking at WebAppClassLoader it knows how to exclude known server classes from the classpath of a webapp, and classes under org.slf4j used to be included amongst those, but were removed in a commit to WebAppContext on 06/08/09.
Is there a preferred way to mark the slf4j classes as server classes again when starting jetty via start.jar? It looks as if I can add an attribute called org.eclipse.jetty.webapp.serverClasses to a Server, but I can't find an example of the best practice for doing this (and it looks like it will over-write all the existing rules, so they would have to be duplicated when setting it).
Thanks,
Rob