ActionScheduler_Abstract_QueueRunner::batch_limits_exceeded()
See if the batch limits have been exceeded, which is when memory usage is almost at the maximum limit, or the time to process more actions will exceed the max time limit.
Based on WC_Background_Process::batch_limits_exceeded()
Method of the class: ActionScheduler_Abstract_QueueRunner{}
No Hooks.
Return
true|false
.
Usage
// protected - for code of main (parent) or child class $result = $this->batch_limits_exceeded( $processed_actions );
- $processed_actions(int) (required)
- The number of actions processed so far - used to determine the likelihood of exceeding the time limit if processing another action
ActionScheduler_Abstract_QueueRunner::batch_limits_exceeded() ActionScheduler Abstract QueueRunner::batch limits exceeded code WC 8.6.1
protected function batch_limits_exceeded( $processed_actions ) { return $this->memory_exceeded() || $this->time_likely_to_be_exceeded( $processed_actions ); }