Menu

Logging categories at a certain level

Help
2008-11-04
2013-06-04
  • Johannes Kilian

    Johannes Kilian - 2008-11-04

    Hi,

    I need some help configuring log4perl.

    Situation: All my classes do logging to certain categories within a clear hierarchy (for example: category  <a.b.c.Class1.Method1>)

    I've configured an logger like this:
    <log4perl.logger.a.b.c=DEBUG, FileAppender>

    What I now want to achieve is (via configuration), is that category <a.b.c.Class1.Method1> is logged only at WARN-Level to the same appender ...
    Something like this:
    <log4perl.logger.a.b.c.Class1.Method1=WARN, FileAppender>

    What happens is, that DEBUG-msg of category <a.b.c.Class1.Method1> are also logged in Fileappender (due to configuration <log4perl.logger.a.b.c=DEBUG, FileAppender>) ...

    Is this possible? Any other way to do this?
    Any help welcome....

    Johannes

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.