none
How is persistence achieved in Workflow Manager?

    Question

  • To investigate the features and limits, I have installed Workflow Manager v1.0 on my local machine. Comparing it with the current solution we have implemented using WorkflowApplication:

    1) There is a slide in the BUILD video about persistence - how is this achieved? Especially when the Trusted Surface does not allow 'Persist' activity to be published.

    2) When an activity/workflow is published, what happens to the activity assembly and its dependents? Are they packaged and stored in a database? How are the dependent assemblies get resolved at run-time?

    Thanks

    Tuesday, November 13, 2012 3:27 PM

All replies

  • There are not many resources about Workflow Manager 1.0 currently. Especially for the internal implementation.

    I spend about one weeks on workflow Manager and I found:

    1) the persistence depends on the SessionMessage's State in ServiceBus . It means that workflow Manager itself doesn't store the persistence data of workflow, instead it put almost all persistence data into ServiceBus's database.

    2)After publishing an activity or workflow, the xaml files are stored in Workflow Manager's database. you can find them in the database named WFResourceManagementDB and the table named dbo.Activities.

    In default situation, only system activities can be used in Workflow Definition. you can build your custom activity based on the system activities, publish you custom activities to Workflow Manager and reuse them in other activity or workflow.

    I guess that all xaml file will be compiled in runtime.

    Of course, you can build your custom activities into dll. but in this way, you can't use the Publish API of Workflow Manager to publish them, you have to put the dll file in a special folder of workflow Manager and do some configuration.


    • Edited by jianyi Wednesday, November 14, 2012 9:54 AM
    Wednesday, November 14, 2012 9:51 AM
  • Hi Tayfun,

    hope this helps:

    Persistence

    Persistence in Workflow Manager is a feature which works automatically out-of-the box. PersistActivity is just most trivial possibility to explicitly persist the instance, which is in general not required.

    For example, Workflow Manager will automatically persist the workflow when workflow instance enters DelayActivity or any of awaiting activities which cause listening for message.
    Whenever such activities are scheduled Manager will enforce persistence of workflow instance.
     

    2.  Deployment
    Deployment of workflows in Workflow Manager is described in this post:

    http://developers.de/blogs/damir_dobric/archive/2012/11/18/deployment-of-workflows-in-workflow-manager.aspx


    Damir Dobric
    developers.de
    daenet.de
    daenet.eu
    daenet.com

    Sunday, November 18, 2012 10:52 AM