Are there any best practices for
Are there any best practices for implementing a workflow that is used for starting and stopping third party services?
I was considering storing a lock in a durable object that states if the start workflow has already been executed you can only run the stop workflow but you still need to track the workflow instance id.
2 Replies
Why 2 separate workflows? Why not listen for a stop event?
Partially just due to the previous implementation (was using xstate within a durable object, built prior to the release of workflows). I had considered a singular workflow but didn’t even think about waiting for a stop event (previously I was thinking controlling it via params)
That actually sounds like an excellent idea though that I overlooked, thank you!