Skip to main content Link Menu Expand (external link) Document Search Copy Copied

Now there’s already a lot of information out there about logging. You only have to do a web search for ‘Art of Logging’ and you’ll find a whole raft of good write ups discussing why, when, how, how much, etc. If you’re new to the concept then please do read up because even the simplest of GUI applications can benefit from it.

I feel that a lot of the write ups out there cover the basics very well but miss out on some of the more advanced techniques that can turn a good log into a great log (if logs can be considered great that is).

The key to great logging is a good, mature and feature rich framework. Don’t create your own as there’s simply no need. Most languages already have logging frameworks that are fast, reliable, well-tested and provide more than enough features. Most are also extensible so if you have a need for a feature that isn’t supported you don’t have to start from scratch, you can write a plugin containing just the functionality you need and get back to the real software you were trying to write. In these pages I’ll provide examples for log4net in C# as well as other frameworks and languages.


Table of contents