Solved

WF: State Machine Persistence WorkFlow

Posted on 2010-11-29
1
890 Views
Last Modified: 2012-05-10
HI!

I need some design help.

I have a state machine that I need to restart when the workflow is done. I do not need to save the current states (pause the state machine) just rerun it from the start.

why I need this is becase the load of a new instance takes to long so I need to build the sate machine and when a user press start I need it to execute the state machine  directly without any delay of creating a new instanceand and when the user press start again I want to rerun it, and so on.

How do I do this?

Must I use the SqlWorkflowPersistenceService even if  I just want to restart it from the beginning? Or is there a easyer way to do it then?
0
Comment
Question by:AWestEng
1 Comment
 
LVL 14

Accepted Solution

by:
existenz2 earned 500 total points
ID: 34246219
Workflows are not designed to do this and it will give you all kinds of problems. You could however build a form of cache pool with a limited amount of new workflows waiting to be used. Everytime a new workflow is taken from the cache pool, you can asynchronisally put a new workflow into the pool to ensure that the pool does not end up without any prepared workflows.

It's a bit like a queueing mechanism or a car plant. Workflows are never fast and will always have a delay. There is no way to fix this, as this is by nature in any kind of workflow in any system. It's just the users perception which is the problem.
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Performance in games development is paramount: every microsecond counts to be able to do everything in less than 33ms (aiming at 16ms). C# foreach statement is one of the worst performance killers, and here I explain why.
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.
Established in 1997, Technology Architects has become one of the most reputable technology solutions companies in the country. TA have been providing businesses with cost effective state-of-the-art solutions and unparalleled service that is designed…

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question