rrq_task_cancel: Cancel a task

View source: R/rrq_task.R

rrq_task_cancelR Documentation

Cancel a task

Description

Cancel a single task. If the task is PENDING it will be unqueued and the status set to CANCELED. If RUNNING then the task will be stopped if it was set to run in a separate process (i.e., queued with separate_process = TRUE). Dependent tasks will be marked as impossible.

Usage

rrq_task_cancel(task_id, wait = TRUE, timeout_wait = 10, controller = NULL)

Arguments

task_id

Id of the task to cancel

wait

Wait for the task to be stopped, if it was running.

timeout_wait

Maximum time, in seconds, to wait for the task to be cancelled by the worker.

controller

The controller to use. If not given (or NULL) we'll use the controller registered with rrq_default_controller_set().

Value

Nothing if successfully cancelled, otherwise throws an error with task_id and status e.g. Task 123 is not running (MISSING)


mrc-ide/rrq documentation built on April 25, 2024, 11:59 p.m.