Adapting the pipeline script to use a referenced project - 7.2

Talend Software Development Life Cycle Best Practices Guide

Version
7.2
Language
English (United States)
Product
Talend Big Data
Talend Data Fabric
Talend Data Integration
Talend Data Management Platform
Talend Data Services Platform
Talend ESB
Talend MDM Platform
Module
Talend Administration Center
Talend Artifact Repository
Talend CommandLine
Talend JobServer
Talend Studio
Content
Administration and Monitoring
Deployment
Design and Development

How to configure the pipeline script provided by Talend to generate the artifacts of a referenced project.

A project reference is a property that you can set for a project so that all or some of the project items can be referenced by another project. When one project is stored on GIT, its items are structured in master and branches so that the reference can be established at either levels to provide more flexibility in project usability.

Procedure

  1. Open the Talend_Pipeline configuration page and go to the Script editor.
  2. To clone the reference project of your choice, replace the 'Git Checkout' stage defined in the default script provided by Talend with the following stage.

    Example

    stage ('Update sources from GIT') {
            // first git repository
            dir('.repo1') {
                git(
                        url: GIT_URL,
                        credentialsId: GIT_CREDENTIALS_ID,
                        branch: 'master'
                    )
            }
            sh "rm -rf $PROJECT_GIT_NAME"
            sh "cp -r .repo1/$PROJECT_GIT_NAME ."
            // other git repository (same way to checkout / copy)
        }
    allows you to copy artifacts from one Git repository (repo1) to another Git repository so that all artifacts can be accessed and used from the same repository.
    Note: The example is adapted for Unix environments. If you are using Windows, replace sh with bat in the example.
  3. Click Save to take your changes into account.