Perf counter alert shows sample count instead of sampled value
I made a unit monitor to alert when the Hyper-V Hypervisor Logical Processor \ % Total Run Time counter exceeded a certain threshold. I used the System.Performance.ConsecutiveSamplesThreshold unit monitor type and noticed that when it alerted the alert parameter for $Data[Default='']/Context/Value$ was showing the number of samples instead of the threshold value that was sampled. Oddly, the $Data[Default='']/Context/Value$ value in System.Performance.ThresholdMonitorType works correctly. Alert description example: Hyper-V server %hostname% is using too much CPU. Counter: Hyper-V Hypervisor Logical Processor \ % Total Run Time Value: 2 << this is the sample number, not the sampled value. To fix this use $Data[Default='']/Context/ SampleValue $ instead. Refer to this article for more: http://www.systemcentercentral.com/system-performance-consecutivesamplesthreshold-monitor-gives-a-wrong-alert-description/