I typically declare the following in every class:
private static readonly log4net.ILog log = log4net.LogManager.GetLogger(
System.Reflection.MethodBase.GetCurrentMethod().DeclaringType);
and use the static member within each class to log at different levels (info, debug, etc.)
I saw that somewhere and have been using it somewhat mindlessly, reasoning that the setup is flexible enough to help me filter by namespace and log individual types if I wanted to in troubleshooting production issues and what not.
But I've rarely had to use that "level" of fine logging. So, I would like to see what others are using. Do you use the above, as I have a feeling many are using just that, or do you create named loggers such as "debug", "trace", "error", "moduleA", etc. and share the logger among different types, assemblies?