I would try instead of triggering them one after another in one workflow, to trigger them at the end of the custom event that lives as a pre-requisite. In this scheme events would only begin when the workflow is complete. In your current scheme, once the “trigger” has completed, it starts the next trigger.
Hey Simon, after scheduling the API workflow the custom event will finish, so the next custom event will be executed wether or not the scheduled API workflow is finished.
To solve this you can f.i.:
Instead of scheduling an API workflow to perform the actions, directly perform the actions in the custom event workflow.
Create a data type “workflow status” in which you mark a certain workflow as completed. Add an action to the API workflow where you set this workflow as completed. Then either use a database trigger or a recursive workflow to check wether or not that API workflow is finished before you execute the next workflow.
@gerbertdelangen I’m trying your method of setting a database value when a workflow is complete.
The problem I’m running into is using the “result of step 1” conditional value to set that value. My understanding is that by setting the conditional value to depend on the step prior, the database change action will wait until the API workflow is finished.
But I dont know what that validation should be, since the workflow is running on a list of items. I’ve got a database field that knows how long the array is, and using that currently - but it doesn’t seem to be working.
Just a warning, if a search takes too long, there will be a time out and the workflow will not be executed. To solve this problem you can use a recursive workflows, check this article from Petter from the ultimate guides on performance and security (very useful books btw.).