Okay, I try to explain it again: I would like
to setting up the loglevels not only for a package, but for a method of
a class. I have no default way so it doesn't matter how to solve it. But
it is important that I can configure this rules easy in the logback.xml.
Of course multiple loggers would work, but I dont want to take hand on
the existing code.
How could this work with markers?
I had a look into the turbo filter, and yes
it works perfect. I have defined a class LoggingRule which contains the
classname and functionname for the Filtering. It looks like this:
But the problem I how can I configure the
TurboFilter easily? I expect a lot of different rules and don't want to
blast my configuration file. First I thought that I could do something
like include another configuration file but this only works for appenders
etc. not for enclosed elements like a filter...
Is my explanation comprehendible?
Marc
Von:
Ralph Goers <rgoers@apache.org>
An:
logback users list <logback-user@qos.ch>
Datum:
20.09.2010 19:12
Betreff:
Re: [logback-user] Logging depending
on Class / Method
Gesendet von:
logback-user-bounces@qos.ch
You really didn't provide enough information on what you
are trying to accomplish. What you are trying to do is filter what
events are logged. You could accomplish that by using Markers, multiple
loggers, or a configurable TurboFilter (the turbo filter can inspect the
method name of the caller).