Commit Graph

15121 Commits

Author SHA1 Message Date
kay delaney
f10047b708
Dashboard: Refactor panel cleanup (#47323) 2022-04-12 14:12:03 +01:00
Andrej Ocenas
c449aadc1b
Prometheus: Fix executing query onBlur in Explore (#47561) 2022-04-12 14:55:57 +02:00
Dominik Prokop
98cbecc4a5
Allow queries import when changing data source type (#47435)
* Enable queries import when changing datasource

* Supporting empty imports

* Review applied
2022-04-12 04:52:55 -07:00
Torkel Ödegaard
7181efd1cf
Explore: Allow users to save Explore queries to dashboards (#47083)
* Select: Expose AsyncSelectProps interface

* DashboardPicker: Add a generic DashboardPicker component

* Dashboard Service: improve types

* Explore: allow saving explore state in a new panel in an existing dashboard

* Handle saving provisioned dashboards error

* Improve test coverage

* simplify test setup

* Strip base path from url when redirecting to a dashboard

* Keep existing variables when saving to an existing dashboard

* group assertions in test

* SearchCard: handle undefined in meta.updated

* Change required error message

* Add to dashboard alternative

* Add to existing is working

* Add to dashboard form

* remove default add-panel when creating a dashboard from explore

* types cleanup

* remove unneeded BE change

* simplify selector

* Add explore2Dashboard feature toggle

* add tests

* Small refactor & add tests

* small DashboardPicker improvements

* use partial from lodash

* Better error handling

* improve tests & disable button when there are no queries

* rename addPanelToDashboard function

* remove localStorage item if opening tab fails

* UI touchups & tracking

* Fix tests & remove close reporting

* remove echologger debug

* fix adding a panel to an existing dashboard

* Enable explore2Dashboard by default and add docs

* Ensure each panel in dashboards has a valid ID

* force CI restart

Co-authored-by: Elfo404 <me@giordanoricci.com>
2022-04-12 13:26:07 +02:00
Gábor Farkas
8db35b9b0b
loki: backend-mode: allow for dashboards too (#47578) 2022-04-12 12:16:05 +02:00
Gábor Farkas
eca61e6dd7
loki: removed unused fields, params, attributes (#47571)
* loki: refactor: removed unused param

* loki: removed unused attribute

* loki: removed unused fields

* loki: remove unused query.format

* loki: removed unused prop
2022-04-12 12:09:47 +02:00
Gábor Farkas
68511e7712
loki: use single-dataframe format on the backend (#47069) 2022-04-12 11:58:48 +02:00
Garrett Guillotte
42431e6ad4
Explore/Logs: Improve and add descriptions of Explore's Escape newlines feature (#46709)
* Explore/Logs: Clarify phrasing of newline escape fix tooltip

Rewrite the tooltip for the smart feature in PR #31352 that
replaces incorrectly escaped newlines in log lines.

-   Clarify the functionality of the feature to emphasize its
    interactivity.
-   Remove language suggesting that the feature is experimental,
    when we intended to suggest reviewing the results manually for
    correctness.

* Docs: Document escape newlines feature

Describe and provide steps for using the "Escape newlines" feature
in Explore added in PR #31352.

* Rewrite topic lead to clarify conditional behavior

* Describe reversion of replacements as a standalone task

Reverting the replacements is a separate action, so it should have
its own task. This also describes the option's transformation and
tightens the task language.

* Remove Grafana 7 version qualifier

* Clarify escape sequence detection lede on task

Co-authored-by: Fiona Artiaga <89225282+GrafanaWriter@users.noreply.github.com>

* Clarify "Remove escaping" state change

Co-authored-by: Fiona Artiaga <89225282+GrafanaWriter@users.noreply.github.com>

* Clarify confidence of tooltip content

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

Co-authored-by: Fiona Artiaga <89225282+GrafanaWriter@users.noreply.github.com>
Co-authored-by: achatterjee-grafana <70489351+achatterjee-grafana@users.noreply.github.com>
2022-04-12 09:22:28 +02:00
Joe Blubaugh
51c98b182d
Unified Alerting: UI explains "match all" case in Notification Policies. (#47574)
This change makes it explicit in the UI that a notification policy with no matching labels matches all alerts that it processes. There are visual changes in both the Notification Policy editor, and in the Notification Policy table where matching columns are shown.

It's valid to have a notification policy with no label matchers attached. Such a policy matches all alerts sent to it. It's a common stumbling block for users. Where are all my alerts going?

Co-authored-by: gillesdemey <gilles.de.mey@gmail.com>
2022-04-12 10:42:17 +08:00
jcolladokuri
7a8437020d
Azure Monitor: Bug Fix for for template variables (#47478) 2022-04-11 19:36:51 -04:00
Ashley Harrison
fb0f30e30b
Navigation: wrap long items in the menu correctly (#47431)
* start implementing wrapping behaviour

* handle more cases

* minWidth > width to preserve mobile behaviour

* Better css
2022-04-11 17:19:33 +01:00
Connor Lindsey
1ed83eb9b2
Tracing: Add README files for tracing datasource plugins 2022-04-11 18:16:38 +02:00
Nathan Marrs
99bb6ebd2b
Search: Update tag filter options dynamically (#47165) 2022-04-08 12:18:52 -07:00
Kevin Yu
ebe5f3646f
AzureMonitor: Use Resource Picker in Metrics Query Editor (#47164)
* wip: new metrics query editor

* prepend subscriptions to url path

* remove duplicated setQueryValue file

* add tests for new metrics query editor

* wip start extracting resource field into a shared component

* fix query editor test

* fix up backend tests

* move azure monitor specific getters to azure_monitor_datasource

* use existing useAsyncState hook

* extract useAsyncState into separate file

* add datahooks tests

* extract resource field component

* cleanup

* clarify variable names

* remove logs query specific resource field component

* add url_builder test

* add azure_monitor_datasources tests

* address comments

* add types

* pass resourceUri to resource field component

* add test to check we reset the query fields when changing resources
2022-04-08 08:49:46 -07:00
Eric Leijonmarck
883ce5ad30
Service accounts: UI polish improvements (#47461)
* ui polishes

* change icon
2022-04-08 16:23:03 +01:00
Gilles De Mey
7e844064a4
Alerting: fix collapsable toggle text regression (#47517) 2022-04-08 17:15:19 +02:00
Gilles De Mey
c530100d45
fix: don't allow editing rule types for existing rules (#47512) 2022-04-08 15:26:33 +02:00
Konrad Lalik
87383b1c8b
Alerting: FGAC for alert rules page (#47418)
* Apply FGAC on the alert rules list page

* Add tests for edit, delete and silence buttons

* Unify access-control helpers

* Fix import

* Add route permissions for alert groups, unify access control helpers

* Improve buttons with data source explore permission

* Fix test
2022-04-08 13:34:02 +02:00
Gábor Farkas
beed3fd5de
loki: remove unused reverse-attribute (#47494) 2022-04-08 12:24:09 +03:00
Gábor Farkas
9574f447bb
grafana-data: removed DataQueryRequest.reverse (#47487) 2022-04-08 12:00:16 +03:00
Gábor Farkas
e1438990ae
Loki: use the same dataframe-format for both live and normal queries (#47153)
* loki: use single dataframe-format for both live and normal queries

* better comment

* better function-name

* simplified code

* logs_model: added test
2022-04-08 09:57:06 +02:00
Stephanie Closson
222325c7f1
Fix: Parse exemplars before parsing heatmap data (#47463)
* parse exemplars before parsing the heatmap. Exemplars are overlayed. Not part of the main heatmap

* added tests
2022-04-07 13:49:54 -03:00
Josh Hunt
b857f8339e
TestData: Interpolate variables in more fields (#47158)
* TestData: Interpolate variables in more fields

* only interpolate variables if the field is set

* Correctly type scenarioId which can be undefined
2022-04-07 14:45:14 +01:00
Ashley Harrison
d95782845d
Navigation: add aria-label to NavBarToggle (#47434)
* add aria-label to NavBarToggle

* use open/close instead
2022-04-07 14:14:01 +02:00
Josh Hunt
41642fd5f4
Modify the Server Error scenario to return frontend errors (#47157) 2022-04-07 10:59:49 +01:00
renovate[bot]
c3fe027d58
Update dependency @reduxjs/toolkit to v1.8.0 (#45950)
* Update dependency @reduxjs/toolkit to v1.8.0

* Fix type errors

* simplified code

Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: kay delaney <kay@grafana.com>
Co-authored-by: Piotr Jamróz <pm.jamroz@gmail.com>
Co-authored-by: Gábor Farkas <gabor.farkas@gmail.com>
2022-04-07 11:27:58 +02:00
kay delaney
0cff2d5980
Library panels: Fix issue where query editor options wouldn't be updated (#47242)
Closes #47241
2022-04-07 09:39:54 +01:00
Giordano Ricci
ca286a238d
Explore: Add explore2Dashboard feature toggle (#47395) 2022-04-07 09:26:01 +01:00
Timur Olzhabayev
25235b3167
Removing plugin list panel (#46914)
The core plugin named plugin list panel is removed
2022-04-07 09:54:27 +02:00
Gábor Farkas
6e0826a986
loki: do not convert NaN to null (#45389) 2022-04-07 09:44:04 +02:00
Nathan Marrs
015a31644c
Search: clean up styling (#47221) 2022-04-06 16:59:24 -07:00
Nathan Rodman
49505b9a3b
Alerting: fgac for notification policies and contact points (#46939)
* add FGAC actions for silences table

* redirect users without permissions

* add permissions checks to routes

* add fgac to notifications and contact points

* fgac for notification policies

* fix mute timing authorization

* use consistent naming for checking grafana alertmanager

* tests for fgac in contact points and notification policies

* bump up timeout on rule editor test

* use new permissions util

* break out route evaluation into util

* Remove test timeout

* Change permissions for the alert-notifiers endpoint

* Use signed in handler for alert-notifiers when unified alerting enabled

Co-authored-by: Konrad Lalik <konrad.lalik@grafana.com>
2022-04-06 18:24:33 +02:00
Ashley Harrison
04c037b2cb
Navigation: implement full-width mobile menu (#47383)
* navigation: implement proper mobile menu

* Update public/app/core/components/NavBar/Next/NavBarMenu.tsx

Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>

* animation feedback

Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
2022-04-06 16:53:59 +01:00
Kristina
b9e6ed3a8a
Convert Rich History tests to RTL (#47220)
* Migrate enzyme tests to RTL

* Convert rich history card tests

* Fix Lint errors

* Fix tests based on feedback

* Fix second await
2022-04-06 10:26:33 -05:00
Piotr Jamróz
88ec750728
Query History: Load history when QueryHistoryContainer is opened (#46457)
* Load Rich History when the container is opened

* Store rich history for each pane separately

* Do not update currently opened query history when an item is added

It's impossible to figure out if the item should be added or not, because filters are applied in the backend. We don't want to replicate that filtering logic in frontend. One way to make it work could be by refreshing both panes.

* Test starring and deleting query history items when both panes are open

* Remove e2e dependency on ExploreId

* Fix unit test

* Assert exact queries

* Simplify test

* Fix e2e tests

* Fix toolbar a11y

* Reload the history after an item is added

* Fix unit test

* Remove references to Explore from generic PageToolbar component

* Update test name

* Fix test assertion

* Add issue item to TODO

* Improve test assertion

* Simplify test setup
2022-04-06 13:49:25 +02:00
Andrej Ocenas
0d3879d1c1
Prometheus: Add beta tag to mode switch for Builder mode (#47376)
* Add beta tag to mode switch

* Fix selectors
2022-04-06 11:50:12 +02:00
Ivana Huckova
caa82a124d
Loki,Prometheus: Fix of showing error message for empty query (#47379)
* Loki,Prometheus: Dont show error on empty query

* Add tests
2022-04-06 11:17:49 +02:00
Andrej Ocenas
ad4fcfd69b
Prometheus: Set default mode to Code (#47342)
* Set default to Code

* Fix tests
2022-04-06 10:07:11 +02:00
Isabella Siu
05b1edb4a7
CloudWatch: re-add filter to handleMetricQueries (#47341) 2022-04-06 09:02:34 +02:00
Ivana Huckova
82aa31df36
Loki: Add missing functions to query builder (#47333) 2022-04-05 19:15:22 +02:00
Josh Hunt
1b27e55e5a
Analytics: Identify users to Rudderstack by externalUserId where available (#47325)
* wip

* tests

* move util, fix test

* fixes

* Update public/app/core/services/echo/utils.ts

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

Co-authored-by: kay delaney <45561153+kaydelaney@users.noreply.github.com>
2022-04-05 17:41:22 +02:00
Ashley Harrison
9b61f1cd9f
close when clicking just the icon (#47331) 2022-04-05 16:16:05 +01:00
Ivana Huckova
6938d5b975
Loki: Show error when parsing nodes not supported in visual query builder (#47321)
* Show error when parsing nodes not supported in visual query builder

* Refactor, simplify

* Spell fix

* Spell fix
2022-04-05 17:07:13 +02:00
Ashley Harrison
b6a184996b
Implement hover states + remove some old code to do with pinning (#47328) 2022-04-05 15:53:23 +01:00
Joao Silva
d311a3bef5
Navigation: Keeps nav item hover when hovering over the item menu (#47281) 2022-04-05 15:38:58 +01:00
Ashley Harrison
8ede6161d4
Navigation: implement underlay (#47311)
* Navigation: implement underlay

* abstract out animation duration and add box-shadow

* rename underlay to backdrop, better syntax for composing css
2022-04-05 14:21:22 +01:00
Josh Hunt
2fe6eca7a0
NewsPanel: Remove Use Proxy option and update documentation with recommendations (#47189)
* NewsPanel: Remove CORS proxy and update documentation with recommendations

* Updated generated model

* Update news-panel.md

* Update docs/sources/visualizations/news-panel.md

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

* Update docs/sources/visualizations/news-panel.md

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

* Update news-panel.md

Co-authored-by: achatterjee-grafana <70489351+achatterjee-grafana@users.noreply.github.com>
2022-04-05 15:16:28 +02:00
Ivana Huckova
c5ac19d499
Loki: Add all supported parsers to query builder (#47304)
* Loki: Add all supported parsers to query builderr

* Update test

* Add tests for new parsers
2022-04-05 14:52:06 +02:00
Ezequiel Victorero
6a059dcb4d
Access Control: hiding add annotation button without permissions (#47223)
* Access Control: hiding add annotation button without permissions
2022-04-05 08:20:10 -03:00
kay delaney
25c91d7bb9
Nav: Capitalize "Dashboards" in "Search Dashboards" (#47289) 2022-04-05 09:17:23 +01:00