Adding Workflow Tasks

Each task on the workflow is represented as a task object. You can have any number of tasks in your workflow, and your tasks can be linked in a sequence that controls the order in which the tasks are executed.

Decision

A Decision task invokes one of the two paths in the workflow, depending on whether the logical expression inside the Decision object returns a Yes (True) or a No (False) flag.

To use, drag and drop the Decision object onto the workflow designer. Configure the object by right-clicking on the object’s header and selecting Properties from the context menu.

This will open the Decision Properties window. This configuration screen provides the interface to create some decision logic.

In the Expression input box, enter an expression. This expression should return a Boolean result, such as True or False. An example of this expression is shown below. The expression here is based on the presence of erroneous records in a Run Dataflow task object.

Note: The right-hand pane displays the object tree (highlighted in yellow). You can double-click on an object to add it to your expression.

Click Compile to check for any syntax errors in your expression. The status should read “Successful” for a successful compilation.

File System

The File System Action task performs actions on a file or a folder, as it is configured. For example, this task can copy a file, move a file to another folder, or delete all files in a folder.

To use, drag and drop the File System Action object onto the workflow designer. Configure the object by right-clicking on the object’s header and selecting Properties from the context menu.

A File System Action Properties window opens as shown below. Here we configure the properties of the File System Action task.

Select an action from the Action dropdown list. The following options are available:

  • File Copy – copies a file from a source folder into a destination folder

  • File Move – moves a file from a source folder into a destination folder

  • File Rename – renames a file

  • File Delete – deletes a file

  • Directory Move – moves all files in the folder into a new folder

  • Directory Delete – deletes the folder along with any files or folders it contains

  • Directory Content Delete – deletes all files from the folder, leaving the folder empty (the folder itself is not deleted).

Source File (Directory) Path – specifies the path to the source file or source directory

Destination Directory Path – specifies the path to the destination file or destination folder.

File Transfer

The File Transfer task performs the specified actions on an FTP server. For example, the task can upload a file to an FTP server, rename a file, or delete all files from a remote directory.

To use, drag and drop the File Transfer task object onto the workflow designer. Configure the object by right-clicking on the object’s header and selecting Properties from the context menu.

A File Transfer Action Properties window opens as shown below. Here, we configure the properties of the File Transfer task.

FTP Connection – To configure the connection with your FTP server, click on the ellipsis. A Web Connection window opens up.

Here, set up the FTP server connection by providing the URL, Login Name, and Password. In case of using a proxy, fill in the details under Proxy Info. For security protocols, provide details under FTPS Security Settings.

FTP Action – select an action from the FTP Action dropdown. The following options are available:

  • Upload a File – uploads a file from a local folder into the remote directory

  • Download a File – downloads a file from the remote directory into a local folder

  • Delete a File – deletes file from the remote directory

  • Rename – renames a file in the remote directory

  • Remove Directory – deletes the remote directory

  • Upload a File with Unique Name– uploads a file from a local folder into the remote directory, renaming the file if needed to ensure a unique file name in the remote directory.

  • Remote Info-Path – specify the path of a file or folder on the FTP server.

  • Local Info-Path– specify the local path on the server running the workflow.

Run Dataflow

The Run Dataflow task is used to execute a dataflow as part of a workflow. Multiple Run Dataflow task objects can be employed as part of a workflow, to orchestrate a data process.

To use, drag and drop the Run Dataflow task object onto the workflow designer. Configure the object by right-clicking on the object’s header and selecting Properties from the context menu.

A Start Dataflow Job Properties window opens as shown below.

Job Info-Path – specify the path to the dataflow that you want to run.

Note: To ensure that your workflow is runnable on a remote server, please avoid using local paths for the dataflow. Using UNC paths is recommended.

Run in Pushdown mode – executes a dataflow on the server without fetching data to the Astera client.

Run Program

The Run Program task is used to run an executable command or batch file, as part of your workflow. Tasks, such as a series of commands in another programming language (e.g. Python/R) in the form of a .bat extension file, are executed through the Run Program task object.

To use, drag and drop the Run Program task object onto the workflow designer. Configure the object by right-clicking on the object’s header and selecting Properties from the context menu.

A Run Program Properties window opens as shown below. This screen lets users define properties for an executable batch file.

  • Program Path – specify the file path to the executable batch file that you want to run as part of the workflow.

  • Run In – specify the default folder where Astera will run the batch file. (optional)

  • Arguments – specify any required or optional arguments for running the batch file, such as providing an external input or indicating an input parameter change.

  • Run As – enter a user account (if different from the administrator) that should be used for running the batch file.

  • Password – enter the password specific to the user account entered in the Run As option.

  • Success Value – a value returned by the executable batch file upon its successful completion. The default value is 0. The Run Program task will expect this value to signal the successful completion of the task.

  • Timeout – define a time after which, if the program task fails to execute, Astera will terminate the process.

  • Fail Action if Unsuccessful – select this option to return an error when the executable batch file ends with an error in the code.

  • Wait for Task to Complete – select this option to stop Astera from proceeding to the next task in the workflow until the batch file has finished running.

Run SQL File

