Running a Route or Data Service Job in local Talend Runtime Test Container - 7.0

Talend ESB Studio User Guide

author
Talend Documentation Team
EnrichVersion
7.0
EnrichProdName
Talend ESB
task
Design and Development
EnrichPlatform
Talend Studio

Talend Studio enables you to set up a local Talend Runtime in the Studio to test Routes and Data Service Jobs easily within the OSGI Runtime environment.

To set up the test Runtime:

  1. Open the [Preferences] dialog box.

  2. In the tree view, click Talend > Run/Debug > ESB Runtime to display the corresponding view.

  3. The ESB Studio Runtime check box is selected by default to use the local Talend Runtime. If this check box is disabled, the Route or Data Service Job will be run in the Studio instead of the local Runtime.

    Note that this option only works for Routes and Data Service Jobs.

  4. In the Connection Information area, click the Add Server... button to show the [Add ESB Runtime Server] wizard.

  5. Choose one of the following to select a Runtime to be used:
    • If you have prepared a Runtime container that you would like to use, select Use an existing local Talend Runtime Container (ESB OSGI Container). Browse to or enter the path of Talend Runtime home and click Finish. This path is filled in the Location field of the ESB Runtime view. You can also enter the path of the Runtime container in the Location field.

    • If you want to use a new Talend Runtime archive, select Install the Runtime container from Talend Runtime (ZIP) or Talend ESB (ZIP). Browse to or enter the path of the Talend Runtime or Talend ESB zip file. You can choose to install the local Runtime into the default target folder, which is <Studio_Home>/esb/container, or a custom target folder of your choice. Click Finish to close the wizard. The Runtime server is extracted to the selected target folder. This target path is filled in the Location field of the ESB Runtime view.

    An initialization script file initlocal.sh is created in the <LocalRuntimeContainerPath>\scripts folder to start all the ESB bundles, use JAAS authentication handlers for the security service, and start an ActiveMQ broker in the Runtime container. You can change the script if needed.

    tesb:start-all
    tesb:switch-sts-jaas
    feature:install activemq-broker
  6. In the ESB Runtime view, click the Initialize... button to start the Runtime server and install the OSGI bundles.

    Note that you can also start the Runtime server using the trun file from the <LocalRuntimeContainerPath>:

    • bin\trun.bat (Windows)

    • bin\trun (UNIX)

  7. In the ESB Runtime view, if you select the Filter system logs check box, the Apache Karaf log information will not be shown when running Routes, or Data Service Jobs in the local Runtime server.

  8. Click OK to close the Preferences dialog box.

    Note that if you enabled or disabled the ESB Studio Runtime option in this view, the container setting needs to close all editors of ESB artifacts before saving your changes.

Once the Runtime server is added, you can run your Route or Data Service Job in the local Runtime for testing purposes:

  1. Go to the Run view of Talend Studio design workspace.

  2. Click the Run button in the Basic Run tab as usual, to deploy and execute the current Route or Data Service Job.

You can stop the Runtime server from the Runtime Console:

  1. Click Window > Show view to show the Console view of the design workspace.

  2. Click the button in the Console view and select ESB Runtime from the list to show the ESB Runtime Console. You can run the Runtime commands in the console.

  3. Click in the Console view to stop the Runtime server. To start the Runtime server again, click .

    Note that if the local Talend Runtime in the Studio is enabled, when running a Route or Data Service Job, the Runtime server will be started automatically if it is down.