Since you defined additivity=false on your com.schinvest Logger, the log 
messages don't reach the root logger.

Your goal can be achieved by xml configuration where you can declare filters on 
appenders. So you only declare a root logger with debug level and a net.sf 
logger with warn level. On the htmlLogFile and console appenders you declare a 
level range filter.

Heri

> -----Original Message-----
> From: David [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, September 13, 2006 6:05 PM
> To: log4j-user@logging.apache.org
> Subject: [SPAM (Bayesain Analysis)] - How configure the categories for
> console, logFile and htmlFile showing different levels - 
> Bayesian Filter
> detected spam
> 
> 
> Dear members,
>    
>   I would like to separate the information from log4j ouptut 
> into the following appenders (files)
>    
>   htmlLogFile, console: myapp for INFO level, net.sf for WARN level
>   logFile:              myapp for DEBUG level, net.sf for WARN
>                            level
>    
>   so I want a defailed information on DEBUG about my 
> application, and for other appenders just INFO level for my 
> app and for external libraries WARN level. It is usefull for 
> me because the html file is for customer and console, logFile 
> is for developers.
>    
>   I am using categories, but I can't find the appropiate 
> combination for that. I expect the following configuration 
> should work:
>    
>   log4j.rootCategory=DEBUG, logFile, htmlLogFile, console
>   # com.schinvest is my application
>   log4j.additivity.com.schinvest=false 
>   
>    
>   log4j.category.com.schinvest = INFO, htmlLogFile, console
>   log4j.category.net.sf =WARN, logFile, htmlLogFile, console
>   log4j.additivity.net.sf =false
>    
>   I get the expected result for console and htmlLogFile, but 
> I don't see the INFO level for my app on logFile I see only 
> the WARN level for external libraries.
>    
>   so why I don't see the debug level on my logFile, it is 
> defined on the root category for all appenders, it seems that 
> the line: 
>    
>   log4j.category.com.schinvest = INFO, htmlLogFile, console
>    
>   overrides the behaviour for logFile
>    
>   Thanks in advance,
>    
>   David
> 
>               
> ---------------------------------
> Get your email and more, right on the  new Yahoo.com 
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to