IBM BPM, V8.0.1, All platforms > Authoring services in Integration Designer > Developing monitor models > Create monitor models > Defining dimensional models

Defining measures

Measures are calculations based on metrics. A measure points to a metric (such as order amount) and specifies an aggregation function (such as average or sum). You can define measures to be used in dimensional analysis in the dashboards.

To define a measure, first have a cube. A cube is created automatically each time a monitoring context is created.

To define a measure:


Procedure

  1. Click the Dimensional Model tab of the editor, and right-click the cube in the model tree. Click New to add a measure to the Measures table.

  2. In the Create New Measure window, type a name in the Name field and click OK. The name is limited to 256 characters, which cannot include backslash (\), forward slash (/), colon (:), asterisk (*), question mark (?), single quotation mark ('), open angle bracket (<), close angle bracket (>), or pipe (|). These unsupported characters will be removed.

    As you type the name, a default ID is created for you, although you can change it if you prefer. The ID is required and must be unique within the cube. The ID must be an XML NCName (non-colonized name), which means that it must start with a letter or underscore, and can contain only letters, digits, underscores, hyphens, and periods.

  3. To select the source of the measure, click Browse. In the Select Metric window, select a metric, key, stopwatch, or counter that is defined in the monitoring context associated with the cube, or click New to create a new one. You can select the same metric, key, stopwatch, or counter for more than one measure.

    For example, Average Order Amount and Total Order Amount can be based on an Order Amount metric.

    Measures based on stopwatches will not perform as well as measures based on duration metrics, because actively running stopwatch values are calculated in the database for each instance to be aggregated. Basing a measure on a stopwatch also limits your options for tuning the database in the future. When possible, use duration metrics instead of stopwatches as the source of measures.

  4. To specify the function to apply, select a function from the Aggregation Function list. Only certain types of functions are valid based on the source you choose.

    If you choose a function that is not valid, you will see a validation error. See "Aggregation functions" for more information.

    If you would like a count of the number of monitoring context instances, use the Count aggregation function and choose one of the monitoring context keys as the source, since key values are guaranteed not to be null.


Results

The measure is added to the Measures table and is also added under the cube in the model tree.


What to do next

Another measure, InstancesCount, which contains the number of instances of the monitoring context, is added when the monitor model is deployed to Business Monitor.

To add or edit the tracking key or description after creating a measure, click the measure in the model tree. Tracking keys are required for returning runtime values collected from Business Monitor to WebSphere Business Modeler. See Returning results to WebSphere Business Modeler using tracking keys for information about tracking keys.

Defining dimensional models