Process Integration

PI Messages

The message flow via SAP PI can be very complex, passing different components (such as adapter engines with the module processor and messaging system, integration engines with their pipeline processing including Java & ABAP proxies, business process engine etc.) and using different adapter types (such as File-, JMS-, IDoc-, RNIF-adapters etc.).

This complexity makes it difficult to track and monitor the flow of a specific message across SAP PI. Automated monitoring of messages is essential to ensure the error-free operation of SAP Process Integration (SAP PI) and each integration scenario.

PI Channels

In order to define the communication details for a SAP PI message so-called communication channels are used in SAP PI. Both the inbound and outbound communication is maintained in the channel definition, including the adapter used for the particular interface. This way the right sender and receiver components are available during runtime of a message. Communication channels can have different statuses which influences the runtime of the PI message, too. If a J2SE adapter engine is used, J2SE adapters are used instead of communication channels to define the inbound and outbound processing.

If a communication channel or J2SE adapter is in an inactive or erroneous state the PI messages of the particular interface cannot be processed (as the sender or receiver components cannot be determined). Thus it is essential to monitor the involved communication channels or J2SE adapters of a SAP PI interface with high frequency, to be notified about failures or unavailability in time.

Technical Prerequisites

The following technical prerequisites have to be met in order to monitor messages in the ABAP system via ABAP proxy:

  • The managed system has SAP Basis release 7.00 or higher

The following technical prerequisites have to be met in order to monitor PI messages in the SAP PI system:

  • Managed system has PI Basis release 7.11 SP 06 or higher

For PI Java message monitoring the following prerequisites have to be met:

  • MESSAGING SYSTEM SERVICE 7.31 SP 21
  • MESSAGING SYSTEM SERVICE 7.40 SP 16
  • MESSAGING SYSTEM SERVICE 7.50 SP 08

For older support packages you can implement the following patches to enable PI Java message monitoring: 

 

Software Component Support Package Patch Level
MESSAGING SYSTEM SERVICE 7.31  SP 17  54 
SP 18  34 
SP 19  14 
SP 20  01 
MESSAGING SYSTEM SERVICE 7.40  SP 12  53 
SP 13  34 
SP 14  14 
SP 15  01 
MESSAGING SYSTEM SERVICE 7.50  SP 05  14 
SP 06  08 
SP 07  03 
SP 08  00 

Advanced Integration Monitoring Setup

Please, select...

To be able to monitor interfaces of an on-premise system you first have to add it to Interface & Cloud Monitoring and select the monitoring categories you want to monitor for the system. 

  1. Open the Advanced Integration Monitoring Application by clicking on the 'Integration & Cloud Monitoring' tile in transaction FRUN
  2. Click on the pinwheel in the upper right corner of the 'Integration & Cloud Monitoring' application
  3. In the configuration panel expand the 'Technical Systems' tray and click on the pen icon in the upper right corner. This will open the 'Integration and Cloud Monitoring - Systems' view. 
  4. If your system is not on the list yet, click the 'Add' button to add it. If it is on the list, click on the system ID of the system. 

In the next step, you see all monitoring categories which are available for the system, depending on the system type and the installed software components. Some recommended standard monitoring categories are preselected.

Select the monitoring categories in scope.

Available Monitoring Categories

For Process Integration Monitoring, different monitoring categories are available:

  • PI Messages (ABAP): Collected from the ABAP business system (monitoring transaction SXMB_MONI)
  • PI Messages (Java): Collected for PI Java systems (PI message monitor)
  • PI Communication Channels: Collected for PI Java systems (PI channel monitor)

For the category 'PI Messages (Java)' you can collect payload information via UDS attributes from the PI message and display this payload in the AIM application in SAP Focused Run. You can then use this information to search for related messages in PI or CPI, related IDocs, or related web service calls. Find out how to set up the collection of payload information here.

Please, select...

After selecting your monitoring categories you have to maintain filters to define what exactly you want to monitor. Some monitoring categories come with standard filters that usually just select all items of this monitoring category. SAP Focused Run can handle this high amount of monitoring data, so you can stick to this standard filters. Or you can set up filters of your own. 

Please note that the filters you set in the 'Monitoring' step filter the data which is collected from the managed system or cloud service. You can also set up filters later in the 'Alerting' step, which will filter the data already in Focused Run.

You can create more than one filter for a monitoring category.

  1. Select the view 'Monitoring'
  2. To add a new filter click the '+' button on the upper right corner of the table
  3. Select the Category for the filter. The drop down list will contain all activated categories for the system
  4. Enter a filter name
  5. Select the target client for the ABAP system / the end-point for the cloud services
