Add missing doc for events alarm metrics name (#7029)

This commit is contained in:
Zhenxu 2021-05-27 21:07:40 +08:00 committed by GitHub
parent 68b918e3cd
commit c563245048
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 29 additions and 7 deletions

View File

@ -103,8 +103,25 @@ however, you can use the methods in [How to Report Events](#how-to-report-events
## Known Events
| Name | Type | When |
| :----: | :----: | :-----|
| Start | Normal | When your Java Application starts with SkyWalking Agent installed, the `Start` Event will be created. |
| Shutdown | Normal | When your Java Application stops with SkyWalking Agent installed, the `Shutdown` Event will be created. |
| Alarm | Error | When the Alarm is triggered, the corresponding `Alarm` Event will is created. |
| Name | Type | When | Where |
| :----: | :----: | :-----| :---- |
| Start | Normal | When your Java Application starts with SkyWalking Agent installed, the `Start` Event will be created. | Reported from SkyWalking agent. |
| Shutdown | Normal | When your Java Application stops with SkyWalking Agent installed, the `Shutdown` Event will be created. | Reported from SkyWalking agent. |
| Alarm | Error | When the Alarm is triggered, the corresponding `Alarm` Event will is created. | Reported from internal SkyWalking OAP. |
The following events are all reported
by [Kubernetes Event Exporter](http://github.com/apache/skywalking-kubernetes-event-exporter), in order to see these
events, please make sure you have deployed the exporter.
| Name | Type | When | Where |
| :----: | :----: | :-----| :---- |
| Killing | Normal | When the Kubernetes Pod is being killing. | Reporter by Kubernetes Event Exporter. |
| Pulling | Normal | When a docker image is being pulled for deployment. | Reporter by Kubernetes Event Exporter. |
| Pulled | Normal | When a docker image is pulled for deployment. | Reporter by Kubernetes Event Exporter. |
| Created | Normal | When a container inside a Pod is created. | Reporter by Kubernetes Event Exporter. |
| Started | Normal | When a container inside a Pod is started. | Reporter by Kubernetes Event Exporter. |
| Unhealthy | Error | When the readiness probe failed. | Reporter by Kubernetes Event Exporter. |
The complete event lists can be found
in [the Kubernetes codebase](https://github.com/kubernetes/kubernetes/blob/v1.21.1/pkg/kubelet/events/event.go), please
note that not all the events are supported by the exporter for now.

View File

@ -21,7 +21,8 @@ Defines the relation between scope and entity name.
An alarm rule is made up of the following elements:
- **Rule name**. A unique name shown in the alarm message. It must end with `_rule`.
- **Metrics name**. This is also the metrics name in the OAL script. Only long, double, int types are supported. See the
[list of all potential metrics name](#list-of-all-potential-metrics-name).
[list of all potential metrics name](#list-of-all-potential-metrics-name). Events can be also configured as the source
of alarm, please refer to [the event doc](../../concepts-and-designs/event.md) for more details.
- **Include names**. Entity names which are included in this rule. Please follow the [entity name definitions](#entity-name).
- **Exclude names**. Entity names which are excluded from this rule. Please follow the [entity name definitions](#entity-name).
- **Include names regex**. A regex that includes entity names. If both include-name list and include-name regex are set, both rules will take effect.
@ -129,7 +130,11 @@ For convenience's sake, we have provided a default `alarm-setting.yml` in our re
1. Endpoint relation average response time over 1s in the last 2 minutes.
### List of all potential metrics name
The metrics names are defined in official the [OAL scripts](../../guides/backend-oal-scripts.md). Currently, metrics from the **Service**, **Service Instance**, **Endpoint**, **Service Relation**, **Service Instance Relation**, **Endpoint Relation** scopes could be used in Alarm, and the **Database access** scope is same as **Service**.
The metrics names are defined in the official [OAL scripts](../../guides/backend-oal-scripts.md) and
[MAL scripts](../../concepts-and-designs/mal.md), the [Event](../../concepts-and-designs/event.md) names can also serve
as the metrics names, all possible event names can be also found in [the Event doc](../../concepts-and-designs/event.md).
Currently, metrics from the **Service**, **Service Instance**, **Endpoint**, **Service Relation**, **Service Instance Relation**, **Endpoint Relation** scopes could be used in Alarm, and the **Database access** scope is same as **Service**.
Submit an issue or a pull request if you want to support any other scopes in alarm.