Using log4net

Image courtesy of KROMKRATHOG / FreeDigitalPhotos.netWe are using log4net in our project. It works great. Here are some links and tips to get you started.

In this tutorial on codeproject you can read all the details and even see a video about it. Very good starting point for getting to know log4net.

We plan to use MEF for IoC. In Little Trick to generate ILogger with MEF based on type you can read how to get it to work. It involves a wrapper around the log4net.ILog interface and an implementation that creates the log4net logger and redirects the calls to log4net.

As last a reference to the Log4net Layout Patternlayout documentation. With the PatternLayout you can configure the information in the output.

* Image courtesy of KROMKRATHOG / FreeDigitalPhotos.net

About erictummers

My work as a recruited developer changes almost every month. I like challenges and sharing the solutions with others. On my blog I’ll mostly post about my work, but expect an occasional home project, productivity tip and tooling review.
This entry was posted in Development and tagged . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s