Commit Graph

12243 Commits

Author SHA1 Message Date
Sofia Papagiannaki
8760627eb0
Cloudwatch: Fix regression with profile datasource field (#28138)
* Fallback to the old field only if new field is undefined
2020-10-13 15:22:00 +03:00
Peter Holmberg
87d6f90acb
Fix: Dynamically add ShowWhen fields to the form watch (#28135) 2020-10-13 09:11:15 +02:00
Sofia Papagiannaki
3928d0c531
Alerting: remove obsolete notifiers (after user confirmation) (#28190)
* Alerting: remove obsolete notifiers (after user confirmation)

* Additional text in confirmation modal
2020-10-12 21:14:08 +03:00
Arve Knudsen
957c88eaca
CloudWatch: Re-implement authentication (#25548)
* CloudWatch: Revisit authentication

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* CloudWatch: Simplify auth code

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Use ARN

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Add Drone configuration

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Remove unused code

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Remove .drone.yml

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Fix external ID usage

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* CloudWatch: Fix issues after merge

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Remove stale code

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Remove stale code

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Use auth type enum

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Fix test snapshot

* Coordinate frontend and backend option names

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Remove old comments

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Fix front-end tests

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Introduce session cache

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Use constants

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Fix field alignment

* CloudWatch: Fix log message

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Tidy go.mod

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* CloudWatch: Handle arn auth type

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* CloudWatch: Fix role assumption duration

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Fix test

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* CloudWatch: Inline unnecessary constants

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* CloudWatch: Use serial comma in UI

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* CloudWatch: Inline unnecessary constants

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* CloudWatch: Fail if missing region

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* CloudWatch: Handle unconfigured region

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* CloudWatch: Log when using cached session

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* CloudWatch: Include region in cache key

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Add UI warnings for lecagy support

* Do not clear ARN fields whenging change authentication provider

* Graph NG: annotations display (#27972)

* Annotations support POC

* Fix markers memoization

* dev dashboard update

* Update public/app/plugins/panel/graph3/plugins/AnnotationsPlugin.tsx

* CloudWatch: Remove errors.BadRequest

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* CloudWatch: Undo unintentional change

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Remove log line

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Fix cache key computation

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Add region to cache key

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Improve log messages

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* CloudWatch: Add documentation

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Improve tooltip

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Improve docs

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Improve docs

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Improve docs

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Improve tooltip

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Add role assumption provisioning example

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Add upgrade notes

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Improve docs

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Apply suggestions from code review

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

* backend: use latest sdk (#28147)

fixes #27713 via https://github.com/grafana/grafana-plugin-sdk-go/pull/227

* Docs: Update Permissions documentation (#28144)

* removed overview.md

* content updates

* Update datasource_permissions.md

* update content

* content updates

* Update organization_roles.md

* Update docs/sources/enterprise/saml.md

Co-authored-by: Kyle Brandt <kyle@grafana.com>

* Update dashboard_folder_permissions.md

Co-authored-by: Kyle Brandt <kyle@grafana.com>

* area/grafana/toolkit: ci-package needs to use synchronous writes (#28148)

* ci needs to use synchronous writes or the file ends up with zero length

* <Enterprise Docs> Add instructions to upload license via UI (#28067)

* Add UI license upload option, reformat Enterprise license activation section

Added the option to upload a license file through the Server Admin UI, and did a little reformatting to make license activation look more like a process.

* Headers not bold, hyphens not asterisks

* Github: run metrics collector workflow every 10min (#28153)

* GithubActions: Updated cron schedule

* Updated

* Docs: Update explore docs: remove dot at the end of line (#28151)

HI - Removed Dot(.) at the end of line to make it consistent with other 2 points.

Thanks,
Ashish

* Fix frontend tests

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Fix frontend tests

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

* Docs: Update upgrade notes

Co-authored-by: Sofia Papagiannaki <sofia@grafana.com>
Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
Co-authored-by: Kyle Brandt <kyle@grafana.com>
Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com>
Co-authored-by: Brian Gann <briangann@users.noreply.github.com>
Co-authored-by: Mitch Seaman <mjseaman@users.noreply.github.com>
Co-authored-by: Torkel Ödegaard <torkel@grafana.org>
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
Co-authored-by: ashishagarwal06 <34888589+ashishagarwal06@users.noreply.github.com>
2020-10-12 17:58:58 +02:00
Hugo Häggmark
7b5decdbb0
Azure: Fixes cancellation of requests with different Azure sources (#28180)
* Azure: Fixes cancellation of requests whit different Azure query types

* Azure: Fixes cancellation of requests whit different Azure query types
2020-10-12 14:59:21 +02:00
Sofia Papagiannaki
83a6a5144d
Cloud monitoring: Add REDUCE_MEAN reducer for cumulative metrics (#28192)
* Cloud monitoring: Add REDUCE_MEAN reducer for cumulative metrics

* Fix tests
2020-10-12 15:28:18 +03:00
Torkel Ödegaard
21ed77d7a5
TemplateSrv: Fix interpolating strings with object variables (#28171) 2020-10-12 14:22:26 +02:00
Ivana Huckova
a3ef101618
Explore: Fix showing of Prometheus data in Query inspector (#28128)
* Fix showing of data in explore's query inspector

* Add test

* Add test

* Updat etest

* Implement react-testing-library and remove props export

* Update tests for consistency
2020-10-09 14:49:14 +02:00
Dominik Prokop
a3d1d9a9c5
Graph NG: EventsCanvas & WIP exemplars support (#28071)
* Use annotations data observable

* WIP exemplars

* Refactor usePlotContext to use getters instead of properties

* Use DataFrame in EventsCanvas instead of custom type

* Minor tweaks
2020-10-09 11:38:30 +02:00
Tom Daly
dc662025cd
Panel Inspect: Allow CSV download for Excel (#27284)
* fix: Use locale to find delimiter for CSV export

* Add sep= Excel header to CSV exporter

* Add modal for Excel export

* Move Excel download to 'Data options' as toggle

* Add 'Download for Excel' documentation
2020-10-09 10:42:57 +02:00
Torkel Ödegaard
d181782943
FieldColor: Adds new standard color option for color (#28039)
* FieldColor: Added field color option

* Progress

* FieldColor: Added custom schemes

* move to fieldColor

* move to fieldColor

* add back the standard color picker

* FieldColor: Added registry for field color modes

* wip refactor

* Seperate scale from color mode

* Progress

* schemes working

* Stuff is working

* Added fallback

* Updated threshold tests

* Added unit tests

* added more tests

* Made it work with new graph panel

* Use scale calculator from graph panel

* Updates

* Updated test

* Renaming things

* Update packages/grafana-data/src/field/displayProcessor.ts

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>

* updated according to feedback, added docs

* Updated docs

* Updated

* Update docs/sources/panels/field-options/standard-field-options.md

Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com>

* Update docs/sources/panels/field-options/standard-field-options.md

Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com>

* Updated docs according to feedback

* fixed test

* Updated

* Updated wording

* Change to fieldState.seriesIndex

* Updated tests

* Updates

* New names

* More work needed to support bar gauge and showing the color modes in the picker

* Now correct gradients work in bar gauge

* before rename

* Unifying the concept

* Updates

* review feedback

* Updated

* Skip minification

* Updated

* UI improvements

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com>
2020-10-09 09:34:57 +02:00
Hugo Häggmark
c052abed87
Variables: hides dropdown before refreshing starts (#28112) 2020-10-09 06:31:45 +02:00
Torkel Ödegaard
71d72cc973
Snapshots: Fixed issue loading graphs in snapshots (#28111) 2020-10-08 18:38:20 +02:00
Ryan McKinley
2567e5202a
Live: remove admin pages, add alpha panel (#28101) 2020-10-08 08:42:15 -07:00
Ryan McKinley
e69fe93e85
Live: improve dashboard editing notifications (#28094) 2020-10-08 08:18:37 -07:00
Peter Holmberg
36f3edc477
Fix: Ensure Notification types loaded before loading notification channel (#28115) 2020-10-08 15:17:27 +02:00
Chris Cowan
3af193358c
Elasticsearch: Support chained pipeline aggregations (#27945)
* Elasticsearch: Support multiple pipeline aggregations for a query

* Ensuring descendents are deleted with their parents.

* Update public/app/plugins/datasource/elasticsearch/metric_agg.ts

Co-authored-by: Giordano Ricci <grdnricci@gmail.com>

* Update public/app/plugins/datasource/elasticsearch/query_def.ts

Co-authored-by: Giordano Ricci <grdnricci@gmail.com>

* Update public/app/plugins/datasource/elasticsearch/specs/query_def.test.ts

Co-authored-by: Giordano Ricci <grdnricci@gmail.com>

* Fixing typo

Co-authored-by: Giordano Ricci <grdnricci@gmail.com>
2020-10-08 11:24:54 +01:00
Will Browne
7d63b2c473
Auth: Add Sigv4 auth option to datasources (#27552)
* create transport chain

* add frontend

* remove log

* inline field updates

* allow ARN, Credentials + Keys auth in frontend

* configure credentials

* add tests and refactor

* update frontend json field names

* fix tests

* fix comment

* add app config flag

* refactor tests

* add return field for tests

* add flag for UI display

* update comment

* move logic

* fix config

* pass config through props

* update docs

* pr feedback and add docs coverage

* shorten settings filename

* fix imports

* revert docs changes

* remove log line

* wrap up next as round tripper

* only propagate required config

* remove unused import

* remove ARN option and replace with default chain

* make ARN role assume as supplemental

* update docs

* refactor flow

* sign body when necessary

* remove unnecessary wrapper

* remove newline

* Apply suggestions from code review

* PR fixes

Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com>
2020-10-08 10:03:20 +02:00
garanews
61749dee23
Fix typos (#28074)
Parsed all repo with a regexp of common misspelled words and fixed.
2020-10-07 11:29:30 +01:00
Giordano Ricci
09574547b8
Elasticsearch: Fix ad-hoc filter support for Raw Data query and new table panel (#28064) 2020-10-07 09:37:31 +01:00
Arve Knudsen
0a2ef086b3
Chore: Convert CloudWatch metrics to data frames (#27449)
* CloudWatch: Convert metrics results to data frames

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>

Co-authored-by: kay delaney <kay@grafana.com>
2020-10-06 13:45:58 +02:00
Dominik Prokop
810c327e31
Use annotations data observable (#28050) 2020-10-06 12:43:45 +02:00
Dominik Prokop
aa6c98f7ff
Graph NG: annotations display (#27972)
* Annotations support POC

* Fix markers memoization

* dev dashboard update

* Update public/app/plugins/panel/graph3/plugins/AnnotationsPlugin.tsx
2020-10-06 11:39:06 +02:00
Hugo Häggmark
de1b2bdc4c
Transformations: Use Observable (#27584)
* WIP: changes transformer API to Observable

* Refactor: changes ResultProcessor

* WIP: TransformationUI

* wip

* Refactor: Cleaning up code in CalculateFieldTransformerEditorProps

* Refactor: pushing editor and input output down to TransformationEditor

* Refactor: renaming props

* Refactor: makes transformDataFrame more readable

* Refactor: fixes editor issues

* Refactor: changes after merge with master and first tests

* Tests: completes the tests for the Explore changes

* Tests: fixes all transform tests

* Tests: fixed annotations test

* Tests: fixed typechecks

* Refactor: changes transform interface to MonoTypeOperatorFunction

* Chore: cleans up typings

* Update packages/grafana-data/src/transformations/transformDataFrame.ts

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

* Tests: fixes broken tests

Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>
2020-10-06 07:55:09 +02:00
David C
1f389d72b2
Docs: Added $__rate_interval to Prometheus help (#28030)
* Docs: Added $__rate_interval to Prometheus help

The variable '$__rate_interval' was added in Grafana 7.2.0. This commit
adds the missing help information to Grafana's Prometheus PromQueryEditor.

Signed-off-by: David Calvert <davidcalvertfr@gmail.com>

* Docs: Fixed line length in PromQueryEditor.tsx

This commit will fix line length of my previous commit to make CI green
again.

Signed-off-by: David Calvert <davidcalvertfr@gmail.com>

* Docs: Fixed ci error

Fixed CI error due to my previous commits

Signed-off-by: David Calvert <davidcalvertfr@gmail.com>
2020-10-05 11:14:33 -04:00
Ryan McKinley
726bb4477b
Live: cleanup and simple changes (#28028) 2020-10-04 23:53:52 -07:00
Ivana Huckova
0ffd9a9a3c
Loki: Run instant query only in Explore (#27974)
* Run instant query only in Explore

* Replace forEach with for loop
2020-10-04 21:41:12 +02:00
Zoltán Bedi
b1186d693a
Stackdriver: fix project name change regression (#27909)
* Update stackdriver query editor not to overwrite project name

* Fix legacy select form no options didn't show

* Update config link to docs
2020-10-03 11:55:09 +02:00
Alex Khomenko
6173aa70b7
UserPicker: Use clearable AsyncSelect for the UserPicker (#27994) 2020-10-03 07:19:45 +02:00
Hugo Häggmark
845bc7c444
Variables: Adds loading state and indicators (#27917)
* Refactor: Replaces initLock with state machine

* Refactor: removes some states for now

* Refactor: adds loading state in OptionsPicker

* Refactor: major refactor of load state

* Refactor: fixes updating graph in parallell

* Refactor: moves error handling to updateOptions

* Refactor: fixes the last cases

* Tests: disables variable e2e again

* Chore: removes nova config

* Refactor: small changes when going through the code again

* Refactor: fixes typings

* Refactor: changes after PR comments

* Refactor: split up onTimeRangeUpdated and fixed some error handling

* Tests: removes unused func

* Tests: fixes typing
2020-10-02 07:02:06 +02:00
kay delaney
185442115c
Chore: Remove angular dependency from data sources (#27735)
* Chore: Remove angular dependency from data sources

* Removes default export for time and template srvs
Also uses @grafana/runtime versions of the interfaces where possible

* Replace usage of internal templateSrv where possible

* Use runtime templateSrv in a couple more places
2020-10-01 18:51:23 +01:00
Ryan McKinley
8a5fc00330
Live: broadcast events when dashboard is saved (#27583)
Co-authored-by: kay delaney <45561153+kaydelaney@users.noreply.github.com>
Co-authored-by: Torkel Ödegaard <torkel@grafana.org>
2020-10-01 10:46:14 -07:00
Andrej Ocenas
26ba7ab598
Chore: Remove loki version hack in explore (#27966) 2020-10-01 15:41:05 +02:00
Ivana Huckova
43c389d119
Revert "Update refId for instant queries (#27954)" (#27960)
This reverts commit 9546da3189.
2020-10-01 14:39:32 +02:00
Zoltán Bedi
a230aa1031
Prometheus: refactor to DataFrame (#27737)
* Add typing to prometheus response

* Refactor result_transformer to return DataFrame

* Refactor + test fixes

* Fix Prometheus data source test

* Modify heatmap function + add back tests

* Update performInstantQuery return type

* Remove duplicate code from result_transformer

* Address review comments

* Update metric labels retrival logic to be safer
2020-10-01 12:58:06 +02:00
Ivana Huckova
9546da3189
Update refId for instant queries (#27954) 2020-10-01 12:19:24 +02:00
Ivana Huckova
2f5a60f561
Explore: Remove ui params from url (#27753)
* Remove ui from url

* Update tests

* Update changeDedupStrategy

* Add test coverage
2020-10-01 12:18:21 +02:00
Hugo Häggmark
fa2781391a
DashboardLinks: values in links are updated when variables change (#27926)
* DashboardLinks: values in links are updated when variable changes

* Tests: adds e2e test that verifies links
2020-10-01 08:44:56 +02:00
Sartaj Singh Baveja
4e4242d475
Variables: Adds support for key/value mapping in Custom variable (#27829)
* Initial work on adding new mapping variable type

* Remove add button

* Update custom variable type to include key/value mapping

* Update custom variable docs

* Try to fix failing build

* Update reducer.ts

* Fix failing build

* Remove expansion of the colon

* Update docs

Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com>

Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com>
2020-10-01 06:06:52 +02:00
Marcus Andersson
b59be220ce
Build: fixing failing release packaged build due to uPlot dependency not properly setup (#27887)
* removed dependency from grafana/ui on public/app.

* fixed so we don't get rollup issues when building the packages.

* fixed so import path is working properly.

* removed uncommented code.
2020-09-30 12:59:02 +02:00
Torkel Ödegaard
d105db3e5b
Graph: Fixed histogram bucket calculations to avoid missing buckets (#27883)
* Graph: Fixed histogram bucket calculations to avoid missing buckets

* Removed testdata

* Updated tests
2020-09-30 09:26:06 +02:00
Agnès Toulet
05cb049733
Dashboard: Don't send analytics for explore or edit events (#27789)
* Dashboard: don't send analytics for explore or edit event

* AnalyticsProcessor: merge subsequent conditions

* Add analyticsProcessor tests

* apply PR feedback
2020-09-30 08:29:33 +02:00
Ryan McKinley
71a01a1053
Chore: Convert internal grafana datasource from angular to react (#27870) 2020-09-29 10:39:31 -07:00
Ryan McKinley
4f3be31e1a
Chore: show error/warning notice with a different icon (#27872) 2020-09-29 07:27:57 -07:00
Dominik Prokop
b995381816
Proposal: Declarative API for axes, scales and series configuration in Graph NG (#27862)
* Fix gdev dashboard

* API for declarative Axis, Series and Scales configuration

* Bring back time zone change support

* Update tests and fix type errors

* Review comments and fixes
2020-09-29 13:25:10 +02:00
Kemal Akkoyun
0c70308870
Prometheus: Add time range parameters to labels API (#27548)
* Add time range parameters to labels API

Signed-off-by: Kemal Akkoyun <kakkoyun@gmail.com>

* Fix minor issues

Signed-off-by: Kemal Akkoyun <kakkoyun@gmail.com>

* Add range to explore component

Signed-off-by: Kemal Akkoyun <kakkoyun@gmail.com>

* Add range to query component

Signed-off-by: Kemal Akkoyun <kakkoyun@gmail.com>

* Cache metric names for time range

Signed-off-by: Kemal Akkoyun <kakkoyun@gmail.com>

* Update public/app/plugins/datasource/prometheus/components/PromQueryField.tsx

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

* Remove unused method

Signed-off-by: Kemal Akkoyun <kakkoyun@gmail.com>

* Only compare the ranges

Signed-off-by: Kemal Akkoyun <kakkoyun@gmail.com>

* Update public/app/plugins/datasource/prometheus/components/PromQueryField.tsx

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

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2020-09-29 11:05:57 +02:00
Ivana Huckova
d7e192a8fe
Prometheus/Explore: Update position of fields in editor (#27816)
* Update position of buttons

* Refactor, add tests

* Pass onKeydown func

* Update public/app/plugins/datasource/prometheus/components/PromQueryField.tsx

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
2020-09-28 21:25:16 +02:00
Berbe
7c0bd29fcc
Fix: bps & Bps default scale remains decimal (backwards-compatibility) (#27838) 2020-09-28 19:24:09 +02:00
Peter Holmberg
2114614197
GEL: Editor UI updates (#27859)
* use new inline form styles

* remove fragment

* rename some of the GEL form labels

* s/gel type/operation for label

Co-authored-by: kyle <kyle@grafana.com>
2020-09-28 16:44:52 +02:00
Alex Khomenko
c35bd84ff1
Grafana-UI: Refactor legacy inline form components (#27660)
* Move styles to emotion

* Move FormLabel to forms

* Add mdx file

* Setup InlineField

* Add InlineField docs

* Add grow prop

* Add isKeyword prop

* Add filled Field

* Keep legacy form label

* InlineFormLabel => InlineLabel

* Update references

* Add multiple elements example

* Revert label

* Add InlineFieldRow

* Adjust label width

* Export InlineFieldRow

* Expand props from base components

* Remove isKeyword prop

* Remove fill prop

* Update docs

* Update docs [2]
2020-09-28 14:24:25 +03:00
Peter Holmberg
244c28750c
Fix: Update badges on PanelEditor tabs when adding a query/transformation/alert (#27729)
* minor nits in paneleditor

* add events for queries and transformations

* fix spelling

* add event to alertctrl

* revert alert changes

* re add force update

* reduce events
2020-09-28 09:06:46 +02:00
kay delaney
d322417217
Chore: Upgrade typescript and related packages (#27316)
* Chore: Upgrade typescript and related packages
Closes #27115

* Apply suggestions from code review

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

* fixes some tests

* Fix failing tests

* Apply suggestions from code review

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

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
2020-09-25 15:48:41 +01:00
Ivana Huckova
336699c575
Fix formating of results from instant queries in Explore (#27767) 2020-09-25 14:34:33 +02:00
Hugo Häggmark
204641a202
Variables: Prevents unnecessary calls to update options (#27790)
* Variables: Prevents unnecessary calls to update options

* Tests: adds tests for QueryVariableEditor
2020-09-25 13:40:03 +02:00
Hugo Häggmark
0bb8b32821
Mysql: Support request cancellation properly (Uses new backendSrv.fetch Observable request API) (#27649) 2020-09-25 12:46:28 +02:00
Ryan McKinley
3ae6ba034d
Graph NG: make series color easy to clear (#27778) 2020-09-25 11:46:39 +02:00
John Belmonte
9ca12a7663
prometheus grafana dashboard: use newer info metric (#27240)
Fixes #24952.
2020-09-24 21:10:57 +02:00
Torkel Ödegaard
adc1b965f3
PanelData: Adds annotations and QueryResultMeta dataTopic (#27757)
* topics round two

* more props

* remove Data from enum

* PanelData: Simplify ideas a bit to only focus on the addition of annotations in panel data

* Test data scenario

* Old graph panel showing annotations from PanelData

* Fixed comment

* Fixed issues trying to remove use of event.source

* Added unit test

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2020-09-24 21:01:31 +02:00
Torkel Ödegaard
f06dcfc9ee
Table: New cell hover behavior and major refactoring of table cells & style build (#27669)
* Table: Image cell and new hover behavior

* ImageCell: progress

* Table: refactoring cell style generation, tricky stuff

* About to do something

* Getting close

* Need another big change

* Almost everything working

* Filter actions working

* Updated

* Updated

* removed unused prop from interface

* Fixed unit test

* remove unused type
2020-09-24 20:09:01 +02:00
Giordano Ricci
d4f785d20a
Elasticsearch: Add query's refId to each series returned by a query (#27614) 2020-09-24 18:06:19 +01:00
Sofia Papagiannaki
42476811a4
Cloudwatch: Fix loading custom credentials profile (#27684)
* Store credentials profile in JSON

* Update docs example

* Apply suggestions from code review

Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com>
2020-09-24 19:21:17 +03:00
kay delaney
267f3e7389
Chore: Remove leftover console.log (#27766) 2020-09-24 15:51:38 +01:00
Dominik Prokop
844dd9e8f0
Graph NG WIP (#27572)
* Squash merge Ryans uPlot work

* uPlot - wrap into composable API

* Remove MicroPlot.tsx

* Add missing uPlot stylesheet import

* Use field config for axes config

* Min selection distance for Zoom

* WIP Tooltip behaviour

* Some progress on rendering plot

* gdev dashboard for graph ng tests

* Update custom field config interface for graph options

* Add support for paths in default field config setup (+2 squashed commits)
Squashed commits:
[93fc3afbfc] Typecheck fix
[a07ef86a8b] Add support for paths in default field config setup

* Include IANA timezone canonical name in TimeZoneInfo

* Use correct time zone on time axis

* Default axis width

* Use system date time formats for time axis ticks

* Graph panel layout

* Respect config paths when rendering default value of field config property

* Fix mismatch in field config editor types

* Color field option editor

* Refactor plot context to a single one

* First version of new graph legend plugin

* Fix mutable data frame

* Multiple ui fixes, layout is still slightly problematic

* Remove unused

* Fix tooltip test

* Some perf optimisations

* Update dev dashboard

* Typecheck fix

* Do not use color value editor as standard property editor, add custom field config to graph panel to control series color

* Update dev dashboard with correct tags

* Fix undefined issues

* Update devenv/dev-dashboards/panel-graph/graph-ng.json
2020-09-24 16:44:35 +02:00
Tiago Mota Santos
17a1e78754
Dashboard: Honour root_url for Explore link (#27654)
* Dashboard: Add subUrl to explore url

Honour subUrl when opening explore in new window

* Dashboard: Add tests to onNavigateToExplore

* Dashboard: Remove condition from tests
2020-09-24 06:15:57 +02:00
Ryan McKinley
93a01eb1d9
Live: improved channel state (#27672) 2020-09-23 08:02:01 -07:00
Giordano Ricci
4c7131425b
Revert "Elasticsearch: add frozen indices search support (#27472)" (#27726)
This reverts commit 61a3160c34.
2020-09-23 12:24:46 +01:00
Hugo Häggmark
a58a9e8e6d
PanelEditor: Prevents adding transformations in panels with alerts (#27706) 2020-09-23 07:47:20 +02:00
Ryan McKinley
d46f33c34c
Annotations: check for null or undefined fields before conversion (#27712) 2020-09-22 10:45:26 -07:00
Ivana Huckova
f6c91d1318
Explore: Remove not running query for collapsed elements (#27026)
* Make graph and table collapsing just a UI thing

* Remove showingGraph and showingTable, set them defaultly to true

* Remove collaapsing for panels in Explore

* UI toggle WiP

* WIP, add query type

* Refactor, clean up

* Update tests

* Clean uo

* Update rangeAll to range and instant

* Remove console logs

* Update packages/grafana-data/src/types/datasource.ts

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>

* Update public/app/core/utils/explore.ts

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>

* Fix prettier error

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
2020-09-22 17:31:42 +02:00
kevin.xu
98f7a2ace0
Update app.ts (#27673)
fix typo
2020-09-21 16:56:33 +01:00
Russ
1f1d7d7f11
Explore: Keep typeahead suggestions for exact label matches in Loki q… (#27201)
* Explore: Keep typeahead suggestions for exact label matches in Loki query editor

* Simplify some typing

* Explore: filter selected loki label option from suggestions

Co-authored-by: kay delaney <kay@grafana.com>
2020-09-21 16:56:20 +01:00
Peter Holmberg
6a14f830ba
Fix: Show an ellipsis if Query row title is too long (#27648)
* add overflow hidden to titleWrapper

* show ellipsis and css labels for components

* readd drag handle after bad merge

* rewrite userpicker test with rtl

* update test after adding css label to icon component

* fix more tests..
2020-09-21 15:33:50 +02:00
Torkel Ödegaard
1e5309a788
DashboardRow: Update to use the new replaceWithText method (#27671)
* DashboardRow: Update to use the new replaceWithText method

* Fixed panel header as well
2020-09-21 15:27:23 +02:00
calebsmac
e32aa99f26
Clarify status of annotation list panel (#27663)
It is confusing as the marketplace plugin is deprecated, and this page indicates that it is **included**, but it is not visible/discoverable by default.
2020-09-21 06:10:09 +02:00
Spencer McMaster
1269fa5cf6
PanelEditor: fix button position when dragging row (#27666) 2020-09-20 14:18:09 +02:00
Giordano Ricci
61a3160c34
Elasticsearch: add frozen indices search support (#27472)
* Elasticsearch: Add frozen indices support for alerting
2020-09-18 18:27:25 +01:00
Dominik Prokop
e5b16952c7
Field config: Respect config paths when rendering default value of field config property (#27652) 2020-09-18 15:46:16 +02:00
kay delaney
ca7263d898
Explore/Actions: Stop loadExploreDatasourcesAndSetDatasource from running queries twice (#27577) 2020-09-17 14:34:28 +01:00
Giordano Ricci
0e34474099
Elasticsearch: Add support for date_nanos type (#27538) 2020-09-17 08:16:58 +02:00
Hugo Häggmark
e86ff52d44
DataLinks: Respects display name and adds field quoting (#27616)
* DataLinks: Adds field quoting and respects DisplayName

* Update public/app/features/panel/panellinks/link_srv.ts

Co-authored-by: kay delaney <45561153+kaydelaney@users.noreply.github.com>

Co-authored-by: kay delaney <45561153+kaydelaney@users.noreply.github.com>
2020-09-17 08:08:32 +02:00
Nick Svanidze
5a06ed431c
ApiKeys: Fixes close('X') button layout issue (#27625)
* ApiKeys: Fixes add API key layout

* ApiKeys: snapshot tests updated
2020-09-17 07:36:47 +02:00
Torkel Ödegaard
31e2b7e7c8
SharedQuery: Error when switching to -- Dashboard -- data source caused "no data" no matter what source panel was selected (#27627)
* SharedQuery: Error when switching to -- Dashboard -- data source made observable subscription error and subsequent data results not update visualization

* added null check just in case
2020-09-17 07:36:18 +02:00
Torkel Ödegaard
c450ffd711
ImageRendering: Fix rendering panel using shared query in png, PDF reports and embedded scenarios (#27628)
* ImageRendering: Fixed issue rendering panel using shared query

* Fixed spelling
2020-09-17 07:35:24 +02:00
Ryan McKinley
e3b79ac428
Chore: remove version from text panel (#27624) 2020-09-16 11:04:27 -07:00
Torkel Ödegaard
b58864792d
NewsPanel: Fixed XSS issue when rendering rss links (#27612) 2020-09-16 11:15:56 +02:00
Ryan McKinley
54b677bda4
Graph: show range warning when all data is outside time range (#27603) 2020-09-15 11:55:34 -07:00
Torkel Ödegaard
cade6dd010
Docs: Field config docs update, Table docs update, Override matcher naming issue (#27558)
* Docs: Field Config Docs Update, Table Docs update, Override matcher naming sync

* removed sentance that feels duplicated

* Update docs/sources/panels/field-configuration-options.md

Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com>

* Update docs/sources/panels/field-configuration-options.md

Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com>

* Update docs/sources/panels/field-configuration-options.md

Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com>

* Update docs/sources/panels/field-configuration-options.md

Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com>

* removed bad newlines and minor tweaks, still need to figure out naming for matchers in UI and docs

* Updated matcher names and descriptions, and UX

* Updated field override docs

* Fixed plural

* Updated wording

* removed plurals for the selectors heading

* Updated names

* Updated docs

Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com>
2020-09-15 14:49:16 +02:00
Ryan McKinley
1e4846d443
Annotation: use DataFrame[] rather than a single DataFrame (#27587) 2020-09-15 01:43:31 -07:00
Dominik Prokop
e04e3e7d46
Field config: Add support for paths in default field config setup (#27570)
* Add support for paths in default field config setup

* Typecheck fix
2020-09-15 10:17:58 +02:00
Giordano Ricci
e350e1fff6
Elasticsearch: Increase maximum geohash aggregation precision to 12 (#27539) 2020-09-15 09:15:18 +01:00
Giordano Ricci
a0beaa3bbe
Elasticsearch: Allow fields starting with underscore (#27520) 2020-09-15 09:14:47 +01:00
jonny
0d2fbd2acd
Variables: Limit rendering of options in dropdown to improve search performance (#27525)
* fixed: bigdata dropdown first limit 1000

* fixed: change to use function of  applylimit

* fixed: remove both applyLimit callers

* feat: test for new logic with applimit

* feat: test showOptions  with the applyLimit logic

* fixed: test equal fixed
2020-09-15 09:52:45 +02:00
Ryan McKinley
aa40320b45
Live: check logged-in-user for grafana live (#27436) 2020-09-15 00:01:14 -07:00
Hugo Häggmark
a587bf4f56
Postgres: Support request cancellation properly (Uses new backendSrv.fetch Observable request API) (#27478)
* Postgres: Replaces dataSourceRequest with fetch

* Postgres: Replaces dataSourceRequest with fetch

* Tests: removes unnecessary import
2020-09-15 08:06:04 +02:00
Torkel Ödegaard
7f6e979056
Fixes typescript issues (#27565) 2020-09-14 10:02:25 +02:00
Torkel Ödegaard
b37e132cec
Annotations: Fixes issue with showing error notice for cancelled annotation queries (#27557) 2020-09-14 09:59:12 +02:00
Torkel Ödegaard
8759a91222
PanelEdit: Drag and drop query order & UI tweaks (#27502)
* PanelEdit: Drag and drop query order & UI tweaks

* Fixed width of title issue

* added correct color and hover

* Updated e2e tests
2020-09-14 08:54:42 +02:00
Marcus Andersson
0c8390cea2
Templating: global/system variables should be properly replaced in templated values. (#27394)
* Fixed so we try to use the variables in the redux store to replace values in template variables.

* First draft of working version.

* Including fieldPath when adding :text format.

* cleaned up code by introducing helper function.

* some minor refactoring.

* Added tests and support for multi variables.

* added test and code to handle the All scenario of a multivariable.

* fixed according to feedback.

* added docs.

* added text format to gdev dashboard.

* updated e2e tests.

* make sure we use the same function for formatting och variable lable.

* increased the number to 22.

* changed label for tests to be All.

* existing format should be respected.
2020-09-14 08:05:51 +02:00
Ryan McKinley
5d11d8faa3
Annotations: add standard annotations support (and use it for flux queries) (#27375) 2020-09-11 08:09:44 -07:00
Berbe
794333de3d
Binary-prefixed data rates (#27022)
* Dashboard: Merge Data units categories

Prefixes already allow to distinguish IEC units from SI ones
+ Prefer using binary function over decimal one when equal

* Dashboard: Clarify SI & binary prefixes

* Dashboard: Homogeneise rate units

* Dashboard: Add Binary (IEC) prefix for data rates
2020-09-11 10:42:54 +02:00
Torkel Ödegaard
0132bca93a
Notifications: UX tweak to redesign of form and sections to make it left aligned and cleaner (#27479)
* UX: Redesign of form and sections to make it left aligned and cleaner

* reduced padding

* design tweaks
2020-09-11 08:10:07 +02:00
Zoltán Bedi
a7ac3f1419
Prometheus: Fix min step variable interpolation (#27505)
* Add missing dependency to lockfile

* Prometheus: Fix min step variable interpolation
2020-09-10 20:31:53 +02:00
Peter Holmberg
400aafa3b3
Migration: Edit notification channel (#25980)
* implement edit page

* connectWithCleanup

* remove angular related code

* use loadingindicator

* use the correct loading component

* handle secureFields

* fixed implementation of secure fields

* Keep secureFields after rerendering the form

* CollapsableSection and Page refactor

* use checkbox instead of switch

* fix comment

* add cursor to section

* Fixed issues after PR review

* Fix issue with some settings being undefined

* new reducer and start with test

* algorithm to migrate secure fields

* UX: Minor UI Tweaks

* Added field around checkboxes, and missing required field

* fixed test

* tests for util

* minor tweaks and changes

* define as records

* fix typ error

* forward invalid to textarea and inputcontrol

* merge formdata and redux data in test

* fix issue with creating channel

* do not figure out securefields in migration

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2020-09-09 12:46:19 +02:00
Giordano Ricci
1e2f3ca599
Explore: Expand template variables when redirecting from dashboard panel (#27354)
* Explore: Add interpolateVariablesInQueries to opentsdb  datasource

* Explore: Add interpolateVariablesInQueries to cloudwatch datasource

* Explore: Add interpolateVariablesInQueries to CloudMonitoring datasource

* Explore: Add interpolateVariablesInQueries to Azure datasource

* Explore: Add dimensions to interpolateMetricsQueryVariables in cloudwatch datasource
2020-09-09 10:00:43 +01:00
Hugo Häggmark
5520cd2c68
Chore: fixes build errors (#27466) 2020-09-09 08:57:07 +02:00
Torkel Ödegaard
431a53594b
Inspect: Fixed missing rows issue in inspect data (#27422) 2020-09-09 08:47:18 +02:00
Hugo Häggmark
b3fb25010c
DashboardSettings: Fixes auto refresh crash with space in interval (#27438)
* DashboardSettings: Fixes auto refresh crash with space in interval

* Tests: fixes typings

* Refactor: validets onBlur and other PR comments

* Tests: adds component tests

* Refactor: changes after PR feedback
2020-09-09 07:45:51 +02:00
Liam Stanley
023054bc62
heatmap: reduce the aggressiveness of hiding ticks/labels (#27016) 2020-09-09 06:53:17 +02:00
Kyle Brandt
9bab551d8b
AzureMonitor: change filterDimensions property to match what is stored (#27459)
Changes the dimensionsFilters property to dimensionsFilter in the Azure Monitor Datasource's AzureMonitor service to make what is sent to match the saved model.

Before this, the property that the backend was expecting was not available in the case of alerting, where the stored model is fetched.

This also fixes a panic when there is a dimension alias but no dimension
2020-09-08 15:12:08 -04:00
Alex Khomenko
32f99669ff
Search: refactor tests to use react-testing-library (#27352)
* Search: refactor SearchItem.test.tsx

* Search: refactor SearchResults.test.tsx

* Search: mock search_srv

* Search: refactor SearchResultsFilter.test.tsx

* Search: remove redundant mocks

* Search: fix type errors

* Search: move selectors to e2e-selectors
2020-09-08 18:01:38 +03:00
Peter Holmberg
cf2597421b
Analytics: Respect appsuburl in tracking url (#27442)
* add suburl if it exists

* remove log

* remove another log
2020-09-08 15:38:04 +02:00
Dominik Prokop
377485cf4c
Panel view: Make sure repeated panel has inView property set correctly (#27424)
* Make sure repeated panel has inView property set correctly

* Test

* Update public/app/features/dashboard/state/DashboardModel.ts

Co-authored-by: Hugo Häggmark <hugo.haggmark@grafana.com>

Co-authored-by: Hugo Häggmark <hugo.haggmark@grafana.com>
2020-09-08 14:19:54 +02:00
Melchior MOULIN
dfc78d0979
Explore: Transform prometheus query to elasticsearch query (#23670)
* Explore: Transform prometheus query to elasticsearch query

Enable a way to transform prometheus/loki labels to elasticsearch query.
This make a link between metrics to logs.
Examples:
A prometheus query : rate(my_metric{label1="value1",label2!="value2",label3=~"value.+",label4!~".*tothemoon"}[5m])
Will be this elasticsearch query when switching to elasticsearch datasource:  __name__:"my_metric" AND label1:"value1" AND NOT label2:"value2" AND label3:/value.+/ AND NOT label4:/.*tothemoon/

* fix test

* remove non needed async

* Use prism token instead of regex

* fix test ./scripts/ci-frontend-metrics.sh

* mock timesrv and TemplateSrv in test

* Remove unnecessary await/async

Co-authored-by: Melchior MOULIN <m.moulin@criteo.com>
Co-authored-by: Andrej Ocenas <mr.ocenas@gmail.com>
2020-09-08 12:34:11 +02:00
Alex Khomenko
6fabfee097
Search: replace cog icon (#27440) 2020-09-08 12:04:40 +03:00
Zoltán Bedi
09c9571462
Explore: table result should not override display property (#27411) 2020-09-08 11:04:25 +02:00
Domas
9acb99904a
Elasticsearch: Fixes localized dates in index pattern (#27351)
Fixes #8403
2020-09-07 18:27:56 +02:00
Kamal Galrani
f6c31c2e10
Fixes signup workflow and UI (#26263)
* fixes signup flow

* Apply suggestions from code review

Co-authored-by: Hugo Häggmark <hugo.haggmark@gmail.com>

* Update ForgottenPassword.tsx

* fixes build failure

* fixes build failure

Co-authored-by: Hugo Häggmark <hugo.haggmark@gmail.com>
2020-09-07 18:24:46 +03:00
Torkel Ödegaard
61bd33c241
System: Date formating options (#27216)
* Add support for local time formats in graph panel

* Enfore 24h format for backward compatibility

* Use existing Intl.DateTimeFormatOptions

* Pre-generate time scale, add tests

* Move localTimeFormat, add local format to units

* updated default fallback

* #25602, use navigator.languages to enforce locale in formatting

* Making options

* Worked new system settings

* things are working

* Local browser time formats working

* Support parsing dates in different formats

* settings updated

* Settings starting to work

* Fixed graph issue

* Logs fix

* refactored settings a bit

* Updated and name change

* Progress

* Changed config names

* Updated

* Updated

* Updated test

* Synced description

* fixed ts issue

* Added version notice

* Ts fix

* Updated heatmap and test

* Updated snapshot

* Updated

* fixed ts issue

* Fixes

Co-authored-by: Alex Shpak <alex-shpak@users.noreply.github.com>
2020-09-07 16:19:33 +02:00
kay delaney
783391a861
CloudWatch Logs: Adjusts CloudWatch Logs timeout logic (#26621)
* CloudWatch Logs: Adjusts CloudWatch Logs timeout logic

Previously CloudWatch Logs queries would time out if,
after a number of attempts, a response was received with no additional data.
This commit changes the behavior so that a consecutive number of requests
yielding no additional data must be made before we cancel the query
2020-09-07 14:41:36 +01:00
Sofia Papagiannaki
b3b28e9f25
Failed to load application files message improvement (#26214)
* Failed to load application files message improvement

* Apply suggestions from code review

Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
2020-09-07 10:53:13 +03:00
Hugo Häggmark
72c3257d19
BackendSrv: Uses credentials and defaults to same-origin (#27385)
Co-authored-by: Liu Yang yangliuyu@163.com
2020-09-04 22:11:34 +02:00
Torkel Ödegaard
b6d76cdba7
PanelEdit: Vertically align padding for panel edit option group body (#27310)
* PanelEdit: Center padding for panel edit group body

* fixed padding
2020-09-04 22:03:26 +02:00
kay delaney
444f2d5896
Dependencies: Adds @testing-library/user-event for best practices (#27397)
Adds @testing-library/user-event so that best practices can be followed
when writing tests
2020-09-04 16:38:27 +01:00
Pranit Bauva
a54df0c3cd
Login: Honour root_url for Forget Password related links (#27368)
Closes #27226
2020-09-04 13:58:22 +02:00
Hugo Häggmark
bba4770509
PanelInspector: Adds a Raw display mode but defaults to Formatted display mode (#27306)
* PanelInspector: Fields with overrides are formatted correct in CSV

* Refactor: adds raw format

* Refactor: changes switch to Formatted values

* Tests: adds tests for applyRawFieldOverrides and getRawDisplayProcessor

* Test: change to utc timeZone

* Refactor: changes after PR comments
2020-09-04 11:21:24 +02:00
Ryan McKinley
ae385983f4
InfluxDB: support flux editor for template queries (#27370) 2020-09-03 14:11:39 -07:00
Ryan McKinley
b867050cfb
Annotations: improve datasource annotation types and add basic query properties (#27342) 2020-09-03 10:41:25 -07:00
Hugo Häggmark
d633cc3c09
Tests: removes unused stuff and replaces monaco transpile with mock (#27324) 2020-09-03 08:54:46 +02:00
Ryan McKinley
febbc60e8b
RangeUtils: migrate logic from kbn to grafana/data (#27347) 2020-09-02 23:54:06 -07:00
Hugo Häggmark
ff1149ac39
Table: Adds column filtering (#27225)
* Table: Adds column filters

* Refactor: adds filter by value function

* Refactor: some styling and sorting

* Refactor: Moves filterByValue to utils

* Tests: add filterByValue tests

* Refactor: simplifies filteredValues

* Refactor: adds dropshadow

* Refactor: keeps icons together with label and aligns with column alignment

* Refactor: hides clear filter if no filter is active

* Refactor: changes how values in filter are populated

* Refactor: adds filterable field override

* Tests: fixed broken tests

* Refactor: adds FilterList

* Refactor: adds blanks entry for non value labels

* Refactor: using preFilteredRows in filter list

* Refactor: adds filter input

* Refactor: fixes issue found by e2e

* Refactor: changes after PR comments

* Docs: adds documentation for Column filter

* Refactor: moves functions to utils and adds tests

* Refactor: memoizes filter function

* Docs: reverts docs for now
2020-09-01 17:06:35 +02:00
Torkel Ödegaard
1f6c2dbcfb
Thresholds: Fixed issue with thresholds in overrides not working after save and reload (#27297)
* WIP: Fix null thresholds in overrides when loading

* Fix thresholds on load instead of in apply field overrides

* simplify expression

* fixed ts issue

* Updated test

* Updated another test

* Updated another test
2020-09-01 16:00:38 +02:00
Hugo Häggmark
8ec2aa02c6
Loki: Replaces dataSourceRequest with fetch (#27265)
* Loki: Replaces dataSourceRequest with fetch

* Update public/app/plugins/datasource/loki/datasource.ts

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
2020-09-01 06:21:21 +02:00
Torkel Ödegaard
4b8f4df18d
Graph: Preseve existing data links in field config when loading dashboard (#27295)
* Graph: Preseve existing data links in field config

* ts fix
2020-08-31 17:53:21 +02:00
Totalus
7db42f0a3c
Transformations: Adding group by and aggregate on multiple fields transformation
* Adding Occurences transformer

* Adding test for Occurences Transformer

* Cleanup. Adding a test.

* Adding doc

* Modifying UI to support custom calculations options

* Implementing data transformation

* Finalizing calculations implementation

* Cleanup

* Using Fields instead of arrays in data grouping

* Renaming transformation to GroupBy

* Adding some doc

* Apply suggestions (solving TS typing errors)

Co-authored-by: Marcus Andersson <systemvetaren@gmail.com>

* Tweaking UI

* Preventing of selecting twice the same field name.

* Removing console print. No calculations by default.

* Forgot to add the current value to the GroupBy selector

* Solving some typing issues and prettyfier errors

* Cleanup

* Updating test

* Ensure proper copy of options (solves some issues)

* Check if the fields exist in the data before processing

* Adding missing import in test file

* If group by field not specified, return all data untouched.

* Adding another missing import in test

* Minor updates

* Implementing GroupBy multiple fields + Improve field typing

* Removing console prints

* Allowing the exact number of fields to be added as aggregation

* Centering remove button icon

* Cleanup

* Correcting TS error

* Chaging transformer options structure

* Sorting so GroupBy fields appear on top

* Cleanup

* Simplifying some operations. Adding curly brackets.

* Changing some labels on the UI

* Updating test

* Cleanup

* Updating doc

* Fixed field list. Storing options as Record instead of Array.

* Update test

* Cleaned up the group by editor UI code.

* changed the transform to a table layout instead of a flexbox layout.

* cleaned up group by transformer.

* removed unused imports.

* Added some more tests.

* Added one more test and cleaned up code.

* fixed failing test.

* Fixed so we we have the proper casing on naming.

* fixed so we don't wrap on the first row.

Co-authored-by: Marcus Andersson <systemvetaren@gmail.com>
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>
2020-08-31 10:46:30 +02:00
Dominik Prokop
6dbb803b3f
Transformations: enable transformations reordering (#27197)
* Transformations: enable queries reorder by drag and drop

* Satisfy ts

* Update unicons and replace ellipsis with draggabledot

* remove import

* Remove that snap

* Review

* review 2
2020-08-31 08:47:27 +02:00
Steven Vachon
611d416f91
Selector improvements for E2E (#27271) 2020-08-28 12:59:56 -04:00
Torkel Ödegaard
7d72837d40
DataFrame: Data source field naming control that does not use field.config.displayName (#27186)
* Field naming simple fix

* fixed unit tests

* Updated to use displayNameDS config

* Update packages/grafana-data/src/types/dataFrame.ts

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>

* Updated name

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2020-08-28 18:22:01 +02:00
Steven Vachon
c45cf83776
@grafana/e2e: selector improvements (#27235)
* Added labels and selectors for explore page

* Added selector for annotations

* Used selector for time picker label
2020-08-27 10:36:24 -04:00
Ivana Huckova
58627a0c38
Loki: Re-introduce running of instant queries (#27213)
* Run instant queries for loki

* Add catch for instant query errors, update test
2020-08-27 10:32:36 +02:00
kay delaney
262a42b249
UI/ClickOutsideWrapper: Adds parent prop for situations where event should be on document (#27221) 2020-08-27 09:18:34 +01:00
Torkel Ödegaard
093477c036
Dashlist: Tweaked design of folder addition (#27241) 2020-08-27 09:49:07 +02:00
Torkel Ödegaard
5e27654298
Dashboard: Ignore cancelled api request error when loading dashboard (#27232) 2020-08-27 08:55:26 +02:00
Alex Khomenko
a1e6090008
Grafana-UI: BarGauge docs (#27188)
* Grafana-UI: Add mdx file

* Grafana-UI: remove _BarGauge.scss

* Grafana-UI: Update snapshot

* Grafana-UI: Fix tests

* Grafana-UI: Use selector
2020-08-26 14:44:08 +03:00
Simon Podlipsky
7121d1e63f
Chore: Use uuid v4 as an identifier instead of Date.now() (#27178) 2020-08-26 11:38:39 +02:00
Michel Engelen
ad2e74d1fe
Dashboard: Adds folder name and link to the dashboard overview on the homepage (#27214)
* Chore: Added foldername to the dashboard overview on the startpage

## Dashlist

### added
- new `<span>` containing `dash.folderTitle`
- styling for the newly created `<span>`

### changed
- added sass-nesting to classes in `_panel_dashlist.scss`

closes #26869

* Chore: Added foldername to the dashboard overview on the startpage

## Dashlist

### changed
- added `ng-if` directive to the dashlist-folder span

* Chore: Added foldername to the dashboard overview on the startpage

## Dashlist

### changed
- added folder-icon and removed brackets to indicate `folderTitle`
- changed font-size of folderTitle-`span` and added left margin
2020-08-26 10:13:20 +02:00
Zoltán Bedi
86e44eec02
Prometheus: fix rate_interval to use min step properly (#27168)
* Prometheus: fix rate_interval to use min step properly

* Update docs/sources/features/datasources/prometheus.md

Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com>

* Simplify `getRateIntervalScopedVariable` (#27174)

Signed-off-by: beorn7 <beorn@grafana.com>

* Modify rate_interval tests to use createQuery

* Change test wording + intervalfactor

Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com>
Co-authored-by: Björn Rabenstein <beorn@grafana.com>
2020-08-25 18:55:08 +02:00
Torkel Ödegaard
ddabf4ade1
Transforms: Labels to fields rewrite that uses merge transform inside it (#27125)
* testing things

* POC: Simplify labels to fields by using merge transform inside it

* removed old code

* Fixed test ts issues

* Added valueLabel field option

* Updated merge transform tests to not expect a sort

* fixed type

* refactoring to minimize nesting
2020-08-25 09:40:49 +02:00
Simon Podlipsky
84eb03e7e5
BackendSrv: Use uuid v4 as an identifier instead of Date.now() (#27176) 2020-08-25 08:58:21 +02:00
Dominik Prokop
f7950491a3
Field overrides: Overrides UI improvements (#27073)
* Add filter name by regex matcher for overrides

* Update docs

* Introduce UI improvements to overrides list

* Update public/app/features/dashboard/components/PanelEditor/OverrideEditor.tsx

Co-authored-by: kay delaney <45561153+kaydelaney@users.noreply.github.com>

* Review improvements

* Fix merge

* Remove ellipsis

Co-authored-by: kay delaney <45561153+kaydelaney@users.noreply.github.com>
2020-08-24 12:07:44 +02:00
Hugo Häggmark
09a1af3f91
Variables: Fixes issue with All variable not being resolved (#27151)
* Variables: Fixes issue with All variable not being resolved

* Tests: update tests according to changes
2020-08-24 09:29:21 +02:00