API Gateway: Setting up Alerts/Notifications

book

Article ID: 191737

calendar_today

Updated On:

Products

CA API Gateway API SECURITY STARTER PACK-7

Issue/Introduction

I need help setting up the alerts/notification in the CA API Gateway so that if some service does not run, I get a notification.

Environment

API Gateway: 9.3+

Resolution

======================= 
CONFIGURE: SEND EMAIL POLICY 
======================= 
1. Login to the Policy Manager 
2. Create a new policy – give it a meaningful name for easy identification
3. From the Policy Type dropdown, select Policy-Backed Service Operation Policy Fragment
4. From the Policy Tag dropdown, select com.l7tech.objectmodel.polback.BackgroundTask
5. Click [OK]


======================= 
CREATE: SEND EMAIL POLICY 
======================= 
1. Import the emailGWMetricsSimple.xml
2. Open the Get Gateway Metrics Assertion and select the service you want to receive email on
3. For the Variable Prefix, for easy identification, use the name of the service
4. For each RegEx assertion, replace 'servA' with the name of the service - DO NOT remove the .document
5. For the Send Email assertion, fill out the required fields
6. In the body of the email, replace 'servA' with the name of the service - DO NOT remove the .document
7. Click [Save and Activate]
NOTE: If you want multiple emails for multiple services, duplicate the assertions and update them according to the instructions in this section.

======================= 
CREATE: SCHEDULED TASK
======================= 
1. Go to Tasks > Global Settings > Manage Scheduled Tasks
2. Click [Add]
3. For the Job Name, provide a name for the task - i.e. For easy identification, give it the same name as the policy
4. For the Gateway Node parameter, if you have a gateway cluster, select One Node (this task should run on the primary gateway node) - this should prevent the duplicate emails
5. Select the frequency that you want the task to be executed
6. Click [OK]

Attachments

1590675178010__emailGWMetricsSimple.xml get_app