Commit Graph

11492 Commits

Author SHA1 Message Date
Karl Persson
3fc925364f
Siningkeys: Fix test setup (#76333)
* Don't use integration tests for service and init store only once for integration tests

* Set one key as expired in test
2023-10-11 13:50:38 +02:00
Giuseppe Guerra
50504ba008
Plugins: Chore: Renamed instrumentation middleware to metrics middleware (#76186)
* Plugins: Chore: Renamed instrumentation middleware to metrics middleware

* Removed repeated logger attributes in middleware and contextual logger

* renamed loggerParams to logParams

* PR review suggestion

* Add contextual logger middleware

* Removed unused params from logRequest

* Removed unwanted changes

* Safer FromContext method

* Removed traceID from logParams
2023-10-11 12:42:32 +02:00
Andres Martinez Gotor
1f8b08202e
Chore: Avoid showing plugin version if it's %VERSION% (#75974) 2023-10-11 10:49:30 +02:00
João Calisto
d5691e6dd1
Live: Allow setting the engine password (#76289) 2023-10-11 09:45:24 +01:00
Ryan McKinley
c26e3d80e3
Playlist: Add create+update timestamps to the database (#76295) 2023-10-10 12:46:12 -07:00
Andrej Ocenas
2a6c16d969
Pyroscope: Change phlare/api module to pyroscope/api module (#76271) 2023-10-10 18:13:14 +02:00
Jo
cada1f040a
Auth: Add support for role mapping and allowed groups in Google OIDC (#76266)
* support google oauth allowed_groups. unify allowed groups logic

* add role mapping for google oauth

* add documentation

* add addendums

* remove extra isGroupMember

* add to sample ini

* Apply suggestions from code review

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>

---------

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
2023-10-10 18:07:23 +02:00
Yuri Tseretyan
810fbc3327
SSE: Support hysteresis threshold expression (#70998)
* extend threshold command with second evaluator called `unloadEvaluator` 
* Introduce a new expression command Hysteresis and update Threshold unmarshaller to create the HysteresisCommand if the second eval
* add feature flag `recoveryThreshold`
* update unmarshal threshold command to not re-marshall because it breaks frame definition by shuffling the schema and data fields
2023-10-10 17:51:50 +03:00
Karl Persson
ceb6f8b409
Authn: error logs (#76264)
* Reduce to debug for session need rotation error

* try to extract log level from error and fallback to warning
2023-10-10 16:30:20 +02:00
Gabriel MABILLE
9dd38de5c1
RBAC: Make fixed role UIDs deterministic (#76239)
* Add fixed role UID

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

* Use base64 url encoding

---------

Co-authored-by: Karl Persson <kalle.persson@grafana.com>
2023-10-10 16:29:31 +02:00
Ashley Harrison
930c753340
Navigation: Implement logic for docking nav menu (#76188)
* Create a state for dockedMegaMenu and the function to manage it

* Add the dockedMenu icon and handle the status when clicking it

* Add Megamenu to section nav area when it is docked

* get logic working

* fix mobile

* refactor state + persist in localStorage

* adjust icon and don't use position absolute

* restore old rudderstack tracking

* use Flex instead

* adjust feature toggle to be experimental

* extract out localStorage handling into utils

* don't need separate file

* use store.set/get instead

---------

Co-authored-by: eledobleefe <laura.fernandez@grafana.com>
2023-10-10 14:55:52 +01:00
Karl Persson
ea741dda6b
Signingkeys: Add local cache (#76234)
* IDForwarding: change audience to be prefixed by org and remove JTI

* IDForwarding: Construct new signer each time we want to sign a token.

* SigningKeys: Simplify storage layer and move logic to service

* SigningKeys: Add private key to local cache
2023-10-10 14:17:16 +02:00
Ashley Harrison
f56cc6fdc0
Navigation: Create navAdminSubsections feature toggle (#76248)
create feature toggle
2023-10-10 13:50:44 +03:00
Sofia Papagiannaki
99e4894636
Chore: Replace mock guardian with the actual one in folder API benchmarks (#76231)
Benchmarks: Replace mock guardian with the actual one
2023-10-10 13:31:55 +03:00
Marcus Efraimsson
90631360eb
Instrumentation: Handle context.Canceled (#75867)
Ref #68480

Co-authored-by: Giuseppe Guerra <giuseppe.guerra@grafana.com>
2023-10-10 12:28:39 +02:00
Gabriel MABILLE
007c2c8131
AuthN: Extract from OAuthServer service account management code (#76128)
* Extract code to manage service accounts

* Add test with client credentials grants

* Fix test with the changed interface

* Wire

* Fix HandleTokenRequest

* Add tests to extsvcaccounts

* Rename Retrieve function

* Document the interface
2023-10-10 09:20:52 +02:00
Horst Gutmann
1355660313
Building: Remove dependency to urw-fonts in RPM packages (#76198) 2023-10-10 08:15:54 +02:00
Jo
8919cafcb4
Identity: Unfurl UserID and Email in pkg/api to user identity.Requester (#76112)
* Unfurl OrgRole in pkg/api to allow using identity.Requester interface

* Unfurl Email in pkg/api to allow using identity.Requester interface

* Update UserID in pkg/api to allow using identity.Requester interface

* fix authed test

* fix datasource tests

* guard login

* fix preferences anon testing

* fix anonymous index rendering

* do not error with user id 0
2023-10-09 16:07:28 +02:00
Andre Pereira
8bf914ac0b
Tempo: Fix service graph menu item links (#75748)
* Only call preventDefault if it exists

* Change "View Traces" link to use traceQLSearch instead of the deprecated nativeSearch

* Thank you again test. Update tests

* Update test

* Update betterer

* Type fix

* Small type change

* Update betterer
2023-10-09 14:22:39 +01:00
Giuseppe Guerra
cfcfbe4aaa
Plugins: Refactoring: Implement plugin instrumentation as a middleware (#76011)
* Plugins: Refactor instrumentation as plugin client middleware

* Simplify repeated code

* Fix compilation error

* Add comments

* Moved status and endpoint consts to utils.go

* Fix wrong endpoint name in CheckHealth InstrumentationMiddleware

* Add tests

* Fix wrong endpoint value in instrumentPluginRequestSize

* removed todo

* PR review feedback: use MustRegister

* PR review feedback: move tracing middleware before instrumentation middleware

* PR review feedback: removed decommissioned check

* PR review feedback: extract prometheus metrics into separate variables
2023-10-09 14:12:57 +02:00
NikolayTsvetkov
ce462e8cd7
Elasticsearch: Added support for calendar_interval in ES date histogram queries (#75459)
* Introduce support for calendar intervals in ES date histogram queries

* Add missing undef type check for ES calendar interval query support
2023-10-09 12:37:38 +02:00
Jo
dcd0c6b11e
Identity: Unfurl OrgID in pkg/services to allow using identity.Requester interface (#76113)
Unfurl OrgID in pkg/services to allow using identity.Requester interface
2023-10-09 10:40:19 +02:00
Torkel Ödegaard
fc0933d5f4
Schema: Clean up dashboard variables schema (#76121)
* Cleanup variable schema model

* minor fix

* remove type ignores that are no longer type errors
2023-10-09 09:10:52 +02:00
Victor Marin
ef82767dab
Panel monitoring (#75456)
* WIP

* remove bug

* XY Chart logs

* wip

* wip

* wip

* wip

* wip

* Revert experimental logs

* wip dataviz options monitor

* add logging functionality on panel save

* remove unused file

* readd start load time

* remove afterFrame lib. remove assertions where possible

* add tests

* PR modifications

* fix betterer

* rename logEvent to logPanelEvent

* add feature flag

* split monitor into measurement and logging parts

* rename component

* log panel options on error capture also. Log overrides only then

* refactor logs

* log panel option changes only on error in panel edit mode

* refactor function
2023-10-09 08:19:08 +03:00
Yuri Tseretyan
2497db4bd6
Alerting: Add UID of rules to response that were affected by update group request (#75985)
* update storage's method InstertRules to return ids of added rules as slice to keep the same order as rules in the argument
* schematize response of update rule group endpoint, add created, updated, deleted fields that contain UID of affected rules.
* update integration tests to use the new fields
2023-10-07 01:11:24 +03:00
Ryan McKinley
717a9dd616
K8s: Add example api service (#75911) 2023-10-06 21:55:22 +03:00
Yuri Tseretyan
0a50ca7231
Alerting: Let users with regular permissions access export endpoints (#76082)
let users with regular permissions access export endpoints
2023-10-06 14:48:20 -04:00
Jo
4474f19836
Service Accounts: Enable adding folder, dashboard and data source permissions to service accounts (#76133)
* Add SAs to Datasource permissions

Co-authored-by: ievaVasiljeva <ieva.vasiljeva@grafana.com>

* add SAs to dashboards/folders managed permissions

* Update public/app/core/components/AccessControl/Permissions.tsx

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>

* regenerate i18n

* add doc

---------

Co-authored-by: ievaVasiljeva <ieva.vasiljeva@grafana.com>
2023-10-06 17:48:13 +02:00
Agnès Toulet
46c1c03183
Rendering: Fix Windows plugin signature check (#76123)
* Rendering: Fix Windows plugin signature check

* apply review feedback
2023-10-06 15:48:29 +02:00
Andrej Ocenas
1cbae72a9e
Pyroscope: Fix backend panic when querying out of bounds (#76053) 2023-10-06 15:03:20 +02:00
Jo
41bcb5e07f
Identity: Port folder library to identity.Requester (#76105)
Port folders to identity.Requester
2023-10-06 15:02:34 +02:00
Jo
c4874f97f8
Identity: Port snapshots and annotations to Requester (#76103)
* Port snapshots to Requester

* Port annotations to Requester
2023-10-06 11:59:48 +02:00
Jo
342af2d078
Identity: Port Annotations and Analytics to Identity.Requester (#76104)
* Port analytics to requester

* Port annotations to identity.Request
2023-10-06 11:38:20 +02:00
Jo
729dafaff9
Auth: Unfurl OrgID in pkg/api to allow using identity.Requester interface (#76108)
Unfurl OrgID in pkg/api to allow using identity.Requester interface
2023-10-06 11:34:36 +02:00
Jan Garaj
68a027993c
CloudWatch: Add missing AWS/Transfer metrics (#76079)
Source: https://docs.aws.amazon.com/transfer/latest/userguide/monitoring.html
2023-10-06 10:47:36 +02:00
Jo
12ccc8ca23
SigningKeys: Clean old keys by expiry (#76048)
* clean old keys by expiry

* nit
2023-10-06 10:45:24 +02:00
Yuri Tseretyan
4343c99e2a
Add compat function for notify.GrafanaIntegrationConfig to EmbeddedContactPoint (#75995)
Co-authored-by: Matthew Jacobson <matthew.jacobson@grafana.com>
2023-10-05 23:13:34 +03:00
Yuri Tseretyan
a66760f9f2
Alerting: Add integration tests for Rule Export API (#75896) 2023-10-05 15:47:49 -04:00
Yuri Tseretyan
51499d7763
Alerting: Update alert rule export models to omit default values (#75918)
* do not include rule uid in response if it's empty
* make some fields of export models nillable
2023-10-05 15:16:44 -04:00
Todd Treece
664ebf771e
K8s: Playlist frontend reads (#76057) 2023-10-05 15:00:36 -04:00
Gabriel MABILLE
e902d8fd10
AuthN: New service to support multiple authentication providers for plugins (#75979)
* OnGoing

* Continue migrating structure

* Comment

* Add intermediary service

* Remove unused error so far

* no need for fmt use errors

* use RoleNone

* Docs

* Fix test

* Accounting for review feedback

* Rename oauthserver.ExternalService to OAuthClient

* Revert as the interface looks weird

* Update pluginintegration

* Rename oauthserver.ExternalService

* closer to what it was before
2023-10-05 18:13:06 +02:00
Karl Persson
81b366e2c8
AuthN: Make logger less noisy (#76044)
* Change to debug for token needs rotation errors
2023-10-05 16:11:36 +02:00
Jo
f2bf066ad2
SigningKeys: Add jwks endpoint (#76040)
* add jwks

add remote caching

add expose jwks test

tweaks

* fix swagger

* nt
2023-10-05 15:17:31 +02:00
Will Browne
8a33a6f958
Plugin: Accept backend plugin process command args (#76037)
accept args
2023-10-05 15:15:57 +02:00
Josh Hunt
3e2ca29c8d
BrowseDashboards: Enable new browse dashboards UI by default (#75822)
* BrowseDashboards: Enable new browse dashboards UI by default

* update docs

* enable new e2e tests
2023-10-05 13:14:10 +03:00
Misi
bd2191c158
Auth: OAuth token sync improvements (#75943)
* Add metric, improve token refresh

* changes

* handle ctx cancelled

* Fix import order
2023-10-05 11:19:43 +02:00
Karl Persson
a2d4ce18ad
IDForwarding: Add basic metrics (#75798)
* IDService: Add basic metrics

* IDService: Add more metrics
---------

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
2023-10-05 09:17:40 +02:00
Andrew Hackmann
e087a8ab05
Azure monitor/remove graf tracing (#75927)
* trying to remove tracing

* trying to remove tracing

* use plugin sdk tracing

* tracing is not init

* add infra tracing back

* remove infra trace

* Update pkg/tsdb/azuremonitor/metrics/azuremonitor-datasource.go

Co-authored-by: Andreas Christou <andreas.christou@grafana.com>

* pr feedback

* remove code from other pr

---------

Co-authored-by: Andreas Christou <andreas.christou@grafana.com>
2023-10-05 02:38:26 +03:00
Todd Treece
d9160553f9
K8s: Remove /k8s/ prefix (#75959) 2023-10-04 14:05:50 -04:00
Yuri Tseretyan
5be52dfe21
Alerting: Fix store's GetNamespaceByUID (#75976) 2023-10-04 13:13:31 -04:00