views:

86

answers:

1

I'm developing an utility in order to work with persisted WF instances in a WF DB.

I'm using the standard SqlWorkflowPersistenceService to access the WF DB. I'd like to use the persistence service functionality such as GetAllWorkflows() und load individual instances via GetWorkflow().

While I'm working with these instances, I'd like to prevent the runtime from processing other instances. The persistence poll interval is set to a high value to prevent the service from polling while the tool is running, however the service loads instances with expired timers when it's starting.

Is there a way to prevent the runtime loading and processing instances at all?

+1  A: 

As far As I know there is no real out of the box setting that will let you load workflows without starting them. The easiest approach/workaround would be to use the ManualWorkflowScheduler with activeTimer set to false. That way you can load workflows but they will not be executed until you explicitly do so. Keep in mind that you have to unload any workflow instance you load yourself because no execution means the workflow doesn't become idle and the unloadOnIdle setting doesn't kick in.

Maurice
Thanks for your super answer. I really didn't think about the ManualWorkflowScheduler, it seems like the logical fit.
kay.herzam