Generate Alert for Performance CSM Event

Microsoft.SystemCenter.Apm.CsmApplicationInstance.AlertPerformanceAspectRule (Rule)

Knowledge Base article:

Summary

The object state is changed to unhealthy when the total number of client-side performance events in the specified interval exceeds the monitor threshold.

Causes

Client-side performance alerts are generated when the page load time or AJAX response for the web application exceeds the configured threshold. The total timing is measured at the web browser, is correlated to server processing time, and then is separated into the following categories that are displayed in the event details:

When the page load time exceeds the threshold:

When the response time for AJAX calls exceed the threshold:

Significant amount of time spent in one or a few categories might point to the root cause of the performance problem. For example, the time spent processing network requests and responses might suggest slow network connectivity. Long server response time might be caused by slowly-running server code, and can be further troubleshoot by investigating associated server-side performance alerts. Slow DOM loading might be linked to excessive complexity or size of the application page, or might also point to slow performance of the client browser. Long run times for the Window.OnLoad() event or slow AJAX JavaScript indicate inefficient code on the page or might be due to slow performance of client browser. A large number of page redirects might result from complex or inefficient application code.

Resolutions

Client-side performance alerts are generated when the run time exceeds the configured threshold. Typical application performance degradation causes might be slow performance of the web server, a slow network, or inefficient application code.

You can access additional details about this alert by using the link to the event details available in the Alert Description and on the Alert Context tab. The link will open the event in the Application Diagnostics console. The Application Diagnostics console contains information specific to this event as well as to related and similar events that have been detected.

Element properties:

TargetMicrosoft.SystemCenter.Apm.CsmApplicationInstance
CategoryAlert
EnabledFalse
Alert GenerateTrue
Alert SeverityWarning
Alert PriorityNormal
RemotableFalse
Alert Message
Client Performance Exception
{0}. The configured threshold {1} ms for {2} on {3} has been exceeded. For additional details please use the following link: $Url[Query='{4}']/APMEvent$

Member Modules:

ID Module Type TypeId RunAs 
LOBProvider DataSource Microsoft.SystemCenter.Apm.Csm.LobDataProvider Default
AlertWriteAction WriteAction System.Health.GenerateAlert Default

Source Code:

<Rule ID="Microsoft.SystemCenter.Apm.CsmApplicationInstance.AlertPerformanceAspectRule" Enabled="false" ConfirmDelivery="false" Target="Microsoft.SystemCenter.Apm.CsmApplicationInstance" Remotable="false">
<Category>Alert</Category>
<DataSources>
<DataSource ID="LOBProvider" TypeID="Microsoft.SystemCenter.Apm.Csm.LobDataProvider">
<Name>$Target/Property[Type="AL!Microsoft.SystemCenter.Apm.ApplicationInstanceBase"]/ApplicationName$ (Client)</Name>
<AspectType>performance</AspectType>
</DataSource>
</DataSources>
<WriteActions>
<WriteAction ID="AlertWriteAction" TypeID="Health!System.Health.GenerateAlert">
<Priority>1</Priority>
<Severity>1</Severity>
<AlertMessageId>$MPElement[Name='Microsoft.SystemCenter.Apm.CsmApplicationInstance.AlertPerformanceAspectRule.AlertMessage']$</AlertMessageId>
<AlertParameters>
<AlertParameter1>$Data/EventData/log/properties/property[name="scomProblemDescription"]/value$</AlertParameter1>
<AlertParameter2>$Data/EventData/log/alertingThreshold$</AlertParameter2>
<AlertParameter3>$Target/Property[Type="AL!Microsoft.SystemCenter.Apm.ApplicationInstanceBase"]/ApplicationName$</AlertParameter3>
<AlertParameter4>$Target/Host/Host/Property[Type="Windows!Microsoft.Windows.Computer"]/NetworkName$</AlertParameter4>
<AlertParameter5>$Data/EventData/ViewDetail$</AlertParameter5>
</AlertParameters>
<Suppression>
<SuppressionValue>$Data/EventData/eventConsolidationHash$</SuppressionValue>
</Suppression>
<Custom1>Performance</Custom1>
</WriteAction>
</WriteActions>
</Rule>