Skip to main content Skip to complementary content

Adding an execution task to a pre-generated Job

Talend Administration Center allows you to associate a pre-generated .zip file to a Job Conductor task, and thus to skip the generation step, in order to make sure the task that is deployed is the same as the one you have previously deployed.

For example, if you have generated a task in a development environment and want to run the exact same task in the production environment, you may want to use this feature.

To perform this action via the MetaServlet application, use the associatePreGeneratedJob command. For more information about the MetaServlet parameters, see Parameters and actions in metaServlet.

Information noteNote: This procedure enables Talend Administration Center to fetch all Jobs in a continuous way- even after the database is restored on a new server.

Before you begin

  • A .zip file holding a specific task has been previously generated by Talend Studio. The best practice is to put this file in the Job archive folder, which path is defined in the Job Conductor node of the Configuration page.
    Information noteImportant:
    • when exporting your Job from Talend Studio, you must select the items check box in the Build Job window.
    • this .zip file must contain a jobInfo.properties file at the root level, which describes the project and the Job characteristics.

      These information are necessary for the .zip file to be imported without generating errors.

  • A project with the same name as the development project used to generate the Jobs has been created in the Projects page. For more information, see Adding a project.
  • Unix only: If you want to execute the Job as a specific Operating System user (Run Job as OS user option), this user must already exist in the system and have the right umask, and some server directories must have been given specific permissions. For more information, see Configuring user impersonation for Talend JobServer.
    Information noteTip: By default, the username must start with a lower-case letter from a to z, followed by a combination of lower-case letters (a to z) and numbers (from 0 to 9). To allow using characters other than those letters and numbers, you need to modify the regular expression ^[a-z][-a-z0-9]*\$ in the value of the org.talend.remote.jobserver.server.TalendJobServer.RUN_AS_USER_VALIDATION_REGEXP parameter in the file {Job_Server_Installation_Folder}\agent\conf\TalendJobServer.properties. For example:
    • To define a username pattern that should include a dot, like firstname.lastname, modify the regular expression to ^[a-z][-a-z0-9]*.[a-z][-a-z0-9]*\$.
    • To allow using one or more underscores (_) in the username, modify the regular expression to ^[a-z][-a-z_0-9]*\$.

Procedure

  1. From the toolbar on the Job Conductor page, click Add > Normal Task to display the Execution task configuration panel.
  2. Enter/select the following information as necessary.

    Field

    Description

    Label

    Name of the task to be triggered.

    Description

    Provides any useful information regarding the task to be carried out.

    Active

    Select/clear this check box to activate/deactivate this task.

    Job

    Click the icon to open the Import generated code window. This window allows you to retrieve the pre-generated file holding the desired Job and to associate this Job to the task.

    Note that, when exporting your Job from Talend Studio, you must select the items check box in the Build Job window to be able to import your Job successfully on the Job Conductor page.

    Project

    This field is automatically completed and is read-only.

    Note that this project must exist in Talend Administration Center.

    Branch

    This field is automatically completed and is read-only.

    Name

    This field is automatically completed and is read-only.

    Version

    This field is automatically completed and is read-only.

    Context

    If you have defined several contexts in Talend Studio for the selected Job, select the relevant context in the list.

    Apply context to children

    This field is automatically completed and is read-only. It can be set when the Job is built from Talend Studio as a standalone Job.

    Log4j Level

    Select the level of log you want to apply to the execution task. The levels are ranked in increasing order of severity, from TRACE (most detailed information) to OFF (logs turned off).

    Execution server

    Select the server on which the task should be deployed.

    If the relevant server does not display on the list, check the Servers page and make sure the server is correctly configured. For more information regarding the execution server configuration, see Configuring execution servers.

    The list of execution servers offers virtual servers corresponding to physical servers grouped together. For details about Virtual Servers, see Configuring virtual servers.

    Statistic

    This field is automatically completed. It is either:

    • enabled (read and write) if you enabled the statistics during the generation of the Job;
    • disabled (read and write) if you deactivated the statistics during the generation of the Job.

    On unavailable JobServer

    This option is part of the failover process provided by Qlik. and allows you to decide what action you want to take on the selected task when the server is unavailable during a predetermined period of time (defined in Adding an execution server).

    Select one of the following from the list. The default value is Reset task.

    • Wait: if the Job has an unknown status, usually caused by server problems, this option puts the task on hold throughout the period of time during which the server is inaccessible. When the server is accessible again, the task will restore the status it held prior to encountering the problem.
    • Reset task: if the Job has an unknown status, usually caused by server problems, this option puts the task status back to Ready to run when the predetermined period of time relating to the Job status elapses. However, the Job itself could continue running depending on the initial problem.
    • Restart task: if the Job has an unknown status, usually caused by server problems, this option will automatically start the task in its original state when the predetermined period of time relating to the Job status elapses.
      Information noteNote: The Restart task option is only useful when you are using virtual servers.
    • Recover task: if the Job has an unknown status, usually caused by server problems, this option will automatically recover the Job execution from the last validated checkpoint.
      Information noteNote: The context parameters used when the task is reset, restarted or recovered, are the same as those used during the last execution

    Timeout (s)

    Type in how long to wait, in seconds, before the task is killed.

    By default, if no value is entered in the field, the task runs indefinitely. This option might be useful if you need to limit the execution of a task to a certain period of time.

    Pause triggers on error

    Select the check box in order to pause the trigger(s) if an error occurs during the execution of the task.

  3. Click Save to validate the configuration or Cancel to cancel the creation of the task.
    Once the task has been created, you can still edit its properties, manually, or using the Metaservlet application. For more information, see Editing a task.

Did this page help you?

If you find any issues with this page or its content – a typo, a missing step, or a technical error – please let us know!