User-based logger level

2012-06-11 Thread yong . li
Dear all, We're about to implement a logging strategy that for different users different effective logger level are used. In particular, we are doing EJB, and we have already pushed user info onto MDC to implement this strategy. By default, the system will run using the following example

Re: User-based logger level

2012-06-11 Thread Jacob Kjome
It's possible that Log4j2 supports this out of the box, but for Log4j1, the obvious way is to call logger.log() methods that accept an explicit Level/Priority [1].  Set a ThreadLocal with the Level to use and pass that Level to log() method. [1]

Re: User-based logger level

2012-06-11 Thread ceki
Yours is a text-book requirement: http://logback.qos.ch/reasonsToSwitch.html#filters See the docs on MDCFilter at [1]. [1] http://logback.qos.ch/manual/filters.html#TurboFilter -- Ceki http://twitter.com/#!/ceki On 11.06.2012 11:55, yong...@agfa.com wrote: Dear all, We're about to

Re: User-based logger level

2012-06-11 Thread Christian Grobmeier
In log4j 2.x there are tons of filters which might help here: http://loggingtest.apache.org/log4j/2.x/manual/filters.html (temporary domain) Cheers Christian On Mon, Jun 11, 2012 at 5:28 PM, Jacob Kjome h...@visi.com wrote: It's possible that Log4j2 supports this out of the box, but for

Re: User-based logger level

2012-06-11 Thread Ralph Goers
wrote on 06/11/2012 11:59:32 PM: From: ceki c...@qos.ch To: Log4J Users List log4j-user@logging.apache.org Date: 06/12/2012 12:00 AM Subject: Re: User-based logger level Yours is a text-book requirement: http://logback.qos.ch/reasonsToSwitch.html#filters See the docs on MDCFilter