Logging "Information" and/or Commenting?
I have written a Logger which writes into a local Text file. The Logger stores Information based开发者_运维技巧 on an indicator value in the App.Config and begins writing to files if the Value is higher than the indicator value. If the Indicator is 2, LogLevels 2,3,4 are Logged. Possible Flags are "Information", "Warning", "Exception", "Systemerror".
Now i have added pretty detailed Logging in the "Information" Level but forget to add comments. And when adding Comments i realized that all the "Information" Level Logging Info could aswell go as a comment.
The Question is: Is that okay? Can i just leave out Comments now? What would you do? What exactly is an "Information" in a log?
If you take a look into the log4net documentation you can find that they use these kinds of log levels:
- ALL
- DEBUG
- INFO
- WARN
- ERROR
- FATAL
- OFF
And comparing this to your levels i think your Comments level is something like Debug and i think there is a difference between these two levels.
精彩评论