MCPcopy Create free account
hub / github.com/ShipSecAI/studio / cancelWorkflow

Method cancelWorkflow

backend/src/temporal/temporal.service.ts:190–196  ·  view source on GitHub ↗
(ref: WorkflowRunReference)

Source from the content-addressed store, hash-verified

188 }
189
190 async cancelWorkflow(ref: WorkflowRunReference): Promise<void> {
191 const handle = await this.getWorkflowHandle(ref);
192 this.logger.warn(`Terminating workflow ${handle.workflowId} (runId=${ref.runId ?? 'latest'})`);
193 // Use terminate() for immediate stop - shows as TERMINATED status
194 // cancel() requires workflow cooperation and may show as FAILED if not handled
195 await handle.terminate('User requested stop');
196 }
197
198 /**
199 * Send a signal to a running workflow

Callers 1

cancelRunMethod · 0.80

Calls 2

getWorkflowHandleMethod · 0.95
warnMethod · 0.80

Tested by

no test coverage detected