Thanks for the info. Think I have it.
For General -- 2) Question I was referencing the information in the documentation directory.
Here: /log4net-1.2.0-beta8/doc/manual/introduction.html#loggers-and-appenders.logger
Cheers, Dave
From: "Denis, Rich" <[EMAIL PROTECTED]> Reply-To: "Log4NET User" <[email protected]> To: Log4NET User <[email protected]> Subject: RE: Configuration Questions Date: Mon, 24 May 2004 13:33:47 -0500
Let me see if I can tackle this...
General
============================
1) What is the difference between using <appender> and <logger>?
Appenders are the conceptual name for outputs. There are multiple appenders
like "RollingLogFile" etc. These are all configured and then referenced as
an 'output' for the logger. Loggers on the other hand are what actually do
the logging.
2) Is there an example somewhere for Level Inheritance? Not sure what you mean here.
<Root> ============================ 1) How does <appender> and <logger> relate to the <root>? Root is the default logger. If you were not to configure an individual appender for each logger, you could just create one appender and associate it with the root logger. Appenders can be associated with either an individual logger or the root logger. Anything that is not specifically sent to a logger will be sent to the root logger.
2) What is the default level for <root> if one is not specified? I believe that default is "Debug" but I may very well be wrong here....just specify one ;)
3) <appender-ref> is implemented to reference by name. What does this buy me? Not sure what you mean by "buy you". Appender ref is how you wire up a logger to output to a particular appender.
<logger>
============================
1) Is the <name = "LoggerName"> the same as
log4net.LogManager.GetLogger("LoggerName") ?
Yes the name that is in the "LoggerName" attrib value is the value of the
logger if you got the logger name when you created it. In a config file
this is simple log4nets way of knowing what to do in regards to logging when
it encounters your logger.
2) How do you log to different places within the application?
What do you mean log to different places? Do you mean log to multiple
outputs? If so you would configure multiple appenders and associate them to
the logger using the appender-ref tag.
Hope this helps.
Rich
-----Original Message----- From: David Elliott [mailto:[EMAIL PROTECTED] Sent: Monday, May 24, 2004 11:23 AM To: [email protected] Subject: Configuration Questions
I am just starting out using Log4Net. I have looked through the .chm file and the introduction.html files and still have some questions on the items contained within the configuration file and in general.
General ============================ 1) What is the difference between using <appender> and <logger>? 2) Is there an example somewhere for Level Inheritance?
<Root> ============================ 1) How does <appender> and <logger> relate to the <root>? 2) What is the default level for <root> if one is not specified? 3) <appender-ref> is implemented to reference by name. What does this buy me?
<logger> ============================ 1) Is the <name = "LoggerName"> the same as log4net.LogManager.GetLogger("LoggerName") ? 2) How do you log to different places within the application?
Any help is appreciated.
Thanks, Dave
_________________________________________________________________ Stop worrying about overloading your inbox - get MSN Hotmail Extra Storage! http://join.msn.click-url.com/go/onm00200362ave/direct/01/
_________________________________________________________________
Watch LIVE baseball games on your computer with MLB.TV, included with MSN Premium! http://join.msn.click-url.com/go/onm00200439ave/direct/01/
