Re-generating POM files, installing a patch and creating a custom script - Cloud

Talend Software Development Life Cycle for Cloud - Best Practices Guide

EnrichVersion
Cloud
EnrichProdName
Talend Cloud
EnrichPlatform
Talend Artifact Repository
Talend Management Console
Talend Studio
task
Administration and Monitoring
Deployment
Design and Development

If you want to migrate your projects to a newer version, you may need to install patches (Talend Studio monthly release patch, manual patch, component patch, etc.) using the -Dpatch.path option at build time.

The option that allows you to regenerate all POM files is available from org.talend.ci:builder-maven-plugin version 7.3.3 onwards (available from R2020-08).

The main advantage of this option is that it allows you to upgrade versions or test the patch(es) on one or several existing projects using Continuous Integration before applying the patch to Talend Studio.

Before doing that it is recommended to do these steps first:
  1. Checkout your Git projects. Read the Git documentation about the git checkout command.
  2. Download the patch manually as described in this documentation.
  3. Re-generate all the POM files of the project(s) workspace and install the patch(es) you want to to test.
    Note: Run the commands under the directory where the Git project has been checked out and make sure the Talend CommandLine application is started.

    Example for 2 patches installed locally:

    # To re-generate all pom files and install a patch
    mvn org.talend.ci:builder-maven-plugin:7.3.4:generateAllPoms 
    -Dlicense.path=/home/talend/talend_studio/license 
    -Dupdatesite.path=/home/talend/talend_studio/Talend_Full_Studio_p2_repository-V7.x.x/
    -Dpatch.path=D:/patches/Patch_TPS-2222.zip,D:/patches/Patch_TPS-3333.zip
    Tip: In case of migration, you probably want to re-generate the POM files for all projects, but if you want to filter on specific artifacts, you can use the -DitemFilter command.

    Example: Use -DitemFilter="label=CI_Jobs" to filter on artifacts with a name that contains CI_Jobs

    You also have the possibility to create a custom script that will regenerate all POM files. Example of a script that regenerate all POM files in the projects with a name that starts with CI:
    # To create the custom script 
    cat /home/talend/talend_studio/script.txt
    regenerateAllPoms
    # To execute the custom script
    mvn org.talend.ci:builder-maven-plugin:<version>:executeScript -Dlicense.path=/home/talend/talend_studio/license -Dupdatesite.path=/home/talend/talend_studio/Talend_Full_Studio_p2_repository-V7.x.x/
    -DscriptFile=/home/talend/talend_studio/script.txt
    Tip: In case of migration, you probably want to re-generate the POM files for all projects, but if you want to filter on specific projects, you can use the -DprojectFilter command.

    Example: Use -DprojectFilter="CI.*" to filter on projects with a name that starts with CI.

  4. Test the generation of existing projects and Jobs.
    Example of generation with the package Maven phase:
    # To test projects/Jobs generation
    mvn clean package -Dlicense.path=/home/talend/talend_studio/license -Dupdatesite.path=/home/talend/talend_studio/Talend_Full_Studio_p2_repository-V7.x.x/
  5. Provided that the project generation is successful, apply the tested patches to Talend Studio as described in this documentation. If the test is not successful, please contact Talend Support.