Commit Graph

28436 Commits

Author SHA1 Message Date
Robby Milo
57edbb4157
docs: add quick build (#31663)
* add quick docs build

* update docs
2021-03-12 08:53:17 -05:00
Ryan McKinley
9dd1d5f553
Cloudwatch: use shared library for aws auth (#29550)
* use sdk for handling auth

* fix broken test

* lint fixes

Co-authored-by: Erik Sundell <erik.sundell87@gmail.com>
2021-03-12 14:30:21 +01:00
Alex Khomenko
8404d54277
Variables: Do not reset description on variable type change (#31933) 2021-03-12 13:49:19 +02:00
Arve Knudsen
1716de88b5
DashboardService: Consolidate constructors (#31886)
* DashboardService: Consolidate constructors

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
2021-03-12 11:51:02 +01:00
Dimitris Sotirakis
f917c2ab0f
Bug: Update react-use-measure dependency to fix docker-build-full f… (#31802)
* Bug: Update `react-use-measure` dependency to fix docker-build-full failure

* Add #remove-cjs-export to point to the correct branch

* Add git package - update js-builder version
2021-03-12 12:28:54 +02:00
Arve Knudsen
f7d6244fa2
Chore: Give backend platform ownership over backend architecture docs (#31931)
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
2021-03-12 10:30:00 +01:00
Piotr Jamróz
d0fa7b81f0
Prevent submitting the datasource form in Loki's datasource configuration page (#31823) 2021-03-12 09:25:41 +01:00
Villena Guillaume
c764bca58f
ValueMappings: Fixes value 0 not being mapped (#31924)
* ValueMapping: Updated tests (#31877)

Checks if value 0 or '0' is considered as a numeric value

* ValueMapping: Changed implementation of isNumeric (#31877)

isNumeric now works with the 0 value

* fixed prettier issue

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2021-03-12 08:34:06 +01:00
Torkel Ödegaard
82e9d59121
GraphContextMenu: Fixes add annotation action & data links that cause full page reload (#31915)
* GraphContextMenu: Fixes add annotation action

* Fixed issue with data links causing full page reload

* A better solution to closing context menu
2021-03-12 07:25:14 +01:00
Kevin Minehart
34105a6db8
Docs: additional caching documentation (#31925)
* Update query-caching.md

* Update enterprise-configuration.md

Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com>
2021-03-11 22:45:16 +01:00
Marcus Andersson
66e810a5aa
Plugins: exposing the getTimeZone function to be able to get the current selected timeZone. (#31900) 2021-03-11 22:24:49 +01:00
Sofia Papagiannaki
fe628c6282
AlertingNG: base API implementation (#31824)
* AlertingNG: base API implementation

* Pass the interface instead of the base impl

* Ruler mock draft (WIP)

* Update alerting-api dependency

* Improve mock implementation
2021-03-11 21:28:00 +02:00
Diana Payton
3c76458015
Docs: Update dashboard-folder-permissions.md (#31908) 2021-03-11 13:26:53 -05:00
Vardan Torosyan
e53b5afcd2
Licensing docs: Add docs about usage billing option (#31267) 2021-03-11 18:49:46 +01:00
Leon Sorokin
4c2ab6752e
uPlot 1.6.7 (#31913) 2021-03-11 11:15:19 -06:00
Sofia Papagiannaki
53bccf1b77
Replace eval.Condition with models.Condition (#31909) 2021-03-11 18:56:58 +02:00
Vicky Lee
6fe2baf168
Grafana/ui: fix searchable options for Cascader with options update (#31906)
* update searchableOptions when this.props.options has been updated

* add tests for using state to update options for cascader component

* update story for cascader

* use memoizeOne
2021-03-11 16:41:08 +00:00
Gábor Farkas
3139a60012
influxdb: flux-editor: fix html.onchange bug with angular, improve types (#31765)
* influxdb: flux-editor: fix html.onchange bug with angular, improve types

* influx: flux: simplified bug-fix
2021-03-11 17:24:48 +01:00
Chris Cowan
ee547b4410
Elasticseach: Support histogram fields (#29079) 2021-03-11 17:09:28 +01:00
kay delaney
48d2dff987
Migration/AlertList: Migrates AlertList from AngularJS to React (#31872)
* Migration/AlertList: Migrates AlertList from AngularJS to React
2021-03-11 14:53:13 +00:00
Diana Payton
93ead2a50c
Docs: Permissions updates (#31843)
* moved restricting access content to a separate topic

* changed topic name

* Update organization_roles.md

* update link

* content updates
2021-03-11 09:52:48 -05:00
ying-jeanne
a7e243db8a
update bump-version.yml (#31542)
* update bump-version.yml

* Update bump-version.yml
2021-03-11 15:38:58 +01:00
Uchechukwu Obasi
f51653647d
Menu: refactor MenuItem and MenuGroup to be standalone component (#31639)
* Menu: refactor MenuItem and MenuGroup to be standalone component

* fixes small nits

* Chore: Refactored other components to correspond with the new Menu system (#31676)

* fixes affected components using Menu

* fixes affected components using Menu components

* fixes frontend test- I hope

* fixes frontend docs test- I hope

* fixes frontend docs test- I hope

* fixes frontend docs test- I hope

* fixes frontend docs test- I hope

* fixes frontend docs test- I hope

* added support for accessibility

* fixes frontend test- I hope

* Improve storybook story and simplify ButtonSelect

* Fixed broken graph context menu

* fixes frontend test- I hope

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2021-03-11 15:35:17 +01:00
Dominik Prokop
77a024abb3
Add deprecation warnigns to $location patch (#31898) 2021-03-11 15:05:35 +01:00
Alex Khomenko
b017c65409
Chore: upgrade eslint and fork-ts-checker-webpack-plugin (#31854)
* Chore upgrade eslint, fork-ts-checker-webpack-plugin

* Update eslint version for grafana-toolkit

* Update @grafana/eslint-config version

* Update @grafana/eslint-config in grafana-toolkit

* Update lockfile
2021-03-11 13:39:43 +02:00
Josh Hunt
13a47aede2
AzureMonitor: Migrate Metrics query editor to React (#30783)
* AzureMonitor: Remove anys from datasource to get the inferred type

* AzureMonitor: Cast some datasource types

TODO: we want proper types for these

* AzureMonitor: Initial react Metrics editor components

* start dimension fields

* replace replaceTemplateVariable with datasource.replace, and rename onQueryChange to onChange

* actually just do template variable replacement in the datasource

* don't use azureMonitorIsConfigured

* Refactors, mainly around the metric metadata

 - Convert all the metric metadata options for the Select before its set into state
 - Stop using SelectableValue because it's basically any when all the properties are optional
 - the onChange function passed to the fields now just accepts the direct value, rather than wrapped in a SelectableValue

* added proper fields, and adding and removing for DimensionFields

* Update query with Dimension changes

* Width

* subscription and query type fields

* Should be feature complete now, more or less

* fix missing import

* fix lint issues

* set default subscription ID

* Starting to write some tests

* tests for query editor

* Remove subscription ID from the label in Metrics

But we keep it there for the angular stuff

* MetricsQueryEditor tests

* Update index.test.tsx

* fix tests

* add template variables to dropdowns

* clean up

* update tests

* Reorganise react components

* Group query fields into rows

* Rename Option type, add Azure response type

* Refactor Metrics metric metadata

 - Types the Azure API
 - Moves default metadata values into datasource

* nit

* update test
2021-03-11 11:37:39 +00:00
Pureewat Kaewpoi
05d6d32f3e
Docker: Support pre-installing plugins from other sources in custom Dockerfiles (#31234)
Update custom Dockerfiles to support pre-installing plugins from other sources.

Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com>
2021-03-11 12:17:34 +01:00
Hugo Häggmark
9f92eb6859
AnnotationList: Adds spacing to UI (#31888)
* AnnotationList: Adds spacing to UI

* Tests: updates snapshots

* Chore: updates after PR comments
2021-03-11 11:59:35 +01:00
Dimitris Sotirakis
d59574ec1e
Update scripts and Dockerfiles to use Go 1.16.1 (#31881)
* Update scripts and Dockerfiles to use Go 1.16.1

* Update build-container image version to 1.4.1

* Update node version to 14.16.0-1nodesource1

* Updated drone configuration
2021-03-11 12:55:04 +02:00
Torkel Ödegaard
0179d23af0
DataQueryRequest: Remove unused props (#31876) 2021-03-11 10:39:41 +01:00
Piotr Jamróz
31cc36dbb0
Loki: Remove $__rate_interval from LogQL autocomplete (#31825)
* Remove $__rate_interval from LogQL autocomplete

* Remove unused const
2021-03-11 09:26:15 +01:00
Zoltán Bedi
3b6168eb4a
Tempo: Add test for backend data source (#31835) 2021-03-11 08:18:24 +01:00
Oscar Kilhed
e7757b0175
Add datalinks support to PieChart v2 (#31642)
* Remove default value for multiSelect

* Add data links support for PieChart v2

* Temporarily fix story

* Refactor PieSlice, deduplicate colors

* Add field config to context menu of pie chart

* Add custom key to legend

This is a bit hacky. When there are multiple DisplayValues with the same
title the react keys collide and LegendListItems are not cleared
correctly.

* Forgot to add the interface

* Fix missing tooltip in edit mode
2021-03-10 23:02:04 +01:00
Diana Payton
477a54ae54
Docs: Update whats new 7 5 (#31875)
* Update whats-new-in-v7-5.md

* Update whats-new-in-v7-5.md
2021-03-10 23:01:01 +01:00
Gopal Ramachandran
12a6e68763
Docs: fixes included readme within manage-teams page (#31878) 2021-03-10 22:37:05 +01:00
Josh Hunt
a51cc050e2
Chore: type backendSrv.datasourceRequest (#31870) 2021-03-10 20:52:25 +01:00
Will Browne
c40d96d0ab
Plugins: Remove pre-existing plugin installs when installing with grafana-cli (#31515)
* remove old install before install if exists

* fix log format
2021-03-10 19:13:08 +01:00
Dominik Prokop
a55a272276
Routing NG: Replace Angular routing with react-router (#31463)
* Add router packages

* Get react app root work instead of Angular one

* Logger util

* Patch Angular routing ($routeProvider, $routeParamsProvider)

* Use react-router-dom history instead of separate dependency

* Add test routes

* Sidemenu - use Link instead of anchors

* Patch Angular $location service (stub)

* WIP: geting rid of $location provider from TimeSrv

* Intercept anchor clicks to use history under the hood

* Sync Redux location slice with history state

* Make login/logout work

* Debug routes for testing

* Make force login work

* Make sure query param change does not recreate page components

* Hide side menu in specified locations

* Make the dashboar route query parameters work, make panel edit menu work

* Enable more routes

* Fix side menu

* Handle view modes

* Disable playlist routes

* Make SafeDynamicImport work again

* Bring back router-debug

* Separate redux location sync from route rendering

* Refactor updateLocation to thunk and move force refresh(login) to it

* Fixing init dashboard issue

* Support switching between dashboards without an unmount of DashboardPage

* More fixes for init dashboard and panel edit

* More type fixes

* Moving angular location wrapper out of main LocationService, and fixing typescript issues

* Fixed last typescript errors

* LocationService: Move to runtime and  remove getLocationService and export singleston const instead (#31523)

* Moving location service implementation to runtime and removing get function and making it a package const singleton

* Added test that used locationService directly

* removed unused import

* AngularApp: Moving angular dependencies and the app boot out of the main app into it's own file  (#31525)

* Fixes angular panels by calling the monkey patch

* Moving angular stuff to to it's own files

* udpated

* Fixing clicking on divs and spans inside anchor

* Moving app notifications out of angular app and removing angular directive wrapper

* Moving search from angular to react and removing angular search wrapper

* Clean up, tried to remove the redux location wrapper but requires a big update for DashboardPage, so adding it back

* Moving AppWrapper to root to limit circular dependencies (app/core -> app/routing and back)

* Open and close search now works

* Hide sidemenu when in kiosk mode

* Restoring some keybindings like ESC key

* Removed kiosk events and simplified it, just handled through updating URL

* Fixing typescript errors

* Simplified GrafanaRouteComponentProps and renamed to ContainerProps

* renamed back

* Changed AlertRuleList to use GrafanaRouteComponentProps and location.search passed to it

* Removing the reloadOnSearch property, this is not needed now for react as react by default does not unmount components when only url match or query parmas change

* SafeDynamicImport causing unmount un every search update, not sure how to fix yet

* Fix signature for SafeDynamicImport so we do not create new route components on every route render

* Removing the redux location wrapper as it was causing errors, and making dashboard page work with RouteProps (location, match) etc

* Updating DashboardPage and SoloPanelPage to use match params and history location

* Fixed DashboardPage tests

* Fixing solo route tests

* LocationService: Rename getCurrentLocation to just getLocation

* do not intercept link clicks with target blank or self

* Experimental useUrlParams hook

* Update DataSourceSettingsPage to use router match params

* fix links with urls that have no starting / to work like before

* Fix forceLogin

* Add queryParams to GrafanaRouteComponentProps

* PanelEditor get rid of updateLocation and location state

* Improve grafana route query params typing

* Add getSearchObject to LocationService

* Use DashboardPAge queryParams instead of location.search parsing

* Fix DashboardPage typing

* Fix some tests weirdness

* Bring back KeyboardSrv

* Fixes typescript issues

* Team pages now use router match params

* Get rid of  from GrafanaRouteComponent props

* Removed unnessary calls to getSearchObject when calling locationService.partial

* Updated DashboardPage tests after queryParams was added

* Fixing dashboard settings back

* GrafanaRoute: Adding tests and remove use of global locationService

* Fixing tests and typescript errors

* Bring back kiosk modes and add tests

* Fix TimeSrv tests

* Fix typecheck errors

* Fixing tests

* Updated SideMenu test to react-testing and wrapped component in Router, and fixed issue importing createMemoryHistory

* Get rid of routeChange event from TimeSrv from

* Fixed TopSectionItem test

* Trying to make basename work but failing

* Update TopSectionItem snapshot

* Fix TopSectionItem snapshot test

* Fix API keys creation

* Remove Angular dependencies from KeybindingSrv (#31617)

* Remove Angular dependency from KeybindingsSrv

* Fix tests and typecheck issues

* basename is starting to work

* Make dashboard save work

* KeybindingSrv: Remove as angular service and no usage angular scope

* So long bridge_srv, we won't miss you

* Update snapshots

* Dashboard: Refactoring ChangeTracker to use History api and no angular (#31653)

* Dashboard: Refactoring ChangeTracker to use History api and no angular

* Updated

* Removed logging

* fixed unit tests

* updated snapshots

* Mechanism for force reloading routes (#31683)

* e2e: Fixes various things in e2e scenarios after router migration (#31685)

* Explore: Update reading query params from router props and updating location via locationService (ReactRouter)  (#31688)

* RoutingNG: Initial explore redux location to router location migration

* Updated explore Wrapper tests

* Fixing more tests

* remove loggin

* rename back to make naming consistent

* Fixing return to dashboard button

* fixing navigation to explore from dashboard

* updated routeProps

* Updated tests

* Make DashboardListPage work

* Fixing navigation after add new data source, and fixes explore e2e

* Fixing solo panel page

* PluginsPage now works

* RoutingNG: When parsing and rendering url search/query params preseve old logic of handling booleans and arrays (#31725)

* RoutingNG: When parsing and rendering url search/query params preserve old logic of handling booleans and arrays

* Fixed test

* Make snapshots list work

* fixed alert notification channel edit page

* Simplify LocationService, did not need special handling for login or forceLogin as target _self on link already handles that

* fixed UserAdminPage

* fixed edit orgs page

* Fixing LdapPage

* fixing dashboard import

* Fixed new folder page

* Fixed data source dashboards page

* fixing Folder permissions and folder settings page

* fixing snapshot list page nav model

* remove unused file

* Added placeholder page for playlist

* Moved browser compatability to index-template

* Restored 404/default page

* Fixed reset password page

* Fixed SignUpInvited page

* Fixing CreateTeam, Create user page, add panel widget

* Restore browwser file to make tests happy

* Fixed unit tests

* Removed unused import

* Replacing usage of updateLocation

* Fixed test

* Updating search filters to use history / location service for filters

* remove unused file

* AppRootPage fixed

* Fixing test and search issue

* Changes to support enterprise extensions

* remove console.log

* Removing more use of redux location

* Fixed signup page

* removed unused old angular controllers

* Fixing bugs

* one final bugfix

* Removed location from redux state

* Fixing ts issues and tests

* Fixing test issue

* fixing tests

* Fixing tests

* removed unused stuff

* Fixed search test

* Adding some doc comments

* Routing NG: Angular location provider patch (#31773)

* Patch Angulars $location provider

* Update public/app/angular/bridgeReactAngularRouting.ts

* Remove only test

* Update tests, disable loggers in test env

* Routing NG: remove $location provider usage (#31816)

* Remove dashboard_loaders

* Remove $location from Analytics service, track page views form GrafanaRoute

* Remove NotificationsEditCtrl

* Remove Angular dependencies from uploadDashboardDirective

* Update public/app/features/dashboard/containers/DashboardPage.tsx

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

* Update public/app/features/dashboard/containers/DashboardPage.tsx

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

* Remove unused test helpers (#31831)

* Playlist react (#31829)

* playlist list in react

* Playlist start

* Things started to work

* Updated

* Handle empty list

* Fix ts

* Fixes and kiosk mode stuff

* Removed unused events

* fixing ts issue

* Another ts issue

* Fixing tests

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>

* fixed test

* Update public/app/AppWrapper.tsx

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

* Update public/app/AppWrapper.tsx

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

* Remove Angular dependency from DashboardLoaderSrv (#31863)

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
Co-authored-by: Torkel Ödegaard <torkel@grafana.org>
Co-authored-by: Hugo Häggmark <hugo.haggmark@grafana.com>
Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
2021-03-10 18:03:36 +01:00
Andrej Ocenas
def58f1f4a
Zipkin: Use new trace data format (#31830)
* Use new trace api for zipkin

* Fix datasource tests
2021-03-10 17:45:03 +01:00
Erik Sundell
f135d75a22
CloudWatch: Consume the grafana/aws-sdk (#31807)
* consume the grafana/aws-sdk

* upgrade aws-sdk
2021-03-10 14:19:39 +01:00
Arve Knudsen
d2aaaeb497
Backend: Tidy go.sum (#31858)
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
2021-03-10 13:13:50 +01:00
Arve Knudsen
47f13abf7a
Backend: Migrate to using non-global configuration (#31856)
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
2021-03-10 12:41:29 +01:00
dependabot[bot]
bac1721546
Chore(deps): Bump go.opentelemetry.io/collector from 0.21.0 to 0.22.0 (#31852)
Bumps [go.opentelemetry.io/collector](https://github.com/open-telemetry/opentelemetry-collector) from 0.21.0 to 0.22.0.
- [Release notes](https://github.com/open-telemetry/opentelemetry-collector/releases)
- [Changelog](https://github.com/open-telemetry/opentelemetry-collector/blob/main/CHANGELOG.md)
- [Commits](https://github.com/open-telemetry/opentelemetry-collector/compare/v0.21.0...v0.22.0)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-10 12:38:07 +01:00
Lê Đặng Hoài Nam
7764739a8e
Alerting: Generate random id when testing notification channel (#31844) 2021-03-10 11:24:31 +01:00
Arve Knudsen
04e9f6c24f
UsageStatsService: Don't use global state (#31849)
* UsageStatsService: Don't use global state

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
2021-03-10 10:14:00 +01:00
Alex Khomenko
598a44076a
Remove invalid attribute (#31848) 2021-03-10 10:24:14 +02:00
Agnès Toulet
ac263f50d6
Docs: Update improved search image (#31827)
* Update image name

* remove added line
2021-03-10 08:22:15 +01:00
Erik Sundell
d512c5a1b4
Cloudwatch: ListMetrics API page limit (#31788)
* add list metrics api page limit

* Update docs/sources/datasources/cloudwatch.md

Co-authored-by: achatterjee-grafana <70489351+achatterjee-grafana@users.noreply.github.com>

Co-authored-by: achatterjee-grafana <70489351+achatterjee-grafana@users.noreply.github.com>
2021-03-10 07:41:22 +01:00
Leon Sorokin
04e46e3853
Tooltip: partial perf improvement (#31774) (#31837) 2021-03-09 14:25:40 -06:00
Erik Sundell
2d660ee502
CloudWatch: Restrict auth provider and assume role usage according to Grafana configuration (#31805)
* restrict usage of providers and assume role according to grafana config

* update docs

* Update docs/sources/datasources/cloudwatch.md

Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com>

* Update pkg/tsdb/cloudwatch/cloudwatch.go

Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com>

* Update pkg/tsdb/cloudwatch/session_test.go

Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com>

* pr feedback

* fix failing test

Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com>
2021-03-09 21:20:59 +01:00