Invoke an IBM Tivoli Netcool/Impact policy

Enable Cloud Pak for AIOps to invoke an IBM Tivoli Netcool/Impact policy that will take actions on your alerts.

Note: If you have existing Impact Policy Language (IPL) policies (versus JavaScript policies) that you want to use in Cloud Pak for AIOps to return the event, you must modify the return statement from:

ReturnEvent(EventContainer);

To:

AIOPS_IPL_Utils.AIOPSReturnEvent(EventContainer);

For example:

@Summary=EventContainer.mynewsummary + " Enriched with this message";

AIOPS_IPL_Utils.AIOPSReturnEvent(EventContainer);

About this task

For example, you want Cloud Pak for AIOps to invoke an existing IBM Tivoli Netcool/Impact policy called Notify_Customer_Email. The policy accepts incoming event information from an event reader service and uses this information to look up affected internal customers in an external database. The policy then sends an email to each customer and reports the event data to a third-party help desk system that uses the web services API provided by that application.

For more information about setting up IBM Tivoli Netcool/Impact policies, see the IBM Tivoli Netcool/Impact documentation.

Important:

  • To successfully enable your IBM Tivoli Netcool/Impact policy with Cloud Pak for AIOps, you must first configure an IBM Tivoli Netcool/Impact connection in Define > Data and tool connections.
  • By default, IBM Tivoli Netcool/Impact policies are invoked without input or transformation. Editing options are available in the policy template.

Example

  1. Click the navigation icon at the upper-left corner of the screen to go to the main navigation menu.

  2. In the main navigation menu, click Operate > Automations.

  3. Click Create policy.

  4. Click the Invoke Netcool/Impact tile.

  5. Enter a name in Policy name, for example, "Notify customer help desk". You can also add an explanation of the policy in Description to help you and others understand the purpose of the policy, for example, "Look up customers affected by the event in the external database."

  6. Set the Execution order to 50.

  7. Define how the policy is triggered to invoke an IBM Tivoli Netcool/Impact policy. Once triggered, it looks for alerts or incidents that match the conditions you specify in order to take action. The policy triggers are when an alert or incident is created, updated, or both. Updated means the alert or incident state changes. For example, if an alert changes from Severity 1 to Severity 6, or if an incident escalates from Priority 5 to Priority 1 (this is an escalation as Priority 1 is the highest priority level).

    Note: Switching between alert and incident entities will reset the input fields for triggers, condition sets, and actions.

    For this example, we will select After an alert is created.

  8. Define the following conditions for alerts that trigger your IBM Tivoli Netcool/Impact policy:

    1. Click Add condition and select Alert property.
    2. From the Property drop-down list, select alert.severity. You can type "sev" and the system will show in the property drop-down list all alert properties that contain the text "sev", which in this case is only alert.severity. From the Operator drop-down list, select greater or equal. From the Matches drop-down list, select only. In the Values field, select 5-Major.
  9. In Invoke Netcool/Impact, specify the IBM Tivoli Netcool/Impact connection instance to invoke the policy. If you don't see anything in the Impact connection dropdown list, see IBM Tivoli Netcool/Impact connections.

  10. Select your Impact policy Notify_Customer_Email from the drop-down list. You can start typing the policy name in the field provided and the matching IBM Tivoli Netcool/Impact policy names will be suggested.

  11. By default, your IBM Tivoli Netcool/Impact policy parameters are mapped to all alerts or all incidents. Select from the following IBM Tivoli Netcool/Impact policy parameter-mapping options:

    • Send the full alert or incident
    • No input
    • Customize

Send the full alert or incident

Send the entire alert or incident without alteration. Click Create policy to save the policy.

No input

Your IBM Tivoli Netcool/Impact policy requires no input. Click Create policy to save the policy.

Customize

Select this option if you want to customize alert or incident field parameters that will be used as input for your IBM Tivoli Netcool/Impact policy. Click Edit parameter mapping to continue.

In this example, alert fields are being mapped as parameters to an IBM Tivoli Netcool/Impact policy. If incidents are selected as the policy trigger entity (see step 7 above), then incident fields are mapped as parameters here. The editor is divided into three sections. You can click and drag the vertical and horizontal middle lines to resize the sections.

Edit parameter mapping
Edit parameter mapping

  • Section 1: Sample alert

    Use the Select alert drop-down menu to load a sample alert, or go the Alert Viewer to copy and paste a raw alert by opening Alert details > Information > Raw > Copy to clipboard Copy. For more information, see Alert details.

    The sample alert provides variables available for use in your mapping, including the alert that the policy is acting on. You can modify the variables to test out different possible inputs to your IBM Tivoli Netcool/Impact policy, for example, by overriding the alert with one from your alert list.

    Note: The sample alert is only used to test your transformation and has no bearing on the execution of your policy.

  • Section 2: Jsonata transformation

    A JSONata expression translates between the variables available to the Cloud Pak for AIOps policy and the EventContainer object that is made available to the IBM Tivoli Netcool/Impact policy during execution. Use the Jsonata transformation section to include your own arguments for an IBM Tivoli Netcool/Impact action by making a selection from the Select template drop-down menu. If you are invoking an IBM Tivoli Netcool/Impact policy that was originally written for an IBM Tivoli Netcool/Impact EventReader, you will likely want to translate the alert variable to a set of ObjectServer columns here.

    When you start typing in Jsonata transformation (or press Ctrl + Space), a suggestion panel with alert properties is shown. Move the cursor into the panel to scroll and select from the list of properties. As you make changes in this section, the Input for Impact policy (section 3) shows a preview of your transformation.

    Parameter suggestion panel
    Parameter suggestion panel

    Warning: Any changes that you make to the source alert are reset if you reedit the parameter mapping.

  • Section 3: Input for Impact policy

    This section shows the results of your transformation and what the content of the EventContainer variable in IBM Tivoli Netcool/Impact will contain, based on the current sample alert and transformation rules that are used in section 2.

Click Save input to save your changes and close the editor. Then, click Create policy to save the policy.

New and updated policies can take up to 1 - 3 minutes to take effect.