How do I do this as a Workflow Service? RRS feed

  • Question

  • I'm using a WF Flowchart as a Controller for a MVC Application.  I saw the example here: http://dotnetslackers.com/articles/aspnet/Multiple-Step-Based-Registration-via-ASP-NET-MVC-2-WF-4.aspx

    I'm using a flowchart instead of a State machine, and I'm using Persistence Services. Also, I'm dynamically loading the XAML from the Workflow(s) from a database. Okay...what I'm doing isn't all that much like the example...

    One thing I am doing that is similar to the example is that I'm causing the Workflow to be persisted by a custom activity called, "ShowStep" which takes an argument called "StepName" Which could be "Welcome," "Step1," "Confirmation," "Finished" etc.  The step name describes the individual screeen the user needs to see.

    When the user completes a step, the workflow is pulled from the persistence store and the bookmark is resumed, passing in the data the user entered and the command they used (Next, Back, Finish, Exit, etc).  The workflow branches based on that command, does some work, and then sets a bookmark and waits for the user to enter more information.

    so, here's my problem...

    I have a number of places where my workflow suspends.  When it resumes, there are a number of places where it could suspend again.  Every time it resumes, I'm using bookmarks and manually resuming it because I want to always use the same command pattern.  Is there any way that I can do this with workflow services instead of manually resuming the bookmarks?  I'm 85% sure that I can't since WF Wants every request-response (unsuspend/suspend) to be represented as a unique operation and I want to use the same operation semantics for every receive/send pair.  Also, I really want to be able to receive  a message and have it returned by an arbitrary SendReply, which I know WF doesn't want to do. 

    I'd like to be able to do delays, and other goodies that you get out of the box when using workflow services.  However, I get the feeling that its not an option for me.

    Any Ideas....anyone....?

    Tuesday, August 2, 2011 12:02 AM

All replies

  • it looks like that we have similar needs, I am using workflow statemachine behind workflow service, I also need to get the blooking bookmarks when a workflow reach a step, workflow persistence service has a blookingbookmarke field in instance table, but, It has latence, especially when more then on instance workflow is running, the persistence service is not at the same page as the workflow, I would like query workflow for the blockingbookmarks inside my custom activity so that I can persist it to my own database in the same transaction as the one that is inside the custom activity, which will set my workflow status. I am seeking help as well.

    Tuesday, August 2, 2011 4:41 PM