Re: Filter log based on package when using getLogger(String)

2012-07-18 Thread Charles Hache
Thanks a lot for the tips guys! tl;dr - skip to the end for my final, simple solution. I'm a bit hesitant to adding expression filters to do this filtering. The root of the issue is that I want to set the package log level using the regular, standard way (so that anyone can do it/understand i

Re: Filter log based on package when using getLogger(String)

2012-07-18 Thread Scott Deboy
Correction: expression would use the LOGGER instead of MSG, since you're filtering on that. On Wed, Jul 18, 2012 at 10:54 AM, Scott Deboy wrote: > You can use filters, including the ExpressionFilter, to build pretty much > arbitrary expressions and filter appenders using that, but it requires yo

Re: Filter log based on package when using getLogger(String)

2012-07-18 Thread Scott Deboy
You can use filters, including the ExpressionFilter, to build pretty much arbitrary expressions and filter appenders using that, but it requires you to use a log4j.xml configuration file. Something like this (requires you to have the 'extras' companion in your classpath):

Re: Filter log based on package when using getLogger(String)

2012-07-18 Thread Douglas E Wegscheid
Use MDC for the string? ■ DOUGLAS E. WEGSCHEID // LEAD ENGINEER (269) 923-5278 // douglas_e_wegsch...@whirlpool.com "A wrong note played hesitatingly is a wrong note. A wrong note played with conviction is interpretation." Charles Hache 07/18/2012 01:26 PM Please respond to "Log4J Users List