Skip to main content

Update Workflow Definitions

The API to update an existing workflow definition.

Input Payload

You can update the workflow definitions directly via UI and using API. The workflow definition include the following parameters:

AttributeDescription
nameProvide a unique name to identify the workflow. This field is mandatory.
descriptionInclude a description to indicate the purpose of the workflow. This field is optional.
versionYou can give versions to the workflow to keep track of the changes. By default, the value is 1.
tasksYou can provide the tasks to be executed in the workflow here. If the task type is an operator or a system task, it is handled by the Conductor server. For user-defined/worker tasks, a worker running outside the Conductor environment is required.
inputParametersIndicates the input values for the workflow.
outputParametersIndicates the output values of the workflow.
schemaVersionIndicates the version number of the workflow definition schema.
restartableSet this value to true to restart a completed workflow. If restarting a completed workflow can impact the functioning, set this value to false.
workflowStatusListenerEnabledSetting this value to true, archive the workflow when completed. This would remove the workflow definition from the Redis persistence module. To unarchive, set the value to false.
ownerEmailThis field will be auto-populated with the user’s email address.
timeoutSecondsTime (in seconds), after which the workflow is marked as TIMED_OUT if not completed after transitioning to IN_PROGRESS status for the first time. No timeout occurs if the value is set to 0.
timeoutPolicyIndicates the condition at which the workflow should time out. It can take any of the following values:
  • TIME_OUT_WF - The workflow status is marked as TIMEOUT and is terminated.
  • ALERT_ONLY - Registers a counter.
failureWorkflowProvide the workflow name to be triggered upon a failure of the execution of this workflow.

API Endpoint

PUT /api/metadata/workflow

When overwrite is passed to true it will overwrite the existing workflow definitions.

Client SDK Methods

void OrkesMetadataClient.updateWorkflowDefs(List<WorkflowDef> workflowDefs) throws ApiException
void OrkesMetadataClient.updateWorkflowDefs(List<WorkflowDef> workflowDefs, boolean overwrite) throws ApiException