Commit Graph

28403 Commits

Author SHA1 Message Date
G Gordon Worley III
0fbe7f7f52
Docs: Add mention of preferredVisualisationType in logs datasource guide (#31910)
* Add mention of preferredVisualisationType to get Log Panel to display

The instructions don't work right now. As described, it was necessary for me to set the preferredVisualisationType to 'logs' to get the log view in Explore. I spent several hours digging around the code to figure this out, so hopefully we can save others the time with this doc update.

* Update docs/sources/developers/plugins/build-a-logs-data-source-plugin.md

Co-authored-by: Andrej Ocenas <mr.ocenas@gmail.com>

* Update docs/sources/developers/plugins/build-a-logs-data-source-plugin.md

Co-authored-by: Andrej Ocenas <mr.ocenas@gmail.com>

* Update docs/sources/developers/plugins/build-a-logs-data-source-plugin.md

Co-authored-by: Andrej Ocenas <mr.ocenas@gmail.com>

Co-authored-by: Andrej Ocenas <mr.ocenas@gmail.com>
2021-03-18 10:44:53 +01:00
Marcus Andersson
69201bbf8c
Plugins: moving the DataSourcePicker to grafana/runtime so it can be reused in plugins (#31628)
* moved the datasource picker to grafana-runtime.

* fixed imports.

* added e2e selectors as an external package.

* adding react as external package.

* exposing dependent types for DataSourcePicker.

* added docs for ui components.

* moving component to components.
2021-03-18 10:44:26 +01:00
Denis Hilt
8fafe95728
DashNav: Pass typed event through the DashNav button onClick handler (#32084)
* Pass typed event thorough the DashNav button onClick handler

Event.stopPropagation() method needs to be called in some cases. This change addresses typescript error Type '(event: ...) => void' is not assignable to type '() => void'.

* Pass typed event thorough the DashNav button onClick handler

* Import MouseEvent from React
2021-03-18 08:23:58 +01:00
Dimitris Sotirakis
2d72b4e69e
Prometheus: Convert Prometheus query response to dataframes (#31948)
* Convert Prometheus query response to dataframes

* Add parseResponse tests

* Fixed lint imports

* Force use UTC as timezone in timeVector

* Updated test to check timezone
2021-03-18 08:40:26 +02:00
Ryan McKinley
5bb1b1602d
Live: use StreamingDataSource for live measurments (#31713) 2021-03-17 21:46:56 -07:00
achatterjee-grafana
5286ddbbc0
Updated broken link for Graph panel documentation. (#32082) 2021-03-17 16:49:19 -04:00
Owen Diehl
7a4ab13a79
API Response implements http.ResponseWriter (#32046)
* rename response.Header -> response.SetHeader to free up method name for http.ResponseWriter ifc

* normalresponse implements http.ResponseWriter
2021-03-17 13:12:28 -04:00
Owen Diehl
36614b03f7
Data Source Proxy: Migrate proxy to its own service and make more extensible (#31927)
* datasource proxy extensions

* revert normalresponse extensions

* data proxy service impl

* lint

* api datasource proxy method

* moves datasource proxy tests into correct new pkg
2021-03-17 13:10:40 -04:00
Torkel Ödegaard
e935e4979f
TimePicker: Fixes hidden time picker shown in kiosk TV mode (#32062)
* TimePicker: Fixes hidden time picker shown in kiosk TV mode

* Use kioskmode passed via props

* Update snaps

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
2021-03-17 18:03:05 +01:00
Ganesh Vernekar
974ccf8091
AlertingNG: Fix the alerting stage for legacy alerts (#32025)
Signed-off-by: Ganesh Vernekar <cs15btech11018@iith.ac.in>
2021-03-17 16:38:33 +00:00
Marcus Efraimsson
866912d62c
Update pr commands glob paths (#32074) 2021-03-17 16:53:22 +01:00
Marcus Efraimsson
2bac4d1787
Update pr commands glob paths (#32073) 2021-03-17 16:48:21 +01:00
Gábor Farkas
8285a34f4c
influxdb: raw-influxql editor: fix state-management bug (#32035)
* influxdb: raw-influxql editor: state-management bug fixed

* influxdb: simplified code
2021-03-17 16:32:40 +01:00
Dimitris Sotirakis
3a841ebe00
Downgrade to node:14.16.0-alpine3.13 (#32065) 2021-03-17 17:07:39 +02:00
Arve Knudsen
87c3a2b790
PluginManager: Make Plugins, Renderer and DataSources non-global (#31866)
* PluginManager: Make Plugins and DataSources non-global

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

* Fix integration tests

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

* Replace outdated command

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

* DashboardService: Ensure it gets constructed with necessary parameters

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

* Fix build

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

* DashboardService: Ensure it gets constructed with necessary parameters

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

* Remove dead code

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

* Fix test

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

* Fix test

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

* Remove FocusConvey

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

* Fix test

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

* Remove dead code

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

* Undo interface changes

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

* Backend: Move tsdbifaces.RequestHandler to plugins.DataRequestHandler

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

* Rename to DataSourceCount

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

* Consolidate dashboard interfaces into one

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

* Fix tests

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

* Fix tests

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

* Fix test

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

* Fix tests

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

* Fix tests

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

* Fix tests

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

* Fix tests

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

* Fix dashboard integration tests

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
2021-03-17 16:06:10 +01:00
Marcus Efraimsson
f1df32ac03
Update pr commands glob paths (#32068) 2021-03-17 15:20:20 +01:00
Uchechukwu Obasi
f93166e7b2
Legacy Input: updates story from knobs to control (#32059) 2021-03-17 14:43:31 +01:00
Dominik Prokop
48f46a597f
GraphNG: Fix PlotLegend field display name being outdated (#32064) 2021-03-17 14:40:30 +01:00
Marcus Efraimsson
c8d8dcd067
Automation: Label pull requests based on changed files (#32039)
* Automation: Label pull requests based on changed files

* Update commands

* Updates for build-packaging

* fix path to backend architecture docs
2021-03-17 12:49:57 +01:00
dependabot[bot]
b95fd1d1ce
Chore(deps): Bump github.com/aws/aws-sdk-go from 1.37.30 to 1.37.32 (#32058)
Bumps [github.com/aws/aws-sdk-go](https://github.com/aws/aws-sdk-go) from 1.37.30 to 1.37.32.
- [Release notes](https://github.com/aws/aws-sdk-go/releases)
- [Changelog](https://github.com/aws/aws-sdk-go/blob/main/CHANGELOG.md)
- [Commits](https://github.com/aws/aws-sdk-go/compare/v1.37.30...v1.37.32)

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

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-03-17 12:23:11 +01:00
Marcus Efraimsson
c0edf88f9f
Data proxy: Fix encoded characters in URL path should be proxied encoded (#30597)
Fix encoded characters in URL path should be proxied as encoded in the data proxy.

Fixes #26870 
Fixes #31438

Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com>
2021-03-17 12:17:41 +01:00
Sofia Papagiannaki
68b05b8aaa
AlertingNG: Unified alerting API mock (#32040)
* AlertingNG: Alertmanager mock API

* AlertingNG: Remove permissions API routes

* Add example POST payloads

* Prometheus and testing mock API
2021-03-17 12:47:03 +02:00
Uchechukwu Obasi
ee8a864615
Form: update story from knobs to controls (#32022)
* Form: update story from knobs to controls

* some code cleanup
2021-03-17 11:14:39 +01:00
Giordano Ricci
0c2045109e
Chore: Collect elasticsearch version usage stats (#31787)
* Chore: Collect elasticsearch version usage stats

* Fix lint error

* use GetDataSources from sqlstore

* Apply review suggestions

* Return error if datasource type is not specified

* Update pkg/services/sqlstore/datasource.go

* fix undefined var
2021-03-17 09:14:53 +00:00
Will Browne
8e1c2d6472
move backend docs to their relevant folder (#32041) 2021-03-17 09:41:16 +01:00
Marcus Andersson
93f17bd2b3
Graphite: Support request cancellation properly (Uses new backendSrv.fetch Observable request API) (#31928)
* changed so we use fetch.

* moved tests to be at the same level as the datasource.

* fixing tests after migrating to fetch.

* removed unused dep.

* refactorings according to feedback.

* adding missing typing.
2021-03-16 18:21:38 +01:00
Joan López de la Franca Beltran
610999cfa2
Auth: Allow soft token revocation (#31601)
* Add revoked_at field to user auth token to allow soft revokes

* Allow soft token revocations

* Update token revocations and tests

* Return error info on revokedTokenErr

* Override session cookie only when no revokedErr nor API request

* Display modal on revoked token error

* Feedback: Refactor TokenRevokedModal to FC

* Add GetUserRevokedTokens into UserTokenService

* Backendsrv: adds tests and refactors soft token path

* Apply feedback

* Write redirect cookie on token revoked error

* Update TokenRevokedModal style

* Return meaningful error info

* Some UI changes

* Update backend_srv tests

* Minor style fix on backend_srv tests

* Replace deprecated method usage to publish events

* Fix backend_srv tests

* Apply suggestions from code review

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
Co-authored-by: Hugo Häggmark <hugo.haggmark@gmail.com>

* Apply suggestions from code review

* Apply suggestions from code review

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

* Minor style fix after PR suggestion commit

* Apply suggestions from code review

Co-authored-by: Ursula Kallio <73951760+osg-grafana@users.noreply.github.com>

* Prettier fixes

Co-authored-by: Hugo Häggmark <hugo.haggmark@gmail.com>
Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
Co-authored-by: Ursula Kallio <73951760+osg-grafana@users.noreply.github.com>
2021-03-16 17:44:02 +01:00
Andrej Ocenas
a1c7e0630d
Docs: Update section on plugin dev for explore (#31905)
* Update section on preferredVisualisationType

* wording changes

* Update docs/sources/developers/plugins/add-support-for-explore-queries.md

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

* Update docs/sources/developers/plugins/add-support-for-explore-queries.md

Co-authored-by: Ursula Kallio <73951760+osg-grafana@users.noreply.github.com>

* Update docs/sources/developers/plugins/add-support-for-explore-queries.md

Co-authored-by: Ursula Kallio <73951760+osg-grafana@users.noreply.github.com>

Co-authored-by: achatterjee-grafana <70489351+achatterjee-grafana@users.noreply.github.com>
Co-authored-by: Ursula Kallio <73951760+osg-grafana@users.noreply.github.com>
2021-03-16 17:25:10 +01:00
Dominik Prokop
48eb747da0
Routing NG: Fix persistent modal after dashboard delete (#32033) 2021-03-16 17:10:47 +01:00
Marcus Efraimsson
a97637a133
Snapshots: Fix usage of sign in link from the snapshot page (#31986)
Fix redirect to login page from snapshot page when not authenticated.

Fixes #28547
2021-03-16 16:46:34 +01:00
Marcus Efraimsson
669a616797
Chore: Remove unused dependencies (#32031) 2021-03-16 16:26:38 +01:00
Vicky Lee
e5ca13deb6
Grafana/ui: display all selected levels for selected value when searching (#32030)
* display all levels for selected values when searching if needed

* add test
2021-03-16 15:10:05 +00:00
Kevin Minehart
6e1c5e957a
Enterprise: Add Redis caching documentation (#32001)
* Document Redis cache config in Grafana Enterprise

Co-authored-by: Diana Payton <52059945+oddlittlebird@users.noreply.github.com>
Co-authored-by: Ursula Kallio <73951760+osg-grafana@users.noreply.github.com>
2021-03-16 15:35:52 +01:00
Gábor Farkas
13fd2bd53f
devenv: removed min-interval setting from influxdb-datasources (#32002) 2021-03-16 14:42:28 +01:00
Dominik Prokop
e967ad9ca9
Routing NG: Fix time range zoom not working when refresh enabled (#32023)
* Fix time range zoom not working when refresh enabled

* Review update
2021-03-16 14:25:40 +01:00
Zoltán Bedi
bb8a703428
Exemplars: always query exemplars (#31673)
* Exemplars: always query exemplars

* Update exemplar button to be an eye

* Add tooltip to eye button
2021-03-16 13:58:51 +01:00
Uchechukwu Obasi
ec95049a95
FormField: update story from knobs to controls (#32018) 2021-03-16 12:49:46 +01:00
Uchechukwu Obasi
cc29bc3c5d
FieldValidationMessage: update story from knobs to controls (#32020) 2021-03-16 12:49:25 +01:00
Gábor Farkas
56bc9a5da7
devenv: fix incorrect url in datasource-config (#32000) 2021-03-16 11:50:38 +01:00
Piotr Jamróz
6495a73ebd
Graphite: fix autocomplete when tags are not available (#31680)
* Return empty list of tags when tags are not available

In some configurations graphite-web fail to return the list of tags. It shouldn't however prevent displaying list of metrics (which is concatenated with tags).

* Populate jsonData with default version of Graphite

The version of Graphite is preselected in the dropdown but was not saved in jsonData initially.

* Fix a typo

* Show a popup with an error message

* Always use the latest Graphite value as the default one when creating a datasource

* Move autocomplete error handling to GraphiteQueryCtrl

* Test error handing in Graphite autocomplete

* Test default Graphite version fallback

* Rename graphite_versions.ts to versions.ts

* Remove redundant import

* Code formatting, minor renaming

* Remove redundant error info
2021-03-16 10:59:53 +01:00
Arve Knudsen
6081c00119
Docs: Document backend package hierarchy model (#31930)
* Docs: Document backend package hierarchy model

Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com>
2021-03-16 10:49:01 +01:00
Gábor Farkas
cbaf700d64
influxdb: switch the raw influxql editor from angular to react (#31860)
* influxdb: switch the raw influxql editor from angular to react

* influxdb: raw-influxql: better callback-naming

* influxdb: raw-influxql: use custom hook

* influxdb: flux: raw-editor: add unit tests
2021-03-16 10:47:33 +01:00
Ganesh Vernekar
ecbc98ba5d
AlertingNG: Add alert provider and basic structure with dispatcher, silences and delivery stages (#31833)
* AlertingNG: Add alert provider

Signed-off-by: Ganesh Vernekar <cs15btech11018@iith.ac.in>

* Add unit tests

Signed-off-by: Ganesh Vernekar <cs15btech11018@iith.ac.in>

* Alertmanager WIP

* Merge alertmanager into notifier

Signed-off-by: Ganesh Vernekar <cs15btech11018@iith.ac.in>

* Fixes for PR 31833 (#31990)

Signed-off-by: Ganesh Vernekar <cs15btech11018@iith.ac.in>

* Use alertmanager from upgrad-uuid temporarily to unblock

Signed-off-by: Ganesh Vernekar <cs15btech11018@iith.ac.in>

* Fix lint

Signed-off-by: Ganesh Vernekar <cs15btech11018@iith.ac.in>

Co-authored-by: Josue Abreu <josue@grafana.com>
2021-03-16 10:44:52 +01:00
Dominik Prokop
e9402a56ba
Make master green (#32011) 2021-03-16 09:55:02 +01:00
Zoltán Bedi
fe763d7d92
Chore: Jaeger ds to use new fetch api (#31969) 2021-03-16 09:39:35 +01:00
Dominik Prokop
0d92425bb8
RoutingNG: Fix infinite loop caused by history state not being cleaned up (#31952)
* Fix infinite loop caused by history state not being cleaned up

* Ude forceRouteReload counter instead of bool flag

* Review fix
2021-03-16 09:27:32 +01:00
Ryan McKinley
7552711660
Streaming: use StreamingDataFrame for testdata client streaming example (#31998) 2021-03-15 12:16:40 -07:00
Dominik Prokop
b0b2ba0157
TooltipContainer - use resize observer instead of getClientBoundingRect (#31937)
* TooltipContainer - use resize observer instead of getClientBoundingRect

* Well, let's screw Safari, shall we?

* Memoize resize observer

* Make ts happy happy happy
2021-03-15 18:08:43 +01:00
Komalis
50e5342379
InfluxDB: Support region annotations (#31526) 2021-03-15 17:29:11 +01:00
Hugo Häggmark
bc60ce9cce
Variables: Fixes filtering in picker with null items (#31979)
* Variables: Fixes filtering in picker with null items

* Chore: some cleanup
2021-03-15 15:45:32 +01:00