The variables feature provides a storage area for information that is used on a regular basis to avoid having to specify the same information in several places. Data stored in a variable can be altered to affect process execution behavior. The Variables in Action Orchestrator work in the same way as variables of any other programming language.
To add a global variable, choose Variables > Global Variables > NEW Variable. From this view, you can create new global variable, modify the properties of a variable, and delete variables. You can also add the variable from the workflow or activities properties pane. For more information, see Creating Global Variables.
Variable type provide a way to define a new user defined variable type that is not represented by any default variable type. To add a variable type, choose Variables > Variable Types > New Variable Type. From this view, you can create new variable type, modify the properties of a variable type, and delete variable types.You can also add the variable type from the workflow or activities properties pane. For more information, see Creating Variable Type.
The following sections describe how you can use variables in Action Orchestrator:
One of the most common uses of variables is to define activity configurations. Any field in an activity can refer to a variable value rather than an explicit value. For example, you can use a variable to:
Specify the start date of the process’ operations window as a parameter to an operating system command.
Specify a condition, such as a file that should not exist after a job is initially triggered by the arrival of that file where a prior activity should have deleted the file.
Workflow Control Components
A Workflow can use variables to define the control components. For example, you can use a variable to define:
A Conditional activity to look at the exit code of a prior activity.
A While Loop activity to loop until a query fails or loop for a number of times corresponding to a number of objects pulled from a query.
Variables can be parameterized so that a workflow definition can be flexible enough to be reused in multiple places and the specifics can remain undefined so that they can be defined by the person or workflow that invokes the workflow or activity.
For example, a workflow called notify server owner might use a variable server for the name of the server that has a problem. The workflow retrieves the email address of the owner of the server and sends an email.
This workflow might be called from multiple places; a step in a server maintenance job fails, so the maintenance job populates the Server variable and invokes the notify server owner process. Another process might notify the server owner when a backup completes.
Formulas as Variable Values
You can specify a formula anywhere a variable value is used. For example, an operating system command's parameter might be formed from concatenating two variables' values or from parsing the output of a prior command.
Variables are used to store or pass a value between executions of a process or between steps within a single workflow.
Common Use of Variables
The most common types of variables in Action Orchestrator are name variables and process or activity property variables.
The most common use of variables is a name that has a changeable value. For example, you can use a global variable to store information used in processes such as:
Locations of files and directories
Workflow or Activity Property Variables
In a Workflow or activity definition, you can refer to the workflow properties or the properties of a prior activity in the workflow. In this scenario, the properties of the workflow or activity may also refer to associated objects.
One of the most common uses of variables is to define activity configuration. Any field in an activity with a Reference tool can refer to a variable value rather than an explicit value.
Another common use of variables is to track state. For instance, you can use variables as a loop counters to store the number of times a loop has executed and know the current loop iteration running.
You can also use a variable to build up a 'summary' message. For each thing event happens, you can append 'what just happened' to the variable. At the end of a process, the result will be the contents of this variable as an entire summary of the workflow.
- No labels