796 Commits

Author SHA1 Message Date
f7eab21f9f Loki: Decouple data source plugin (#107242)
* WIP

* Update yarn.lock

* Align uuid dependency

* Add e2e test and update

* Update cue version

* Fix lint

* Update snapshot test

* Fix test that was importing from coupled module

* Fix lint

* Update public/app/plugins/datasource/loki/package.json

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>

---------

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
2025-06-27 15:09:45 +02:00
f8189eece9 Dashboard Imports: Fix creating new library panels (#107219) 2025-06-26 05:23:05 -06:00
b93cde0adb Alerting: Use default identifier for extra configs in Alertmanager API (#107049) 2025-06-26 12:44:49 +02:00
9a95430815 Provisioning: Increase timeout for flaky CreateGithubRepository integration test (#107091)
Increase timeout CreateGithubRepository test
2025-06-24 08:49:59 +00:00
63bc65fa4c Dashboards: Fix history list for dashboard uids that end in - (#107073) 2025-06-22 06:56:45 -06:00
ef6e28b955 K8s: Make v0alpha1 opt-in (#107056) 2025-06-20 16:37:17 -05:00
0b7e2f5601 K8s/Dashboards: Add mode 1, 2 to dashboard TestIntegrationValidation (#107018)
* Add mode 1 to dashboard TestIntegrationValidation
* Reject update with version conflict also in mode 1
* Add integration testing for mode 2
2025-06-20 13:11:26 +02:00
f0fab90072 Loki: Remove lokiSendDashboardPanelNames toggle (#106991) 2025-06-20 10:06:15 +02:00
700c9a857c Alerting: Return extra alertmanager config as a string for mimirtool (#106959) 2025-06-19 01:12:26 +02:00
4b46da9214 Alerting: Hide extra Prometheus configuration secrets (#106916) 2025-06-18 17:01:19 +02:00
426c334973 Alerting: API to create extra Alertmanager configurations (#106904)
What is this feature?

Implements the POST endpoint for deleting imported Mimir Alertmanager configurations:

    POST /api/convert/api/v1/alerts

The API endpoint creates the extra Alertmanager configuration with the provided identifier and matchers.
2025-06-18 15:05:06 +02:00
3cb62e370b Provisioning: Add pure git repository type (#106815)
* Add repository type git to spec
* Register git type
* Update test checks
2025-06-18 09:05:37 +02:00
dbe815ee68 SecretsManager: keepers with secure values credentials (#106761)
* SecretsManager: keepers with secure values

Co-authored-by: Matheus Macabu <macabu@users.noreply.github.com>
Co-authored-by: Dana Axinte <53751979+dana-axinte@users.noreply.github.com>

* Keepers: Refactor extract secure values remove extra helper functions

Co-authored-by: Matheus Macabu <macabu@users.noreply.github.com>

---------

Co-authored-by: Matheus Macabu <macabu@users.noreply.github.com>
2025-06-16 14:37:36 +01:00
0ae635974e App Platform Provisioning: Fix flaky test to assert dashboards deletion on repository deletion (#106753)
Use assert instead of require within eventually
2025-06-16 11:46:09 +02:00
6097841e67 SecretsManager: add secure value store (#106708)
* SecretsManager: add secure value model and sql templates

Co-authored-by: Matheus Macabu <macabu@users.noreply.github.com>
Co-authored-by: Dana Axinte <53751979+dana-axinte@users.noreply.github.com>
Co-authored-by: Leandro Deveikis <leandro.deveikis@gmail.com>
Co-authored-by: PoorlyDefinedBehaviour <brunotj2015@hotmail.com>

* SecretsManager: secure value rest layer to use store

Co-authored-by: Matheus Macabu <macabu@users.noreply.github.com>
Co-authored-by: Dana Axinte <53751979+dana-axinte@users.noreply.github.com>
Co-authored-by: Leandro Deveikis <leandro.deveikis@gmail.com>
Co-authored-by: PoorlyDefinedBehaviour <brunotj2015@hotmail.com>

* SecretsManager: temporary add actor prefix to decrypters

* Remove list securevalue by namefor now

---------

Co-authored-by: Matheus Macabu <macabu@users.noreply.github.com>
Co-authored-by: Leandro Deveikis <leandro.deveikis@gmail.com>
Co-authored-by: PoorlyDefinedBehaviour <brunotj2015@hotmail.com>
2025-06-16 10:19:44 +01:00
feeced9618 K8s: Dashboards /apis: Fix library element connections (#106734) 2025-06-13 21:40:39 +02:00
5f21f320f7 fix(unified-storage): use continue token containing both formats for dualwriter (#106525) 2025-06-13 15:59:46 +02:00
910eb1dd9e Security: apply patch 428 (#106710)
* declare dingding url as secret

patch raw settings before parsing because DingDing's config parser does not know about secrets

* fix integration test

---------

Co-authored-by: Yuri Tseretyan <yuriy.tseretyan@grafana.com>
2025-06-13 15:56:26 +02:00
f7a52bc04e Alerting: Fix group-level labels and query_offset in the import API (#106379)
What is this feature?

Fixes a bug when group-level query_offset and labels parameters are ignored and not saved

Why do we need this feature?

In the import API Prometheus YAML rule definitions are supported:

groups:
  - name: group-1
    interval: 1m
    query_offset: 10m
    labels:
      severity: "warning"
    rules:
      - alert: Alert 0 > 0
        expr: vector(0) > 0

But applying group-level labels and query_offset is broken and they are not saved right now because during the conversion of the API model to PrometheusRuleGroup they aren't saved to the new structure.
2025-06-06 11:21:39 +02:00
e256f2d5e2 Alerting: Enable recording rules by default (#105603) 2025-06-02 10:56:05 +02:00
edb0865caa Chore: Ensure we save correct default admin user in integration test DB setup (#105752)
* fix helper + amend tests

* fix import + remove unused var

* remove more users

* remove unused code

* update test comment
2025-05-28 11:25:01 +01:00
10f2b76156 Chore: Update apps codegen to v0.38.2 (#106111) 2025-05-28 12:35:44 +03:00
d4c446f42c Chore: Update k8s.io to v0.33.1 (#105307) 2025-05-28 00:13:18 +03:00
4f18ad30c9 SchemaV2: Remove legacy rows from schema v2. (#105238)
* save transparent setting

* make sure we test both transparent and non transparent

* no more legacy rows

* schema changes

* Add testing, fix first row offset

* Remove legacy row from transform test

* Remove panel that's not present in layout

* Remove expects after removing the row, fix lint issues

* Remove unused commit

* update codegen

* update openapi snapshot

* Fix snapshot

* add missing default prop

* Fix repeating, fix first row, fix not flushing last row

* Use correct repeater

* fix lint, remove unused empty check

* update codegen

* update openapi test snapshot
2025-05-26 14:33:30 +02:00
c4d3eb1cd0 Remove support for Google Spanner database. (#105846)
* Remove support for Google Spanner database.
2025-05-23 11:35:59 +02:00
7f2923d4ed SecretsManager: Introduce keeper store (#105557)
* SecretsManager: Introduce secret database wrapper

Co-authored-by: PoorlyDefinedBehaviour <brunotj2015@hotmail.com>
Co-authored-by: Leandro Deveikis <leandro.deveikis@gmail.com>
Co-authored-by: Dana Axinte <53751979+dana-axinte@users.noreply.github.com>
Co-authored-by: Matheus Macabu <macabu@users.noreply.github.com>

* SecretsManager: Introduce db migrator with keeper table

Co-authored-by: PoorlyDefinedBehaviour <brunotj2015@hotmail.com>
Co-authored-by: Leandro Deveikis <leandro.deveikis@gmail.com>
Co-authored-by: Dana Axinte <53751979+dana-axinte@users.noreply.github.com>
Co-authored-by: Matheus Macabu <macabu@users.noreply.github.com>

* SecretsManager: Introduce keeper store

Co-authored-by: Leandro Deveikis <leandro.deveikis@gmail.com>
Co-authored-by: Dana Axinte <53751979+dana-axinte@users.noreply.github.com>
Co-authored-by: Matheus Macabu <macabu@users.noreply.github.com>

* new line

* without query listByNameSecureValue

* remove unused extractSecureValues for now

* SecretsManager: Add keeper integration tests

Co-authored-by: Leandro Deveikis <leandro.deveikis@gmail.com>
Co-authored-by: Dana Axinte <53751979+dana-axinte@users.noreply.github.com>
Co-authored-by: Matheus Macabu <macabu@users.noreply.github.com>

---------

Co-authored-by: PoorlyDefinedBehaviour <brunotj2015@hotmail.com>
Co-authored-by: Leandro Deveikis <leandro.deveikis@gmail.com>
Co-authored-by: Matheus Macabu <macabu@users.noreply.github.com>
2025-05-22 14:26:47 +01:00
b1a6860f52 Dashboards: Schema V2 - Rename Annotations 'options' to 'legacyOptions' and Fix stale props (#105266)
* Rename Annotations 'Options' to 'legacyOptions'

* use new legacyOptions in StandardAnnotationQueryEditor

* use new legacyOptions in transformSaveModelSchemaToScene

* use legacyOptions in transformSceneToSaveModelSchemaV2

* Fix bug with ds query editors not taking the latest state

* update snapshot
2025-05-20 17:55:30 +02:00
03f1bb950b DashboardSchemaV2: add missing allowCustomValue property in variables (#105416)
* add missing allowCustomValue property to variables in schema V2

* fix K8s Codegen Check

* updade snapshots for backend tests
2025-05-20 11:50:46 +01:00
bdae4424e8 unified-storage: setup distributor module option A (#104737)
* setup distributor module

* move lifecycler into resource server provider

* remove ring/client pool setup from distributor module and use the same ring/client pool between storage server module and distributor module

* implement resourcestore server methods

* make healthcheck fail if ring is not running
2025-05-19 07:46:03 -04:00
c58ac15031 Alerting: Remove grafanaManagedRecordingRules feature flag (#105569) 2025-05-19 12:15:49 +02:00
002f46736a refactor(unified-storage): move generated protos to own pkg (#105356) 2025-05-15 21:36:52 +02:00
a32b379177 chore: correct links for jaeger data source (#105475)
* chore: correct links for jaeger data source

* Update plugin.json

* test fix attempt
2025-05-15 16:44:36 +01:00
7d0f73058b api/admin: Reenable AdminApiReencrypt tests, fix enterprise version of the test. (#105462)
* Reenable tests. Fix access to "key" column when using mysql.
2025-05-15 16:25:30 +02:00
ba111e612b Skip TestIntegration_AdminApiReencrypt. (#105454)
* Skip TestIntegration_AdminApiReencrypt and TestIntegration_AdminApiReencrypt_Enterprise.
2025-05-15 11:38:42 +00:00
7268d6c1bc admin api: Fix reencryption of private_key in signing_key table, introduce test for reencryption (#105010)
* Add integration test for reencrypting secrets.
Rotate keys before reencryption.
Test for setting table from enterprise repo.
2025-05-15 09:51:25 +02:00
441fa18590 Chore: Update golang.org/x/ and do not omitempty Items (#105371)
* deps and omitempty Items

* update apis
2025-05-14 14:31:45 +03:00
9fe523b9e6 Alerting: API to pause all alert rules in a folder (#104674) 2025-05-13 17:04:01 +02:00
c17b019ab1 Alerting: Support simplified routing receivers in Prometheus conversion API (#105135)
Adds ability to set notifications settings using the Prometheus conversion API.

The API now supports a new optional header: X-Grafana-Alerting-Notification-Settings which can be used to specify notification settings.

The value of the header is the AlertRuleNotificationSettings structure in JSON:
mimirtool rules load alerts.yaml --extra-headers 'X-Grafana-Alerting-Notification-Settings: {"receiver": "my-webhook", "group_by": ["cluster", "pod"]}'
2025-05-12 22:07:02 +02:00
0ceea29787 Alerting: Remove alertingSimplifiedRouting feature toggle (#104980)
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2025-05-09 16:30:56 +03:00
c78ae5cb76 Alerting: Move alerting codegen to --grouping=group (#105068) 2025-05-08 12:59:33 +00:00
3e2296acd3 Alerting: Support for active time intervals in notification policies (#104252)
* add active_time_intervals to route model

* update k8s compat layer

* update notification policies service to validate active time intervals

* update integration tests

* update openapi

* add active time interval to model

* update route generator to include active time interval

* Update storage list and rename methods to handle active intervals

* update api model

* update provisioning and export models

* update ui to allow active timing config

* update i18n

* fix snapshots for ui tests

* run prettier

* Alerting: Active time intervals UI naming (#104402)

* update naming in UI

* update naming in the edit page title

* update translations

* update alerting module

---------

Signed-off-by: Yuri Tseretyan <yuriy.tseretyan@grafana.com>
Co-authored-by: Sonia Aguilar <33540275+soniaAguilarPeiron@users.noreply.github.com>
Co-authored-by: Sonia Aguilar <soniaaguilarpeiron@gmail.com>
2025-05-07 19:19:33 -04:00
85344e30c0 Alerting: Migrate notifications API to app-platform SDK application (#104424)
* introduce alerting notification app
* move code as is and remove from old registry
* update api server registration
* update make file and remove unnecessary args, copy some useful make commands from dashboards
* update codeowners

* move constants inside module and remove dependency from grafana
* add support for selectors to the app builder
2025-04-30 10:23:56 -04:00
129e8bb1e4 Dashboards: Fix moving to general folder (#104655) 2025-04-30 03:03:57 +03:00
4adebd6058 unified-storage: setup ring to shard requests (#103783)
* Updates the instrumentation_server service to use mux instead of the builtin router, and have it store the router in the module server: this is so we can register the /ring endpoint to check the status of the ring
* Create a new Ring service that depends on the instrumentation server and declares it as a dependency for the storage server
* Create standalone MemberlistKV service for Ring service to use
* Update the storage server Search and GetStats handler to distribute requests if applicable
2025-04-25 13:08:44 -04:00
43d0053c80 K8s: Dashboards: Fix transformation between v1 and v2 (#104502) 2025-04-25 05:06:49 -06:00
109267ab03 Alerting: Remove feature toggle for custom recovery threshold (#104455) 2025-04-24 11:58:17 -04:00
2e51096eb4 Provisioning: Export dashboards with conversion errors (#104369) 2025-04-24 14:16:25 +01:00
edeff68645 Advisor: Allow to retry checks for a single element (#104279) 2025-04-24 12:00:32 +02:00
faa33e30a9 Schema: Add origin property to AdHocFilterWithLabels (#104320)
* add origin to AdHocFilterWithLabels

* typo

* fix

* use singular for FilterOrigin

* run ./hack/update-codegen.sh

* add canary scenes to verify typechecks

* update dashboard schema json snapshot

* fix

* fix

* update canaries

* fix

* bump scenes version
2025-04-24 11:13:17 +03:00
9f07e49cdd Alerting: Add extended definition to prometheus alert rules api (#103320)
* Alerting: Add extended definition to prometheus alert rules api

This adds `isPaused` and `notificationSettings` to the paginated rules api to enable the paginated view of GMA rules.

refactor: make alert rule status and state retrieval extensible

This lets us get status from other sources than the local ruler.

* update swagger spec

* add safety checks in test
2025-04-23 21:14:09 +01:00