The Run SQL File task runs the SQL code inside a file of .sql extension as part of a workflow.

To use, drag and drop the Run SQL File task object onto the workflow designer. Configure the object by right-clicking on the object’s header and selecting Properties from the context menu.

A Database Connection window opens as shown below. This is where we configure the connection with the database.

Astera offers native connectivity to a number of databases and applications. To connect to a database, click on the drop-down menu next to the Data Provider option and select a data provider from the list.

To establish a connection to a data provider, fill in the credentials such as User Id, Password, Server Name, Database, and Schema.

The next screen is the Run Sql File Properties window.

SQL File Path – specify the path to the SQL file that you want to execute through this task.

The next screen is the Config Parameters screen. This is where users can set up variable parameters to indicate a run-time change for values in the list on the screen.

Run SQL Script

The Run SQL Script task provides flexibility to write SQL code within Astera and deploy it as part of a workflow.

To use, drag and drop the Run SQL Script task object onto the workflow designer. Configure the object by right-clicking on the object’s header and selecting Properties from the context menu.

A Database Connection window opens as shown below. This is where we configure the connection with the database.

The connection to a data provider is established similar to how it is described for the Run SQL File task object.

The next is the Run Sql Properties screen. In the SQL Statement box, enter the SQL code. This code will be executed by the Run SQL Script task.

Run Transfer

The Run Transfer task executes a transfer setting as part of your workflow.

Note: The Run Transfer task is in place for compatibility with previous versions of Astera. In the current version of Astera, dataflows replace transfer settings and provide superior functionality, so you should use the Run Dataflow task instead.

To add a Run Transfer task, drag the Run Transfer object from the Workflow Tasks group in the Flow toolbox and drop it on the workflow.

An example of what a Run Transfer object might look like is shown below.

To configure the properties of a Run Transfer object after it was added to the workflow, right-click on it and select Properties from the context menu. The following properties are available:

  • Start Transfer Job Properties screen:

    • Job Info: Path – specify the path to the transfer setting that this task will execute.

Note: To ensure that your workflow is runnable on a remote server, please avoid using local paths for the transfer setting. Using UNC paths is recommended.

  • Run At: select the server that should execute the transfer setting

  • General Options screen: The Comments input allows you to enter comments associated with this object.

Run Transfer Batch

The Run Transfer Batch task executes a transfer batch as part of your workflow.

Note: The Run Transfer Batch task is in place for compatibility with previous versions of Astera. In the current version of Astera, dataflows replace transfer batches and provide superior functionality, so you should use the Run Dataflow task instead.

To add a Run Transfer Batch task, drag the Run Transfer Batch object from the Workflow Tasks group in the Flow toolbox and drop it on the workflow.

An example of what a Run Transfer Batch object might look like is shown below.

To configure the properties of a Run Transfer Batch object after it was added to the workflow, right-click on it and select Properties from the context menu. The following properties are available:

  • Start Batch Job Properties screen:

  • Job Info: Path – specify the path to the transfer batch that this task will execute.

Note: To ensure that your workflow is runnable on a remote server, please avoid using local paths for the transfer batch. Using UNC paths is recommended.

  • Run At: select the server that should execute the transfer batch

  • General Options screen: The Comments input allows you to enter comments associated with this object.

Run Workflow

The Run Workflow task starts another workflow as part of a nested workflow. The object works similarly to the Run Dataflow task.

To use, drag and drop the Run Workflow task object onto the workflow designer. Configure the object by right-clicking on the object’s header and selecting Properties from the context menu.

A Start Workflow Job Properties window opens as shown below.

Job Info-Path – specify the path to the workflow you want to run.

Note: To ensure that your workflow is runnable on a remote server, please avoid using local paths for the workflow executed by this task. Using UNC paths is recommended.

  • Run At: select the server that should run the workflow

  • Parameter Information Replacement screen provides the interface to modify connection parameters as required by your target environment.

  • General Options screen: The Comments input allows you to enter comments associated with this object.

Send Mail

The Send Mail task sends emails to the administrator at appropriate junctions in a workflow.

To use, drag and drop the Send Mail task object onto the workflow designer. Configure the object by right-clicking on the object’s header and selecting Properties from the context menu.

A Send Mail Properties window opens up as shown below.

Server – specify the server setting for an email platform by clicking on the ellipsis.

An Email Connection window opens up. This is where we specify the server connection details.

Recent – select from the dropdown list of recent server configurations to automatically populate your connection info.

Options under Connection Info depend on the email provider the user wants to employ.

Note: For more information on server settings for different email providers, click here.

Test your connection with the email provider by clicking on the Test Connection button. A Send Test Email window opens up that lets users send a test mail to the intended recipient.

Once the connection with the email provider has been set up, go back to the Send Mail Properties window to fill in the necessary details.

  • From – enter the sender's email account

  • To – enter the recipients of the email

  • Subject – enter the subject line for the email

  • CC – specify any CC recipients

  • BCC – specify any BCC recipients

  • Attachment – Provide any attachments that should be sent with the email

  • Message – Enter the body of the email that will be sent by this task

This concludes the description of the various workflow tasks in Astera.

Last updated