Author Posts

January 6, 2017 at 10:38 pm

I'm very new to PowerShell, but I have a good idea of what it can do and used it a little bit at my previous job. It's very powerful and I was wondering if I can use it to gather data about the workflows in use across the farm. Can I use PowerShell to do the following:

1) Find the number of workflows running
2) Find the number of instances per workflow
3) Find the number of errors per workflow
4) Find how long it takes for each workflow instance to run
5) Determine the amount of resources each workflow instance consumes

January 9, 2017 at 2:51 pm

Probably not. Workflows run under WWF, not PowerShell, and WWF isn't well instrumented for this. Keep in mind that a Workflow written in PowerShell is translated into the XAML used by WWF and then handed off; "monitoring" WWF isn't really within PowerShell's scope.

WWF has some tracking and tracing functionality; I Googled "monitoring wwf .net" and you might see if any of those are helpful.