Scenario
Say you find that the CPU utilization on your computer or server keeps spiking, but it does so at random times. If you are looking in task manager, you might be able to identify which process is responsible for the spikes. Now say you want to be notified when these spikes occur. You can actually use a built in Microsoft product to send alerts and or log events like this.Microsoft Performance Monitor.
Using Microsoft's Performance Monitor, you can select counters such as "%Processor Time" or "Handle Count" and then trigger alerts based on these counters. Microsoft has a lot of counters that you can use so that you can monitor computer or server with a high degree of granularity. Here is an example of the Processor Object containing counters for CPU usage: http://msdn.microsoft.com/en-us/library/ms804036.aspx. You can also monitor memory, disk usage, network usage, etc.You can set up a data collector set that will allow you to be notified, for example, when a process reaches 60% User Time. When you do this, you will receive an alert every time this threshold is met.
Unfortunately, while you can setup these alerts to be tripped when a counter reaches a threshold, you can't set it up to alert you when, say the %Processor reaches X amount for Y duration.