How to view or edit a survivorship rule item - 6.3

Talend Real-time Big Data Platform Studio User Guide

EnrichVersion
6.3
EnrichProdName
Talend Real-Time Big Data Platform
task
Data Quality and Preparation
Design and Development
EnrichPlatform
Talend Studio

The items you are able to view or edit of a rule package include the package itself, each of the validation steps and the whole survivor validation flow.

The validation step item

One validation step contains a group of validation rules that you are able to view or edit. To do this, proceed as follows:

  1. In Metadata > Rules Management > Survivorship Rules of the Repository tree view, expand it to show the survivorship rule package folder that you have generated.

  2. Select the rule package folder of interest and expand it. Then the contents of this package folder are listed under it.

  3. Right-click the validation step item that you need to view or edit. Then in the contextual menu, select Edit rule.

    The selected step item is opened in the workspace of your Studio.

    In this example, the validation rule of this step is labelled 5_MostCommonZip, belonging to the rule group whose identifier in the established survivor validation flow is 5_MostCommonZipGroup, and it examines the data from the zip column. The when clause indicates the condition used to examine the data and the then clause indicates the target columns from which the best-of-breed data is selected.

  4. Type in the necessary modifications and press Ctrl+S to save it.

    Note

    The edit feature is intended for viewing items as well as minor modifications such as, in this example, the change of the matching regex from "\\d{5}" to "\\d{6}". If you have to rewrite the clauses, or remove or add some clauses, we recommend using tRuleSurvivorship to define and organize the rules of interest and then regenerate the new rule package into the Repository in order to avoid manual efforts and risky errors.

The rule package item

To view or edit a rule package item, proceed as the same as described in the section earlier regarding the validation step item. Thus you are able to open the contextual menu of the rule package item, labelled drools x.x (x.x indicates the version number of the package) and select Edit package to open it on the workspace of your Studio. In the following figure, the rule package item is drools 0.1.

Once opened, its contents read as presented in the figure below:

This package defines a Drools declarative model for the corresponding survivor validation flow, using the user-defined columns in the input schema of the tRuleSurvivoship component. For further information about Drools declarative model, see the manual of Drools Guvnor.

Note

The edit feature is intended for viewing items as well as minor modifications. If you have to rewrite the whole contents, or remove or add some contents, we recommend using tRuleSurvivorship to define and organize the rules of interest and then regenerate the new rule package into the Repository in order to avoid manual efforts and risky errors.

The validation flow item

The survivor validation flow item presents the diagram of a survivor validation flow. To view or edit it, proceed as the same as described in the section earlier regarding the validation step item. Thus you are able to open the contextual menu of the survivor flow, and select Edit flow to open it on the workspace of your Studio.

Once opened, the diagram of the validation flow in this example reads as presented in the figure below:

This diagram is a simple Drools flow. You can select each step to check the corresponding properties in the Properties view, for example, the RuleFlowGroup property, which indicates the group identifier of the rules defined and executed at each step.

Note

If the Properties view does not display, click the Window menu > Show view > General > Properties to enable it.

On the left side are docked the tool panel where you can select the tools of interest to modify the established diagram. Three flow components are available in this figure, but in the Drools Flow nodes view of the [Preferences] dialog box, you can select the corresponding check box to add a flow component or clear the corresponding check box to hide it. To validate the settings of preferences, you need to re-open the flow of interest.

For further information about the [Preferences] dialog box, see Setting Talend Studio preferences

Note

The edit feature is intended for viewing items as well as minor modifications. If you have to rearrange the flow or change properties of a step, we recommend using tRuleSurvivorship to define and organize the rules of interest and then regenerate the new rule package into the Repository in order to avoid manual efforts and risky errors.

For further information about a Drools flow and its editing tools, see the relative Drools manuals.