Docs: Update with annotations filtering and time regions (#68591)

This commit is contained in:
Adela Almasan 2023-05-22 11:24:32 -05:00 committed by GitHub
parent 108acee08e
commit e42c3ee55e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -78,6 +78,22 @@ In Grafana v5.3+ it's possible to use template variables in the tag query. So if
{{< figure src="/static/img/docs/annotations/annotation_tag_filter_variable-8-1-0.png" max-width="600px" >}}
### Filter by panel
You can configure which panels to apply annotations to by choosing an option from the _Show in_ section. You can apply the annotations to `All panels` that support annotations, or filter specific panels by choosing `Selected panels` or `All panels except`. The annotations will be displayed accordingly.
{{< figure src="/media/docs/grafana/screenshot-grafana-10-0-annotation-filtering.png" max-width="600px" caption="Annotation filtering" >}}
### Add time region
When adding or editing an annotation, you can define a repeating time region by setting _Query type_ to `Time regions` - simply define the _From_/_To_ sections with the preferred days of the week and time. You also have the possibility to change the timezone - the default being set to dashboard's timezone.
{{< figure src="/media/docs/grafana/screenshot-grafana-10-0-time-regions-annotations.png" max-width="600px" caption="Time regions business hours" >}}
The above configuration will produce the following result in the Time series panel:
{{< figure src="/media/docs/grafana/screenshot-grafana-10-0-timeseries-time-regions.png" max-width="600px" caption="Time series time regions business hours" >}}
## Querying other data sources
Annotation events are fetched via annotation queries. To add a new annotation query to a dashboard