[logback-user] Changing a logger's level for only one appender?

Gerweck Andy - agerwe Andy.Gerweck at acxiom.com
Thu May 17 01:03:57 CEST 2007

Thanks, but this isn't quite enough: I want to set the level for a specific logger on a specific appender. E.g., set level to WARN for com.example in appender FILE.

Thanks again,

-----Original Message-----
From: logback-user-bounces at qos.ch [mailto:logback-user-bounces at qos.ch] On Behalf Of dirk ooms
Sent: Wednesday, May 16, 2007 3:33 PM
To: logback users list
Subject: Re: [logback-user] Changing a logger's level for only one appender?

To create a threshold filter inside an appender:

   <filter class="ch.qos.logback.classic.filter.ThresholdFilter">

hope this helps,

On Thursday 17 May 2007 00:20, Gerweck Andy - agerwe wrote:
> Hello,
> I have a couple of applications that create two log files: one with all
> debug statements for troubleshooting and another with just INFO and
> above for general information. The debug logs are erased after a day or
> two while the general log is kept for a month or longer.
> I apologize if I just missed this in the documentation, but is there an
> easy way to set the minimum level for a specific logger hierarchy on
> just a single appender. For example, I want com.example.* to write only
> WARN and above to my general log, but I still want its DEBUG statements
> in the debug log. I'm sure I could write my own filter or use an
> EvaluatorFilter, but this seems like such a common requirement that
> there would be a standard mechanism.
> Thanks,
>   Andy
> ***************************************************************************
> The information contained in this communication is confidential, is
> intended only for the use of the recipient named above, and may be legally
> privileged.
> If the reader of this message is not the intended recipient, you are
> hereby notified that any dissemination, distribution or copying of this
> communication is strictly prohibited.
> If you have received this communication in error, please resend this
> communication to the sender and delete the original message or any copy
> of it from your computer system.
> Thank You.
> ***************************************************************************
Logback-user mailing list
Logback-user at qos.ch

More information about the Logback-user mailing list