You can create an alert notification template to customize the titles and content of alert notifications and alert resolution notifications.
Procedure
Log in to the OceanBase Cloud console.
In the left-side navigation pane, click Alerts.
On the Alert Management page, click More, and then click Notification templates.
On the Notification templates tab, click Create notification template.
Configure the alert notification template.
ParameterDescriptionTemplate Name Specifies the name of the alert notification template. Notification Method Specify the alert notification method. Supports email, DingTalk, Lark, Telegram, and custom webhooks. Alert Notification Template Title The title displayed in alert notifications. Specify it when you select email or DingTalk. The title can contain up to 50 characters; any excess is truncated. Use placeholders such as ${AlertName}to insert variables.AlertNamerepresents the alert name.Note
The 50-character limit includes variable values after substitution.
Alert Notification Template Content The content displayed in an alert notification. The maximum length of the content is 500 characters. Any excess will be truncated. Use placeholders such as ${AlertName}to insert variables.AlertNamerepresents the alert name. For more information about the supported variables, see Alert variables.Note
The 500-character limit includes variable values after substitution.
Alert Resolution Notification Template Title The title displayed in alert resolution notifications. Specify it when you select email or DingTalk. The title can contain up to 50 characters, and any excess will be truncated. Use placeholders such as ${AlertName}to insert variables.AlertNamerepresents the alert name.Note
The 50-character limit includes variable values after substitution.
Alert Resolution Notification Template Content The content displayed in the alert resolution notification. The maximum length of the content is 500 characters. Any excess will be truncated. Use placeholders such as ${AlertName}to insert variables.AlertNamerepresents the alert name. For more information about the supported variables, see Alert variables.Note
The 500-character limit includes variable values after substitution.
Click Create.
Alert variables
The following variables are supported in alert notifications:
Variable |
Description |
|---|---|
| ${AlertName} | The alert name. |
| ${AlertLevel} | The alert level. |
| ${MetricNames} | The names of the alert metrics. |
| ${AlertStartTime} | The time when the alert was triggered. |
| ${AlertUpdateTime} | The most recent alert time. |
| ${AlertCloseTime} | The time when the alert was resolved. Used in alert resolution notifications. |
| ${AlertResourceInfo} | Information about the alert object. |
| ${MViewInfo} | Materialized view information for alerts about incremental refresh delays or errors in a tenant. A single view is displayed as db_name.mv_name, and multiple views in the same database as db_name.mv_a,mv_b. If the database name is unavailable, only the view names are displayed. If no view information is available, - is displayed. |
| ${AlertSummary} | The alert summary. |
| ${AlertDescription} | The alert description. |
| ${AlertDetailUrl} | The URL of the alert details page. |