But my case is a little different as the time to complete can be days not mintues.
This is the workflow I want:
Create New Request for an Order.
Check status of Order
condition - if "completed" (or it's been a month) mark workflow completed and end the wf. If not wait 5 hours then try again(ie go to step 2). Keep trying for a
month, then give up and complete the workflow with status failed.
I can't just have a sleep then point back to step two because it will create a "cycle", even though cycles seem like a very common workflow pattern.
Any Ideas how to implement a simple workflow like this?
@victory,
You could instead call the entire workflow again. So create your if/else branch and in one branch you can create a wait block of 5 hours, and after that triggerWorkflowAgain (trigger the same workflow you are in). In the other branch, you can just return or send an email, etc. However, I caution you to make sure your condition to stop this workflow is working and in place, or you run the risk of creating a never-ending, endless workflow.