I have a recurrent workflow in my app that cleans up logs > 30 days old. However, this workflow somehow keeps failing rescheduling itself.
I have a button to kickstart the workflow but I can’t keep up and we have nearly 800,000 logs to delete now.
I was thinking of doing a recurring event, like every day restart the workflow if this workflow isn’t already scheduled. However, it seems I cannot query whether the workflow is scheduled or not.
Any ideas to share?
It could be your conditions that are causing the scheduling to fail.
There are only two conditions, one where the count of logs > 30 days = 0 and the other where count > 0 and I reschedule the log at different times (+1 day if =0 and now if > 0).
It must be one or the other so I would suspect it’s not that.
Logs in backend show it’s to do with backend capacity:
Workflow error - Operation timed out -- app too busy
I am trying to split the workflow in two: one worklow to schedule deletion, another workflow to actually delete.
I’m hoping this will keep the system going when deletion makes the “app too busy”.
Right. This is what I do too. That way for sure the scheduling will happen for tomorrow too even if it fails one day.
This topic was automatically closed after 70 days. New replies are no longer allowed.