July 30, 2023

tSystem – Docs for ESB 7.x

tSystem

Calls other system processing commands, already up and running in a larger
Job.

tSystem Standard properties

These properties are used to configure tSystem running in the Standard Job framework.

The Standard
tSystem component belongs to the System family.

The component in this framework is available in all Talend
products
.

Basic settings

Use home directory

Select this check box to change the name and path of a dedicated
directory.

Use Single Command

When the required command is very simple, to the degree that, for
example, only one parameter is used and without space, select this
option to activate its Command
field. In this field, enter the simple system command. Note that the
syntax is not checked.

Warning:

In Windows, the MS-DOS commands do not allow you to
pass directly from the current folder to the folder
containing the file to be launched. To launch a file, you
must therefore use an initial command to change the current
folder, then a second one to launch the file

Use Array Command

Select this option to activate its Command field. In this field, enter the system
command in array, one parameter per line.

For example, enter the following command with consecutive spaces
in array for
Linux:

Standard
Output and Error
Output

Select the type of output for the processed data to be transferred
to.

 

to console: data is passed on to
be viewed in the Run view.

 

to global variable: data is
passed on to an output variable linked to the tSystem component.

 

to console and
to global variable: data is passed on to
the Run view and to an output
variable linked to the tSystem
component.

 

normal: data is passed on to the
component that comes next.

Schema and Edit
Schema

A schema is a row description, it defines the number of fields to be processed and
passed on to the next component. The schema is either Built-in or stored remotely in the
Repository.

Click Edit
schema
to make changes to the schema. If the current schema is of the Repository type, three options are available:

  • View schema: choose this
    option to view the schema only.

  • Change to built-in property:
    choose this option to change the schema to Built-in for local changes.

  • Update repository connection:
    choose this option to change the schema stored in the repository and decide whether
    to propagate the changes to all the Jobs upon completion. If you just want to
    propagate the changes to the current Job, you can select No upon completion and choose this schema metadata
    again in the Repository Content
    window.

Click Sync columns to retrieve
the schema from the preceding component in the Job.

 

Built-in: You create and store the schema locally for
this component only. Related topic: see
Talend Studio User Guide
.

 

Repository: You have already created the schema and
stored it in the Repository. You can reuse it in various projects
and job flowcharts. Related topic: see
Talend Studio User Guide
.

Environment variables

Click the [+] button to add as
many global variables as needed.

name: Enter the syntax of the new
variable.

value: Enter a value for this
variable according to the context.

Advanced settings

tStatCatcher Statistics

Select this check box to collect log data at the component level.

Global Variables

Global Variables

ERROR_MESSAGE: the error message generated by the
component when an error occurs. This is an After variable and it returns a string. This
variable functions only if the Die on error check box is
cleared, if the component has this check box.

OUTPUT: the standard output from a process. This is an
After variable and it returns a string.

ERROROUTPUT: the erroneous output from a process. This is
an After variable and it returns a string.

EXIT_VALUE: the exit code from a process. This is an
After variable and it returns an integer.

A Flow variable functions during the execution of a component while an After variable
functions after the execution of the component.

To fill up a field or expression with a variable, press Ctrl +
Space
to access the variable list and choose the variable to use from it.

For further information about variables, see
Talend Studio

User Guide.

Usage

Usage rule

This component can typically used for companies which already
implemented other applications that they want to integrate into
their processing flow through Talend.

Connections

Outgoing links (from this component to another):

Row: Main.

Trigger: On Subjob Ok; On Subjob
Error; Run if.

Incoming links (from one component to this one):

Row: Main; Reject; Iterate.

Trigger: On Subjob Ok; On Subjob
Error; Run if; On Component Ok; On Component Error; Synchronize;
Parallelize.

For further information regarding connections, see

Talend Studio User
Guide
.

Echoing ‘Hello World!’

This scenario is one single component tSystem to
execute a system command and shows the results in the Run view “console”.

tSystem_1.png

To replicate this scenario, proceed as follows:

Procedure

  1. Drop a tSystem component from the Palette to the design workspace.
  2. Double-click tSystem to open its Component view.

    tSystem_2.png

  3. Select the Use Single Command option to
    activate its Command field and type in
    "cmd /c echo Hello World!".
  4. In the Standard Output drop-down list, select
    to both console and global variable.
  5. Press F6 to run this Job.
tSystem_3.png

The Job executes an echo command and shows the output in the Console of the Run view.


Document get from Talend https://help.talend.com
Thank you for watching.
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x