dag-runtime / Exports / RunCancelService
Class: RunCancelService
Service for cancelling active DAG runs via the state machine.
See
DagRunStateMachine for valid cancellation transitions
Table of contents
Constructors
Methods
Constructors
constructor
• new RunCancelService(storage, clock): RunCancelService
Parameters
| Name | Type |
|---|---|
storage | IStoragePort |
clock | IClockPort |
Returns
Defined in
services/run-cancel-service.ts:22
Methods
cancelRun
▸ cancelRun(dagRunId): Promise<TResult<IRunCancelResult, IDagError>>
Cancels a DAG run if its current status allows the CANCEL transition.
Parameters
| Name | Type | Description |
|---|---|---|
dagRunId | string | The unique identifier of the DAG run to cancel. |
Returns
Promise<TResult<IRunCancelResult, IDagError>>
The cancelled run ID and status, or an error if the transition is invalid.