logging-log4net-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Walden H. Leverich" <Wald...@TechSoftInc.com>
Subject RE: Newbie: Does Log4Net have the concept of "Topics" and, if so, can I route messages based on topic rather than "Class" hierarchy?
Date Wed, 24 Oct 2007 17:50:48 GMT
Steve,

If I understand correctly, just have multiple loggers. Perhaps the
"per-class" logger for general diagnostics an trace, and then a more
global "audit" logger you use to write your audit information. You could
use different storage for the two or use the same storage. If you're
using the same storage there is nothing special needed. If you want
different storage you'd simply add an appender to the config file entry
for the "audit" logger specifically.

-Walden

-- 
Walden H Leverich III
Tech Software
(516) 627-3800 x3051
WaldenL@TechSoftInc.com
http://www.TechSoftInc.com

Quiquid latine dictum sit altum viditur.
(Whatever is said in Latin seems profound.)


-----Original Message-----
From: shaeney [mailto:stevehaeney@yahoo.co.uk] 
Sent: Wednesday, October 24, 2007 6:40 AM
To: log4net-user@logging.apache.org
Subject: Newbie: Does Log4Net have the concept of "Topics" and, if so,
can I route messages based on topic rather than "Class" hierarchy?


The title says it all really, I would like to be able to route my
messages
based on a topic rather than the class that posts the message. For
example,
I have an audit requirement and a log requirement for the same class.

When I start/stop a given job, I want to audit that, but I also want to
record job progress within the class via logging. I see my audit and
logging
sinks as being different and backed by different storage. How can I
model
this in Log4Net?

Also, is it possible to include meta data with the log message? I could
do
with appending an XML payload to be digested by the sink, if that's
possible.


Cheers,
Steve
-- 
View this message in context:
http://www.nabble.com/Newbie%3A-Does-Log4Net-have-the-concept-of-%22Topi
cs%22-and%2C-if-so%2C-can-I-route-messages-based-on-topic-rather-than-%2
2Class%22-hierarchy--tf4683548.html#a13383219
Sent from the Log4net - Users mailing list archive at Nabble.com.


Mime
View raw message