Integrator Task List and Task Objects
This topic describes using both tasks list objects and task objects within a script. Overall, a script is easier to develop, read, and maintain if parameters are defined at the top followed by the task list, then the tasks and finally the input, process, and output objects. See Integrator Parameters Overview.
TSKL
A task is an object or set of commands that Integrator executes. The tasks performed must be listed in the Task List ('TSKL') object called Main. The task list contains a single attribute, which is an array of task names to be performed. The order of the list determines the order of Task execution.
Example 1
object 'TSKL' "Main" { { "select sales", "lookup customer", "create customer_sales", } };
Example 2
object 'TSKL' "Main" { {"Purchasing",} };
There is one TSKL object required per script. It is called "Main". If an Integrator script contains multiple tasks, then object names must be unique within the script. One advantage of this requirement is that the same object can be used in different tasks without re-defining it. If an Integrator script does contain multiple tasks and one fails, the remaining tasks in the sequence are not executed. If this is not desired, separate the tasks into different scripts.
TASK
A task ('TASK') is an object that takes data from one or more inputs, and processes it to form a single output. It can contain a number of input objects, a number of process objects, but only one output object. The total of these objects (input + process + output) cannot exceed 1,000. These objects must be listed in the ('TASK') object definition. There needs to be one TASK object definition for each TASK named in the TSKL. Although the order of TASK attributes is not fixed, a task is easier to read and understand if inputs are followed by processes and then the output.
NOTE: An object name can only exist once in the entire Integrator script; however, a TASK object can have the same name as an INPT, PROC, or OUTP object.
TASK Object Attributes
Attribute | Type | Description |
---|---|---|
inputs (required) |
Array of Strings | Contains the names of input objects used in this task. The attribute name is always plural, even
if there is only one input. NOTE: An INPT object cannot be used multiple times in the same TASK. There is only one copy of the file state flag, so different uses can interfere with each other. Using the same INPT object multiple times fails, while using a different INPT object for the same file works. |
output | String | Contains the name of the output object used in this task. |
processes (required) |
Array of Strings | Contains the names of process objects used in this task. |
Visual Integrator automatically creates the Task List and initial Task objects (see Visual Integrator Task List and Task Objects).