action_scheduler_before_process_queue

action_scheduler_before_process_queue

Appears in: , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
Hook Type: action
See hook in action

See hook in core

Displaying hooks found in version: woocommerce.9.5.1

do_action('action_scheduler_before_process_queue') is found 2 times:

  • /packages/action-scheduler/classes/ActionScheduler_QueueRunner.php line 133
    	 */
    	public function run( $context = 'WP Cron' ) {
    		ActionScheduler_Compatibility::raise_memory_limit();
    		ActionScheduler_Compatibility::raise_time_limit( $this->get_time_limit() );
    		do_action( 'action_scheduler_before_process_queue' );
    		$this->run_cleanup();
    
    		$this->processed_actions_count = 0;
    		if ( false === $this->has_maximum_concurrent_batches() ) {
    			do {
    				$batch_size                     = apply_filters( 'action_scheduler_queue_runner_batch_size', 25 );
    
  • /packages/action-scheduler/classes/WP_CLI/ActionScheduler_WPCLI_QueueRunner.php line 108
    	 *
    	 * @return int The number of actions processed.
    	 */
    	public function run( $context = 'WP CLI' ) {
    		do_action( 'action_scheduler_before_process_queue' );
    		$this->setup_progress_bar();
    		foreach ( $this->actions as $action_id ) {
    			// Error if we lost the claim.
    			if ( ! in_array( $action_id, $this->store->find_actions_by_claim_id( $this->claim->get_id() ) ) ) {
    				WP_CLI::warning( __( 'The claim has been lost. Aborting current batch.', 'woocommerce' ) );
    				break;
    

See this hook used in plugins: