Open GrigoreMihai opened 1 year ago
Is there any way to do this that we have missed ?
You can limit it to how many actions it runs with wp action-scheduler run --batches=N --batch-size=X
where N
and X
are integers.
Is there any way to do this that we have missed ?
You can limit it to how many actions it runs with
wp action-scheduler run --batches=N --batch-size=X
whereN
andX
are integers.
I was aware of this, we want to limit the time that the command runs regardless of the number of actions. For example stop running actions after 10 minutes have passed.
hey @GrigoreMihai it's currently not supported out of the box as of now, but sounds like a good enhancement request. Meanwhile, perhaps you can use the action_scheduler_before_execute
to stop the process if a time limit is exceeded.
We would like to limit the running time of the CLI runner, similar to how the
action_scheduler_queue_runner_time_limit
filter is working for the default runner, but we could not find a way to do this.Is there any way to do this that we have missed ?