Reputation: 51
We are developing an application using Workflow Foundation 4. We expect to use multiple activities each doing database updates within a transaction. We would also like to pause and resume the workflow. The pauses may be long-running. To ensure consistency we would like to make sure there is a bookmark created regarding where to resume the workflow before committing the transactions. Is this at all possible? Or any other suggestions on how to implement this well?
Regards
Upvotes: 4
Views: 249
Reputation: 4637
WF4 has a TransactionScope
activity, which you can use to perform database calls. However, it does not support creating bookmarks within the TransactionScope
sequence. A work around would be to have staging tables for temporarily storing in-progress data for a long running process that the workflow can read from when its resumed. Once everything is settled, you can write the data from the staging tables to your real storage.
Upvotes: 1