Azure / durabletask

Durable Task Framework allows users to write long running persistent workflows in C# using the async/await capabilities.
Apache License 2.0
1.47k stars 287 forks source link

how to pause and resume orchestration #1030

Closed msoliman85 closed 4 months ago

msoliman85 commented 5 months ago

I am attempting to create an orchestration with long running tasks but I need the ability to pause the orchestration until an event is raised to continue the execution of the orchestration at a later time. Is this possible with the framework?

kaushiksk commented 5 months ago

You can try the SuspendInstanceAsync and ResumeInstanceAsync methods in TaskHubClient and see if it fits your use case. You just need the instanceId of the executing orchestration.

You can try this out with samples in https://github.com/kaushiksk/durabletask-samples