Sql-server – Resource Waits: Mathematical link between Wait Time and Average Waiter Count

activity-monitorsql serversql-server-2008

Just curious, per BOL

Wait Time (ms/sec) is the wait time in milliseconds for all tasks waiting for one or more resources in the category since last update.

Average Waiter Count is the number of tasks waiting.

Is it a coincidence that on my server Average Waiter Count is always Wait Time / 1000 rounded to nearest 10th? Is there a link here that makes it so? Am I going to be embarrassed when the answer is extremely logical but for some reason escaping me at the moment?

i.e here are sample values from the last 15 minutes for latch but other wait categories are the same (when any values exist) – I've noticed it for quite some time (much longer than last 15 mins) it just never piqued my interest enough to investigate until now.

Wait Time         Average Waiter Count
______________________________________
576               0.6
1403              1.4
1856              1.9
1233              1.2
1365              1.4

It just seems to me that since wait time is a cumulative count and waiters is an average the numbers shouldn't follow a ratio of each other as tightly as they appear.

Best Answer

I think a task is considered waiting if it is waiting for a whole second -- 1000ms. So if wait time for 1 second is 2000ms that means that 2 tasks where waiting in that second.