locked
Visually tracing the execution path in WF RRS feed

  • Question

  • I have an application requirement where I need to show the execution path of an already executed workflow.  If an activity was flagged with an error, possibly through a custom tracking property, that activity needs to be highlighted in red color.   Because a workflow could have taken different paths during its execution, it would be nice to show which path in the decision tree was taken.    Is there a way to accomplish this?   Any insights would greatly be appreciated. 

     

    Monday, February 6, 2012 4:27 PM

Answers

  • Hi Jaime,
    I have not seen a ready-made published sample that does exactly what you are asking, but when you drill into the details of how the Visual Workflow tracking sample above works, it should not be hard to adapt. The way it determines the 'currently' executing activity is by looking at at tracking record, so you can look at any number of tracking records for the workflow instance to determine the execution history. Also the way it highlights the currently executing activity is by applying adornments to an activity designer, and you can just apply similar adornments (with stylistic differences) to all the other activities you have tracking records for that executed in the past.

    Tim



    Tuesday, February 7, 2012 4:44 PM

All replies

  • Hi Jaime,
    Workflow Tracking should enable this scenario with no problem, as you can use it to trace a record for each activity which is executed.

    http://msdn.microsoft.com/en-us/library/ee513992.aspx

    There is also an article/sample explaining how you can also leverage the workflow designer to visualize workflow execution based on tracking records.

    http://msdn.microsoft.com/en-us/library/ee624139.aspx

    I believe the article itself was probably based upon some blog posts by Workflow PM Kushal such as this one

    http://blogs.msdn.com/b/kushals/archive/2009/12/29/visualworkflowtrackingwithstepservice.aspx

    Tim

    Tuesday, February 7, 2012 1:38 AM
  • Thank you Tim for the response.  In all the documentation I have seen so far, it is possible to visualize the activity being executed currently.  In addition to hosting and debugging workflows, I would like to take existing tracking details and visualize all activities already executed, the whole path of execution within the workflow's look and feel.   This would be accomplished by taking an existing workflow and its tracking detail records from a previous run.   The application would then show a thicker line along the activities' nodes and edges already executed.   Unvisited nodes and edges would show in normal workflow color.    

    I wonder if there is built in support for this already, it seems like there would be, but I am missing the documentation that explains how to do it.  If not, it would be a neat feature to add.

    - Jaime

    Tuesday, February 7, 2012 2:05 PM
  • Hi Jaime,
    I have not seen a ready-made published sample that does exactly what you are asking, but when you drill into the details of how the Visual Workflow tracking sample above works, it should not be hard to adapt. The way it determines the 'currently' executing activity is by looking at at tracking record, so you can look at any number of tracking records for the workflow instance to determine the execution history. Also the way it highlights the currently executing activity is by applying adornments to an activity designer, and you can just apply similar adornments (with stylistic differences) to all the other activities you have tracking records for that executed in the past.

    Tim



    Tuesday, February 7, 2012 4:44 PM
  • Thanks Tim, adding adornments to activities that executed in the past will work fine for me.
    Thursday, February 9, 2012 1:40 PM