diff --git a/docs/reference-docs.md b/docs/reference-docs.md index b9add157..e7141c43 100644 --- a/docs/reference-docs.md +++ b/docs/reference-docs.md @@ -15,6 +15,7 @@ See the left navigation for all of the reference documentation for Netflix Condu * [Inline Task](/content/docs/reference-docs/system-tasks/inline-task) * [Kafka Publish Task](/content/docs/reference-docs/system-tasks/kafka-publish-task) * [Business Rule Task](/content/docs/reference-docs/system-tasks/business-rule) +* [Terminate Workflow Task](/content/docs/reference-docs/system-tasks/terminate-workflow) ## Operator Tasks * [Switch](/content/docs/reference-docs/switch-task) diff --git a/docs/reference-docs/system-tasks/terminate-workflow.md b/docs/reference-docs/system-tasks/terminate-workflow.md new file mode 100644 index 00000000..709a9849 --- /dev/null +++ b/docs/reference-docs/system-tasks/terminate-workflow.md @@ -0,0 +1,43 @@ +--- +sidebar_position: 4 +--- + +# Terminate Workflow Task + +```json +"type" : "TERMINATE_WORKFLOW" +``` + +### Introduction +TERMINATE_WORKFLOW is a task used to terminate one or more workflows using workflow IDs. + +### Use Cases +Consider a use case where you want to terminate a long-running workflow (or a set of workflows) from another, unrelated workflow. + +### Configuration + +#### Input Configuration + +| Attribute | Description | +|-------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------| +| workflowId | Either a workflow ID or a list of workflow IDs. | +| terminationReason | Optional text used to update reason for termination of the workflows being terminated. | + +#### Output Configuration +Task output will contain field "terminatedWorkflows" which is a set of workflow IDs corresponding to the workflows that were terminated. + +## Example + +Sample task + +```json +{ + "name": "terminate_workflow_example", + "taskReferenceName": "terminate_wfs_1", + "inputParameters": { + "workflowId": ["0ea3b193-7268-4886-aa97-d6ed170de854", "${workflow.input.idProvidedFromWorkflowInput}"], + "terminationReason": "Custom reason for termination" + }, + "type": "TERMINATE_WORKFLOW" +} +``` \ No newline at end of file diff --git a/sidebars.js b/sidebars.js index 22accba7..a612d561 100644 --- a/sidebars.js +++ b/sidebars.js @@ -46,6 +46,11 @@ module.exports = { type: 'doc', id: 'reference-docs/wait-task', label: "Wait Task" + }, + { + type: 'doc', + id: 'reference-docs/system-tasks/terminate-workflow', + label: "Terminate Workflow" } ] },