Which filter fields are available depends on the selected category.

Available Filter Options

You can collect all PI messages and channels or you can use a filter to restrict the data collection. The available filter options depend on the category selected:

PI Messages (ABAP)

  • Status Group: The status group of the message. Please use the input help to select a status group
  • Sender namespace: The namespace of the source of the message
  • Sender interface: The interface of the source of the message
  • Sender party: The communication party of the source of the message
  • Sender component: The component of the source of the message
  • Receiver namespace: The namespace of the target of the message
  • Receiver interface: The interface of the target of the message
  • Receiver party: The communication party of the target of the message
  • Receiver component: The component of the target of the message

PI Messages (Java)

  • Status Group: Status group of the message
    • Cancelled
    • Errors
    • Scheduled
    • Processed Successfully
  • Interface namespace: The namespace of the message
  • Interface name: The interface name of the message
  • Sender party: The communication party of the source of the message
  • Sender component: The component of the source of the message
  • Receiver party: The communication party of the target of the message
  • Receiver component: The component of the target of the message
  • UDS Attribute Name: User Defined Search criteria defined for these messages

PI Communication Channels

  • Channel Name: The name of the channel
  • Party: If a party is maintained for the channel you can use it as a filter here
  • Service: The communication component of the channel

Please, select...

The setup of the filters for the monitoring categories only makes sure that the data is collected, however, alerts are not created automatically. To create alerts and notifications you have to create an alert individually. 

  1. Go the the view 'Alerting'
  2. Click on the '+' button in the upper right corner of the alerts table. A new panel will appear below the table for you to enter the alert information
  3. Select the monitoring category
  4. Select the metric name. The available metrics depend on the monitoring category.
  5. Enter a name for the alert

In the next sub-step, you have to maintain the filter. For most monitoring categories the available filter fields will be the same as for the 'Monitoring' configuration described above. 

For some metrics, you have additional filter fields or you have to maintain metric parameters. You can check the collected data in Focused Run to determine which filter values to use for alerting. Most of the fields can be found in the Collection Context of the collected data.

Please note that the filters on 'Alerting' level filter the data that is already available in Focused Run. They do not influence the data collection itself. You can only filter for data that is collected. Be aware of this if you created strict filters in the 'Monitoring' step.

  1. Enter a name for the filter
  2. Maintain the necessary filter fields

In the last sub-step you have to activate the alert:

  1. Check the check box next to 'Active'
  2. You can adjust the calculation frequency and the severity
  3. Available threshold types depend on the metric selected. If the threshold type allows it you can adjust the threshold value which triggers the alert.
  4. Select the notification variant and the outbound connector variant from the drop-down list.

For single exceptions, the threshold type is always 'Already Rated'. This means depending on the calculation frequency the number of exceptions is checked and an alert is created if this number is bigger than 0. If you want to reduce the number of alert for these metrics, you could increase the value for the calculation frequency to increase the time between checks.

Available Metrics

The following metrics are collected for the different Process Integration categories:

PI Messages (ABAP)

  • PI Messages in status "Error" for longer than N minutes: Indicates new PI messages in the status Error were found during the collection interval
    Metric parameters:
    • STATUS_GROUP (not changeable) = ERROR
    • OLDER_THAN_MINUTES = Only consider PI Messages older than [minutes]
  • PI Messages in status "Scheduled" for longer than N minutes: The number of new PI messages in the status Scheduled found during the collection interval
    Metric parameters:
    • STATUS_GROUP (not changeable) = SCHEDULED
    • OLDER_THAN_MINUTES = Only consider PI Messages older than [minutes]

PI Messages (Java)

  • PI Messages in status "Error" for longer than N minutes: Indicates new PI messages in the status Error were found during the collection interval
    Metric parameters:
    • STATUS_GROUP (not changeable) = ERROR
    • OLDER_THAN_MINUTES = Only consider PI Messages older than [minutes]
  • PI Messages in status "Scheduled" for longer than N minutes: The number of new PI messages in the status Scheduled found during the collection interval
    Metric parameters:
    • STATUS_GROUP (not changeable) = SCHEDULED
    • OLDER_THAN_MINUTES = Only consider PI Messages older than [minutes]

PI Communication Channels

  • Number of PI Channels in status ERROR: Indicates PI channels went into status ERROR during the last collection interval
    Metric parameters:
    • LAST_N_MEASUREMENTS = Only consider a channel if the last N measurements returned ERROR