Commit Graph

7569 Commits

Author SHA1 Message Date
Drew Slobodnjak
3e583ff423
VizRepeater: Prevent opposite scrollbar (#94230)
* VizRepeater: Prevent opposite scrollbar

* Update packages/grafana-ui/src/components/VizRepeater/VizRepeater.tsx

Co-authored-by: Adela Almasan <88068998+adela-almasan@users.noreply.github.com>

* Update packages/grafana-ui/src/components/VizRepeater/VizRepeater.tsx

Co-authored-by: Adela Almasan <88068998+adela-almasan@users.noreply.github.com>

---------

Co-authored-by: Adela Almasan <88068998+adela-almasan@users.noreply.github.com>
2024-10-07 10:05:09 -07: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
renovate[bot]
65fc40385a Update dependency eslint-plugin-react to v7.37.1 2024-10-07 13:33:33 +00: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
712314e832
CloudMigrations: create onPremToCloudMigrationsAlerts feature toggle in experimental stage (#94257)
CloudMigrations: create onPremToCloudMigrationsAlerts feature toggle in experimental stage

This feature toggle requires the `onPremToCloudMigrations` toggle to be enabled in order to work.

Given migration of Alerts (and child resources) is more critical, this flag was separated from
the main one.
2024-10-07 12:53:24 +02:00
Drew Slobodnjak
d0abb08f31
Limit: Prevent negative limit (#94237) 2024-10-04 12:05:16 -07:00
renovate[bot]
797da67467 Update dependency @lezer/common to v1.2.2 2024-10-04 17:27:16 +00:00
renovate[bot]
6344eeac3b Update dependency @grafana/faro-web-sdk to v1.10.2 2024-10-04 16:52:13 +00:00
renovate[bot]
77e1f222a0
Update babel monorepo to v7.25.7 (#94262)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-10-04 15:58:12 +01:00
renovate[bot]
6ed3868921 Update dependency @emotion/css to v11.13.4 2024-10-04 14:22:51 +00:00
renovate[bot]
94444319ec Update React Aria 2024-10-04 13:59:26 +00: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
Ihor Yeromin
9801b92c3d
Table: Fix table cell text jumping on hover (#93913)
fix(table): table cell text jumping on hover
2024-10-04 13:20:15 +02: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
Arati R.
a42caa7a61
K8s/Folders: Fix tests for creating folders (#94192)
* Add feature toggle grafanaAPIServerTestingWithExperimentalAPIs
* Customise registration of FolderAPIBuilder for tests and fix tests
2024-10-03 12:11:40 +02:00
Tobias Skarhed
e48d166c3e
New Select: width auto sets width based on content (#93800)
* Add inline prop for AutoSizeInput

* Rename to autoSize

* Use conditional props and width auto

* remove variable

* Remove 100% max width
2024-10-03 11:45:22 +03:00
Bogdan Matei
a87df0528b
Prometheus: Interpolate vars in adhoc filters request (#94087)
* Interpolate vars in adhoc filters request

* interpolate variables on BE

---------

Co-authored-by: Kyle Brandt <kyle@grafana.com>
2024-10-01 18:33:06 +03:00
kay delaney
1b82595251
UI/AutoSizeInput: Fixes issue where controlledValue being null caused crash (#94078) 2024-10-01 16:02:26 +01:00
Kyle Brandt
2a73b89374
Prometheus: Add resource for suggestions that include scopes/adhoc filters (#94001)
Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
Co-authored-by: Bogdan Matei <bogdan.matei@grafana.com>
2024-10-01 07:17:59 -04:00
renovate[bot]
8338e92a70
Update dependency sass-loader to v16 (#94006)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-10-01 10:30:32 +01:00
ismail simsek
f8fd45892d
Chore: Fix legend changing when using incremental querying (#93529)
* rename variables

* fix setting legend

* yarn prettier:write

* only update displayNameFromDS
2024-10-01 10:58:08 +02:00
owensmallwood
6a3eb276ef
Grafana Indexing PoC: Adds feature flag and gRPC endpoint (#93356)
* adds Filter gRPC and make protobuf

* adds route for querying the filter gRPC

* wires up Filter gRPC call

* [WIP] index from start

* renames gRPC endpoint to "Search"

* adds /apis/search route into k8s routes. Hacky for now.

* updates readme - wrong casing

* adds feature toggle for unified storage search

* hides US search behind feature flag. Clean up print statements.

* removes indexer - will be added in another PR

* Search: Add API Builder

* adds required method

* implementing UpdateAPIGroupInfo (WIP)

* adds groupversion

* commenting out for now

* remove unneeded code from experimenting and update register.go to match interface required

* namespaces search route

---------

Co-authored-by: leonorfmartins <leonorfmartins@gmail.com>
Co-authored-by: Todd Treece <todd.treece@grafana.com>
2024-09-30 13:46:14 -06:00
Joao Silva
a45662bf2d
Revert "Restore Dashboards: Add e2e tests (again) (#93214)" (#94003) 2024-09-30 14:26:16 +01:00
Joao Silva
42f1fcaf2c
Restore Dashboards: Add e2e tests (again) (#93214) 2024-09-30 10:44:15 +01:00
Tom Ratcliffe
af82dfa95d
Alerting/Chore: Fix TimeRangeInput not working across multiple months (#93622) 2024-09-30 10:26:07 +01:00
jackyin
e23ba32722
Transformations: Fix crash in Config from query results (#93427) 2024-09-28 09:04:40 -05:00
Adela Almasan
47b51326cc
VizTooltip: Update datalinks styling (#93950) 2024-09-28 05:33:10 +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
Leon Sorokin
165ca3b4e8
Chore: uPlot v1.6.31 (#93952) 2024-09-27 23:11:05 -05: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
renovate[bot]
0401fa1652
Update dependency @faker-js/faker to v9 (#93917)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-09-27 15:35:15 +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
xiyu95
ce8c42ab35
chore: enforce the validationMessageHorizontalOverflow for InlineField (#93858)
chore: enforce the validationMessageHorizontalOverflow prop for inlineField
2024-09-27 07:01:18 -07: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
Jack Westbrook
012d62782c
Fix: Prevent import errors caused by Rollup 4 (#93903)
fix(packages): prevent import errors by injecting exports.esmodule and check for default prop
2024-09-27 12:18:52 +01:00
renovate[bot]
08dab3f816
Update dependency eslint-plugin-react to v7.37.0 (#93891)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2024-09-27 10:48:11 +01:00
Jack Westbrook
f22bee8ca2
Build: Migrate packages to rollup v4 (#93731)
* chore(packages): bump rollup and rollup plugins to latest

* chore(packages): fix rollup node-externals plugin imports

* chore(packages): update build/bundle scripts to pass configPlugin arg to rollup

* feat(packages): migrate rollup configs to be esm compliant

* feat(packages): build using es2018 target and use same tsconfig and tsc for rollup
2024-09-27 11:00:13 +02:00
renovate[bot]
efe8739864 Update dependency @types/node to v20.16.9 2024-09-26 14:55:59 +00:00
renovate[bot]
ad960827cc Update dependency @types/jquery to v3.5.31 2024-09-26 14:33:05 +00:00
Hugo Kiyodi Oshiro
be8c8baf6f
ConfirmModal: Allow button disable to be externally managed (#93446) 2024-09-26 15:56:25 +02:00
renovate[bot]
eee53810c0 Update dependency @grafana/faro-web-sdk to v1.10.1 2024-09-26 13:31:09 +00:00
linoman
e2816ee51a
RolePickerDrawer: Add feature toggle (#93752)
Add feature toggle
2024-09-26 14:51:38 +02:00
Edvard Falkskär
20a66343bd
SparklineCell: Improve text alignment factor (#93539) 2024-09-26 14:41:03 +03:00
kay delaney
6c8f24adc9
Dashboards: Fix issue with percentage difference formatting (#93389)
* Dashboards: Fix issue with percentage difference formatting

---------

Co-authored-by: Ihor Yeromin <yeryomin.igor@gmail.com>
2024-09-26 11:15:51 +01:00
Sonia Aguilar
536edee7bf
Alerting: Query and expressions section simplification (#93022)
* Add mode switch in Query section

* Implement simple query mode : WIP

* fix logic switching mode

* move guard and get methodd to another folder

* Add more requiremts for being transformable from advanced to not advanced mode

* fix usig mode when it's not a grafana managed alert

* Show warning when switching to not advanced and its not possible to convert

* Add feature toggle alertingQueryAndExpressionsStepMode

* fix test

* add translations

* address PR feedback

* Use form context for sharing simplfied mode used, save in local storage and use the new fields in the api

* add check to valid reducer and threshold when switching to simplified mode

* Use only one expression list

* fix test

* move existing rule check outside storeInLocalStorageValues

* add id in InlineSwitch to handle onClick on label

* fix

* Fix default values when editing existing rule

* Update dto fields for the api request

* fix snapshot

* Fix recording rules to not show switch mode

* remove unnecessary Boolean conversion

* fix areQueriesTransformableToSimpleCondition

* update text

* pr review nit

* pr review part2
2024-09-26 08:33:14 +02:00
Adela Almasan
c36f7aa92b
VizTooltip: Improved sizing (#93762)
Co-authored-by: Staton Hysell <staton.hysell@grafana.com>
2024-09-25 20:47:03 -05:00
Jeff Levin
a21a232a8e
Revert read replica POC (#93551)
* Revert "chore: add replDB to team service (#91799)"

This reverts commit c6ae2d7999.

* Revert "experiment: use read replica for Get and Find Dashboards (#91706)"

This reverts commit 54177ca619.

* Revert "QuotaService: refactor to use ReplDB for Get queries (#91333)"

This reverts commit 299c142f6a.

* Revert "refactor replCfg to look more like plugins/plugin config (#91142)"

This reverts commit ac0b4bb34d.

* Revert "chore (replstore): fix registration with multiple sql drivers, again (#90990)"

This reverts commit daedb358dd.

* Revert "Chore (sqlstore): add validation and testing for repl config (#90683)"

This reverts commit af19f039b6.

* Revert "ReplStore: Add support for round robin load balancing between multiple read replicas (#90530)"

This reverts commit 27b52b1507.

* Revert "DashboardStore: Use ReplDB and get dashboard quotas from the ReadReplica (#90235)"

This reverts commit 8a6107cd35.

* Revert "accesscontrol service read replica (#89963)"

This reverts commit 77a4869fca.

* Revert "Fix: add mapping for the new mysqlRepl driver (#89551)"

This reverts commit ab5a079bcc.

* Revert "fix: sql instrumentation dual registration error (#89508)"

This reverts commit d988f5c3b0.

* Revert "Experimental Feature Toggle: databaseReadReplica (#89232)"

This reverts commit 50244ed4a1.
2024-09-25 15:21:39 -08:00
Serena
c822feff9e
Home: add setup guide tab under home tab (#92947)
* feat: add setup guide in home tab

* chore: add feature toggle for setup guide

* chore: add feature toggle for sub menu

* chore: run pretier

* chore: run i18n

* chore: run generated files again

* chore: update description

* chore: update comment to trigger test flow

* chore: trigger test

* chore: fix styling
2024-09-25 18:20:04 +01:00