Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Which log utility is good for .NET application in C# (ASP.NET, WinForms)? [closed]

I am trying to evaluate some of the best log utilities available for .NET framework, such as Microsoft Enterprise Library, Log4Net, elmah.

Can someone who has already gone through this exercise would come to my help in listing pros and cons of the best available in the market.

Thanks & Regards, Rajeev Ranjan Lall

like image 240
Rajeev Ranjan Lal Avatar asked Jan 21 '10 07:01

Rajeev Ranjan Lal


2 Answers

In general good one is Log4net.

PROS: Log4Net supports many output sources.
CONS: Sometimes can slow your application.

For ASP.NET application is of the best ELMAH.

PROS: You do not have to change an application code a bit to use Elmah. You have to just include in you application.
CONS: Not that I know.

like image 155
Peter Stegnar Avatar answered Oct 13 '22 00:10

Peter Stegnar


I have also heard good things about NLog although I haven't tested yet. They say the API is similar to the one provided by log4net.

Also, looking through SO you have a lot of questions related with this issue:

https://stackoverflow.com/questions/98080/what-is-the-best-logging-solution-for-a-c-net-3-5-project

.NET logging framework

Error logging in C#

Hope this helps.

like image 32
yeyeyerman Avatar answered Oct 13 '22 00:10

yeyeyerman