[slf4j-user] Log4j.properties?

Adam Parkin pzelnip at gmail.com
Tue Mar 1 21:35:07 CET 2011


I'm finding the documentation on how to specify a log4j.properties file
a bit weak.

As it stands I have a standalone Java application which is using SLF4J
overtop the Log4j library (I have log4j-over-slf4j-1.6.1.jar,
slf4j-api-1.6.1.jar, slf4j-simple-1.6.1.jar files on the classpath).

I want to be able to modify it so that DEBUG messages appear on the
console, normally this is done by creating a log4j.properties file if
using log4j.  I've done this, but it would appear the file is not being
read as I still only see info & higher messages.

How do I instruct SLF4J to read a log4j.properties file (or for that
matter, how do I specify a log level in SLF4J)?  Where does the file go?
How do I instruct the libraries to read that file? etc.

Thanks.



More information about the slf4j-user mailing list