ASP.NET健康监测或ELMAH选择什么? [英] ASP.NET Health Monitoring or ELMAH what to choose?

查看:103
本文介绍了ASP.NET健康监测或ELMAH选择什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

4净额在C#中使用SQL Server 2008 R2。

我要选择我的Web应用程序的错误记录解决方案。

我读了一些文章 ELMAH 和<一个href=\"http://www.asp.net/hosting/tutorials/logging-error-details-with-asp-net-health-monitoring-cs\">ASP.NET在话题健康监测但我想听听你的意见和想法上系统,您prefers在现实世界的应用程序,以及为什么。

一些点在我感兴趣的是:

   - 设置和配置
- 错误报告
- 性能


解决方案

ASP.NET健康监测是不是一个记录解决方案。据 ASP.NET运行状况监视概述

ASP.NET运行状况监视,您可以执行以下任务:


  • 监视应用程序的性能,以确保它是健康的。

  • 快速诊断认为是失败的应用程序或系统。

  • 在应用程序的生命周期中评价显著的事件。

  • 监控现场ASP.NET应用程序,单独或在Web场中。

  • 请不一定涉及到的错误在ASP.NET应用程序的事件。

所需配置的高低取决于你所需要完成的任务。对于我的几个应用程序,我们需要的是:

 &LT; healthMonitoring启用=真正的&GT;
  &LT;规则与GT;
    &LT;添加名称=应用程序生命周期事件在eventName的=应用程序生命周期事件
         供应商=EventLogProvider配置文件=默认/&GT;
  &LT; /规则&GT;
&LT; / healthMonitoring&GT;

这使得健康监测,并增加了应用程序生命周期事件,在默认情况下收集的事件。通过这种方式,我们知道当一个应用程序的启动和停止,以及为什么。

请注意,我们没有触及任何code得到此功能。

net 4 in C# with SQL Server 2008 R2.

I need to choose an error logging solution for my Web Application.

I read some article ELMAH and ASP.NET Health Monitoring on the topic but I would like have your opinion and thoughts on which system you prefers in your a real world application and why.

Some point in which I'm interested:

- setup and configuration
- error reports
- performance

解决方案

ASP.NET Health Monitoring is not a logging solution. According to ASP.NET Health Monitoring overview:

ASP.NET health monitoring enables you to do the following tasks:

  • Monitor the performance of an application to make sure that it is healthy.
  • Rapidly diagnose applications or systems that are failing.
  • Appraise significant events during the life cycle of an application.
  • Monitor live ASP.NET applications, individually or across a Web farm.
  • Log events that do not necessarily relate to errors in an ASP.NET application.

The level of required configuration depends on what you need to accomplish. For several of my applications, all we need is:

<healthMonitoring enabled="true">
  <rules>
    <add name="Application Lifetime Events On" eventName="Application Lifetime Events" 
         provider="EventLogProvider" profile="Default"/>
  </rules>
</healthMonitoring>

This enables health monitoring and adds application lifetime events to those events collected by default. This way, we know when an application starts and stops, and why.

Note that we didn't have to touch any code to get this functionality.

这篇关于ASP.NET健康监测或ELMAH选择什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