Workflow Routines

Derick Larson
Administrators and Developers New to Kinetic
5.x

Introduction

Many of the tasks in workflow are repeated processes, like transforming data, creating notifications, and sending approvals. In this article you learn how to create repeatable independant processes called Routines.

Goals

The goals for the article are:

  • Learn to create a Routine
  • Learn how a Routine is used in a Tree

Description

A Routine is similar to a Tree except that it's independant of a source, so all inputs to the routine must be provided when the routine is called.

Creation

Similar to a tree, you can import, clone, or create a routine from scratch. Because the import and clone are the same as trees, the focus here is on create from scratch.

Example New Tree dialog:

V5 Routine Details

Creating a new routine from scratch is similar to creating a handler, and is treated that way by the engine. Each Routine has both a descriptive Name and a unique Definition ID. Both of these are required.

The Process Owner Email is optional and receives any errors.

Status is required, but defaults to Active. The other options are Inactive and Paused.

Category is optional and helps define access to the Routine.

Inputs and Outputs

The part that makes a routine most like a handler are the inputs and outputs. When you create the routine, you define what inputs are needed and what outputs are provided back to the tree after the routine completes.

Inputs need a name. They can have a default value, description, and be marked required if needed.

Outputs only have a name (required) and description.

If you change the inputs after the routine is used in a production capacity, it is recommended to update the Definition ID with a new version. Changes in parameters should be considered a new routine and be used as a new node in the tree.

System Return

When you are creating a Routine, there is one additional System Control available, the System Return node. This node has the list of outputs as parameters, and you can input any values or results that need to be passed back to the tree that called the routine.

Routine workflow

Now that the basics of the routine are created and saved, you can open the builder. All the options of a tree are available, including any existing routines. The only requirement is that you must have a System Return node if you want to pass any information back to the calling tree. Even of you don't pass any information, the System Return will complete the routine and allow the calling tree to continue. By default, every routine is set as a deferred node in the calling tree.

In the Next Article

That's all the articles that make up the Manager Training. From here it's recommended to look at creating handlers and information about creating bundles with React.