Collect .NET Statistic/Avg. Request Time (ms)

Microsoft.SystemCenter.Apm.Transaction.CollectAvgDurationTime (Rule)

Collects .NET Statistic/Avg. Request Time performance counter (ms)

Knowledge Base article:

Summary

This rule collects .NET Statistic Avg execution time performance counter for transactions.

The counter records the average time (in milliseconds) that it takes for a request to be processed by a transaction. The timing of each request begins when a request reaches the application, and is stopped when the request completes successfully or fails somewhere in the code. The sum of these times is averaged across the total number of monitored requests. If this time consistently exceeds 10000 ms, it indicates a bottleneck that should be investigated.

This counter is only available when application performance monitoring is enabled.

Excessively long database calls might be due to either a problem with the server or with the structure and complexity of the query. Long file I/O times might be due to problems with the file server. Web Services performance issues might occur because the Web Service or the server it resides on is down or there is a problem in the Web Service code. Long internal execution times for applications might result from complex or inefficient code.

Element properties:

TargetMicrosoft.SystemCenter.Apm.Transaction
CategoryPerformanceCollection
EnabledTrue
Instance Name.NET Statistic
Counter NameAvg execution time
Frequency300
Alert GenerateFalse
RemotableFalse

Member Modules:

ID Module Type TypeId RunAs 
DS DataSource System.Performance.DataProvider Default
WriteToDB WriteAction Microsoft.SystemCenter.CollectPerformanceData Default
WriteToDW WriteAction Microsoft.SystemCenter.DataWarehouse.PublishPerformanceData Default

Source Code:

<Rule ID="Microsoft.SystemCenter.Apm.Transaction.CollectAvgDurationTime" Enabled="true" Target="Microsoft.SystemCenter.Apm.Transaction" ConfirmDelivery="false" Remotable="false" Priority="Normal" DiscardLevel="100">
<Category>PerformanceCollection</Category>
<DataSources>
<DataSource ID="DS" TypeID="Performance!System.Performance.DataProvider">
<ComputerName>$Target/Host/Host/Host/Property[Type="Windows!Microsoft.Windows.Computer"]/NetworkName$</ComputerName>
<CounterName>Avg execution time</CounterName>
<ObjectName>.NET Statistic</ObjectName>
<InstanceName>$Target/Property[Type="Microsoft.SystemCenter.Apm.Transaction"]/CounterInstance$</InstanceName>
<AllInstances>false</AllInstances>
<Frequency>300</Frequency>
</DataSource>
</DataSources>
<WriteActions>
<WriteAction ID="WriteToDB" TypeID="SC!Microsoft.SystemCenter.CollectPerformanceData"/>
<WriteAction ID="WriteToDW" TypeID="SCDW!Microsoft.SystemCenter.DataWarehouse.PublishPerformanceData"/>
</WriteActions>
</Rule>