ActionScheduler_Abstract_QueueRunner::get_time_limit()protectedWC 1.0

Get the maximum number of seconds a batch can run for.

Method of the class: ActionScheduler_Abstract_QueueRunner{}

Return

Int. The number of seconds.

Usage

// protected - for code of main (parent) or child class
$result = $this->get_time_limit();

ActionScheduler_Abstract_QueueRunner::get_time_limit() code WC 9.3.3

protected function get_time_limit() {

	$time_limit = 30;

	// Apply deprecated filter from deprecated get_maximum_execution_time() method
	if ( has_filter( 'action_scheduler_maximum_execution_time' ) ) {
		_deprecated_function( 'action_scheduler_maximum_execution_time', '2.1.1', 'action_scheduler_queue_runner_time_limit' );
		$time_limit = apply_filters( 'action_scheduler_maximum_execution_time', $time_limit );
	}

	return absint( apply_filters( 'action_scheduler_queue_runner_time_limit', $time_limit ) );
}