Commit Graph

1364 Commits

Author SHA1 Message Date
Levente Balogh
eb3ee35e1c
Frontend Routing: Always render standalone plugin pages using the <AppRootPage> (#57771)
* chore: fix go lint issues

* feat(Routing): route standalone plugin pages to the `AppRoutePage`

* feat(plugin.json): introduce a new field called `isCorePage` for `includes`

* chore: add explanatory comments for types

* refactor(AppRootPage): receive the `pluginId` and `pluginSection` through the props

Now we are able to receive these as props as the pluginId is defined on navLinks
that are registered by plugins.

* chore: update teests for AppRootPage

* fix: remove rebase issue

* tests(applinks): add a test for checking isCorePage plugin page setting

* refactor(applinks): update tests to use FindById() and be more resilient to changes

* fix: Go lint issues

* refactor(routes): use cleaner types when working with plugin nav nodes

Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>

* chore: fix linting issues

* t: remove `isCorePage` field from includes

Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>
2022-11-07 15:19:31 +01:00
Ryan McKinley
bff19747bd
Timeseries: Use standard editor for fillBelowTo field picker (#58283) 2022-11-04 22:00:46 -07:00
renovate[bot]
5f5b3521d9
Update dependency rollup-plugin-dts to v5 (#58258)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-04 17:04:00 +00:00
renovate[bot]
10ee9f129d
Update dependency rollup-plugin-node-externals to v5 (#58259)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-04 16:52:15 +00:00
renovate[bot]
c1ea944c79
Update dependency @types/node to v18 (#58139)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-04 15:28:47 +00:00
Levente Balogh
376f4b0cc7
Navigation: Add pluginId to standalone plugin page NavLinks (#57769)
* feat(Navigation): add `pluginId` to NavLink and override sibling navlinks with the same URL

* test replacing page from plugin

* chore: fix go lint issues

* fix(NavLink): change `PluginId` to `PluginID`

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>

* fix(NavLink): make the `PluginId` -> `PluginID` change everywhere

* chore(navModel.ts): update explanatory comment for `pluginId`

Co-authored-by: Miklós Tolnai <miklos.tolnai@grafana.com>
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-11-03 21:19:42 +01:00
Ryan McKinley
857e545c5a
FeatureFlags: set defaults in the registry rather than the ini file (#58106) 2022-11-03 17:34:01 +00:00
renovate[bot]
15b553c11c
Update dependency @rollup/plugin-node-resolve to v15 (#58130)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-03 11:43:28 +00:00
renovate[bot]
ed31f0fe20
Update dependency @rollup/plugin-json to v5 (#58083)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-03 11:17:52 +00:00
renovate[bot]
cf5f88ca47
Update dependency @rollup/plugin-commonjs to v23 (#58075)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-03 06:56:11 -04:00
Marcus Andersson
b804b2f073
Plugins: Added hook to make it easier to track interactions in plugins (#56126)
* first stab at context away plugin tracking.

* adding a plugin context and a hook to get hold of a tracker that always appends the plugin context information.

* wip

* improved the code a bit.

* wip

* Fixed type errors.

* added datasource_uid to data sources.

* fixed error message when trying to use hook outside of context.

* small refactoring according to feedback.

* using the correct provider for data source context.

* check not needed.

* enforcing the interaction name to start with grafana_plugin_

* exposing guards for the other context type.

* added structure for writing reporter hook tests.

* added some more tests.

* added tests.

* reverted back to inheritance between context types.

* adding mock for getDataSourceSrv
2022-11-02 16:57:57 +01:00
Carl Bergquist
06705a49e2
Instrumentation: Log plugin and datasource info for each plugin request. (#54769)
Signed-off-by: bergquist <carl.bergquist@gmail.com>
2022-11-02 14:51:51 +01:00
renovate[bot]
909d0f4ced
Update Monthly patch updates (#58002)
* Update Monthly patch updates

* update typescript sdk, add ignore for emotion css prop

* fix unit tests

* type fixes

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-11-02 12:05:32 +00:00
renovate[bot]
0ed71dbdd4
Update dependency marked to v4.2.0 (#58000)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-01 16:02:49 +00:00
Torkel Ödegaard
f0ab4bea8c
Scene: SceneObject and SceneObjectBase refinements and stricter typing (#57851) 2022-10-31 15:16:16 +01:00
Torkel Ödegaard
19b961465c
TopNav: Make it possible to to have sections without children (#57815) 2022-10-31 11:01:34 +01:00
Ryan McKinley
7346280316
LibraryPanels: Load library panels in the frontend rather than the backend (#50560)
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-10-26 15:38:20 -07:00
Kristin Laemmert
b346ae0310
feat: add new Folder table migration & define nested folder interfaces (#56882)
* feat: add new Folder table migration

Add a new folder table to support the Nested Folders feature.

https://github.com/grafana/grafana/issues/56880

* register nested folders feature flag (unused)

* feat: nested folder service (experiment)

This commit adds a NestedFolderSvc interface and stubbed out implementation as an alternative to the existing folder service. This is an experimental feature to try out different methods for backwards compatibility and parallelization, so that Grafana can continue to store folders in the existing (non-nested) manner while also using the new nested folder service.

Eventually the new service will (hopefully) become _the_ service, at which point the legacy service can be deprecated (or remain, with the new service methods replacing the original. whatever makes sense at the time).


* nested folders: don't run the new migration

This commit removes the nested folder migration from the list of active migrations so we can merge this branch and continue development without impacting Grafana instances built off main.
2022-10-26 10:15:14 -04:00
Ryan McKinley
a3acfb1a48
Chore: Register a feature flag for "newDBLibrary" (#57468) 2022-10-25 18:20:41 -07:00
Beto Muniz
069a4cb21b
Fix orderFieldsTransformer sorting (#57635) 2022-10-25 17:48:14 -03:00
Ashley Harrison
d2a70bc42d
Chore: more any/type assertion improvements (#57450)
* more friday any/type assertion improvements

* Apply suggestions from code review

Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>

* Update public/app/angular/promiseToDigest.test.ts

Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>

Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>
2022-10-25 11:04:35 +02:00
Leon Sorokin
0640eeef0a
Number formatting: only 0-trim decimals in y axis ticks. omit currency, locale units. (#57386) 2022-10-21 21:35:29 -06:00
Leon Sorokin
7eac79b5f8
Number formatting: Strip trailing zeros after decimal point when decimals=auto (#57373) 2022-10-20 17:56:21 -05:00
Leon Sorokin
883d61d191
Transformers: PartitionByValues (#56767)
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-10-20 17:22:02 -05:00
Ryan McKinley
e3c2859e83
Geomap: Upgrade to openlayers 7.x (#57317) 2022-10-19 17:03:44 -07:00
Gabriel MABILLE
717bd4a6c0
RBAC: Add a feature toggle for primitives we provide to OnCall (#57289) 2022-10-19 18:10:09 +02:00
Victor Marin
9c514748f7
Revert data links code for sorted vector case (#57175) 2022-10-18 08:59:53 -04:00
Victor Marin
76d6e3c075
TimeseriesPanel: Fix variables in data links (#56729)
* TimeseriesPanel: Fix variables in data links

* Refactor variable fix for all Timeseries panels

* cr mods
2022-10-18 14:22:31 +03:00
Torkel Ödegaard
9f5e691994
Theme: Inter font (behind feature toggle) (#56441)
* Theme: Inter font change with new line-height

* Add it behind feature toggle

* make buildVariant easier to read + enforce integer multiples of 2 (#56486)

* Minor update

* Update

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-10-15 16:22:33 +02:00
Josh Hunt
2e16d5499e
Dashboard: Add dashboard validation warning to save drawer (#55732)
* add api route for validating a dashboard json

* add feature flag for showDashboardValidationWarnings

* tidy up

* comments and messages

* swagger specs

* fix typo

* more swagger

* tests!

* tidy test a little bit

* no more ioutil

* api will return different status code depending on validation error

* clean up

* handle 4xx errors

* remove console.log

* fix backend tests

* tidy up

* Swagger: Exclude alpha endpoints

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>
2022-10-14 09:51:05 -04:00
ying-jeanne
80ede174dd
update the feature toggle usage in backend (#56787) 2022-10-12 13:43:35 +02:00
Gabriel MABILLE
10c080dad1
LDAP: Add skip_org_role_sync configuration option (#56679)
* LDAP: Add skip_org_role_sync option

* Document the new config option

* Nit on docs

* Update docs/sources/setup-grafana/configure-security/configure-authentication/ldap.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Docs suggestions

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Add test, Fix disabled user when no role

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Jguer <joao.guerreiro@grafana.com>
2022-10-12 13:33:33 +02:00
Gareth Dawson
10a34a041c
Add feature tracking for LogRow.tsx (#56656)
* Add feature tracking for LogRow.tsx

* Add type and logRowUid to reportInteraction

* Rename logs variable
2022-10-11 10:04:43 +01:00
Polina Boneva
129a5a29e7
PanelChrome: New Panel Header design Feature Flag (#56450)
* add feature toggle newPanelHeader

* add feature toggle newPanelHeader

* more explicit naming and description of PanelChrome feature flag
2022-10-10 18:03:16 +03:00
Artur Wierzbicki
bf264d2f76
Query library: requiresDevMode dummy backend (#56466)
* query library - dummy backend

* fix tests

* dont explicitly marshall backend dataresponse

* skip integration tests

* null check for tests

* added query library to codeowners

* null check for tests

* lint
2022-10-07 11:31:45 -07:00
Joey Tawadrous
74c809f544
Plugins: Introduce new Flame graph panel (#56376)
* Flamegraph

* Updated flame graph width/height values

* Fix top table rendering issue

* Add feature toggle for flamegraph in explore

* Update tests

* Hide flamegraph from dash panel viz list if feature toggle not enabled

* Show table if no flameGraphFrames

* Add flame graph to testdata ds

* Minor improvement
2022-10-07 11:39:14 +01:00
Ryan McKinley
609abf00d1
ObjectStore: Write json as json when possible (#56433) 2022-10-06 15:48:53 -04:00
Matias Chomicki
729ce8bb72
Loki: query editor using Monaco (#55391)
* loki: switch to a monaco-based query field, step 1 (#46291)

* loki: use monaco-logql (#46318)

* loki: use monaco-logql

* updated monaco-logql

* fix all the tests (#46327)

* loki: recommend parser (#46362)

* loki: recommend parser

* additional improvements

* more improvements

* type and lint fixes

* more improvements

* trigger autocomplete on focus

* rename

* loki: more smart features (#46414)

* loki: more smart features

* loki: updated syntax-highlight version

* better explanation (#46443)

* better explanation

* improved help-text

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>

* Fix label

* feat(loki-monaco-editor): add monaco-logql as a dependency

* feat(loki-monaco-editor): add back range function removed during merge

* feat(loki-monaco-editor): sync imports with recent changes

* feat(loki-monaco-editor): add missing lang provider functions

* feat(loki-monaco-editor): fix imports

* feat(loki-monaco-editor): display monaco editor by default

Temporarily

* Chore: remove commented code

* Chore: minor refactor to NeverCaseError

* Chore: minor code cleanups

* feat(loki-monaco-editor): add history implementation

Will see how it behaves and base the history slicing on tangible feedback

* feat(loki-monaco-editor): turn completion data provider into a class

* Chore: fix missing imports

* feat(loki-monaco-editor): refactor data provider methods

Move complexity scattered everywhere to the provider

* Chore: clean up redundant code

* Chore: minor comments cleanup

* Chore: simplify override services

* Chore: rename callback

* feat(loki-monaco-editor): use query hints implementation to parse expression

* feat(loki-monaco-editor): improve function name

* Chore: remove superfluous variable in favor of destructuring

* Chore: remove unused imports

* Chore: make method async

* feat(loki-monaco-editor): fix deprecations and errors in situation

* feat(loki-monaco-editor): comment failing test case

* Chore: remove comment from test

* Chore: remove duplicated completion item

* Chore: fix linting issues

* Chore: update language provider test

* Chore: update datasource test

* feat(loki-monaco-editor): create feature flag

* feat(loki-monaco-editor): place the editor under a feature flag

* Chore: add completion unit test

* Chore: add completion data provider test

* Chore: remove unwanted export

* Chore: remove unused export

* Chore(loki-query-field): destructure all props

* chore(loki-completions): remove odd string

* fix(loki-completions): remove rate_interval

Not supported

* fix(loki-completions): remove line filters for after pipe case

We shouldn't offer line filters if we are after first pipe.

* refactor(loki-datasource): update default parameter

* fix(loki-syntax): remove outdated documentation

* Update capitalization in pkg/services/featuremgmt/registry.go

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>

* refactor(situation): use node types instead of names

* Chore: comment line filters pending implementation

It's breaking the build due to a linting error.

* Chore: update feature flag test after capitalization change

* Revert "fix(loki-completions): remove line filters for after pipe case"

This reverts commit 3d003ca4bc.

* Revert "Chore: comment line filters pending implementation"

This reverts commit 84bfe76a6a.

Co-authored-by: Gábor Farkas <gabor.farkas@gmail.com>
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
Co-authored-by: Ivana Huckova <ivana.huckova@gmail.com>
2022-10-06 10:35:30 -04:00
Torkel Ödegaard
0958d9ba55
Theme: Change body line-height to fix alignment issue (#56442)
* Theme: Change body line-height to fix alignment issue

* Updates
2022-10-06 12:59:43 +02:00
Joe Blubaugh
b476ae62fb
Alerting: Write and Delete multiple alert instances. (#55350)
Prior to this change, all alert instance writes and deletes happened
individually, in their own database transaction. This change batches up
writes or deletes for a given rule's evaluation loop into a single
transaction before applying it.

These new transactions are off by default, guarded by the feature toggle "alertingBigTransactions"

Before:

```
goos: darwin
goarch: arm64
pkg: github.com/grafana/grafana/pkg/services/ngalert/store
BenchmarkAlertInstanceOperations-8           398           2991381 ns/op         1133537 B/op      27703 allocs/op
--- BENCH: BenchmarkAlertInstanceOperations-8
    util.go:127: alert definition: {orgID: 1, UID: FovKXiRVzm} with title: "an alert definition FTvFXmRVkz" interval: 60 created
    util.go:127: alert definition: {orgID: 1, UID: foDFXmRVkm} with title: "an alert definition fovFXmRVkz" interval: 60 created
    util.go:127: alert definition: {orgID: 1, UID: VQvFuigVkm} with title: "an alert definition VwDKXmR4kz" interval: 60 created
PASS
ok      github.com/grafana/grafana/pkg/services/ngalert/store   1.619s
```

After:

```
goos: darwin
goarch: arm64
pkg: github.com/grafana/grafana/pkg/services/ngalert/store
BenchmarkAlertInstanceOperations-8          1440            816484 ns/op          352297 B/op       6529 allocs/op
--- BENCH: BenchmarkAlertInstanceOperations-8
    util.go:127: alert definition: {orgID: 1, UID: 302r_igVzm} with title: "an alert definition q0h9lmR4zz" interval: 60 created
    util.go:127: alert definition: {orgID: 1, UID: 71hrlmR4km} with title: "an alert definition nJ29_mR4zz" interval: 60 created
    util.go:127: alert definition: {orgID: 1, UID: Cahr_mR4zm} with title: "an alert definition ja2rlmg4zz" interval: 60 created
PASS
ok      github.com/grafana/grafana/pkg/services/ngalert/store   1.383s
```

So we cut time by about 75% and memory allocations by about 60% when
storing and deleting 100 instances.
2022-10-06 14:22:58 +08:00
Tania
222c33c307
Remove branding feature toggle (#56379) 2022-10-05 14:07:35 +02:00
George Rodrigues
8950d86141
fix: some typos (#56171) 2022-10-04 18:43:49 -05:00
Gábor Farkas
3c1de8750c
GrafanaData: Deprecate the LogsParser type (#56242)
* added copy of code to main-grafana

* grafana-data: add depreceted-notice
2022-10-04 11:25:22 +02:00
renovate[bot]
bcd1c48a4d
Update dependency rollup-plugin-esbuild to v4.10.1 (#56191)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-03 16:27:37 +01:00
renovate[bot]
8f578d18ce
Update dependency rollup to v2.79.1 (#56187)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-03 16:42:55 +02:00
Gábor Farkas
a069a01853
grafana-data: logs: add deprecated-info (#56077) 2022-09-30 14:22:04 +02:00
Jack Westbrook
b81f90cd0c
Toolkit: Fix script failures due to missing import paths (#55857)
* fix(toolkit): package without dist folder so config file paths are correct

* chore(packages): make sure to bundle readme, changelog and apache2 license

* refactor(packages): recursively copy src when prepacking toolkit

* chore(toolkit): lock down babel dependencies. use grafana-eslint-config@5 for TS4.8 support
2022-09-28 17:04:55 +02:00
Joao Silva
cf1862ecc4
Storybook: Explicitly set init on a registry to stop Storybook from being broken (#55909) 2022-09-28 13:29:41 +01:00
Torkel Ödegaard
e31cb93ec0
NavTree: Make it possible to configure where in nav tree plugins live (#55484)
* NewIA: Plugin nav config

* progress

* Progress

* Things are working

* Add monitoring node

* Add alerts and incidents

* added experiment with standalone page

* Refactoring by adding a type for navtree root

* First test working

* More tests

* more tests

* Progress on richer config and sorting

* Sort weight working

* Path config

* Improving logic for not including admin or cfg nodes, making it the last step so that enterprise can add admin nodes without having to worry about the section not existing

* fixed index routes

* removed file

* Fixes

* Fixing tests

* Fixing more tests and adding support for weight config

* Updates

* Remove unused fake

* More fixes

* Minor tweak

* Minor fix

* Can now control position using sortweight even when existing items have no sortweight

* Added tests for frontend standalone page logic

* more tests

* Remove unused fake and fixed lint issue

* Moving reading settings to navtree impl package

* remove nav_id setting prefix

* Remove old test file

* Fix trailing newline

* Fixed bug with adding nil node

* fixing lint issue

* remove some code we have to rethink

* move read settings to PrivideService and switch to util.SplitString
2022-09-28 08:29:35 +02:00
Tania
4a4201ec92
Chore: Update versions (#55813) 2022-09-27 14:07:16 +02:00
Alexander Emelin
55aae79744
GRPC Server: Add gRPC server service (#47849)
Co-authored-by: Todd Treece <todd.treece@grafana.com>
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-09-26 16:25:34 -04:00
Torkel Ödegaard
018733dd24
PluginDetails: Make plugin details page look good in topnav (#55571)
* PluginDetails: Make plugin details page look good in topnav

* Minor style tweak aligning things

* minor refactoring where I moved the logic to decide the default tab into its own hook.

* refactor(plugindetails): first pass at using navmodel for usePluginDetailsTabs hook

* refactor(plugindetails): move "reset page when uninstalling plugin" to installcontrols

this prevents a user from seeing a blank page if they uninstall an app plugin whilst viewing a
config page

* refactor(plugindetails): remove usage of toIconName and reduce nested if

* Trying to fix tests

* minor fix

* test(plugindetails): update selectors causing failing tests

* chore(plugindetails): remove commented out test code

* test(plugindetails): clean up - remove unnecesary usage of waitFor

Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>
Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
2022-09-26 15:04:07 +02:00
Will Browne
b25ea75bac
Plugins: Add secure JSON fields to plugin setting DTO (#55313)
* add secure JSON fields to plugin setting DTO

* add nil pointer fix

* adding secureJsonFields to the plugin meta.

Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>
2022-09-21 12:20:11 +02:00
Jo
006944a360
Auth: Add development manual override (#55496)
* Auth: Add development manual override

* rename to disable_sync_lock
2022-09-20 11:48:40 -04:00
Alexander Emelin
0e6a8cc6ac
Live: Migrate to centrifuge-js v3 (new API and client protocol) (#51977) 2022-09-20 11:39:46 -04:00
Josh Hunt
d014a3a09b
Echo: Add support for Google Analytics 4 (#55446)
* user essentials mob! 🔱

lastFile:public/app/core/services/echo/backends/analytics/GA4Backend.ts

* user essentials mob! 🔱

* user essentials mob! 🔱

lastFile:public/app/core/services/echo/backends/analytics/GA4Backend.ts

* user essentials mob! 🔱

lastFile:public/app/core/services/echo/backends/analytics/GA4Backend.ts

* user essentials mob! 🔱

lastFile:public/app/app.ts

* user essentials mob! 🔱

Co-authored-by: eledobleefe <laura.fernandez@grafana.com>
Co-authored-by: Leodegario Pasakdal <leodegario.pasakdal@grafana.com>
2022-09-20 03:13:14 -07:00
kay delaney
64bbb7a7ce
Chore: Update and enforce usage of typed react-redux hooks (#55349)
* Chore: Update and enforce usage of typed react-redux hooks
2022-09-19 10:49:35 +01:00
Leo
1a0cbdeabe
Navigation: Add help menu to top search bar (#55062)
* add help menu to top search bar

* fixes

* handle preventDefault in node graph specifically

* use icon prop of MenuItem

* undo changes to ContextMenuPlugin/DataLinksContextMenu

* remove unused component

* revert storybook changes

* Tweaks

* remove unused style

* stop propagation on the header so version can be highlighted

* make sure useContextMenu has the exact same logic as before

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-09-17 18:17:00 +02:00
Gareth Dawson
98a8908910
Loki: Remove any type from logs.test.ts (#55303)
* Remove any type from logs.test.ts

* Replace unknown types and move type casting to variables
2022-09-16 16:57:42 +01:00
Piotr Jamróz
9b4cdfe652
Correlations: Hide Correlations Page behind a feature toggle (#55224)
* Hide Correlations Page behind a toggle

* Remove redundant defaults

* Ensure top nav is rendered when correlations are disabled

This is for the case when:

[feature_toggles]
topnav = true
2022-09-16 15:14:27 +02:00
Jo
3e2e9f93b9
Auth: Allow admins to manually change oauth user role if oauth_skip_org_role_update_sync is enabled (#55182)
* Auth: Allow admins to change oauth user info it it's not synced.

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

* Update public/app/features/admin/UserAdminPage.tsx

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

* Add missing import

* Simplify init

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

* SAML: Add option to skip org role sync (#55230)

* SAML: Add option to skip org role sync

* Modify frontend accordingly

* Remove update from config option name

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Remove update from config option name

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Fix typo

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
Co-authored-by: gamab <gabi.mabs@gmail.com>
Co-authored-by: Josh Hunt <joshhunt@users.noreply.github.com>
2022-09-15 12:06:09 -04:00
Seyaji
7ec1d137b4
Logs: Relocate "show context" button, add copy line log button (#50977)
* add context button to right side of log row

* add context button to right side of log row

* add context button to right side of log row

* add context button to right side of log row

* add show-context icon

Co-authored-by: Sven Grossmann <svennergr@gmail.com>
2022-09-15 17:13:58 +02:00
Adam Simpson
92857ef331
CloudMonitor: Remove cloudMonitoringExperimentalUI feature flag (#55054)
* CloudMonitor: remove cloudMonitoringExperimentalUI

* fix: address typecheck errors

* fix: fix SLO import and width cleanup

* fix wrong metricType when switching datasources

* fix: remove legacy SLO and fix queryType check
2022-09-15 14:12:26 +00:00
Marcus Andersson
c95b530502
DataSource: Adding possibility to hide queries from the inspector (#54892)
* adding the possibility to hide queries when they are executed via the DataSourceWithBackend.query
2022-09-13 13:27:16 +02:00
Ivana Huckova
e70395f07a
Query editor: Allow query editors to create new query (#55028)
* Query editor: Allow query editors to create new query

* Update

* Revert "Update"

This reverts commit d5b79d60dd.
2022-09-13 13:09:31 +02:00
Torkel Ödegaard
d59bb1e4c2
IconName: Move to grafana/data and use type on NavModelItem (#55013)
* IconName: Allow strings

* Moving to grafana/data and adding type to NavModelItem

* Removed any type

* ts fix
2022-09-12 20:09:33 +02:00
Torkel Ödegaard
49bc70c812
TopNav: Panel edit changes (#54746)
* Progress

* Progress

* Things are working

* More tweaks

* Fixing unit test

* Tweaks and fixing e2e tests

* Remove ... in Save as

* Fixing unit test

* Fixing e2e test

* Fixes

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-09-12 15:45:14 +02:00
Carl Bergquist
72ae4a5aa3
toggles: add feature toggle to increase in mem caching (#55014)
Signed-off-by: bergquist <carl.bergquist@gmail.com>
2022-09-12 03:50:54 -04:00
Leon Sorokin
dbb33eaba9
DataFrameJSON: add string enums inflation of field values (#54938)
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-09-09 13:59:29 -06:00
kay delaney
4c7732ad17
Chore: Upgrade Typescript to 4.8.2 (#54901)
* Chore: Upgrade typescript to 4.8.2
2022-09-09 16:17:58 +01:00
renovate[bot]
b382c7ac1d
Update dependency marked to v4.1.0 (#54972)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-09 09:09:32 -04:00
renovate[bot]
ad19f018a9
Update dependency esbuild to v0.15.7 (#54928)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-09 10:56:49 +01:00
Leon Sorokin
085db83cd9
DisplayProcessor: Handle reverse-ordered data when auto-showing millis (#54923) 2022-09-08 12:49:03 -05:00
Kevin Yu
34fe7a1119
Plugins: Add feature toggles for long running queries (#54349)
* Add feature toggles for long running queries

* update feature flag name

* make feature toggle frontend only
2022-09-05 08:39:45 -07:00
Torkel Ödegaard
11de1dfe40
TopNav: Plugin page layouts / information architecture (#53174)
* Change nav structure when topnav is enable to do initial tests with new information architecture

* Support for nested sections

* Updated

* sentance case

* Progress on plugin challange

* Rewrite to functional component

* Progress

* Updates

* Progress

* Progress on things

* missing file

* Fixing issue with runtime, need to use setter way to set component exposed via runtime

* Move PageLayoutType to grafana/data

* Fixing breadcrumb issue, adding more tests

* reverted backend change

* fix recursive issue with cleanup
2022-09-05 14:56:08 +02:00
Leon Sorokin
8273839539
Histogram: ensure y axis is unit-less (#54667) 2022-09-02 13:50:01 -05:00
Ashley Harrison
0ab548a8b5
Chore: fixing some anys/type assertions (#54661)
* fixing some anys/type assertions

* make types consistent
2022-09-02 16:39:09 +00:00
Timur Olzhabayev
b5b41988cf
Docs: Deprecating packages_api and removing it from our pipelines (#54473) 2022-09-01 18:15:44 +02:00
Josh Hunt
f15ce633c9
Navigation: Don't round app plugin icon images (#54543)
* Navigation: Don't round app plugin icon images

* round icon
2022-09-01 10:28:50 +01:00
renovate[bot]
7efefbaece
Update dependency moment-timezone to v0.5.35 [SECURITY] (#54523)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-01 10:27:39 +01:00
Kristina
38c1f3d054
Explore: Add Mixed Datasource (#53429)
* Toggle on the mixed mode option

* Ensure switching to mixed gives existing query prev datasource

* WIP - Populate datasource when switching between mixed and not

* WIP - handle change from mixed

* Remove preimport filter, refine filter to work for queries

* WIP debugging datasource transition

* Ensure creating a new query gets target data source if switching with no matches between

* Add mixed datasource to rich history display

* Cleanup console logs, add relevant comments

* Add feature toggle for mixed datasource

* Fix Wrapper tests

* Fix tests!

* Fix test types and add feature tracking

* Remove unnecessary default, remove explore/mixed workarounds for D2E

* Move display text logic to mixed datasource file

* Add in the default query parameters to a generated empty query

* Condense some code

* Apply suggestions from code review

Co-authored-by: Giordano Ricci <me@giordanoricci.com>

* Add more logic around mixed datasource being off for explore

* Build out logic to handle different datasource scenarios

* Add tests

* Finalize last test

* Fix mixed URL with mixed ds off, and relevant test

* Fix datasource to explore workflow

* Add datasource change function, call import queries if needed

* add logic for changing single query ds

Co-authored-by: Giordano Ricci <me@giordanoricci.com>
2022-08-31 09:24:20 -05:00
renovate[bot]
6f72c4d10d
Update dependency @testing-library/user-event to v14.4.3 (#54292)
* Update dependency @testing-library/user-event to v14.4.3

* use ReturnType instead of using a nested import

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-08-26 13:30:34 +01:00
Giordano Ricci
c68d7f1e35
Correlations: Add CorrelationSettings Page (#53821)
* GrafanaUI: add option to close DeleteButton on confirm click

* add datasource readOnly info to frontend settings

* move isTruthy utility type guard

* add generic non-visualization table component

* Add correlations settings page

* add missing readOnly in mock

* Fix typo

* avoid reloading correlations after add/remove

* use DeepPartial from rhf

* validate source data source

* fix validation logic

* fix navmodel test

* add missing readonly property

* remove unused styles

* handle multiple clicks on elements

* better UX for loading states

* fix remove handler

* add glue icon
2022-08-26 11:27:28 +01:00
Andre Pereira
c8f2148f75
Tempo: Basic PoC of the upcoming TraceQL editor in Explore (#54028)
* First working version of the TraceQL editor with syntax highlighting and autocomplete

* Add feature flag around the new editor option

* Fix tests and cleanup

* Fix misspelling
2022-08-24 17:57:59 +01:00
Torkel Ödegaard
264645eecd
TopNav: Dashboard settings (#52682)
* Scenes: Support new top nav

* Page: Make Page component support new and old dashboard page layouts

* Pass scrollbar props

* Fixing flex layout for dashboard

* Progress on dashboard settings working with topnav

* Updated

* Annotations working

* Starting to work fully

* Fix merge issue

* Fixed tests

* Added buttons to annotations editor

* Updating tests

* Move Page component to each page

* fixed general settings page

* Fixed versions

* Fixed annotation item page

* Variables section working

* Fixed tests

* Minor fixes to versions

* Update

* Fixing unit tests

* Adding add variable button

* Restore annotations edit form so it's the same as before

* Fixed semicolon in dashboard permissions

* Fixing unit tests

* Fixing tests

* Minor test update

* Fixing unit test

* Fixing e2e tests

* fix for e2e test

* fix a11y issues

* Changing places Settings -> General

* Trying to fix a11y

* I hope this fixes the e2e test

* Fixing merge issue

* tweak
2022-08-24 18:05:12 +02:00
Ryan McKinley
1d4e01f8ba
Transformers: Support inner vs outer join (#53913) 2022-08-23 10:14:03 -07:00
Josh Hunt
9db9ebce02
Typed variables pt6: Clean up and test variable type guards (take 2) (#54025)
* Add fixture-factories for all variable types

* clean up variable guards

* add tests for isMulti, hasCurrent, and hasOptions variable type guards

* create VariableSupport type to try and work around ts wonkiness
2022-08-22 14:45:40 +01:00
Ashley Harrison
0b322a0f5d
fix some anys (#53789) 2022-08-19 16:46:58 +01:00
Ryan McKinley
7cbf6015db
StructureRev: use deep equals for structure revision change detection (#53920) 2022-08-19 08:29:23 -07:00
Joao Silva
4f2d30b153
Decimals: Fixes auto decimals to behave the same for positive and negative values (#53960) 2022-08-19 15:42:34 +01:00
Alex Karacaoglu
a3c1cd836e
Transformations: Add support for an inner join transformation (#53865) 2022-08-18 10:22:45 -07:00
Karl Persson
4ff4aaab23
RBAC: Remove builtin role code (#53767)
* remove rbacBuiltInRoleAssignmentEnabled from frontendsettings

* RBAC: Remove RBACBuiltInRoleAssignmentEnabled

* RBAC: Remove code for builtin role

* RolePicker: Remove unused prop

* RolePicker: Rename builtinRole to basicRole

* RolePicker: Rename onBuiltinRoleChange to onBasicRoleChange

* RolePicker: Rename properties
2022-08-18 12:25:37 +02:00
Ivan Ortega Alba
38c690ecb0
Revert "Analytics: Use Fullstory to get behavioral data (#53732)" (#53762)
This reverts commit 961479b111.
2022-08-16 12:45:14 +02:00
Ivan Ortega Alba
961479b111
Analytics: Use Fullstory to get behavioral data (#53732) 2022-08-16 10:32:00 +02:00
Andres Martinez Gotor
a31d96d20a
Prometheus: Promote Azure auth flag to configuration (#53447) 2022-08-11 16:12:57 +02:00
Yaelle Chaudy
dfe33a63fb
Datasources: Emit event on dashboard load with queries info (#52052)
Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>
Co-authored-by: Andres Martinez <andres.martinez@grafana.com>
2022-08-11 09:30:14 +02:00
Josiah (Jay) Goodson
7d7890e23c
Transform: Add a limit transform (#49291)
* Add a limit transform

* Add a limit transform

* Simplify filter code

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
2022-08-10 07:21:11 -07:00
Kirchen99
46004037e2
Dashboard: Support Variables in "Filter by Name" Transformation (#51804) 2022-08-10 10:54:40 +01:00
Leo
c4984854b6
added dashboard uid when tracing header in browsermode (#53232) 2022-08-10 10:36:19 +02:00
kay delaney
1772bd4238
Chore: Reduce usage of v1 theme (#53245) 2022-08-08 16:37:06 +01:00