diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2020-04-10 09:09:39 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2020-04-10 09:09:39 +0000 |
commit | c52b81f45762cb7f05a950689dfc6d51b197ea73 (patch) | |
tree | c44830c2fc21d13b81814958c44b09fa8d11c805 /doc/user/project/integrations | |
parent | 187ee320b39af22929d74c5a2d9b0650bf50a09b (diff) | |
download | gitlab-ce-c52b81f45762cb7f05a950689dfc6d51b197ea73.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'doc/user/project/integrations')
-rw-r--r-- | doc/user/project/integrations/prometheus.md | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/doc/user/project/integrations/prometheus.md b/doc/user/project/integrations/prometheus.md index 273ab9095c0..4b07ecd2743 100644 --- a/doc/user/project/integrations/prometheus.md +++ b/doc/user/project/integrations/prometheus.md @@ -802,6 +802,22 @@ It is also possible to embed either the default dashboard metrics or individual ![Embedded Metrics in issue templates](img/embed_metrics_issue_template.png) +### Embedding metrics based on alerts in incident issues + +For [GitLab-managed alerting rules](#setting-up-alerts-for-prometheus-metrics-ultimate), the issue will include an embedded chart for the query corresponding to the alert. The chart displays an hour of data surrounding the starting point of the incident, 30 minutes before and after. + +For [manually configured Prometheus instances](#manual-configuration-of-prometheus), a chart corresponding to the query can be included if these requirements are met: + +- The alert corresponds to an environment managed through GitLab. +- The alert corresponds to a [range query](https://prometheus.io/docs/prometheus/latest/querying/api/#range-queries). +- The alert contains the required attributes listed in the chart below. + +| Attributes | Required | Description | +| ---------- | -------- | ----------- | +| `annotations/gitlab_environment_name` | Yes | Name of the GitLab-managed environment corresponding to the alert | +| One of `annotations/title`, `annotations/summary`, `labels/alertname` | Yes | Will be used as the chart title | +| `annotations/gitlab_y_label` | No | Will be used as the chart's y-axis label | + ### Embedding Cluster Health Charts **(ULTIMATE)** > [Introduced](<https://gitlab.com/gitlab-org/gitlab/issues/40997>) in [GitLab Ultimate](https://about.gitlab.com/pricing/) 12.9. |