[slf4j-user] Making Spring use SL4J in a web application served by a Tomcat 5.5 server (should I expect problems?)

Ceki Gulcu ceki at qos.ch
Wed Jan 21 14:13:30 CET 2009


Hello Kent,

You can place a copy of jcl-over-slf4j as well as slf4j-api plus logback-core 
and logback-classic in your web-application's WEB-INF/lib folder. I would expect 
this combination to work well. Logs generated by Spring (using commons-logging) 
should be logged by logback.

I hope this helps,

Kent Larsson wrote:
> Hi, I'm pretty new to logging, in fact I've only used logging before 
> with log4j and never set it up myself. However there is a time to learn 
> everything and I've looked around and think that SL4J with Logback as 
> its back end will be a nice solution for us.
> 
> I have two important questions:
> 
> We use Tomcat 5.5.x and it comes bundled with JCL and there might be 
> problems overriding that bundled JCL version, will it also stop SL4J 
> from pretending to be JCL? (Reference: 
> http://commons.apache.org/logging/troubleshooting.html#Apache%20Tomcat )
> 
> How can I check that Spring 2.5 is actually using SL4J? That is, how can 
> I verify that logging is working as it should?
> 
> As Tomcat is quite popular, as is Spring, I hope there are some answers 
> out there.
> 
> Thank you for reading! Have a nice day!
> 
> / Kent

-- 
Ceki Gülcü
Logback: The reliable, generic, fast and flexible logging framework for Java.
http://logback.qos.ch



More information about the slf4j-user mailing list