action-scheduler
action-scheduler copied to clipboard
Managing consistent failure threshold
Version 3.5.0 included this change:
Enhancement – If a recurring action is found to be consistently failing, it will stop being rescheduled.
Commits 5296abe, 75b2766, d9872aa appear to cover this change.
I'm using Action Scheduler to perform an action on a per-minute basis; with the new functionality, if that action fails 5 times due to a disruption in a third-party service that lasts 5+ minutes, I'm out of luck.
Are there any plans in a future version to either make the cancelling of consistently failing actions optional or to control the failure threshold via UI? Also, is there a notice in the WP Admin to inform admins when there has been a cancellation of an action due to consistent failure?
Is it possible to provide a suggestion for which hook/filter I should use to make a custom adjustment in my theme?
Thanks.
Hi @designhammer-tiffany,
Are there any plans in a future version to either make the cancelling of consistently failing actions optional or to control the failure threshold via UI?
No such plans currently: but I could certainly see the utility in making this and a few other things adjustable via a user interface instead of via code. We'll look into that.
Is it possible to provide a suggestion for which hook/filter I should use to make a custom adjustment in my theme?
Yes, you can use action_scheduler_recurring_action_failure_threshold. A minimal snippet for this might look like:
add_filter( 'action_scheduler_recurring_action_failure_threshold', function() {
return 100;
} );
@barryhughes p1669233141903949-slack-C7U3Y3VMY