- 04 Feb 2025
-
DarkLight
-
PDF
Jobs, Tasks and Variables
- Updated on 04 Feb 2025
-
DarkLight
-
PDF
The Automation Builder lifecycle refers to the various states associated with running an automation. Each state (i.e., status) corresponds to a running job or task in a workflow.
Job Lifecycle
Upon start, a job is set to running status. Running jobs can move into cancelled, completed, or error states.
Figure 1: Job Lifecycle
Task Lifecycle
When a job is started, its tasks are set to an incomplete status. From incomplete, tasks move into running or scheduled states. A running task can move to completed, canceled, or error states.
Figure 2: Task Lifecycle
Variable Types
In both generations of Automation Builder, variables are used to hold one or more values that can be referenced by various devices and applications There are three variable types (static, job, and task) that can be used in a Reference task on the Automation Builder canvas.
Static Variables
Static variables are hard-coded and maintain the same value between function calls. They cannot be modified or changed programmatically in the lifecycle of an automation run. A static variable remains in memory while the automation is running. They are often used to maintain settings whose values should not change once a workflow (automation) has started.
Job Variables
Job variables allow you to use changeable values in the configuration and execution of a job. You create a variable, give it a name and a value. You can then insert the variable (by referencing its name) in various places in a workflow. When Itential Platform runs a job, it replaces the reference variable with the job variable's value. Job variables are useful in two ways. First, they allow you to pass values as inputs to a workflow each time you execute it. Secondly, anywhere in the workflow, a task can set/update the value of a job variable. As a best practice, use task variables instead of job variables whenever possible, but if task variables will not work, then use job variables.
Task Variables
Task variables are values provided as a result of executing another task earlier in the workflow of an automation. Essentially, they provide reference information for another task. This means you are choosing some previously executed task, taking its output, and using that as the selected task’s input.