Triggering alert (Email) using java mapping

By Sabyasachi Masanta

1.0 Introduction  

Alert Management (ALM) tool is a very effective way of expediting monitoring in XI. Within ALM, conditions for critical situations are predefined. When an alert is triggered in ALM that meets these conditions, responsible or interested parties are determined and informed. This decreases the pain of manual monitoring. The users can receive alerts as e-mail, SMS, and fax, if these external methods of communication are configured in SAP connect.

This document enables the developer to create an alert and trigger the alert using java mapping. Here the alert is sent as an email. Here we have triggered the alert from a RFC enabled function module. This function module is called from the java mapping.  

2.0 Business Requirements  

We had a requirement to retrieve product name from the product id. Product name is stored in a database (MYSQL) for the key field product id. If the product id is absent in the database then an alert will be triggered as an email. As the alert triggering function module is not a RFC enabled function module so we need to create a RFC enabled wrapper function module which will call the alert triggering function module (SALRT_CREATE_API). Both the product name lookup and triggering alert is handled by the java mapping.  

3.0 Methodology  

STEP 1 Create an alert category from transaction ALRTCATDEF. Define the container variables. Then write the message title and long text. Finally define the fixed alert recipients. Then go to transaction SCOT and configure the mail server (SMTP).

·         First create an alert category (Z_SABU_TEST_01) with transaction ALRTCATDEF.

·         Populate all the container variables needed in the alert email.  

·         Populate the long texts with the help of container variables created in the earlier step.  

·         Create the fixed recipients for the alert category and save the alert category.  


·         Go to transaction SCOT and configure the SMTP to send email for the alert.  

·         Double click on the SMTP and populate the mail host (IP or host name of the mail server) and mail port (by default it is 25).  

·         Click on the Set push button and enter email address.  

Click here to continue...


Please send us your feedback/suggestions at webmaster@SAPTechnical.COM 

HomeContribute About Us Privacy Terms Of Use • Disclaimer • SafeCompanies: Advertise on SAPTechnical.COM | Post JobContact Us  

Graphic Design by Round the Bend Wizards

footer image footer image