When an alarm triggers in Analytics, the following events occur:
Information about the alarm is recorded and displays in the Status tab of Analytics.
If enabled, an alarm notification is sent to the recipients you configured to receive them. The notification is sent as an email or SMS (text) or both.
You can set the type of notification the alarm sends out by changing the settings under each resource or by setting up default alarms that affect all the resources of a particular type, for example, ArcGIS Servers.
There are several types of alarm notifications:
Email: Sends an email message to a specified set of recipients using a specified SMTP server. You can send alarm messages to multiple emails.
SMS: Sends a text message to a specified set of recipients using a Twilio account. You can send alarm messages to multiple phone numbers using the same Twilio account.
If you want recipients to receive email or SMS notifications when Analytics alarms trigger, you need to configure a list of alarm recipients under System in Configuration on the Alarm Recipients tab. You can configure a recipient to receive all notifications, or under each resource on the Alarm tab, you can select particular recipients to receive specific alarms. You need to provide email addresses or SMS details for each recipient.
For more information, see Configure Alarm Recipients
In addition to the list of alarm recipients, you also need to set up an SMTP email host and a Twilio account for Analytics to use when it sends emails or texts to alarm recipients. You use only one SMTP email host and a one Twilio account (Twilio website) to send notifications to multiple emails or phones.
For more information, see Configure Email Settings, Configure SMS Settings.
When Analytics sends notifications for triggered alarms, it uses template files to generate the notifications. These template files can be edited to customize the notifications that are sent out or to translate the notifications into another language.
The templates can be found within the Geocortex Core installation folder; the default location is:
C:\Program Files\Latitude Geographics\Geocortex Core\Data\Analytics.ResourceCollector\AlarmTemplates
Both the email and SMS templates are in the AlarmTemplates
folder under the Email
and SMS
folders respectively.
All the templates support a variety of replacement tokens. The replacement tokens are used to indicate where dynamic values need to be inserted in the template.
There are three different types of templates: Alarms, Resources, and Generic.
All the different template files combine in different ways depending on the resource and alarms that need to be sent in the notification.
If you want to preview your notification changes, in Configuration | System | Email Settings, use the Send Sample Notification to Recipient feature. For more information, see Configure Email Settings.
When a template file is deleted, it will be rewritten to the file system when the template needs to be used. You can delete a template file to return it to default settings.
SMS templates tend to have less information in them to ensure text message limits are not exceeded.
Do not change any of the file names or extensions of the template files. Changing a file name will result in Analytics generating a new default template file and using the new file instead.
Email templates consist of HTML files and text files. The HTML files are used for the content of the email notification while the text files (.subject.template
) are used for the subject line of the email.
Because the HTML templates are designed to support a wide range of email clients, we recommend you leave the HTML in the files as is and only change the wording of the templates.
For email templates, there are at least two files for each alarm type, an HTML file for the alarm content portion of the email and a subject.template
file used to generate the alarm portion of the subject line for the email notification.
For SMS templates, there is at least one template file for each alarm type.
Some alarm types are separated into multiple templates to accommodate how the alarm can trigger. For example, the Request Failure Alarm has additional template files for when a web exception triggers the alarm or when it triggers due to a parsing error.
The email .subject.template
file and the SMS .template
file are both text files and can be opened in any text editor.
The following is a list of replacement tokens that are supported by alarm templates.
Token |
Description |
Alarm Types |
---|---|---|
|
The date that the alarm triggered. |
All. |
|
The value that triggered the alarm. |
All except Request Failure Alarm. |
|
The configuration value the alarm was set to when the alarm triggered. |
All except Windows Performance Alarm, Request Failure Alarm, Server Down Alarm. |
|
The name given to the alarm. |
Windows Performance Alarm. |
|
The number of times the alarm had to meet the configured criteria to trigger. |
Request Failure Alarm, Response Time Alarm, Memory Usage Alarm, CPU Usage Alarm, Windows Performance Alarm. |
|
The minimum configuration value the alarm had to fall under to trigger the alarm. |
Windows Performance Alarm. |
|
The maximum configuration value the alarm had to exceed to trigger the alarm. |
Windows Performance Alarm. |
|
The response received from the web request. Only the first 500 characters are shown. |
Request Failure Alarm, Content Match Alarm. |
|
The status code of the returned response from the web request as its text representation. |
Request Failure Alarm. |
|
The status code of the returned response from the web request. |
Request Failure Alarm. |
|
The web exception type that occurred when sending the web request. |
Request Failure Alarm. |
For email templates, there are at least two files for each resource type, an HTML file for the resource content portion of the email and a subject.template
file used to generate the resource portion of the subject line for the email notification.
For SMS templates, there is at least one template file for each resource type.
The following is a list of replacement tokens that are supported by resource templates.
Token |
Description |
Alarm Types |
---|---|---|
|
The name of the resource as it is displayed in Analytics. |
All. |
|
The URL to the resource. |
All web-based resources, for example, ArcGIS Server, services, Essentials, Websites, and so on. |
The default template file for notifications is Default.template
. It provides the type of information to be included in the notification and the order that the information should be presented in. The file itself is a text file and consists solely of short codes. Each short code represents a general type of information, that is, Alarms or Resource information.
Not all short codes need to be included in the Default.template
file, for example, the Default.template
for SMS messages does not include the [AnalyticsLink]
short code by default.
Short Code |
Description |
---|---|
|
The information about the resource that the alarm triggered for. |
|
The alarms that triggered. |
|
A link to the Analytics reports interface. This link can be configured in the System Global Settings configuration. |
This file determines the format of how the link to Analytics is displayed in a notification. It supports a single replacement token: {{analytics-link}}
.
This file is the main wrapper for the entire notification. It supports a single replacement token: {{main}}
.
There is also a corresponding CoreTemplate file for an email notification’s subject line.
The {{main}}
replacement token’s content is the result of the Default.template
.