Commit Graph

23608 Commits

Author SHA1 Message Date
Jack Westbrook
cfb46c8003
Frontend: Extract CSS imports into files (#94655)
* build(webpack): extract css imports into files including node_modules

* feat(webassets): add cssfiles to entrypoint assets for extracted css files

* feat(views): add entrypoint css link tags to html templates

* feat(webassets): set CDN prefix for CSS files

* test(webassets): trim down sample-assets-manifest, fix failing snapshot tests

* Update pkg/api/webassets/webassets_test.go

Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>

* build(webpack): remove css module loader

---------

Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
2024-10-16 11:10:34 +02:00
Torkel Ödegaard
384562e1ad
Dashboard: Fixes issue with dashboard inside get help drawer (#94725)
* Dashboard: Fixes issue with dashboard inside help help drawer

* Fix lint
2024-10-16 10:09:00 +02:00
Andrej Ocenas
1f39692d9b
Sidecar: Use a proper way to get header height (#94691)
Use a proper hook
2024-10-15 18:09:34 +02:00
Kristina
6e39ea5e46
Transformations: Add description to what is searched (#94501)
Add transformation description to what is searched
2024-10-15 10:26:44 -05:00
Matheus Macabu
47115c714a
CloudMigrations: create snapshot for Contact Points (#94719)
* CloudMigrations: create snapshot for Contact Points

* CloudMigrations: add contact point copies and components in frontend

* CloudMigrations: temporarily use bell for all alerts resources
2024-10-15 16:27:28 +02:00
Alex Khomenko
e5795c7b6d
Routing: Update connections to react router 6 (#94461)
* Update routes

* Update test

* Remove the useDataSourcesRoutes hook

* Remove DataSourcesRoutesContext

* Fix imports

* Fix more imports

* Add default

* Betterer
2024-10-15 16:10:31 +03:00
kay delaney
7104782a74
Chore: Remove unused sass variables (#94723) 2024-10-15 13:38:42 +01:00
Jack Westbrook
9e50866356
Build: Nx improvements (#88341)
* feat(frontend): introduce project.json for every workspace to improve caching

* refactor(frontend): use nx tags for grafana dependson

* refactor(frontend): clean up nx tags for packages and plugins

* build(nx): make grafana dependent on cacheable generate icons command

* build(nx): clean up project files
2024-10-15 14:25:45 +02:00
Marcus Efraimsson
b28085110d
Plugins: Auto instrumentation improvements (#94193) 2024-10-15 14:02:34 +02:00
kay delaney
22a3c9976f
Chore: Convert QueryGroupOptions to functional component (#94342)
Also rewrites styles
2024-10-15 12:57:58 +01:00
grafana-pr-automation[bot]
940a9e0144
I18n: Download translations from Crowdin (#94707)
New Crowdin translations by GitHub Action

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-10-15 14:20:18 +03:00
Tom Ratcliffe
0841497cad
Alerting: Show a warning when a template has been potentially misconfigured (#94698) 2024-10-15 14:00:20 +03:00
Matheus Macabu
016dea1143
CloudMigrations: create snapshot for Notification Templates (#94676)
* CloudMigrations: create snapshot for Notification Templates

* CloudMigrations: add notification templates resource to frontend
2024-10-15 12:55:33 +02:00
Ieva
284c2d6f71
Folders: Correctly show new folder button under root folder (#94687)
show new folder button under root folder if nested folders are disabled and user has the right perms
2024-10-15 10:45:07 +01:00
Victor Marin
aaba5a43bd
DashboardScene: Rerender dashboard links on timerange change (#94570)
* fix

* refactor

* refactor
2024-10-15 12:39:36 +03:00
Matheus Macabu
081ec57443
CloudMigrations: create snapshot for Mute Timings (#94668)
* CloudMigrations: Create snapshot for Mute Timings

* CloudMigrations: add mute timings icon and copies to frontend
2024-10-15 09:44:41 +02:00
Agnès Toulet
5fb685dcc6
Scenes: add clearSceneCache to DashboardScenePageStateManager (#94227) 2024-10-15 09:43:54 +02:00
Ashley Harrison
e48351fbd3
AppChromeService: Improve useChromeHeaderHeight to only react to necessary state changes (#94624)
make useChromeHeaderHeight only react to necessary state changes
2024-10-14 16:21:15 +01:00
Eric Leijonmarck
d5fe9ce87f
LBAC for datasources: Fix generated swagger updates (#94587)
fix: generated swagger updates
2024-10-14 16:14:11 +01:00
Levente Balogh
2867f92974
Extensions: Show error and warning logs in the console (#94682)
fix: log extensions framework errors and warnings to the console
2024-10-14 16:44:47 +03:00
Alexa V
00af0afe52
Dashboard Scene: Fix permissions and error handling in creating alert from panel (#94521)
* Dashboard Scene: Add better error handling when creating alert from panel menu

* Add missing permission to createNewAlert and add unit test
2024-10-14 12:11:31 +02:00
grafana-pr-automation[bot]
e746f55126
I18n: Download translations from Crowdin (#94667) 2024-10-14 10:37:05 +01:00
renovate[bot]
77effa6d90
Update testing-library monorepo (#94632)
* Update testing-library monorepo

* add @testing-library/dom

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2024-10-14 12:22:34 +03:00
Sonia Aguilar
fb5fb76ad1
Alerting: Use advanced options when query params are not transformable (#94588)
* Use advanced options when query params are not transformable

* Update public/app/features/alerting/unified/components/rule-editor/query-and-alert-condition/QueryAndExpressionsStep.tsx

Co-authored-by: Konrad Lalik <konrad.lalik@grafana.com>

---------

Co-authored-by: Konrad Lalik <konrad.lalik@grafana.com>
2024-10-14 11:03:58 +03:00
Andres Martinez Gotor
235f7db967
Add query migration handlers (#93735) 2024-10-14 09:29:44 +02:00
Dominik Prokop
97037580df
PanelMenu: Allow showing panel menu when data source does not exist (#94545) 2024-10-14 09:17:37 +02:00
Alex Khomenko
9811725c59
Routing: Update PluginDetails (#94513) 2024-10-14 09:52:58 +03:00
Matheus Macabu
1830820363
CloudMigrations: add basic resource component and update migration message with many resource types (#94423)
* CloudMigrations: display generic success message with more than 4 resource types

* CloudMigrations: create generic named resource component
2024-10-14 08:08:33 +02:00
Sonia Aguilar
0dd5373e4a
Alerting: Add interactions for Fullstory (#94631)
add interactions for Fullstory
2024-10-11 19:23:58 +02:00
grafana-pr-automation[bot]
20b94ea92f
I18n: Download translations from Crowdin (#94623)
New Crowdin translations by GitHub Action

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-10-11 17:21:24 +03:00
Ashley Harrison
4d08f44667
SingleTopNav: Revert to using AppChromeUpdate so banners are correct (#94540)
* revert to using AppChromeUpdate

* fix dashboard settings in old arch

* remove empty interface

* fix AlertRuleForm
2024-10-11 15:07:01 +01:00
Alex Khomenko
a5d72e264d
DataTrailsApp: Update to react-router v6 (#94447)
* DataTrailsApp: Update router

* Update route
2024-10-11 16:33:01 +03:00
Torkel Ödegaard
6787e2f108
AddToDashboard: Refactorings & changes to address a number of problems (#94458)
* Extract shared add to dashboard flow

* Change how we save and add the new panels

* More cleanup

* Began updating tests

* Move and update tests

* set time range

* Fix lint / ts issues

* Fix time history step issue

* fix test

* Update betterer

* remove more tests that are now not needed

* work around cyclic dep

* Update

* Fixes

* fix lint

* remove unused type
2024-10-11 15:24:45 +02:00
Sonia Aguilar
1596acbd3b
Alerting: Add data-testids for Fullstory (#94555)
* add data-testids for Fullstory

* add more data-testids
2024-10-11 13:55:01 +02:00
Giuseppe Guerra
95afb3a112
Plugins: Track SystemJS load errors with Faro (#94465)
* Test SRI check errors with Faro

* Plugins: Send SystemJS import errors to Faro

* unbork

* track loadingStrategy

* Revert "unbork"

This reverts commit 02a61f4046.

* Reapply "unbork"

This reverts commit eaee8fbb39.
2024-10-11 13:33:18 +03:00
grafana-delivery-bot[bot]
032d0669cd
Release: Bump version to 11.4.0-pre (#94569)
bump version 11.4.0-pre

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-10-11 11:31:04 +01:00
grafana-pr-automation[bot]
67ee40ce12
I18n: Download translations from Crowdin (#94599) 2024-10-11 11:24:47 +01:00
Tom Ratcliffe
b91b9a1e38
Alerting: Use jest/expect-expect rule to check for assertions (#93112) 2024-10-11 13:08:50 +03:00
Sonia Aguilar
029b5bc2d0
Alerting: Default to right instant or range when filling alert rule from query params (#94272)
* default to right instant or range when filling alert rule from query params

* address pr review comment
2024-10-11 12:07:43 +02:00
Tom Ratcliffe
f08de95630
Alerting: Change styling so query results with no labels are clearer (#94404) 2024-10-11 10:54:15 +01:00
Mihai Doarna
0bd3ad1d5a
SSO: Fix client side validations for LDAP (#94561)
* fix client side validations for LDAP

* add translations for new messages

* simplify code in isInvalidField()
2024-10-11 12:09:34 +03:00
Laura Benz
4092741f24
RestoreDashboards: Merge both feature toggles to dashboardRestore (#94412)
* refactor: remove FE feat toggle from BE

* refactor: remove FE toggle and adjust roles

* refactor: replace feat toggle in tracking events

* refactor: remove FE feat toggle

* refactor: remove FE feat toggle

* fix: autogenerated file
2024-10-11 10:29:58 +02:00
Brendan O'Handley
ce857c2680
Explore metrics: set options directly because of scenes error when options not set (#94284)
* scenes error when options not set

* add all of the options that are updated in onOptionsChange

* add options to all the other places we are building timeseries panels

* Update public/app/features/trails/AutomaticMetricQueries/graph-builders/percentiles.ts

Co-authored-by: Nick Richmond <5732000+NWRichmond@users.noreply.github.com>

* remove activation handlers and unused code

* Update public/app/features/trails/AutomaticMetricQueries/graph-builders/simple.ts

Co-authored-by: Nick Richmond <5732000+NWRichmond@users.noreply.github.com>

* Update public/app/features/trails/AutomaticMetricQueries/graph-builders/percentiles.ts

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>

---------

Co-authored-by: Nick Richmond <5732000+NWRichmond@users.noreply.github.com>
Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
2024-10-10 11:49:24 -05:00
Victor Marin
4600bd2e77
Scopes: Open dashboard list when a scope is selected (#94464)
* Open dashboard list when a scope is selected

* refactor

* test

* remove localstorage key

* add checks on open/close methods

* remove redundant statement

* improve dashboards listing
2024-10-10 19:12:26 +03:00
Victor Marin
516e0cf7e2
DashboardScene: Update timerange in datalinks on change (#94419)
* fix types

* mods

* refactor

* refactor
2024-10-10 19:11:58 +03:00
Joey
a268a56acb
Tempo: Put trace results data frame first when streaming (#93739)
* Put trace results dataframe first

* Add comment
2024-10-10 15:51:43 +01:00
kay delaney
42eb033b03
Chore: Change VariableEditorList overflow styling & tidy markup (#94394)
Chore: Channge VariableEditorList overflow styling & tidy markup
2024-10-10 15:49:48 +01:00
Oscar Kilhed
315778227b
Dashboards: Links to explore should respect subpath (#94525)
* Links to explore should respect subpath

* Change to using assureBaseUrl

* Change back to normal single quotes
2024-10-10 15:54:48 +02:00
Virginia Cepeda
c41c8c2026
Icons: add new k6 icons (#94439)
Added 4 new icons:
 - api-endpoint
- browser-alt
- k6-rounded
- multi-step

These icons where added in https://github.com/grafana/synthetic-monitoring-app/issues/955
2024-10-10 16:18:28 +03:00
Tom Ratcliffe
074831153a
Alerting: Config tracker - update link for default contact point (#94384)
Co-authored-by: Sonia Aguilar <soniaaguilarpeiron@gmail.com>
2024-10-10 10:18:36 +01:00
Tom Ratcliffe
f6abde3328
Alerting: Remove accesscontrol license feature requirement for contact points RBAC (#94418) 2024-10-10 10:18:25 +01:00
jjaychen
636d17c111
PanelQueryRunner: Fix diff between multiple errors (#89868) 2024-10-10 11:02:33 +02:00
Sonia Aguilar
419598c745
Alerting: Fix getSimpleConditionFromExpressions (#94516)
fix getSimpleConditionFromExpressions
2024-10-10 09:56:15 +02:00
Marcus Andersson
bc7386e815
PluginExtension: Added debug log (#94146)
* wip

* add simple scenes object with logs panel

* return hardcoded log message from runtime ds

* simplify log entry

* use log in links registry

* wired the log together.

* wip

* Connected the extensions log to the runtime datasource to steam logs

* wired the other registies.

* implemented child function.

* set right field type on labels

* set meta type

* using the logger in various places.

* added type of onclick.

* removed time picker.

* removed imports.

* passing log to functions where they are needed.

* moved scene into admin page.

* minor improvement to the message.

* added possibility to update query with values based on the data.

* added filter suppoert.

* wip

* wip

* fixed so extension points are displayed.

* use log level from grafana data

* fixed bugs with the filtering.

* Fixed some logs.

* only register extensions page in development mode.

* fixed filtering.

* added on click debug log.

* PluginExtensions: Add debug log to Grafana (Rewrite to scenes-react) (#93954)

* refactoring.

* simplify it even more.

* Update public/app/features/plugins/extensions/logs/LogViewer.tsx

Co-authored-by: Erik Sundell <erik.sundell87@gmail.com>

* used VizGridLayout instead of VizGrid component.

* Fixed feedback and fixed bug in filtering logic.

* fixed another nit.

* empty string instead of title.

* Added tests and fixed error.

* added test file.

* regenerated yarn.lock

* Update public/app/features/plugins/extensions/logs/filterTransformation.test.ts

Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>

* fixed nit.

* more nits.

* added more test cases.

* simplified filtering logic.

* removed unused dep.

* defined broadcast channel in jest setup.

* added tests for datasource.

* fixed failed tests.

* fixed tests.

* fixing go lint issue.

* silent go lint.

* fixed lint issue.

---------

Co-authored-by: Erik Sundell <erik.sundell87@gmail.com>
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>
2024-10-10 09:27:57 +03:00
Alex Khomenko
97249d15d1
Routing: Update alerting routes to react router 6 (#94469)
* Update alertingRuleEditor

* Update Policy.test

* Update AlertRuleForm

* Update ReceiversSection

* Update SimplifiedRuleEditor.test.tsx

* Update CloneRule.tsx
2024-10-10 07:33:16 +03:00
Alex Khomenko
e0217c37a1
AlertmanagerContext: Remove react router dependency (#94470)
* AlertmanagerContext: Remove react router dependency

* Cleanup
2024-10-10 07:33:04 +03:00
kay delaney
0201e8e8fb
Chore/TimezonesEditor: Add vertical gaps between inputs (#94487) 2024-10-10 01:57:14 +01:00
Kristina
1f9562ea72
State Timeline: Align left text to 0 when rectangle is left-truncated (#94422)
Handle negative x placement with displaying text
2024-10-09 11:24:06 -05:00
renovate[bot]
d5ff74ebac Update dependency @grafana/experimental to v2.1.2 2024-10-09 16:13:52 +00:00
Scott Lepper
c86c4ca65a
[unified search] fix: remove unified searcher (#94492) 2024-10-09 12:02:52 -04:00
Joao Silva
322dccdb4d
Navigation: Fix wrong active item shown when parent is bookmarked (#94478) 2024-10-09 15:53:05 +01:00
Nick Richmond
38827e5a16
ExploreMetrics: Keep gaps consistent between sticky elements (#94441)
style: maintain gap between sticky elements while scrolling
2024-10-09 10:05:41 -04:00
Haris Rozajac
5f26fd87c7
Query Library: Notifications and query counter (#94444)
* Notifications about the feature

* i18n

* Fix test
2024-10-09 06:54:11 -06:00
Victor Marin
4a3ce66193
[Scopes] Inherit scope paths on node fetching (#93824)
* [Scopes]: Inherit scope paths on node fetching

* add function desc

---------

Co-authored-by: Bogdan Matei <bogdan.matei@grafana.com>
2024-10-09 14:49:38 +03:00
grafana-pr-automation[bot]
08d03cc315
I18n: Download translations from Crowdin (#94415) 2024-10-09 14:19:13 +03:00
Alex Khomenko
380ce19b1a
Routing: Remove nested silences routes (#94385)
* Update SilencesTable

* Remove nested routes

* Update tests

* Update component names

* Update test

* Remove unused code
2024-10-09 13:56:54 +03:00
Alex Khomenko
38f57d270a
Routing: Update alerting template routes (#94366)
* Templates: Remove Switch routes

* Update tests

* Fix test

* Revert mock behaviour and render AppNotificationList

---------

Co-authored-by: Tom Ratcliffe <tom.ratcliffe@grafana.com>
2024-10-09 12:08:10 +03:00
Sonia Aguilar
3924751827
Alerting: Fix detail view not showing instances nor history tab (#94424)
* Fix detail view not showing instances nor history tab

* small refactor

* Update public/app/features/alerting/unified/hooks/useCombinedRule.ts

Co-authored-by: Konrad Lalik <konrad.lalik@grafana.com>

* refactor

---------

Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
Co-authored-by: Konrad Lalik <konrad.lalik@grafana.com>
2024-10-09 11:50:05 +03:00
Laura Fernández
9491ab9a93
Bookmarks: Create e2e tests (#90373) 2024-10-09 10:43:01 +02:00
Alex Khomenko
be7b293b79
Routing: Hoist alerting receivers routes (#94309)
* Separate receivers components

* Update exports

* Remove type assertion

* Add back test

* Format

* Update test

* Fix test import
2024-10-09 07:29:07 +03:00
Scott Lepper
c2fb2dcfbe
wire up unified search from the ui; add basic search support (#94358)
* wire up search from the ui;  add basic search support
2024-10-08 13:09:56 -04:00
Ieva
8cade5c550
Role mapping: Add new query parameter to docs (#94413)
* small doc addition

* swagger gen

* pr feedback
2024-10-08 17:53:21 +01:00
Lucy Chen
e1067b817d
ShareDrawer: Export CTA UI tweaks (#94348)
change arrow size
2024-10-08 11:57:13 -04:00
Mihai Doarna
4bbae5eb0a
LDAP: Render root CA and client cert as text fields (#94382)
render root CA and client cert as text fields
2024-10-08 18:54:34 +03:00
Nick Richmond
ff7a96d60e
ExploreMetrics: Ensure compatibility with Incremental Querying (#94355)
fix: use unique refs in breakdown panels
2024-10-08 09:15:07 -04:00
Haris Rozajac
ee65f89533
Query Library: Enhance user data (#94231)
* Enhance user data

* Remove irrrelevant logic outside of try block

* Encode user uid for url
2024-10-08 07:12:33 -06:00
Piotr Jamróz
c6387854c5
TraceView: Fix icon background after making a copy of an attribute (#94402)
Fix icon color after making a copy
2024-10-08 15:09:06 +02:00
renovate[bot]
8fbd8eabec Update dependency @types/node to v20.16.11 2024-10-08 11:48:39 +00:00
kay delaney
1d244ae1ec
Chore: Rewrite TraceView css using object styles (#87621) 2024-10-08 14:39:22 +03:00
Mihai Doarna
501f1bc7a9
LDAP: Render bind password as a secret input field (#94376)
render bind password as a secret input field
2024-10-08 12:54:16 +03:00
Misi
bd7850853e
Auth: Attach external session info to Grafana session (#93849)
* initial from poc changes

* wip

* Remove public external session service

* Update swagger

* Fix merge

* Cleanup

* Add backgroud service for cleanup

* Add auth_module to user_external_session

* Add tests for token revocation functions

* Add secret migration capabilities for user_external_session fields

* Cleanup, refactor to address feedback

* Fix test
2024-10-08 11:03:29 +02:00
Jo
9eea0e99fc
Chore: Use UIDs as identifiers for teams frontend (#94345)
* Team frontend now uses UIDs as identifiers. Safe to revert
2024-10-08 09:48:35 +02:00
Victor Marin
f70fefc67c
DashboardScene: Fix dependencies on field overrides (#94335)
fix deps on field overrides
2024-10-08 08:25:42 +03:00
Victor Marin
a63a271f88
DashboardScene: Fix row actions removing behavior on second update (#94333)
fix row actions removing behavior on second update
2024-10-08 08:25:29 +03:00
Ezequiel Victorero
cc40211f71
Chore: Update api docs (#92616) 2024-10-07 14:49:58 -03:00
grafana-pr-automation[bot]
45eb292a74
I18n: Download translations from Crowdin (#94343) 2024-10-07 17:38:59 +01:00
Brendan O'Handley
2113c13e6e
Explore metrics: Add bookmarks empty state (#94291)
* add empty state component for bookmarks

* translations

* remove image, update text

* all text
2024-10-07 10:59:06 -05:00
jackyin
63bdbb67fc
SubMenu: Fix expanding sub menu items on touch devices (#93208)
* click more in mobile phone

* use stopPropagation stop event

* delete log

* delete inspect click and add stopPropagation

* bug fix

* fix unit tests

* fix e2e tests

* fix old-arch tests

---------

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2024-10-07 15:22:18 +01:00
grafana-pr-automation[bot]
1a3365d99b
I18n: Download translations from Crowdin (#94317)
New Crowdin translations by GitHub Action

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-10-07 17:19:19 +03:00
Brendan O'Handley
aefe08f738
Explore metrics: Add limit for adhoc filters options in providers functions (#94036)
* add limit for adhoc filters in providers functions

* add comments to describe function

* return early if filtersVariable is not an instance of AdHocFiltersVariable

* update function comments

* add tests to confirm the providers are limited to 10000
2024-10-07 09:06:50 -05:00
Lars Stegman
f9361bf5bf
PageHeader: Fill title container width (#94213)
page-header title: flex 1
2024-10-07 15:41:18 +02:00
Juan Cabanas
e2735dd9c8
ShareInternally: Remove menu item description (#94326)
Share internally menu item description removed
2024-10-07 10:36:36 -03:00
renovate[bot]
32c55555cb Update dependency @types/node to v20.16.10 2024-10-07 13:00:31 +00:00
renovate[bot]
45835f7ea2 Update dependency @types/lodash to v4.17.10 2024-10-07 10:54:58 +00:00
Matheus Macabu
9af095d730
CloudMigrations: Add data types for alerts resources (#94251) 2024-10-07 12:52:31 +02:00
Dana Axinte
d88be2819d
CloudMigrations: Store parent folder name in cloud_migration_resource table (#94009)
* use name in fe

* store parent folder name in local db

* clean up

* tiny test

* trial react

* rename to parent name

* go lint

* generate api and ts

* go tests

* rearrange

* clean

* update with suggestions from josh

* make library elements work

* updates from comments

* global migration types

* parent name for alter table
2024-10-07 11:35:08 +01:00
Ashley Harrison
d04dcb3da0
SingleTopNav: Fix tab order for docked menu (#94306)
fix tab order for docked menu when singleTopNav is enabled
2024-10-07 11:16:30 +01:00
Alex Khomenko
9680722b78
Dashboards: Switch to useParams hook (#94060)
* Update DashboardScenePage

* Update SoloPanelPage

* Update DashboardPage

* Cleanup

* Switch to useLocation

* Do not use location from history
2024-10-07 12:11:57 +03:00
kay delaney
4569872048
Chore: Add tests for HelpWizard (#94271) 2024-10-07 10:02:01 +01:00
Jo
acd13e05ef
Teams: Support team UIDs in APIs (#94011)
* support team UIDs in APIs

* unify middleware logic and add team tests

* add UID test to resource permissions

* remove unused middleware
2024-10-07 10:18:24 +02:00
Tim Mulqueen
413548806d
add zendesk to enterprise ds list (#91751) 2024-10-07 11:10:20 +03:00
Alex Khomenko
3bda6c2c0a
Routing: Use location from hooks (#94148)
* Update GrafanaRoute

* Update Silences

* Update PublicDashboardPage

* Cleanup

* Switch to the location from locationService

* Move location to render
2024-10-07 09:31:13 +03:00
Alex Khomenko
d730c66579
Routing: Remove useRouteMatch hook (#94152)
* Update useSilenceNavData.ts

* Update MuteTimings

* Update AppRootPage.tsx

* Cleanup props

* Remove empty file
2024-10-07 08:21:44 +03:00
Drew Slobodnjak
4ec75bcc60
Transformations: Show filter for single query (#94238) 2024-10-04 14:17:46 -07:00
renovate[bot]
797da67467 Update dependency @lezer/common to v1.2.2 2024-10-04 17:27:16 +00:00
Ivan Ortega Alba
d09017f7a2
Dashboard Scene: Sync variable state with TemplateSrv result (#93327)
* Generate options for variables through TemplateSrv

* Add refresh when object changes

* Remove unnecesary static function

* Extract logic

* Add extra test case when variable changes and refresh event is triggered

* bring back old logic, query options should not live in the dashboard json

* add missing change

* Add support to keep variable options in query

* tests

* move refreshEvent to DashboardVariableDependency

---------

Co-authored-by: alexandra vargas <alexa1866@gmail.com>
Co-authored-by: Victor Marin <victor.marin@grafana.com>
2024-10-04 20:19:18 +03:00
Misi
2b320b0f9e
Auth: Only apply redirection if the user is signed in (session storage redirection) (#94279)
Fix: do not redirect if the user is not signed in
2024-10-04 20:06:06 +03:00
Torkel Ödegaard
938bc9c2cc
DashboardScene: Update matcher options immutably (#93960) 2024-10-04 17:39:35 +02:00
Haris Rozajac
84cee7cab6
Query Library: Vertical space between rows; change "Run query" button color (#94177) 2024-10-04 09:38:23 -06:00
Josh Hunt
c7c66ccf4a
BrowseDashboards: Limit the type for folder parents to just a few fields (#94244)
* BrowseDashboards: Limit the type for folder parents to just title, uid, and url

* export type, use in buildNavModel
2024-10-04 17:32:50 +03:00
Ashley Harrison
e43e430e6a
SingleTopNav: Move scopes selector to second bar (#94186)
move scopes selector to second bar
2024-10-04 15:31:28 +01:00
renovate[bot]
6ed3868921 Update dependency @emotion/css to v11.13.4 2024-10-04 14:22:51 +00:00
grafana-pr-automation[bot]
89b292f514
I18n: Download translations from Crowdin (#94261)
New Crowdin translations by GitHub Action

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-10-04 17:21:48 +03:00
Ashley Harrison
40ad52fdbc
SingleTopNav: Handle for non-scenes dashboards (#94198)
handle singleTopNav for non-scenes dashboards
2024-10-04 15:11:32 +01:00
Sergej-Vlasov
f32fe9a846
PanelEditor: add data provider when switching from non data panel (#94220)
* add data provider when switching from non data panel

* handle adding and cleaning up data provider in panel editor on panel switch

* add data provider check sin panel  editor tests
2024-10-04 15:05:52 +01:00
kay delaney
b5821ef473
PanelSearch: Add support for rows & repeats (#94243)
* PanelSearch: Add support for rows & repeats

* Show message if there are no matches
2024-10-04 15:01:01 +01:00
Sonia Aguilar
4c27b2c59d
Alerting: Fix default value for input in simple condition (#94248)
fix default value for input
2024-10-04 16:57:29 +03:00
renovate[bot]
93b8243da7
Update dependency @grafana/experimental to v2 (#93919)
* Update dependency @grafana/experimental to v2

* add data-testid to old save button so it works properly in e2e test

* fix azure monitor e2e tests

* use raw selectors

* remove .only

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2024-10-04 14:21:10 +01:00
Giuseppe Guerra
0db65d229e
Plugins: Add Subresource Integrity checks (#93024)
* Plugins: Pass hashes for SRI to frontend

* Add SRI hashes to frontendsettings DTOs

* Add docstring

* TestSriHashes

* Fix typo

* Changed SriHashes to ModuleHash

* update loader_test compareOpts

* update ModuleHash error message

* Add TestModuleHash/no_module.js

* Add omitEmpty to moduleHash

* Add ModuleHash to api/plugins/${pluginId}/settings

* moved ModuleHash field

* feat(plugins): add moduleHash to bootData and plugin types

* feat(plugins): if moduleHash is available apply it to systemjs importmap

* Calculate ModuleHash for CDN provisioned plugins

* Add ModuleHash tests for TestCalculate

* adjust test case name

* removed .envrc

* Fix signature verification failing for internal plugins

* fix tests

* Add pluginsFilesystemSriChecks feature togglemk

* renamed FilesystemSriChecksEnabled

* refactor(plugin_loader): prefer extending type declaration over ts-error

* added a couple more tests

* Removed unused features

* Removed unused argument from signature.DefaultCalculator call

* Removed unused argument from bootstrap.DefaultConstructFunc

* Moved ModuleHash to pluginassets service

* update docstring

* lint

* Removed cdn dependency from manifest.Signature

* add tests

* fix extra parameters in tests

* "fix" tests

* removed outdated test

* removed unused cdn dependency in signature.DefaultCalculator

* reduce diff

* Cache returned values

* Add support for deeply nested plugins (more than 1 hierarchy level)

* simplify cache usage

* refactor TestService_ModuleHash_Cache

* removed unused testdata

* re-generate feature toggles

* use version for module hash cache

* Renamed feature toggle to pluginsSriChecks and use it for both cdn and filesystem

* Removed app/types/system-integrity.d.ts

* re-generate feature toggles

* re-generate feature toggles

* feat(plugins): put systemjs integrity hash behind feature flag

---------

Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
2024-10-04 14:55:09 +02:00
linoman
e37b43117b
SSO LDAP: Implement documentation (#94215)
* Add documentation for LDAP UI

* Add hyphen to string

* Polish writing

---------

Co-authored-by: Irene Rodriguez <irene.rodriguez@grafana.com>
2024-10-04 12:33:47 +02:00
grafana-pr-automation[bot]
788ef7fec3
I18n: Download translations from Crowdin (#94210)
New Crowdin translations by GitHub Action

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-10-04 10:00:30 +01:00
Ashley Harrison
d4bb8122cb
SingleTopNav: Tweaks for mobile responsiveness (#94188)
tweaks for mobile responsiveness
2024-10-04 09:54:17 +01:00
Levente Balogh
6096f46774
Plugin Extensions: Require meta-data to be defined in plugin.json during development mode (#93429)
* feat: add extensions to the backend plugin model

* feat: update the frontend plugin types

* feat(pluginContext): return a `null` if there is no context found

This will be necessary to understand if a certain hook is running inside a plugin context or not.

* feat: add utility functions for checking extension configs

* tests: fix failing tests due to the type updates

* feat(AddedComponentsRegistry): validate plugin meta-info

* feat(AddedLinksRegistry): validate  meta-info

* feat(ExposedComponentsRegistry): validate meta-info

* feat(usePluginComponent): add meta-info validation

* feat(usePluginComponents): add meta-info validation

* feat(usePluginLinks): add meta-info validation

* fix: only validate meta-info in registries if dev mode is enabled

* tests: add unit tests for the restrictions functionality

* tests: fix Go tests

* fix(tests): revert accidental changes

* fix: run goimports

* fix: api tests

* add nested app so that meta data can bested e2e tested

* refactor(types): extract the ExtensionInfo into a separate type

* refactor(extensions/utils): use Array.prototype.some() instead of .find()

* refactor(usePluginLinks): update warning message

* feat(usePluginExtensions()): validate plugin meta-info

* Wip

* fix(e2e): E2E tests for extensions

* fix(extensions): allow multiple "/" slashes in the extension point id

* fix(extensions/validators): stop validating the plugin id pattern

---------

Co-authored-by: Erik Sundell <erik.sundell87@gmail.com>
2024-10-04 08:41:26 +02:00
Nathan Marrs
7188c13d22
ElasticSearch: Add keywords to plugin.json (#94174)
* add keywords

* add additional keywords
2024-10-04 01:52:19 +03:00
Haris Rozajac
2ea662854a
QueryLibrary: Don't use description when generating name (#94236) 2024-10-03 16:24:39 -06:00
Kyle Cunningham
a38d6e57c2
Get help: Make quality of life updates (#93594)
* Get help updates

* Remove beta badge

* Further cleanups

* Some updates

* Fix tests

* Prettier

* Update betterer results

* i18n

* i18n extraction

* Bettererest
2024-10-03 13:38:18 -05:00
Laura Benz
f92ef0e126
RestoreDashboards: Add link to dashboards browse view (#94000)
* feat: add button

* refactor: clean up

* feat: add tracking

* refactor: change button copy

* refactor: add payload to tracking

* refactor: add subURL

* refactor: user permissions

* refactor: group conditions

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>

---------

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
2024-10-03 15:13:29 +02:00
Gilles De Mey
4224d05934
Alerting: Hoist routes for mute timings (#94201) 2024-10-03 14:41:11 +02:00
Ashley Harrison
87fd36aecf
SingleTopNav: Add chevron and tooltip to menu trigger (#94199)
add chevron and tooltip to menu trigger
2024-10-03 13:20:32 +01:00
Joey
eb60773073
Tempo: Add deprecation notice for Aggregate By (#94050)
Add deprecation notice
2024-10-03 12:13:56 +01:00
Joey
75640a6ad3
Tempo: Update lezer-traceql version (#94197)
Update lezer-traceql version
2024-10-03 11:40:38 +01:00
grafana-pr-automation[bot]
cda3791d49
I18n: Download translations from Crowdin (#94196)
New Crowdin translations by GitHub Action

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-10-03 11:22:17 +01:00
Matheus Macabu
1635a3cd67
CloudMigrations: Add support for migration of Library Elements (Panels) resources (#93898)
* CloudMigrations: create snapshots of Library Elements

* CloudMigrations: render library element resource in resources table

* CloudMigrations: create newtype with necessary fields for library element creation
2024-10-03 11:54:54 +02:00
Ashley Harrison
dd7f45011d
SingleTopNav: Add toolbar to Page and replace usage of AppChromeUpdate (#94022)
* add page-level toolbar for actions

* handle explore

* fix panel edit sizing

* remove comments

* remove TOGGLE_BUTTON_ID

* undo alerting changes

* use fixed position header

* feature toggle Page changes

* add page context for alerting use cases

* simplify

* prettier...
2024-10-03 09:52:01 +01:00
grafana-pr-automation[bot]
bcee44db5f
I18n: Download translations from Crowdin (#94168)
New Crowdin translations by GitHub Action

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-10-03 07:27:27 +03:00
Haris Rozajac
eb7573828e
Query Library: Search and filter (#94038)
* Search by query text, pagination

* Support default filtering by active datasource; filter by datasource name; improve table display

* Cleanup

* Fix update and delete url paths

* Fix test

* Use Stack, remove uneccessary function wrapper

* Notify when something is wrong with a row, add interaction tracking

* i18n
2024-10-02 11:33:14 -06:00
Misi
d3d5735098
Auth; Fix shourt url redirect when useSessionStorageForRedirection is enabled (#94163)
Fix shourt url redirect
2024-10-02 18:25:47 +02:00
Laura Benz
a0542e7307
RestoreDashboards: Fix restoring to 'Dashboards' (#94086)
* pairing WIP

* refactor: clean up

---------

Co-authored-by: joshhunt <josh@trtr.co>
2024-10-02 17:15:31 +02:00
Konrad Lalik
9fff736549
Alerting: Support k8s templates API (#92112)
Co-authored-by: Tom Ratcliffe <tom.ratcliffe@grafana.com>
Co-authored-by: Sonia Aguilar <soniaaguilarpeiron@gmail.com>
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2024-10-02 17:14:54 +02:00
Sonia Aguilar
fe656229c3
Alerting: Pluralize error tag (#94157) 2024-10-02 18:14:35 +03:00
Gilles De Mey
41b175e7ae
Alerting: Use useProduceNewAlertmanagerConfiguration for contact points (#88456) 2024-10-02 17:56:35 +03:00
Michael Derynck
97f480386f
Alerting: Update OnCall integration url (#93407)
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2024-10-02 16:13:55 +02:00
Sonia Aguilar
e80ef522bb
Alerting: Hide query name when using simplified mode in the alert rule (#93779)
* Hide query name when using simplified mode in the alert rule

* rename hideName to hideRefId
2024-10-02 13:55:48 +02:00
kay delaney
dae492f6c8
PanelSearchLayout: Support repeat panels (#94140) 2024-10-02 12:27:27 +01:00
grafana-pr-automation[bot]
a7497ae846
I18n: Download translations from Crowdin (#94138)
New Crowdin translations by GitHub Action

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-10-02 11:19:31 +01:00
Ashley Harrison
cf61ab3da2
SingleTopNav: Flip collapse arrows for better alignment (#94081)
flip megamenu arrows for better alignment
2024-10-02 11:08:34 +01:00
Misi
ddbbf8df4b
Auth: Fix redirection in case of ERR_TOKEN_REVOKED (#94137)
Fix redirection in case of token revoked error
2024-10-02 12:08:25 +02:00
linoman
763163603c
SSO LDAP: Bug-bashing follow-up changes (#94093)
* fix html encoding rendering

* Redirect to providers page

* Fix cert isEmpty

* Rework input fields into multiselect

* add disable button

* Rework MultiSelect design

* Remove prompt modal
2024-10-02 11:42:23 +02:00
Alex Khomenko
f55f7f2634
Routing: Replace Redirect component with Navigate (#94072)
* Routing: Replace Redirect with Navigate

* Use replace state

* Update routes.tsx

* Fix test
2024-10-02 09:44:18 +03:00
Brendan O'Handley
28d9cc7310
Explore metrics: Fix bug that turns off otel experience when selecting otel variables (#94106)
fix bug that turns of otel experience when selecting otel variables
2024-10-01 15:09:39 -05:00
Yuri Tseretyan
78290301f4
Alerting: Update GettableRuleGroupConfig and PostableRuleGroupConfig with missing fields supported by Prometheus (#94030) 2024-10-01 14:17:57 -04:00
grafana-pr-automation[bot]
a9095b1dd1
I18n: Download translations from Crowdin (#94076) 2024-10-01 15:27:28 +01:00
Alex Khomenko
586c95654d
Routing: Update more components using props.match to use hooks (#93918)
* RuleViewed: Get params from hook

* ProviderConfigPage: Use hooks for redux logic

* Update NewDashboardWithDS

* Update StorageFolderPage

* Update StoragePage

* Cleanup

* Update PublicDashboardPage

* Update RuleEditor

* Update BrowseFolderAlertingPage

* Update BrowseFolderLibraryPanelsPage

* Update SoloPanelPage

* Fix test

* Add useParams mocks

* Update ServiceAccountPage

* Simplify mocks

* Update SignupInvited

* Update Playlist pages

* Update AdminEditOrgPage

* Update UserAdminPage

* Update Silences

* Update BrowseDashboardsPage

* Update GrafanaModifyExport

* Update AppRootPage

* Remove useParams mock

* Update PublicDashboardsPages

* Cleanup

* Update PublicDashboardPage.test

* Cleanup

* Update PublicDashboardScenePage.test.tsx

* Update imports

* Revert AppRootPage changes

* Add back AppRootPage changes
2024-10-01 16:29:11 +03:00
Laura Benz
bc3e1df5e3
RestoreDashboards: Improve tracking (#93934)
feat: add tracking in DeleteModal
2024-10-01 15:27:25 +02:00
Alexa V
5cc11bd1a1
Dashboard Scene: Improve Angular experience (#92847)
In Dashboard Scene: 

* Display a warning in the panel header when rendering an angular panel
* Display a warning in the dashboard when rendering one or more angular panels
* Display a button to migrate in the dashboard banner
* Display a button to migrate in the panel editor
* Display a button to "Edit options" when it is an Angular panel, to open the panel JSON inspector to be able to edit the options
* Add tests

---------

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2024-10-01 15:02:13 +02:00
Juan Cabanas
6c91b65aca
ShareButton: Split copy link button and dropdown (#94020) 2024-10-01 09:46:32 -03:00
grafana-pr-automation[bot]
dc31bbb555
I18n: Download translations from Crowdin (#94065)
New Crowdin translations by GitHub Action

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-10-01 14:24:52 +02:00
Matheus Macabu
821bb235b3
CloudMigrations: document and re-generate api for syncing (#94063)
* CloudMigrations: document frontend open-api generator steps

* CloudMigrations: re-run api generation
2024-10-01 14:09:42 +02:00
Alex Khomenko
a20ebbc8f8
Routing: Replace useHistory hook (#94061)
* Update ConfigureIRM

* Update Browse
2024-10-01 14:11:58 +03:00
Tim Levett
8de1047f65
Change from Apps to "More Apps" (#93454)
* Change the label used for additional app links from apps to more apps so it doesn't conflict with applications, which is application observability, not the other bucket

* update to more apps

* more in german is mehr

* fix case, update translations correctly

* revert changes to de

* fix be tests

---------

Co-authored-by: joshhunt <josh@trtr.co>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2024-10-01 11:31:31 +01:00
Ashley Harrison
a8b94fe203
SingleTopNav: Move org switcher into Megamenu header (#94053)
move org switcher into megamenu header
2024-10-01 10:55:48 +01:00
Bogdan Matei
137da12c99
Fix panel search (#94043) 2024-10-01 12:45:31 +03:00
Sergej-Vlasov
d75fee5207
DataTrail: Remove newFiltersUI feature toggle usage from explore metrics (#93693)
remove newFiltersUI feature toggle usage from explore metrics
2024-10-01 09:45:16 +01:00
Dana Axinte
1a31abe254
CloudMigrations: Limit frontend query to get latest snapshots (#93639)
* latest param to endpoint and adapt frontend query

* change to sort param

* api

* remove description
2024-10-01 09:28:25 +01:00
grafana-pr-automation[bot]
8b6cbae96b
I18n: Download translations from Crowdin (#94032)
New Crowdin translations by GitHub Action

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-10-01 06:22:27 +01:00
Sonia Aguilar
cebcb38df2
Alerting: Style nits for the simple query mode (#93930)
* Style nits for the simple query mode

* update translations

* update text

* update translations

* update disable word to deactivate

* update preview text when not advanced options

* update text

* update text
2024-09-30 19:47:16 +01:00
grafana-pr-automation[bot]
fcbaf188c2
I18n: Download translations from Crowdin (#94013)
New Crowdin translations by GitHub Action

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-09-30 17:19:54 +01:00
Alexa V
8b215d60ac
Dashboard Scene: Add sceneGraph missing dependency (#94014)
Add sceneGraph missing dependency
2024-09-30 16:25:58 +01:00
Torkel Ödegaard
0c22aac7f0
Dashboards: Add support for systemPanelFilterVar and systemDynamicRowSizeVar variables in scenes (#93670)
Co-authored-by: kay delaney <kay@grafana.com>
2024-09-30 15:46:43 +01:00
Joao Silva
b937b70a46
Internationalization: Restore some plurals text (#94002) 2024-09-30 15:05:16 +01:00
grafana-pr-automation[bot]
ae05e4422d
I18n: Download translations from Crowdin (#93983)
New Crowdin translations by GitHub Action

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-09-30 15:00:20 +01:00
Joao Silva
a45662bf2d
Revert "Restore Dashboards: Add e2e tests (again) (#93214)" (#94003) 2024-09-30 14:26:16 +01:00
Torkel Ödegaard
b17e256a3c
DashboardScene: Fixes url issue with subpath when exiting edit mode (#93962) 2024-09-30 12:19:47 +02:00
Torkel Ödegaard
1c14c85b97
Dashboards: Fixes view & edit keyboard shortcuts when grafana is behind a subpath (#93955)
DashboardScene: Fixes view & edit keyboard shortcuts when grafana is behind a subpath
2024-09-30 12:19:24 +02:00
Joao Silva
42f1fcaf2c
Restore Dashboards: Add e2e tests (again) (#93214) 2024-09-30 10:44:15 +01:00
Sonia Aguilar
fc93d6f795
Alerting: Update texts in annotations step (#93977)
* Update texts in annotations step

* add translations
2024-09-30 09:57:09 +01:00
grafana-pr-automation[bot]
ef06724a2d
I18n: Download translations from Crowdin (#93910)
New Crowdin translations by GitHub Action

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-09-30 09:32:50 +01:00
Tom Ratcliffe
0b2478859a
Alerting: Allow linking to silence form with __alert_rule_uid__ value preset (#93526) 2024-09-30 09:20:53 +01:00
Tom Ratcliffe
e4698d9c52
Alerting: Fix eval interval not being saved when creating a new group (#93821) 2024-09-30 09:19:01 +01:00
Adela Almasan
f9f85131a9
FieldConfig: Add support for Actions (#92874)
Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
2024-09-27 23:12:37 -05:00
Brendan O'Handley
54ada3fc47
Explore metrics: Fix bug when switching from OTel enabled Prometheus DS to non OTel PRometheus DS (#93941) 2024-09-27 15:03:37 -05:00
Tom Ratcliffe
fc51ec70ba
Alerting: Add manage permissions UI logic for Contact Points (#92885)
* Add showPolicies prop

* Add manage permissions component for easier reuse within alerting

* Add method for checking whether to show access control within alerting

* Remove accidental console.log from main

* Tweak styling for contact point width and add manage permissions drawer

* Improve typing for access control type response

* Add basic test for manage permissions on contact points list

* Only show manage permissions if grafana AM and alertingApiServer is enabled

* Update i18n

* Add test utils for turning features on and back off

* Add access control handlers

* Update tests with new util

* Pass AM in and add tests

* Receiver OSS resource permissions

There is a complication that is not fully addressed: Viewer defaults to read:*
and Editor defaults to read+write+delete:*

This is different to other resource permissions where non-admin are not granted
any global permissions and instead access is handled solely by resource-specific
permissions that are populated on create and removed on delete.

This allows them to easily remove permission to view or edit a single resource
from basic roles.

The reason this is tricky here is that we have multiple APIs that can
create/delete receivers: config api, provisioning api, and k8s receivers api.
Config api in particular is not well-equipped to determine when creates/deletes
are happening and thus ensuring that the proper resource-specific permissions
are created/deleted is finicky.

We would also have to create a migration to populate resource-specific
permissions for all current receivers. This migration would need to be reset so
it can run again if the flag is disabled.

* Add access control permissions

* Pass in contact point ID to receivers form

* Temporarily remove access control check for contact points

* Include access control metadata in k8s receiver List & Get

GET: Always included.
LIST: Included by adding a label selector with value `grafana.com/accessControl`

* Include new permissions for contact points navbar

* Fix receiver creator fixed role to not give global read

* Include in-use metadata in k8s receiver List & Get

GET: Always included.
LIST: Included by adding a label selector with value `grafana.com/inUse`

* Add receiver creator permission to receiver writer

* Add receiver creator permission to navbar

* Always allow listing receivers, don't return 403

* Remove receiver read precondition from receiver create

Otherwise, Creator role will not be able to create their first receiver

* Update routes permissions

* Add further support for RBAC in contact points

* Update routes permissions

* Update contact points header logic

* Back out test feature toggle refactor

Not working atm, not sure why

* Tidy up imports

* Update mock permissions

* Revert more test changes

* Update i18n

* Sync inuse metadata pr

* Add back canAdmin permissions after main merge

* Split out check for policies navtree item

* Tidy up utils and imports and fix rules in use

* Fix contact point tests and act warnings

* Add missing ReceiverPermissionAdmin after merge conflict

* Move contact points permissions

* Only show contact points filter when permissions are correct

* Move to constants

* Fallback to empty array and remove labelSelectors (not needed)

* Allow `toAbility` to take multiple actions

* Show builtin alertmanager if contact points permission

* Add empty state and hide templates if missing permissions

* Translations

* Tidy up mock data

* Fix tests and templates permission

* Update message for unused contact points

* Don't return 403 when user lists receivers and has access to none

* Fix receiver create not adding empty uid permissions

* Move SetDefaultPermissions to ReceiverPermissionService

* Have SetDefaultPermissions use uid from string

Fixes circular dependency

* Add FakeReceiverPermissionsService and fix test wiring

* Implement resource permission handling in provisioning API and renames

Create: Sets to default permissions
Delete: Removes permissions
Update: If receiver name is modified and the new name doesn't exist, it copies
the permissions from the old receiver to the newly created one. If old receiver
is now empty, it removes the old permissions as well.

* Split contact point permissions checks for read/modify

* Generalise getting annotation values from k8s entities

* Proxy RouteDeleteAlertingConfig through MultiOrgAlertmanager

* Cleanup permissions on config api reset and restore

* Cleanup permissions on config api POST

note this is still not available with feature flag enabled

* Gate the permission manager behind FF until initial migration is added

* Sync changes from config api PR

* Switch to named export

* Revert unnecessary changes

* Revert Filter auth change and implement in k8s api only

* Don't allow new scoped permissions to give access without FF

Prevents complications around mixed support for the scoped permissions causing
oddities in the UI.

* Fix integration tests to account for list permission change

* Move to `permissions` file

* Add additional tests for contact points

* Fix redirect for viewer on edit page

* Combine alerting test utils and move to new file location

* Allow new permissions to access provisioning export paths with FF

* Always allow exporting if its grafana flavoured

* Fix logic for showing auto generated policies

* Fix delete logic for contact point only referenced by a rule

* Suppress warning message when renaming a contact point

* Clear team and role perm cache on receiver rename

Prevents temporarily broken UI permissions after rename when a user's source of
elevated permissions comes from a cached team or basic role permission.

* Debug log failed cache clear on CopyPermissions

---------

Co-authored-by: Matt Jacobson <matthew.jacobson@grafana.com>
2024-09-27 19:56:32 +01:00
Sven Grossmann
157ded7c3f
Tempo: Create trace to logs links with traces in structured metadata (#93923) 2024-09-27 17:11:09 +01:00
Ihor Yeromin
d5e35c4b78
Legend: Render legend threshold colors (#92838)
* feat(barchart): render legend threshold and value mapping colors

Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
2024-09-27 17:02:03 +02:00
Ashley Harrison
bc6752a51c
SingleTopNav: Add "Grafana" header to MegaMenu (#93798)
* add "Grafana" header to MegaMenu

* add truncation for really long custom app titles

* revert padding change since paddingLeft will handle it
2024-09-27 15:20:45 +01:00
renovate[bot]
0e4c90dd87
Update emotion monorepo (#93914)
* Update emotion monorepo

* add @emotion/serialize package + update unit test

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2024-09-27 15:16:12 +01:00
Torkel Ödegaard
1941ae21d7
DashboardScene: Refactor body property to be layout manager interface (#93738)
* Began layout refactor

* fixing tests

* Progress

* Progress

* Progress

* Progress

* Progress

* Progress

* finally no errors

* Remove unused interface

* Remove unused interface

* fixed tests

* Update

* Update

* Fixes to keyboard shortcuts and solo route

* fix lint issues
2024-09-27 15:11:28 +02:00
Alex Khomenko
5b53b37634
Routing: Update components using props.match to use hooks (#93792)
* RuleViewed: Get params from hook

* ProviderConfigPage: Use hooks for redux logic

* Update NewDashboardWithDS

* Update StorageFolderPage

* Update StoragePage

* Cleanup

* Update PublicDashboardPage

* Update RuleEditor

* Update BrowseFolderAlertingPage

* Update BrowseFolderLibraryPanelsPage

* Update SoloPanelPage

* Fix test

* Add useParams mocks

* Update ServiceAccountPage

* Simplify mocks

* Cleanup

* Reuse types for path params

* Remove mock for router compat in test

* Switch to element

---------

Co-authored-by: Tom Ratcliffe <tom.ratcliffe@grafana.com>
2024-09-27 15:39:29 +03:00
grafana-pr-automation[bot]
9fc4436418
I18n: Download translations from Crowdin (#93904)
New Crowdin translations by GitHub Action

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2024-09-27 13:28:37 +01:00
Konrad Lalik
db42af20ca
Alerting: Prometheus primary mode for the alert list page (#92975)
* Lazy loading of mimir groups

* Refactor rule statuses

* Use prometheus endpoint to populate namespace and group dropdowns

* Add a feature toggle

* Use lazy loading ruler rules if the feature toggle enabled

* Remove unnecessary props form dynamic table

* Remove query from hash calculation

* Conditionally load ns and group autocompletions from Prom or Ruler APIs

* Fix prometheus dto labels property type

* Add a new suggestions hook which provides autocomplete options for the alert rule form

* Improve delete status handling

* Add waiting for Prometheus endpoint consistency after update submission

* Get rule definition from ruler or prometheus endpoint in useCombinedRule

* Add Prometheus consistency check. Fix view page redirects

* Remove rules reload after rule creation, remove statuses from Prom primary mode

* Add waiting for Prometheus consistency on delete rule action

* Add groups list rendering improvements

* Add memo to useAbilities

* Fix GMA consistency check, fix GMA statuses

* defer filered rules rendering

* Update failing tests

* Update locales

* Add rule-id tests

* Remove unused action

* update loading styles

* Fix unrelated test

* Add a new object for reading alerting feature toggles, address minor review issues

* Improve consistency check

* update i18n

* Improve rule form redirects

* Refactor feature toggle handling

* Update docs/sources/setup-grafana/configure-grafana/feature-toggles/index.md

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>

* Update public/app/features/alerting/unified/components/rule-viewer/RuleViewer.tsx

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>

* Fix prettier issues

* Fix i18n

* Fix the feature toggle description

* Fix rule updates, fix ruler-based suggestions, wait for deletion for GMA rules

* Fix rename

* Remove unused code, improve copy

* Update i18n

* Fix url redirect when serving from subpath

---------

Co-authored-by: Tom Ratcliffe <tom.ratcliffe@grafana.com>
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
2024-09-27 14:27:16 +02:00
Tobias Skarhed
f49b4d35f2
OAuth: Add custom unauthorized message option in configuration (#93717)
* read custom message from config

* Read error key from bootdata

* oopsie

* Remove console.log

* Update docs and sample/default inis

* Add default key value to the config
2024-09-27 12:11:27 +02:00
Sonia Aguilar
3dbba3e509
Alerting: Fix Grafana recording rules expressions (#93878)
fix grafana recording rules expressions
2024-09-27 10:07:48 +02:00
Torkel Ödegaard
2cfba519f1
DashboardScene: Fixes urlsync issue when going from normal to home dashboard (#93758)
* DashboardScene: Fixes urlsync issue when going from normal to home dashboard

* Better fix

* Update
2024-09-27 09:10:49 +02:00
Joao Silva
1418e88695
Bookmarks: Do not query preferences if no user logged in (#93840) 2024-09-26 16:47:57 +01:00
renovate[bot]
efe8739864 Update dependency @types/node to v20.16.9 2024-09-26 14:55:59 +00:00
Claudiu Dragalina-Paraipan
59ea63384d
[bugfix] Fix missing URI in breadcrumbs in Teams view (#93828)
Fix missing URI in breadcrumbs in Teams view
2024-09-26 17:41:56 +03:00
Bruno
1b7cd4c684
Cloud migrations: store resource name in the cloud_migration_resource table (#93612)
* Cloud migrations: store resource name in the cloud_migration_resource table

* remove unused function: convertMigrateDataResponseToDTO

* make swagger-clean && make openapi3-gen

* use DB_Text for cloud_migration_resource.name instead of DB_Varchar
2024-09-26 11:16:52 -03:00
Ihor Yeromin
2e559bb333
Transformation: UI date field transformation (#93807)
fix(transformation): ui date field transformation
2024-09-26 16:12:58 +02:00
Haris Rozajac
eb8e6c6a9f
Query Library: Display query text even when datasource doesn't have getQueryDisplayText (#93668)
Display query text even when datasource doesn't have getQueryDisplayText
2024-09-26 08:10:02 -06:00
Gilles De Mey
4b1d8eeef0
Alerting: Remove filter for state without reason (#93604) 2024-09-26 15:40:04 +02:00