AW: [SPAM (Bayesain Analysis)] - Using log4j.properties to handle other properties - Bayesian Filter detected spam

2009-03-09 Thread Bender Heri
I assume you mean following (pseudo code) If SystempropertyCollectStatistics==True myLog.info( ... ) The correct way would be to use a special named logger and declare it in the propeties file with the desired log level. Possible code in class with statstic logging needs: Logger myNormalD

Using log4j.properties to handle other properties

2009-03-09 Thread Christophe Elek
My developers are using System Properties to enable certain trace options (like collecting statistics) Is there a way I could define such property in the log4j.properties instead so we keep trace/log options and metadata together ? So my developers will do .getProperty('my property') instead of S

AW: How to filter the unnecessary log messages

2009-03-09 Thread Bender Heri
Either you strongly restrict the level of your root logger (e.g. ERROR) and declare a logger for your own classes with DEBUG level: (appender-refs) (appender-refs) Or you go the other way round, you restrict the library loggers stro

Re: How to filter the unnecessary log messages

2009-03-09 Thread Kannan Ekanath
[Not pasting the big log file] You need to use a log4j.xml in the classpath. The format/how to of the log4j.xml is explained in this link http://logging.apache.org/log4j/1.2/manual.html Many examples are provided here http://wiki.apache.org/logging-log4j/Log4jXmlFormat. To cut the short story eve