Calculating the cost of a flow

You can assign a cost to a flow by defining values for assignments and flow actions that are added together at run time. By collecting information about the path that a flow takes, you can generate metrics that are specific to your application.

  1. Open a flow by searching for it or by using the Application Explorer.
  2. Repeat the following steps for each assignment in the flow:

    1. Double-click the assignment to open the Assignment properties dialog box.

    2. In the Advanced section, click Assignment details.

    3. In the Effort cost field, associate a value with the assignment by doing one of the following actions:

      • Press the Down Arrow key and select the name of a property that stores an integer or decimal.

      • Enter an integer or decimal.

      • Enter an expression.

      For example, you can assign different monetary amounts to assignments in a service repair flow to calculate the total price of parts to order.

    4. Click Submit.

  3. Repeat the following steps for each flow action in the flow:

    1. Double-click the connector that displays the name of the flow action to open the Connector properties dialog box.

    2. In the Flow action field, click the Open icon .

    3. Click the Action tab of the Flow Action form.

    4. In the Apply cost field, associate a value with the flow action by doing one of the following actions:

      • Enter an integer or decimal.

      • Enter the name of a property that stores an integer or decimal.

    5. Click Save.

    6. On the Flow form, click Submit to close the Connector properties dialog box.

  4. On the Flow form, click Save.

At run time, you can retrieve the cost of a flow by inspecting the value of the Work-.pyResolutionCost property.