grafana/pkg
Matthew Jacobson ba3994d338
Alerting: Repurpose rule testing endpoint to return potential alerts (#69755)
* Alerting: Repurpose rule testing endpoint to return potential alerts

This feature replaces the existing no-longer in-use grafana ruler testing API endpoint /api/v1/rule/test/grafana. The new endpoint returns a list of potential alerts created by the given alert rule, including built-in + interpolated labels and annotations.

The key priority of this endpoint is that it is intended to be as true as possible to what would be generated by the ruler except that the resulting alerts are not filtered to only Resolved / Firing and ready to be sent.

This means that the endpoint will, among other things:

- Attach static annotations and labels from the rule configuration to the alert instances.
- Attach dynamic annotations from the datasource to the alert instances.
- Attach built-in labels and annotations created by the Grafana Ruler (such as alertname and grafana_folder) to the alert instances.
- Interpolate templated annotations / labels and accept allowed template functions.
2023-06-08 18:59:54 -04:00
..
api Plugins: Account for nil user when constructing plugin context (#69811) 2023-06-08 19:36:41 +03:00
build Docker: Add ARM64 architecture for Docker, for PRs (#68295) 2023-06-07 17:17:15 +03:00
bus Chore: Fix goimports grouping in other backend platform packages (#62422) 2023-01-30 08:26:42 +00:00
cmd Plugins: Standardize Golang enum naming convention (#69449) 2023-06-08 12:21:19 +02:00
codegen Chore: Hacky first pass on generating composable kinds within grafana/schema (#64723) 2023-05-30 05:56:18 -07:00
components ApiKeyGenPrefix: rename package (#65623) 2023-03-30 17:04:10 +02:00
cuectx Chore: Hacky first pass on generating composable kinds within grafana/schema (#64723) 2023-05-30 05:56:18 -07:00
events Alerting: Update rules version when folder title is updated (#53013) 2022-08-01 19:28:38 -04:00
expr Plugins: Refactor creation of plugin context to dedicated service (#66451) 2023-06-08 13:59:51 +02:00
extensions Deps: Replace go-jose v2 with go-jose v3 (#64228) 2023-03-06 15:12:51 +01:00
ifaces/gcsifaces Chore: Upgrade Go to 1.19.1 (#54902) 2022-09-12 12:03:49 +02:00
infra Plugins: Standardize Golang enum naming convention (#69449) 2023-06-08 12:21:19 +02:00
kinds Schema: Improve Dashboard kind docs and remove deprecated props (#69359) 2023-06-06 14:28:10 +02:00
kindsysreport Chore: update user-essentials to frontend-platform (#69533) 2023-06-05 12:24:17 +01:00
login Chore: Adding "allowed_groups" Configuration Parameter to Generic OAuth Method (#69025) 2023-05-30 11:07:04 +02:00
middleware RBAC: Remove legacy ac from authorization middleware (#68898) 2023-05-24 09:49:42 +01:00
mocks/mock_gcsifaces Chore: Fix goimports grouping in other backend platform packages (#62422) 2023-01-30 08:26:42 +00:00
models Auth: Add feature flag to move token rotation to client (#65060) 2023-03-23 14:39:04 +01:00
modules Chore: Add initial support for deployment modes (#63992) 2023-03-06 14:06:52 -05:00
plugins Plugins: Standardize Golang enum naming convention (#69449) 2023-06-08 12:21:19 +02:00
registry Schema: Remove ServiceAccount kind (#69194) 2023-06-01 07:02:17 -07:00
server Pyroscope: Rename phlare to grafana-pyroscope-datasource (#68859) 2023-06-07 06:09:29 +03:00
services Alerting: Repurpose rule testing endpoint to return potential alerts (#69755) 2023-06-08 18:59:54 -04:00
setting Auth: Use auth broker by default (#69620) 2023-06-07 08:57:41 +02:00
tests Alerting: Repurpose rule testing endpoint to return potential alerts (#69755) 2023-06-08 18:59:54 -04:00
tsdb CloudWatch: Add missing AWS/FSx metrics (#69816) 2023-06-08 21:44:28 +00:00
util Util: Fix panic when generating UIDs concurrently (#69476) 2023-06-05 11:21:11 +02:00
web Alerting: Add limits and filters to Prometheus Rules API (#66627) 2023-04-17 17:45:06 +01:00
README.md Chore: Move all backend contribution documents to a single directory (#61140) 2023-01-11 11:16:52 +01:00
ruleguard.rules.go Chore: update all +build statements (#38782) 2021-09-01 17:38:56 +03:00

This directory contains the code for the Grafana backend.

The contributor documentation for Grafana's backend is in /contribute/backend/README.md.