The communication channel monitor allows a system administrator to call information about communication channels and to administrate them.
The monitor provides current runtime information about the adapters of a communication channel. It also provides a connection to alerting.
Interface Overview
Characteristic | Value |
---|---|
Name |
Adapter Administration und Monitoring (AAM) |
Purpose |
Queries the communication channel status, administration of channels (start, stop) Connection to the Alert Framework |
Type |
Service in the facade com.sap.aii.af.svc.facade |
Technical name |
com.sap.aii.af.service.administration.api, com.sap.aii.af.service.administration.api.i18n, com.sap.aii.af.service.administration.api.monitoring |
Certification |
Mandatory |
Syntax |
Javadoc package com.sap.aii.af.service.administration.api and sub packages |
The APIs for communication channel monitoring are located in the hierarchy under the Adapter Framework service package com.sap.aii.af.service.administration.api.
com.sap.aii.af.service.administration.api.cpa
com.sap.aii.af.service.administration.api.monitoring
com.sap.aii.af.service.administration.api.i18n
Registering/Deregistering Adapters
An adapter is identified uniquely by its name and namespace. Enter these two values as the first two parameters in the method call.
For the example adapter, the adapter name is JCA and the namespace is http://sap.com/xi/XI/sample.
In the case of incompatible adapter changes, select a different namespace for the adapter. The adapter will then register itself for all communication channels.
Adapter Capability | Description |
---|---|
AdapterCapability.NONE |
No particular capabilities are supported. |
AdapterCapability.PUSH_CHANNEL_STATUS |
This allows the adapter to forward information about the status of the communication channel to the AAM framework (more information below under Push mechanism). |
AdapterCapability.PUSH_PROCESS_STATUS |
This allows the adapter to forward process status information to the AAM framework (more information below under Process status). Process status information can trigger SAP alerts (more information below). |
In the case of the example adapter, XIConfigurationimplements the following interfaces:
However, it is possible that these interfaces are implemented by different classes, which are then transferred by the AdapterCallback parameter.
Open XIConfiguration.java and search for the character strings CS_ADMONR and CS_ADMOND.
Under CS_ADMONR, the registration of the adapter with the AAM framework is displayed.
Under CS_ADMOND, the deregistration of the adapter with the AAM framework is displayed.
Monitoring
In the communication channel monitor, you can monitor two types of status: the channel status and the process status.
Implement the ChannelStatusCallback interface so that the AAM framework calls a callback as soon as a user wants to get status information about a channel in communication channel monitoring.
The getChannelStatus method is then called. The AAM framework expects the ChannelStatuscontainer to be filled with status information. Use the ChannelStatusFactory to get an instance of this class.
Use the registerAdapter API to register the ChannelStatusCallback implementation with the AAM framework.
Open XIConfiguration.java and search for the character string CS_ADMON.
There is a description of how to determine the channel status.
The adapter provides the AAM framework with status information during runtime. The AAM framework supports this mechanism with the reportChannelStatus methods of the MonitoringManager.
To get an instance, use MonitoringManagerFactory.
The process status is reported to the AAM framework exclusively by the reportProcessStatus methods of the MonitoringManager interface.
The channel status corresponds to the Status column in the communication monitor. The process status is displayed in the Processing Errors column.
Localization
The AAM framework supports the LocalizationCallbackinterface. When an adapter registers an instance of this interface with the AAM framework, this callback is called for each string provided to the AAM framework, before it is displayed to the user.
The callback is not called for text information from ChannelStatusCallback.
Open XIConfiguration.java and search for the character string CS_LOCAL.
A general LocalizationCallback implementation is provided with the ResourceBundleLocalizationCallback class.
Connecting to the Alert Framework
The AAM framework offers an option to trigger alerts, which, for example, send SMS messages to an administrator. To do this, the adapter must report an error with the value FATAL for the process status.
This happens by way of the reportProcessStatus() call. The adapter must specify that it supports the process status at registration using AdapterCapability.PUSH_PROCESS_STATUS. You configure alert rules in the Alert Framework.
More information: Alert Configuration
For an example sender adapter, you can set the Raise Error Condition (demo) parameter to Raise Rollback .... This triggers an error in sender message processing. In addition, a FATAL process status is reported to the AAM framework.
Open SPIManagedConnectionFactory.java and search for the character string CS_CS_PROCALERT.