Configuring the AI Factsheets integration
You need to do some steps to configure the integration of IBM OpenPages® for IBM Cloud Pak for Data and AI Factsheets.
Do this configuration after you load the integration files.
- If you are running an on-prem or on-cloud installation of OpenPages, you must set up OpenPages to connect to a separate RabbitMQ server to exchange messages with AI Factsheets. For more information, see Setting up OpenPages to connect to RabbitMQ.
- Assign the MRG AI Factsheets Master profile to users. See Profile.
- Set up a user to give AI Factsheets access to the OpenPages API. See API user.
- Set up the messaging from OpenPages to AI Factsheets. See RabbitMQ messaging.
- Set the message expiration time for messages. See Adjusting the time-to-live for RabbitMQ messages.
Profile
The MRG AI Factsheets Master profile contains access to all the objects, views, and fields needed to use MRG together with AI Factsheets. Assign this profile to the users who want to use the AI Factsheets data in OpenPages.
API user
AI Factsheets uses the OpenPages REST API to populate OpenPages objects with model facts and other data that is initially captured in AI Factsheets.
To access the OpenPages REST API, an API user must be created in OpenPages and configured with the necessary permissions. OpenPages comes with a role template that is called MRG – AI Factsheets – API Access, which has the minimum set of access required for the API to function with AI Factsheets. Use this role template when you define a role assignment for the API user. For more information, see Creating user accounts.
Assign the MRG AI Factsheets Master profile to the API user to ensure the API user has access to all the required objects. For more information, see Associating profiles to a user.
RabbitMQ messaging
OpenPages uses RabbitMQ messaging to notify AI Factsheets about changes to OpenPages objects that need to be reflected in AI Factsheets. You can configure RabbitMQ messages for the following types of object changes (actions):
- Create
- Update
- Delete
- Associate
- Disassociate
Table 1 outlines the messages that are required for the integration with AI Factsheets.
| Object Type | Create | Update | Delete | Associate | Disassociate |
|---|---|---|---|---|---|
| Model Use Case (Register) | X | X | X | X | X |
| Model (Model) | X | X | X | X | X |
| Model Deployment (Usage) | X |
To set up this messaging, you add GRC triggers for the object types and operations. To set up the
triggers, you need to modify the _trigger_config_.xml file. The OpenPages
Platform 3 profile includes access to all of the system files, including the
_trigger_config_.xml file. Add the ready-to-use OpenPages Platform 3 profile to
the list of available profiles for your administrators who manage system files. Using this profile,
you have access to the menu items. For more information on modifying system files, see System file management. The following is a sample of XML code
for the triggers. Add each <grcTrigger> element to the
<trigger-definitions> section of the file.
<grcTrigger name="<triggerName>" event="<actionType>" position="<position>">
<rule class="com.ibm.openpages.api.trigger.oob.ContentTypeMatchRule">
<attribute name="content.type" value="<objectType>"/>
</rule>
<eventHandler class="com.ibm.openpages.api.trigger.oob.messaging.RabbitMQObjectChangeEventHandler">
</eventHandler>
</grcTrigger>
| Parameter | Description | Example |
|---|---|---|
<triggerName> |
A name for the trigger | grcTrigger name="RabbitMQ event for Model creation” |
<actionType> |
The action for which you want a RabbitMQ message. The possible values are:
|
event="create.object" |
| <position> | Position Events are generated in one of two phases of an operation, PRE or POST. Triggers are
registered to listen for either one or other position. The possible values are:
For more information, see the OpenPages 8.3 trigger development guide. |
position="POST" |
<objectType> |
The name of the object type you want to create messages for (i.e. Model, Register, Usage). | value="Model" |
For an example of the complete content of _trigger_config_.xml content, see Sample trigger configuration for AI Factsheets.
Adjusting the time-to-live for RabbitMQ messages
RabbitMQ allows for messages to expire after a specified amount of time, called the time to live (TTL) of the messages. In OpenPages, the TTL of RabbitMQ messages is controlled by the registry setting . By default, the TTL is set to 172,800,000 milliseconds (2 days).