A real hot-swappable open Source Logging component

Source: Internet
Author: User

Two days ago found an open source log component Elmah, I like it all of a sudden, like him because it supports "hot plug" (no need to change any program), a simple configuration (several lines of configuration), a variety of logging methods (database, file, Email), supporting multiple databases (Access, SQL Server, Oracle, Sqlite, vistadb), and view results do not need to be written (and support RSS publishing view).

Elmah the latest version is ELMAH-1.0-BETA3, he is based on httpmodules, httphandlers processing, but only log the error log does not deal with, but this is enough, we are likely to occur in the unusual place will be handled, For unexpected exceptions to the elmah on it, we just give users a friendly error page can be.

His usage is very simple, simple to believe, the following details of his usage.

The newest component of download component Click here to download elmah-1.0-beta3, add the bin file add Elmah.dll to the project (he supports net-1.0, 1.1, 2.0, 3.5).

Second, the DB folder under the SQL script execution, we choose Sqlserver.sql here, in your database will generate a elmah_error table.

Third, configure Webconfig to add in <configuration>:

<configSections>
<sectiongroup name= "Elmah" >
<!--tips! asp.net1.x requirepermission= "false" to remove-->
<section name= "Security" requirepermission= "false" type= " Elmah.securitysectionhandler, Elmah "/> <section name=" ErrorLog "requirepermission="
false "type=" Elmah.errorlogsectionhandler, Elmah "/> <section name=" Errormail "requirepermission="
false "Type=" Elmah.E Rrormailsectionhandler, Elmah "/> <section name=" Errorfilter "requirepermission="
false "Type=" Elmah.Error Filtersectionhandler, Elmah "/>
</sectionGroup>
</configSections>
<elmah >
<security allowremoteaccess= "0"/><!--whether remote access is allowed. 0 represents no, 1 representatives are-->
<errorlog type= "Elmah.xmlfileerrorlog, Elmah" logpath= "E:\LogHaHa\"/><!--recorded to file- >
</elmah>    

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.