Creating Compound Metrics

A compound metric is generated by adding one or more derivative metrics. The dimensions, definitions, standards, and modifiers of a compound metric are the same as those of the derivative metrics. No new dimensions and modifiers for the compound metrics generated if the derivative metrics have no dimensions and modifiers.

Prerequisites

You have created a derivative metric and the metric has been approved. For details, see Creating Derivative Metrics.

Creating a Compound Metric

To create a compound metric, do the following:

  1. Log in to the DGC console, select a DGC instance, and click Access.

    On the displayed page, click the Workspaces tab. In the workspace list, locate the required workspace.

  2. Click Data Design of the corresponding workspace to access the Data Design console.
  3. Choose Technical Metrics from the left navigation bar. On the displayed page, click the Compound Metric tab.
  4. On the Create Compound Metric page, select a subject from the subject tree on the left and click Add.
  5. On the displayed page, set parameters as prompted.
    Figure 1 Creating a compound metric
    Table 1 Parameters for creating compound metrics

    Parameter

    Description

    Name

    Only letters, digits, and underscores (_) are allowed. Compound metric names must start with letters.

    Code

    Only letters, digits, and underscores (_) are allowed. Metric code names must start with letters.

    Subject

    Subject information. Click Select to select a subject.

    Statistical Dimension

    Configured on the Derivative Metrics page.

    Data Type

    Select a data type for the compound metric to be created.

    Set Expression

    Select the required derivative metrics and set the expression as required.

    Alarm Triggering Condition

    An alarm triggering condition consists of derivative metrics and expressions. An expression consists of alarm parameters and logical operators. When a metric is running, the system calculates the result of the alarm condition expression and determines whether to trigger the alarm based on the result of the expression. If the expression result is true, the alarm will be triggered. Otherwise, no quality alarm will be triggered.

    Description

    A description of the compound metric to be created. Up to 600 characters are supported.

  6. In the lower part of the page, click Trial Run. In the dialog box that is displayed, click Trial Run to check whether the compound metric can run properly.

    If the trial run fails, locate the fault based on the error message, correct the configurations, and click Trial Run to try again.

  7. If the trial run is successful, click Publish.
  8. In the dialog box that is displayed, select a reviewer and click Confirm.
  9. Wait for the reviewer to approve the application.

    After the application is approved, the compound metric is created.

Editing a Compound Metric

  1. Choose Technical Metrics from the left navigation bar and click the Compound Metrics tab.
    Figure 2 Compound metrics
  2. In the compound metric list, select a metric that you want to edit and click Edit on the right. The page for editing the compound metric is displayed.
  3. Set the parameters as prompt. For details, see Table 1.
  4. In the lower part of the page, click Trial Run. In the dialog box that is displayed, click Trial Run to check whether the compound metric can run properly.

    If the trial run fails, locate the fault based on the error message, correct the configurations, and click Trial Run to try again.

  5. If the trial run is successful, click Publish.
  6. In the dialog box that is displayed, select a reviewer and click Confirm.

Publishing a Compound Metric

After creating or editing a compound metric, it takes effect only after it is published. Compound metrics to be published, already published, or to be suspended cannot be published.

  1. Choose Technical Metrics from the left navigation bar and click the Compound Metrics tab.
  2. In the compound metric list, select the compound metrics you want to publish and click Publish. The dialog box for publishing compound metrics is displayed.
  3. If there are no changes made to the information, click Confirm.

Viewing the Publish History

  1. Choose Technical Metrics from the left navigation bar and click the Compound Metrics tab.
  2. Select a compound metric in the list and choose More > View Publish History.
  3. On the displayed page, you can view the publish history and version comparison information of the metric.

Previewing a SQL Statement

  1. Choose Technical Metrics from the left navigation bar and click the Compound Metrics tab.
  2. In the compound metric list, locate the target compound metric and choose More > Preview SQL. The Preview SQL dialog box is displayed.
  3. On the displayed page, you can view or copy the SQL statement.

Suspending a Compound Metric

You can bring a published compound metric offline if it is no longer used.

  1. Choose Technical Metrics from the left navigation bar and click the Compound Metrics tab.
  2. In the compound metric list, select the compound metrics you want to suspend and click Suspend above the list. The dialog box for suspending compound metrics is displayed.
  3. If there are no changes made to the information, click Confirm.

Deleting a Compound Metric

  1. Choose Technical Metrics from the left navigation bar and click the Compound Metrics tab.
  2. Select compound metrics in the list and click Delete above the list. The dialog box for deleting the compound metrics is displayed.
  3. If there are changes made to your selection, click OK.