Commit Graph

11407 Commits

Author SHA1 Message Date
Ivana Huckova
c40bc0665b
Elasticsearch: Add instrumentation for elasticsearch_plugin_parse_response_duration_seconds (#75628)
* Elasticsearch: Add instrumentation for elasticsearch_plugin_parse_response_duration_seconds

* Update error tracking
2023-09-28 18:38:14 +03:00
Ivana Huckova
5510a0d8d1
Loki: Add instrumentation for grafana_loki_plugin_parse_response_duration_seconds_bucket (#75570)
* Add metric for loki parsing response duration

* Rename and add exemplars

* Fix lint
2023-09-28 17:25:09 +02:00
Gabriel MABILLE
6ffd4a23de
Team: Support sort query param for teams search endpoint (#75622)
* Teams: Implement backend sorting

* Add docs

* Make name ordering case insensitive

* lint

* Fix no lowercasing on memberCount

* Add test to double check the filters or correctly OrderBy
2023-09-28 18:20:51 +03:00
Karl Persson
fd2235b5ad
AuthN: Implement requester interface for identity (#75618)
* AuthN: Implement identity.Requester interface for authn.Identity

* AuthN: Replace OrgRole with GetOrgRole

* IDForwarding: skip converting to SignedInUser

* Pass identity directly in permission sync hook
2023-09-28 16:37:32 +02:00
Sonia Aguilar
169c5262a5
Alerting: Add Modify export feature for Grafana-managed alert rules (#75114)
* Initial POC for modified rule expor

* Add rule and group export options to modified export

* Add feature toggle for modifier export

* Rename GrafanaRuleDesigner to ModifyExportRuleForm to identify it easily as a rule form

* Refactor naming and folder for RuleDesigner => ModifyExport

* Don't render more action drop-down button when no more actions are allowed

* Redirect cancel button to alert list view

* Fix modify export page being reloaded correctly without errors

* Fix test

* Protect modify-export route when toggle-feature is not enabled

* Fix css betterer error

* Address pr review coments

---------

Co-authored-by: Konrad Lalik <konrad.lalik@grafana.com>
2023-09-28 16:07:45 +02:00
Orgad Shaneh
b0b2158dea
Chore: Update ubuntu image to 22.04 (#70719) 2023-09-28 08:48:41 -05:00
Sergey Kostrukov
3ee40d3a5a
Azure: Settings for Azure AD Workload Identity (#75283)
* Settings for Azure AD Workload Identity

* Update dependency on Grafana Azure SDK

* Documentation

* Fix JS code

* Cleanup Prometheus backend code

* Making prettier happy
2023-09-28 12:05:16 +01:00
Gabriel MABILLE
969e6a17ba
Plugins: Rename oauth package to auth (#75611)
* Plugins: Rename oauth package to auth

* Missed one comment
2023-09-28 12:18:09 +02:00
Gabriel MABILLE
96cbe70b14
User: Support sort query param for user and org user, search endpoints (#75229)
* User: Add sort option to user search

* Switch to an approach that uses the dashboard search options

* Cable user sort on the org endpoint

* Alias user table with u in org store

* Add test and cover orgs/:orgID/users/search endpoint

* Add test to userimpl store

* Simplify the store_test with sortopts.ParseSortQueryParam

* Account for PR feedback

* Positive check

* Update docs

* Update docs

* Switch to ErrOrFallback

Co-authored-by: Karl Persson <kalle.persson@grafana.com>

---------

Co-authored-by: Karl Persson <kalle.persson@grafana.com>
2023-09-28 10:16:18 +02:00
Gabriel MABILLE
4563fc48af
FeatureToggle: Add a feature toggle for automatic service account and token setup (#75560)
Add a feature toggle for automatic service account and token setup
2023-09-28 09:26:37 +02:00
Karl Persson
b9b4246432
IDForwarding: Add auth hook to generate id token (#75555)
* AuthN: Move identity struct to its own file

* IDForwarding: Add IDToken property to usr and identity structs and add GetIDToken to requester interface

* Inject IDService into background services

* IDForwarding: Register post auth hook when feature toggle is enabled
2023-09-28 09:22:05 +02:00
Sofia Papagiannaki
3a1c3be057
Chore: Log failures during provisioning initialization (#75550)
Provisioning: Log failures
2023-09-28 10:00:36 +03:00
Daniel Lee
33a32df47b
imagestorage: fix templating of public_url option for webdav (#74885)
* spelling in error message

* imguploader: fix template for webdav url

Since a few years ago, when loading the config file, the  template gets replaced in the expanding
env var phase (see ##25075) and introduced a bug in the webdav public_url config option. This commit
changes the template syntax to be {{file}}. This doesn't get expanded and removed when the config file
is loaded.

* devenv: add a block for a WebDAV server

* Adding alerting as codeowners for webdav

---------

Co-authored-by: Timur Olzhabayev <timur.olzhabayev@grafana.com>
2023-09-28 00:35:10 +03:00
Ryan McKinley
bbdd1fc3b1
Playlist: Remove unused/deprecated api and unused wrapper (#75503) 2023-09-27 15:28:16 +00:00
Isabella Siu
06a35f55ac
CloudWatch: Correctly add dimension values to labels (#74847)
Co-authored-by: Shirley <4163034+fridgepoet@users.noreply.github.com>
2023-09-27 10:41:48 -04:00
Karl Persson
b50f1e15a8
IDForwarding: Add service and a local signer (#75423)
* IDForwarding: Add service for handling id token and create a local signer
---------

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
2023-09-27 11:36:23 +02:00
Gabriel MABILLE
0ed649b108
AuthN: Change EnableDisabledUserHook to EnableUserHook (#75248)
* Replace the enable disable user hook by a hook that systematically enable users

* Fix tests

* Remove the skip test
2023-09-27 11:16:53 +02:00
Marcus Efraimsson
0128d0403f
Tracing: Use tracing.InitializeTracerForTest (#75479) 2023-09-27 09:51:57 +02:00
Andres Martinez Gotor
af8a46adbb
Bug Fix: Restore health check error (#75508) 2023-09-27 10:44:43 +03:00
Todd Treece
bb9e66e671
K8s: Add storage dual writer (#75403) 2023-09-26 17:15:15 -04:00
Carl Bergquist
8d62ed77f0
instrumentation: set slogroup high-fast for more handlers (#75449)
Signed-off-by: bergquist <carl.bergquist@gmail.com>
2023-09-26 19:11:29 +02:00
Kevin Minehart
edc36d3948
CI: check /tmp/grafana-enterprise; don't fail if rev-parse fails (#75480)
check /tmp/grafana-enterprise; don't fail if rev-parse fails
2023-09-26 20:09:18 +03:00
Yuri Tseretyan
237ce5ea82
Alerting: Extract methods for fetching rule groups with authorization (#75375)
* extract methods for fetching rule groups with authorization and refactor the request handlers.
* add logging to delete handler
2023-09-26 12:45:22 -04:00
Dimitris Sotirakis
1867fc5cee
Arm: Exclude armv6/v7 from downstream builds only (#75465)
* Bump grabpl

* Disable armv6 and armv7 in downstream builds
2023-09-26 18:42:06 +03:00
Andres Martinez Gotor
c129c0cd39
Chore: Allow to compile testdata backend as a plugin (#75360) 2023-09-26 15:30:25 +02:00
Marcus Efraimsson
534e3ebf0c
Plugins: Use a Grafana specific SDK tracer implementation for core plugins (#75388) 2023-09-26 14:46:31 +02:00
Giordano Ricci
1aa911dee6
Correlations: improve test (#75370)
* Correlations: improve test

* re-add err check
2023-09-26 12:21:24 +01:00
Todd Treece
440f9a6ffb
K8s: Register apiserver as background service, and list real playlists (#75338)
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2023-09-25 15:31:58 -07:00
Sijmen
60922e5f77
Cloudwatch: Add missing AWS regions (#75392) 2023-09-25 17:13:46 -04:00
Kat Yang
9532ff3799
Chore: Split OSS and Enterprise OAPI Spec Generation (#75133)
* chore: implement sofia makefile changes from #62456

* chore: clean up makefile and generate specs

* docs: update command to delete old specs

* fix: regenerate specs with enterprise linked

* chore: implement review comments

* Update Makefile

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>

* chore: update make command in drone step

* chore: update bingo, fix makefile indentation error, regen specs

* fix: revert .bingo/README changes to make prettier happy

* chore: add BEP as owners of api-enterprise-spec.json

* chore: rerun drone

---------

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>
2023-09-25 15:34:57 -04:00
Sarah Zinger
ef441f02d0
Cloudwatch: Fix Unexpected error (#74420)
Fix unexpected error when creating a new cloudwatch datasource.

Involves a fair amount of refactoring, so if this causes unexpected issues related to region fetching we can turn this off with the cloudwatchNewRegionsHandler feature toggle, although we do not predict it will so we are enabling it to default to true and hope to remove it shortly.
2023-09-25 14:19:12 -04:00
João Calisto
7e1b45ba31
Feature Toggles API: Trigger webhook call when updating (#75254)
* Feature Toggles API: Trigger webhook call when updating

* update status code error check

* lint - handle Close() error

* Rename update webhook config

* fix tests
2023-09-25 19:11:24 +01:00
Karl Persson
d15661c726
IDForwarding: Add toggle for id forwarding (#75378)
Features: Add toogle for id forwarding
2023-09-25 18:21:28 +03:00
Jo
40a1f8434d
Anon: Scaffold anon service (#74744)
* remove API tagging method and authed tagging

* add anonstore

move debug to after cache

change test order

fix issue where mysql trims to second

* add old device cleanup

lint

utc-ize everything

trim whitespace

* remove dangling setting

* Add delete devices

* Move anonymous authnclient to anonimpl

* Add simple post login hook

* move registration of Background Service

cleanup

* add updated_at index

* do not untag device if login err

* add delete device integration test
2023-09-25 16:25:29 +02:00
Andres Martinez Gotor
ece94b1e01
Chore: Remove plugincontext.ErrPluginNotFound (#74997) 2023-09-25 13:10:47 +03:00
Andres Martinez Gotor
1714fa598c
Chore: Refactor backend plugin errors (#74928) 2023-09-25 11:56:03 +02:00
gotjosh
59694fb2be
Alerting: Don't use a separate collection system for metrics (#75296)
* Alerting: Don't use a separate collection system for metrics

The state package had a metric collection system that ran every 15s updating the values of the metrics - there is a common pattern for this in the Prometheus ecosystem called "collectors".

I have removed the behaviour of using a time-based interval to "set" the metrics in favour of a set of functions as the "value" that get called at scrape time.
2023-09-25 10:27:30 +01:00
Ryan McKinley
e72b5c54f8
K8s/Playlist: Isolate apiGroup from server (#75321) 2023-09-22 18:29:43 -07:00
Todd Treece
0f398e940d
K8s: Playlist API example (#75260)
K8s: Playlist example
2023-09-22 14:17:53 -04:00
ismail simsek
a64bfdfb94
InfluxDB SQL: Provide raw query preview for query history (#75030)
* log the sql query

* render the raw sql

* Update rawQuery

* unit tests
2023-09-22 17:40:18 +02:00
Andres Martinez Gotor
c70623fb85
Chore: Rename testdata plugin with a fully qualified name (#75104) 2023-09-22 15:00:40 +03:00
Will Browne
d6db9eaeb2
Plugins: Make sure feature toggles config value is deterministic (#75249)
* make sure feature toggle config vals are deterministic

* fix nil pointer

* undo changes

* fix condition

* add tests
2023-09-22 13:56:48 +02:00
Ezequiel Victorero
4cfc834c08
HealthCheck: show enterprise commit (#75242) 2023-09-22 08:17:10 -03:00
George Robinson
15f6e8a500
SQLStore: Fix race condition in RecursiveQueriesAreSupported (#75274) 2023-09-22 11:30:14 +01:00
Carl Bergquist
e5fbc4a4cd
web: add slo group to request meta (#74765)
Signed-off-by: bergquist <carl.bergquist@gmail.com>
2023-09-22 11:52:28 +03:00
Andres Martinez Gotor
61cdfba87a
Feature: Allow to load a core plugin as external (#75157) 2023-09-22 10:50:13 +02:00
William Wernert
925f12d0ea
Alerting: Add support for keep_firing_for field from external rulers (#75163)
* Add support for `keep_firing_for` in ruler proxy

* Don't delete `keep_firing_for` when editing a rule with the field set

Co-Authored-By: Sonia Aguilar <33540275+soniaAguilarPeiron@users.noreply.github.com>

---------

Co-authored-by: Sonia Aguilar <33540275+soniaAguilarPeiron@users.noreply.github.com>
2023-09-21 16:02:53 -04:00
Juan Cabanas
633605af4e
PublicDashboards: Refresh ds plugin supported list (#74947) 2023-09-21 16:24:08 -03:00
Todd Treece
71fe6f8390
Live: Add logging to memory cache (#75245) 2023-09-21 12:59:01 -04:00
Will Browne
de2a107efa
Chore: Fix slug cfg name (#75235)
fix cfg name
2023-09-21 15:59:49 +03:00