Adding a decision identifier

You can identify the results of a ruleset execution by adding a decision identifier to the transparent decision service request.

Procedure

Use the DecisionID element to identify the transparent decision service that your request defines.

Add the appropriate code to the transparent decision service request.
See the following example in REST:
<par:Request xmlns:par="http://www.ibm.com/rules/decisionservice/Example/Example/param" xmlns:int="http://www.ilog.com/Example">
  <!--Optional:-->
  <par:DecisionID>decision1234</par:DecisionID>
   ...

</par:Request>

The value of the DecisionID element is string.

Attention:
  • If you use Decision Warehouse and you want to provide IDs in the DecisionID element, make sure that each ID is unique. When the ID is not unique, the client receives a response but the execution is not registered in Decision Warehouse. In that case, a warning is issued in the output string.

    Rule Execution Server generates a unique ID when the ID is not specified.

  • If you want to implement your own mechanism to identify the results of a ruleset execution by adding an ID for each ruleset, make sure to use a different element name from DecisionID to avoid a conflict with the element implemented in Rule Execution Server. For example, having your own element called DecisionId is fine.

Results

You can see the DecisionID parameter in the decision service response. If the decision is stored in Decision Warehouse, you can identify it by looking up its ID.