Commit Graph

19178 Commits

Author SHA1 Message Date
Joey
f1338cee60
Tracing: Add inline validation to time shift configuration fields (#70879)
* Inline validation

* Update invalidTimeShiftError after self review

* Renames and moved err msg

* Update validation

* Remove local state
2023-07-04 10:49:21 +01:00
ismail simsek
80c432e524
InfluxDB: Fix backend mode table result with aliases (#69943)
Co-authored-by: ludovio <ludovic.viaud@gmail.com>
2023-07-03 14:50:08 +02:00
Galen Kistler
4217c8057b
Graphite: Fix infinite loop in text editor when using graphite in a Mixed datasource (#70970)
Fix infinite react state loop exhibited in mixed datasource by stringifying objects in useEffect dependencies
2023-06-30 14:00:26 -05:00
Ashley Harrison
7a2a5dde8b
Chore: Enable remaining jsx-a11y rules (#70990)
enabling remaining a11y rules + ignore existing violations
2023-06-30 16:58:16 +01:00
Adam Simpson
f32f1859a0
AzureMonitor: Fix metric names for multi-resources. (#70864)
When building a query for multiple resources only a subset of metrics
are valid and that selection is only available via the API version `2017-12-01-preview`.

fixes #68603
2023-06-30 15:36:03 +00:00
sam boyer
751b982d9c
Schemas: Allow nulls in schema for +/-Infinity types (#70958)
* Add null options and remove veneer attributes

* Generate all code, remove old veneer defs

* Remove now-unnecessary error expect
2023-06-30 18:15:02 +03:00
Andrej Ocenas
3eaee12e3e
Flamegraph: Add switch for color scheme by value or by package (#70770) 2023-06-30 17:01:11 +02:00
Sven Grossmann
6393ef9385
Logs: Add pinning icon in log context (#70945)
add pinning icon
2023-06-30 15:33:40 +02:00
Sonia Aguilar
97420119e1
Alerting: Reduce number of unnecessary request in the alert list panel in case … (#70583)
* Reduce number of unnecessary request in the alert list panel in case we have data source filter selected

* use fetchPromAndRulerRulesAction instead of fetchAllPromAndRulerRulesAction in case of having datasource selected in options

* remove unnecessary useEffect

* Reduce number of requests in GroupBy component if data source is selected

* use redux utils for asyncmapslice

* lint

* Address review comments

* Skip fetching grafana rules if datasource is not Grafana rules source name

---------

Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2023-06-30 15:16:14 +02:00
RoxanaAnamariaTurc
e2dd1e9055
I18n: Mark up phrases for translation on NewFolder drawer (#70888)
* I18n:Mark up phrases for translation on NewFolder drawer

* Updated variable name from field-label to name-label
2023-06-30 12:13:03 +01:00
RoxanaAnamariaTurc
af9b071a78
I18n: Mark up strings on Navigation - Connections section (#70914) 2023-06-30 11:27:19 +01:00
RoxanaAnamariaTurc
ea361f5db4
Login: Adjust error message when user exceed login attempts (#70736)
* Adjust error message when user exceed login attempts

* empty commit to add coauthors

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
Co-authored-by: L-M-K-B <48948963+L-M-K-B@users.noreply.github.com>
Co-authored-by: tskarhed <1438972+tskarhed@users.noreply.github.com>

---------

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
Co-authored-by: L-M-K-B <48948963+L-M-K-B@users.noreply.github.com>
Co-authored-by: tskarhed <1438972+tskarhed@users.noreply.github.com>
2023-06-30 11:22:44 +01:00
Sven Grossmann
13dd821961
Loki: Fix wrong query expression with inline comments (#70947)
fix remove comments from query
2023-06-30 11:35:43 +02:00
Gábor Farkas
2084cc9955
Logs: Do not insert log-line into log-fields in json download (#70901)
* logs: do not insert log-line into log-fields in json download

* fixed test after merge
2023-06-30 09:37:32 +02:00
Sonia Aguilar
0e4a8b01ab
Alerting: Use ToggleTip instead of Hovercard in the info popup on Math expressions (#70881)
* Use ToggleTip instead of Hovercard in the info popup on Math expressions

* Address review comments
2023-06-29 20:02:30 +02:00
Shantanu Alsi
72581a77ac
Prometheus: Add disableRecordingRules datasource config (#70903)
* Add config to toggle recording rules for Prometheus

* Add documentation for Prometheus disableRecordingRules
2023-06-29 18:58:22 +03:00
Gareth Dawson
0072b2cca4
Loki: Use better query validation before requesting stats (#70800)
* fix: use correct validate funtion

* rename isValidQuery to isQueryWithError

* lets pretend i didnt break things again

* Loki validation: add missing comments and refactor validation function

* isValidQuery: add unit test

* Loki datasource: add tests for getQueryStats

* Remove isValidQuery function

* UnwrapParamEditor: interpolate query before testing validity

* Stats: trim queries when evaluating change

---------

Co-authored-by: Matias Chomicki <matyax@gmail.com>
2023-06-29 16:50:17 +01:00
Juan Cabanas
28d251e5f8
Export: Templateize datasource uid when it's a library panel (#70648) 2023-06-29 12:48:25 -03:00
Ashley Harrison
ebd6aa5034
Permissions: Fix incorrect navId in permissions page (#70906)
fix navId in permissions page
2023-06-29 16:35:41 +01:00
Eric Leijonmarck
59be79b5f4
SAML UI: metric for provider card clicked (#70894)
provider card clicked
2023-06-29 15:42:52 +01:00
Matias Chomicki
f274484727
Elasticsearch: escape colons in ad hoc filters (#70611)
* Elasticsearch: escape colons in ad hoc filters

* Escape filter: update regex

* Elasticsearch: escape colons from all filters
2023-06-29 16:40:55 +02:00
Gábor Farkas
4548b0d9fc
logs: better nanosecond handling (#70878)
* logs: simplify code

* refactor

* handle nanoseconds
2023-06-29 15:33:41 +02:00
Josh Hunt
ae2378395b
Login: Fix footer from displaying under the login box (#70897) 2023-06-29 13:16:55 +00:00
Brendan O'Handley
bb7a3be86e
Prometheus: Metrics explorer remove select dropdown behavior (#70722)
* remove hover style from results

* remove metric select keyboard interactions and highlighting for table results

* update naming for metrics explorer

* fix bug for match highlighting persisting when empty query
2023-06-29 08:57:47 -04:00
Ashley Harrison
9ee2cc742a
Chore: Use theme.shape.radius.circle everywhere (#70896)
* use theme.shape.radius.circle everywhere

* add useTheme2 import
2023-06-29 13:56:05 +01:00
Gábor Farkas
890316c105
logs: add more tests (#70886) 2023-06-29 14:53:31 +02:00
RoxanaAnamariaTurc
0e2626b004
I18n:Mark up phrases for translation on Permissions drawer (#70842)
* I18n:Mark up Permissions

* Mark up strings in Permissions file

* I18n:Mark up phrases for on Permissions drawer

* I18n:Mark up phrases for translation on Permissions page

* I18n:Mark up phrases for translation on Permissions page

* Made the changes based on suggestions received

* restore translations

* Run extract again
2023-06-29 13:43:14 +01:00
Ashley Harrison
703bf4afcc
Nested folders: Unify visual styles between tree + search view (#70814)
* unify search table styles with browse

* add a skeleton state when switching to search view

* show all column headers

* use isItemLoaded

* extract number of placeholder rows into variable + add comment

* fix all selection toggle behaviour

* tidy up

* fix unit test
2023-06-29 10:31:22 +01:00
Alexander Weaver
f94fb765b5
Alerting: Add limit query parameter to Loki-based ASH api, drop default limit from 5000 to 1000, extend visible time range for new ASH UI (#70769)
* Add limit query parameter

* Drop copy paste comment

* Extend history query limit to 30 days and 250 entries

* Fix history log entries ordering

* Update no history message, add empty history test

---------

Co-authored-by: Konrad Lalik <konrad.lalik@grafana.com>
2023-06-28 13:32:28 -05:00
Gábor Farkas
50ad099eab
logs: refactor tests to make them smaller (#70824) 2023-06-28 16:19:34 +02:00
Esteban Beltran
5732fc7b2a
Plugins: Add CDN support to sandboxed frontend plugins (#70608) 2023-06-28 16:58:37 +03:00
Sven Grossmann
48db23b32f
Logs: Add back properties to prevent unnecessary re-renders (#70839)
* add back properties

* use spread to not define all props
2023-06-28 15:45:22 +02:00
Marcus Andersson
f1529997f2
Explore: Make toolbar action extendable by plugins (#65524)
* Cleaned up solution and starting to make it work properly.

* will disable add button if no queries available.

* Changed so 'add to dashboard' is registered as an extension in explore.

* moved utility function to utils

* hides button if insufficent permissions.

* Fixed ts issue.

* cleaned up the code and change to using the 'getPluginLinkExtensions'

* Added values to explore context.

* truncating title in menu.

* added tests to verify explore extension point.

* fixed failing tests in explore.

* made excludeModal optional.

* removed temporary fix to force old button.

* reverted generated files.

* fixed according to feedback.

* Update public/app/features/explore/extensions/ToolbarExtensionPoint.test.tsx

Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>

* Update public/app/features/explore/extensions/ToolbarExtensionPoint.test.tsx

Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>

* added tests suggested in reviews.

* fixed failing tests after sync with main.

* replaced exploreId type with stirng.

* cleaned up code a bit more.

---------

Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>
2023-06-28 15:42:41 +02:00
Sonia Aguilar
519e840f97
Alerting: Render folder selector in options for Alert List Panel only when having Grafana datasource (#70816)
Render folder selector in options for Alert List Panel only when no datasource is selected or when Grafana is selected as the datasource
2023-06-28 15:38:32 +02:00
Sven Grossmann
1206cf3dfa
LogContext: Make centered row unsticky on click (#70832)
* add pinning in log context

* add tests

* move icon names

* fix type of `pinned`
2023-06-28 15:22:54 +02:00
Andrej Ocenas
4969a78f83
Pyroscope: Fix normalize query function (#70836) 2023-06-28 15:22:13 +02:00
Sven Grossmann
e0619e8aa7
LogContext: Add button to scroll to center (#70821)
add scroll to center button
2023-06-28 14:55:22 +02:00
Jaryk
db478ced45
Variables: Detect a name for duplicated variable (#68110)
* Variables: Detect a name for duplicated variable

* Variables: create copies of copies
2023-06-28 13:53:53 +02:00
Gábor Farkas
3f44412bfd
logs: more tests related to timestamp handling (#70819) 2023-06-28 13:50:29 +02:00
RoxanaAnamariaTurc
9e844b36b2
I18n:Mark up phrases for translation on Folder Page (#70801)
* I18n:Mark up phrases for translation on Folder Page

* I18n:Mark up phrases for translation on Folder Page, made suggested updates
2023-06-28 11:41:35 +01:00
Andrej Ocenas
0259ae2630
Pyroscope: Preselect default profile type or app in the query editor dropdown (#70624) 2023-06-28 12:26:09 +02:00
Josh Hunt
f18a7f7d96
NestedFolders: Nested folder picker (#70148)
* Initial layout

* Add some styles

* Add checkbox functionality

* Add feature flag

* Extract list component

* remove feature flag

* expand folders

* Don't show empty folder indicators in nested folder picker, prevent opening folder from selecting that folder

* remove legend and button

* selection stuff

* new feature flag just for nested folder picker

* fix lint

* cleanup

* fix movemodal not showing selected item

* refactor styles, make only label clickable

---------

Co-authored-by: Tobias Skarhed <tobias.skarhed@gmail.com>
2023-06-28 09:40:29 +00:00
Joey
0668fcdf95
Tempo: Update error messages (#70448)
Update error messages
2023-06-28 10:34:11 +01:00
Gábor Farkas
9ca888527b
Logs: Implement "infinite" scrolling in log context (#69459)
* logs: context: allow "infinite" scroll

* Log Context: Add visual changes to infinite scrolling (#70461)

* remove text showing how many log lines are loaded

* better positioning of loading indicators

* add border

* fix import

* better loading states

* improve corner cases

* increase page size 10 => 50

* updated unit test, simplified code

* fixed tests

* updated tests

* removed unused code

* fixed test

* improved refid-handling in loki

* removed unnecessary code

* better variable name

* refactor

* refactor

---------

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
2023-06-28 11:51:16 +03:00
Giuseppe Guerra
dde4a03544
Catalog: Display badges for Angular plugins and disable install if Angular is disabled (#69084)
* Angular deprecation: Add Angular badge in plugin catalog page

* Angular deprecation: Add alert in plugin details page

* Angular deprecation: Disable install button if for Angular plugins

* removed extra console.log

* Add tests for Angular badge

* Add tests for PluginDetailsAngularDeprecation

* Add tests for InstallControlsButton

* Add tests for ExternallyManagedButton

* Table tests

* Catalog: Update angular deprecation message

* PR review feedback

* Update tests

* Update copy for angular tooltip and alert

* Update tests

* Fix test warnings

* Fix angularDetected not being set for remote catalog plugins

* Dynamic alert text based on grafana config

* Moved deprecation message to a separate function

* Removed unused Props in PluginAngularBadge
2023-06-28 09:58:45 +02:00
Gábor Farkas
ebe5e9c2e6
logs: removed unused code (#70758) 2023-06-28 08:35:51 +02:00
Kristina
c0b64612f8
Explore: Remove duplicate decorator (#70775)
Remove duplicate decorator
2023-06-27 16:04:59 -05:00
Oscar Kilhed
50c0ff8400
DatasourcePicker: Skip flaky upload test (#70756)
Skip flaky upload test
2023-06-27 18:05:06 +02:00
RoxanaAnamariaTurc
12ddfbf2be
I18n: Mark up phrases for translation on Folder page (#70754)
* I18n:Mark up phrases for translation on Folder page

* Updated the Trans tag to be inside the Button
2023-06-27 16:23:57 +01:00
Ashley Harrison
beb166f1d2
Checkbox: Fix alignment in Safari (#70673) 2023-06-27 16:10:56 +01:00
Sonia Aguilar
c7ddf29cdf
Alerting: Add NeedHelpInfo component in notifications step. (#70740)
Add NeedHelpInfo component in notifications step and use it in annotations step (instead of HoverCard) for consistency
2023-06-27 16:46:56 +02:00
Piotr Jamróz
c9c357fc19
Explore: Ensure old panes are removed before opening split view (#70670) 2023-06-27 14:59:13 +02:00
Brendan O'Handley
e3a4d7c099
Prometheus: Add label filters to label_values query type variable query (#70644)
* add labelfilters to label_values query type with tests

* fix tests
2023-06-27 08:58:46 -04:00
Gábor Farkas
e9b9a08dd0
logs: handle dataplane-compatible logs-frames (#70318)
* logs: handle dataplane-compatible logs-frames

* simpler tests

* simpler code

* simpler code

* switch to null from undefined

* updated tests

* added test for simplest case

* more direct comparisons

* simplified code

* removed by-mistake added code
2023-06-27 14:50:36 +02:00
Gábor Farkas
8e9ec9dcef
Elasticsearch: Make it compatible with the new log context functionality (#70697)
* elastic: make it work with the new logs-context

* add remaining fields

* lint fix
2023-06-27 14:04:29 +02:00
Kristina
2738a3a6da
Correlations: Account for restricted datasource (#70717)
* Account for restricted datasource

* Allow for fetching datasource to return undefined and beef up filtering after to remove invalid datasources

* Revert "Account for restricted datasource"

This reverts commit 1087159b93.

* Empty-Commit
2023-06-27 07:02:57 -05:00
kay delaney
6c900b84bd
Variables: Remount query editor when datasource changed (#70615) 2023-06-27 12:59:24 +01:00
Ashley Harrison
135ef088ed
Nested folders: Paginate child folder items (#70730)
* make handleLoadMore aware of child folders

* combine PAGE_SIZE and ROOT_PAGE_SIZE
2023-06-27 11:38:33 +01:00
Selene
b0893c29a7
Chore: Generate plugin version and remove lineage version (#69781)
* Generate plugin version and remove lineage version

* Generate version for each major

* Remove pluginVersion from core plugins

* Remove code version generation

* Generate cue files

* Move grafana version into jenny

* fix go import
2023-06-27 12:47:14 +03:00
Sonia Aguilar
b0ac49926d
Alerting: Expression card improvements (#70395)
* Show description for each expression type in the body and change widht depending on the type

* Move condition indicator to the header

* Make order of fields in expressions to be consistent for each expression type

* Add tooltip for expression type menu

* Update styles depending on the expression type

* Update styles and move add query button under queries

* Add NeedHelpInfo component

* Adress PR review comments

* Apply description updates from #70540

* Rename gelTypes to expressionTypes

* Update layout for expressions according to the real usecases

* Update footer to include series count in all expressions

---------

Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2023-06-27 11:35:56 +02:00
Matias Chomicki
c1ce24c90f
Elasticsearch: Put new log details filters behavior behind a feature flag (#70703)
* Elasticsearch: create elasticFiltersToggle feature flag

* Elasticsearch: add new filter behavior behind a feature flag

* Rename feature flag
2023-06-27 10:38:20 +02:00
Joey
5b13b71ed0
TraceView: Remove unused trace selectors (#70527)
Remove unused selectors
2023-06-27 09:01:35 +01:00
Virginia Cepeda
e03f61fe26
Alerting: don't copy original rule uid when cloning (#70645)
* Prevent using original rule uid when cloning

* Use uid from url instead of a new param in the alert rule form

* Add function to clone rule and tests for it

* Fix lint & tests

---------

Co-authored-by: Sonia Aguilar <soniaaguilarpeiron@gmail.com>
2023-06-26 17:44:26 -03:00
ismail simsek
a742149687
InfluxDB: Refactor annotation transform logic (#69866)
* Reformatting and restructuring

* Update unit test

* Always send the default retention policy as first element

* Fix typo

* Update test

* Update test once more

* Field names start with capital letters

* Simplify the condition

* Case-insensitive checks

* Fix typo

* Update response_parser test

* Update imports

* Refactor annotation transform logic

* More types

* Moore types

* Fix table rendering issue

* Use it as raw query

* Migrate annotations

* Set default retention policy when there is no policy in the query

---------

Co-authored-by: Ludovic Viaud <ludovic.viaud@gmail.com>
2023-06-26 19:20:03 +02:00
Ryan McKinley
698b07518a
Dashboards: Support an auto refresh interval that is based on the query range (#70479) 2023-06-26 19:46:23 +03:00
Kristina
72f34524d7
Traces to Logs: Use onclick for navigation if function is not defined (#70197)
* Use onclick for navigation if function is not defined

* Use locationService, provide clarification comments
2023-06-26 11:17:27 -05:00
Andrej Ocenas
0f2922d709
Flamegraph: Prevent cropping of tooltip by bottom of the viewport (#70633) 2023-06-26 18:03:41 +02:00
Matias Chomicki
4c4bd69eb6
Logs: Add toggle behavior support for "filter for" and "filter out" label within Logs Details (#70091)
* Datasource test: fix describe nesting

* Parsing: export handleQuotes function

* Modify query: add functions to detect the presence of a label and remove it

* Loki: add support to toggle filters if already present

* Datasource test: fix describe nesting

* Loki: add support to toggle filter out if present

* Remove label: handle escaped values

* Datasource: add test case for escaped label values

* Loki: remove = filter when applying !=

* Remove selector: add support for Selector node being far from Matcher

* Modify query: add unit tests

* Elasticsearch: create modifyQuery for elastic

* Elastic modify query: implement functions

* Elasticsearch: implement modifyQuery functions in datasource

* Elasticsearch: update datasource test

* Loki modify query: check for streamSelectorPositions length

* Elasticsearch query has filter: escape filter value in regex

* Remove unused type

* Modify query: use query modeller instance from module
2023-06-26 16:45:33 +02:00
ismail simsek
903af7e29c
InfluxDB: Backend parser compatibility with frontend parser (#69865)
* Reformatting and restructuring

* Update unit test

* Always send the default retention policy as first element

* Fix typo

* Update test

* Update test once more

* Field names start with capital letters

* Simplify the condition

* Case-insensitive checks

* Fix typo

* Update response_parser test

* Update imports
2023-06-26 14:03:02 +02:00
Josh Hunt
e50cf55649
Dashboards: Allow dashboards with same name in different folders (#70378)
* Dashboards: Allow dashboards with same name in different folders

Co-authored-by: Tobias Skarhed <tobias.skarhed@gmail.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
Co-authored-by: joshhunt <josh@trtr.co>

* fix

---------

Co-authored-by: Tobias Skarhed <tobias.skarhed@gmail.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-06-26 11:49:50 +00:00
Gilles De Mey
9e0f6ceb57
Alerting: small typescript fix for Policy (#70655) 2023-06-26 13:19:33 +02:00
Ashley Harrison
8ea74333f1
Nested folders: Replace explicit type column with icon in browse view (#70666)
* remove type column and add icon instead

* extract translations
2023-06-26 11:58:26 +01:00
Konrad Lalik
9ebede1e18
Alerting: Display a warning when a contact point is not in use (#70506) 2023-06-26 11:05:44 +02:00
Virginia Cepeda
f17c49e632
Alerting: Display correct results when using different filters on alerting panels (#70482)
* Trigger separate rules request for each alerting panel in a dashboard

* Add RTK method to fetch prom rules

* Use RTKQuery to get prom rules in UnifiedAlertList

* Fix lint

* Mock promRules call

* Address PR comments

* Fix tests
2023-06-23 14:15:24 -03:00
Leon Sorokin
fe45dc9f27
XYChart: Fix axis range and scale overrides (#70605) 2023-06-23 10:50:36 -05:00
Esteban Beltran
53231cb68d
Sandbox: Fix react class components stale state (#70572) 2023-06-23 17:44:03 +02:00
Laura Benz
d64b6264ff
GrafanaUI: Define tooltip or aria-label as required for IconButton (#69699)
* refactor: modify interfaces to make tooltip or aria-label required

* refactor: change functionality around aria-label and tooltip

* refactor: change and add information in storybook documentation

* refactor: remove default from tooltip

* refactor: IconButton to make tooltip or aria-label required

* refactor: Fix tests

* refactor: Fix tests

* refactor: Fix tests

* refactor: Fix tests

* feat: add migration guide for breaking change

* feat: add latest requirements to storybook docs

* refactor: separate iconbutton story with and without tooltip

* refactor: remove exported baseArgs

* refactor: clean up and restructure original story

* refactor: adjust styling

* refactor: enable control for tooltip

* refactor: clean up

* refactor: enable control for aria-label

* refactor: fix theme getting the wrong theme

* refactor: fix tests

* refactor: adjust story

* refactor: remove confusing story

* refactor: adjust controls for stories
2023-06-23 17:10:37 +02:00
Leon Sorokin
0f7407dd91
XYChart: Remove some panel opts that can't logically apply (#70202) 2023-06-23 08:18:48 -05:00
Gilles De Mey
dc7e967cd4
Alerting: Fixes clone url for instances hosted on sub path (#70543) 2023-06-23 14:29:47 +02:00
Zoltán Bedi
6fbc0b9b9c
Chore: Add tracking for dashboard load (#70057)
* Chore: Add tracking for dashboard load

* Address review comments
2023-06-23 14:14:06 +02:00
Andre Pereira
08ed68e675
Tracing: Move upload trace to button (#69402)
* Tempo: Move upload trace to its own button

* Zipkin: Move upload trace to its own button

* Jaeger: Move upload trace to its own button

* Fix test

* Remove extra upload section from editor body

---------

Co-authored-by: Joey Tawadrous <joey.tawadrous@grafana.com>
2023-06-23 12:03:00 +01:00
Joao Silva
cebc180e5b
Forms: Remove usage of gf-form textarea and help icons (#70561) 2023-06-23 19:07:28 +09:00
Giordano Ricci
24efcc54d2
Explore: make sure panes are initialized in order (#70519) 2023-06-23 10:50:07 +01:00
Sven Grossmann
4c28b01975
Revert "Logs: Change permalink icon back to link" (#70570)
Revert "Logs: Change permalink icon back to `link` (#70362)"

This reverts commit fc39dadf62.
2023-06-23 10:58:07 +02:00
Ivan Ortega Alba
3bf8dc1397
DS Picker: Add missing props and improve autoheight logic (#70393)
* DS Picker: Add `inputId` and `noDefault` options

* DS Picker: Add `disabled` state

* Add tests for `disabled`

* Select default DS if `current` is not provided

* Remove `width` from style

* Move types next to components

* Only calculate height when opening
2023-06-23 10:26:18 +02:00
Sven Grossmann
9cf685cfda
LogContext: Fix filtering out log lines with the same entry (#70538)
* fix bug with filtering out too many log lines

* fix acts

* remove unused line
2023-06-23 10:20:07 +02:00
Alexa V
fbfd1c24e4
Dashboard: Fix issue where a panel with a description and a cached response displays 2 info icons (#70513) 2023-06-23 10:15:27 +02:00
Ashley Harrison
ff429c9af5
Navigation: Fix toolbar actions flickering on mobile (#70524)
* fix flickering overflow

* set everything to hidden by default

* extend intersectionobserver mock
2023-06-23 08:50:51 +01:00
Joao Silva
0dac2b7d08
PermissionList: Fix sizing of permission column so they are all aligned (#70420) 2023-06-23 09:55:20 +09:00
Galen Kistler
7cb1f6541e
Prometheus: Add capability to filter label names by metric in template variable editor (#70452)
* Adds new text input in prometheus template variable UI that allows label names function to filter values by metric. 
Co-authored-by: Brendan O'Handley <brendan.ohandley@grafana.com>
2023-06-22 14:11:06 -05:00
George Robinson
404afedc25
Alerting: Adds in-app documentation for Classic Conditions (#70540)
This commit adds in-app documentation that explains using Classic
Conditions disables multi-dimensional alerts for the rule.
2023-06-22 19:29:54 +01:00
Sven Grossmann
d7337e4f9c
Loki: Preserve pipeline stages in context query (#70472)
* add pipeline stages to context query

* add ui

* improve `Postion`

* add `processPipelineStagesToExpr` to logcontextprovider

* add ui toggle

* fix lokicontextui tests

* remove import

* contextually hide the toggle

* Update `SHOULD_INCLUDE_PIPELINE_OPERATIONS` name

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

* add setIncludePipelineOperations to false in revert

* add prepareExpression method

* remove unused method

* fix test and add `runContextQuery`

* set correct revert state

* let let be const

* remove argument

---------

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2023-06-22 17:34:43 +02:00
Piotr Jamróz
cb2cc591da
Explore: Clean up query subscriptions when a query is canceled (#70235)
* Ensure clean up functions are called when query subscriptions are canceled

* Fix unit tests
2023-06-22 15:00:20 +02:00
Sarah Zinger
162be9d76c
Cloudwatch: fix typo (#70478) 2023-06-22 08:04:57 -04:00
Sven Grossmann
b5de806f66
Logs: Link anchored logline when opening context in split view (#70463)
* add logline link id to context opened in split

* add comment
2023-06-22 14:00:35 +02:00
Gareth Dawson
d6e4f2a504
Elasticsearch: Enable logs samples for metric queries (#70258)
* enable logs samples on elastic ds

* add tests for getSupplementaryQuery

* only display log samples for date_hostogram queries

* changes

* test

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

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

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

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

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

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

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

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

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

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

* address feedback / tests

---------

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2023-06-22 12:53:05 +01:00
Matias Chomicki
dbf7ebb923
Elasticsearch: Fix infinite loop when using mixed datasources (#70386)
* Elasticsearch context: do not init query when it is already initialized

* Fix buggy conditional
2023-06-22 12:44:02 +02:00
Giordano Ricci
e60966d977
Explore: fix URL encoding on load (#70503) 2023-06-22 11:34:12 +01:00
Ashley Harrison
eacb5bee7e
Nested folders: Consolidate mutations in RTK query (#70249)
* this is an ok intermediate point

* delete some unused actions + fix tag invalidation on folder save

* remove prefetching for now (it creates a permanent subscription?!)

* leave paginated fetch out of rtk query for now

* ensure we're invalidating the cache correctly

* fix dashboard saving

* simplify

* recursively invalidate children on rename

* tidy up

* don't need to invalidate tags on delete

* don't need to invalidate on new either

* make new refreshParents action

* pageheader spacing

* invalidate getFolder on move

* bit of rearrangement
2023-06-22 09:44:19 +01:00
Andreas Deininger
95b1f3c875
Fixing typos (#70487) 2023-06-22 09:43:38 +01:00
Ashley Harrison
1441c90178
Accessibility: use Collapse in QueryOptionGroup (#70446)
* use collapse in QueryOptionGroup

* fix unit tests

* fix tests after merging main

* adjust padding to match
2023-06-22 09:31:55 +01:00
Songhn
c455b01078
Dashboard: Update query group options (#63138)
* Dashboard: update query group options

* chore: remove unused `console`

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

* fix: update placeholder

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

* feat(QueryGroupOptions): add tooltip example values

* feat(QueryGroupOptions): update interval tooltip

* Update public/app/features/query/components/QueryGroupOptions.tsx

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

* Update QueryGroupOptions.tsx

---------

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
2023-06-22 00:44:55 -07:00
Drew Slobodnjak
b6d4b701b9
TimeSeries: Add option to disconnect values (#70097)
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
2023-06-21 21:26:15 -05:00
Leon Sorokin
3007e3b209
XYChart: Ensure color scale is field-local and synced with data updates (#70480) 2023-06-21 16:23:52 -05:00
Ryan McKinley
ae688adabc
TestData: Drop some percentage of CSV values from a request (#70404) 2023-06-21 13:17:10 -05:00
Leon Sorokin
1db0ace5e7
Viz: get UPlotChart out of the timeRange business (#70412) 2023-06-21 13:10:25 -05:00
Virginia Cepeda
929d9eaa91
Alerting: Change how we display annotations in the rule form (#69338)
* Change how we display annotations in the rule form

* Allow to add custom annotations using a free text input

* Get dashboard and panel titles to display in the annotations section

* Add component to display dashboard and panel annotations as links

* Add styling to help tooltip

* Fix styling on annotations controls

* Fix tests

* Fix tests

* Remove unused imports

* Add component for custom annotations

* Display default annotations even if editing and they're empty

* Adjust tests

* Make conditional rendering more clear

* Fix tests

* Move annotation header to separate component

* Fix lint

* Show annotation fields in the right order

* Prevent showing custom annotation fields by default

* Don't display links to dashboard/panel if response fails

* Rename custom annotation header component

* Fix after rebase
2023-06-21 11:15:12 -03:00
Joey
8f7e1f36ab
Traces: Remove noop functions (#70392)
Remove unused functions
2023-06-21 14:49:04 +01:00
Juan Cabanas
ee73d41d24
PublicDashboards: Audit table pagination (#69823) 2023-06-21 10:48:09 -03:00
Esteban Beltran
ed5a697825
Plugins: Sandbox frontend plugins DOM access. (#69246) 2023-06-21 14:49:22 +02:00
Joey
00ec9fceb9
Tempo: Represent OTLP Span Intrinsics correctly (#69394)
* Span intrinsics

* Update intrinsics and add to span details

* Remove intrinsics section

* Update tests

* Update status code text

* Self review

* Move previously intrinsic values to span

* Remove few methods
2023-06-21 11:39:12 +01:00
Josh Hunt
e9d42a6395
Login: Show error messages inline in form instead of in toasts (#70266)
* Login: Show error messages inline in form instead of in toasts

* remove console.log lol

* fix test
2023-06-21 10:28:20 +00:00
Ivana Huckova
55d18361dc
Loki: Deprecate resolution (#70326)
* Loki: Deprecate resolution and only show it if it was selected before

* Deprecate

* Fix merge, add missing brackets
2023-06-21 12:21:29 +02:00
Joao Silva
a83a040f35
Library Panels: Fix issue when deleting library panels from folder view (#70413) 2023-06-21 18:59:59 +09:00
Josh Hunt
a770188acb
Search: Always send specified kind in sql searcher (#70376)
Co-authored-by: Tobias Skarhed <tobias.skarhed@gmail.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-06-21 09:18:31 +00:00
Giordano Ricci
d3450d75a4
Explore: URL migrations & improved state management (#69692)
Co-authored-by: Piotr Jamróz <pm.jamroz@gmail.com>
2023-06-21 10:06:28 +01:00
Matias Chomicki
a489135825
Loki Query Utils: Extract and refactor common functionality (#70185)
* Query utils: refactor isQueryPipelineErrorFiltering and getLogQueryFromMetricsQuery

* Query utils: refactor isQueryWithRangeVariable and getHighlighterExpressionsFromQuery

* Get parser: return log expression even if no pipelineExpr is present

* Update tests
2023-06-21 11:59:50 +03:00
Oscar Kilhed
cf4d86d95f
DataSourcePicker: refactor file drop out of query group (#68236)
* refactor file drop out of query group

* make sure we display errors when file upload fails

* refactor to make onChange take default queries

* let grafana datasource handle file -> query

* add dropdown tests

* add modal tests

* add filtering props to dropdown

---------

Co-authored-by: Ivan Ortega Alba <ivanortegaalba@gmail.com>
2023-06-21 10:55:55 +02:00
Ashley Harrison
d65c9396f3
Chore: Remove DashboardSearchModal/SearchWrapper since they're no longer used (#70374)
remove DashboardSearchModal/SearchWrapper since they're no longer used
2023-06-21 09:51:28 +01:00
Ashley Harrison
0325fdecb8
Chore: Fix main build (#70424)
add check for empty object
2023-06-21 11:33:09 +03:00
RoxanaAnamariaTurc
3c88868fe5
Internationalization: Mark up phrases for translation on Dashboards page (#70361)
* Internationalization:Mark up phrases for translation on Dashboards page

* Internationalization: Mark up phrases for translation on Dashboards page
2023-06-21 09:07:42 +01:00
Sonia Aguilar
e6243f72fd
Alerting: Add file and rule_group query params in request for filtering the res… (#70379)
* Add file and rule_group query params in request for filtering the response when loading rule in view mode

* Fix test
2023-06-21 09:08:20 +02:00
Ashley Harrison
13e3308959
Chore: some type fixes (#69860)
* some type fixes

* restore empty object

* undo 1 fix for now

* commit betterer update

* explicitly type slug and uid as string | undefined
2023-06-20 17:13:49 +01:00
Piotr Jamróz
a94ba7784a
Explore: Remove storing derived "loading" property (#70324)
* Remove storing derived state (loading property) and use a selector instead

* Remove redundant tests

There's no way to change the interval while live streaming

* Remove check for isLive when deriving waiting for data

It was introduced in #18804

* Remove unused props
2023-06-20 17:38:05 +02:00
Matias Chomicki
fd6836e326
Cloud rules: fix hardcoded conditional (#70387) 2023-06-20 16:39:48 +02:00
Ivana Huckova
60f6538bad
Loki: Use getNormalizedLokiQuery to get queryType (#70237)
* Loki: Use getNormalizedLokiQuery to get queryType

* Simplify

* Remove unused import

* Refactor, improve and add tests

* Update
2023-06-20 16:27:32 +02:00
Sven Grossmann
90b621be20
Logs: Add tracking for permalinking (#70334)
* add permalink tracking

* move location override to beforeAll

* add `logLevel` to tracking
2023-06-20 14:55:51 +02:00
Gilles De Mey
5c4571f231
Alerting: Align notification policies design (#70345) 2023-06-20 15:49:54 +03:00
Matias Chomicki
912c5ccb6a
Elasticsearch: fix type-related bug within targetContainsTemplate (#69798)
* Elasticsearch: fix type-related bug within targetContainsTemplate

* Refactor to fix found regression
2023-06-20 15:43:49 +03:00
Sarah Zinger
65d85ca9bf
Suggestions: Prioritize preferred visualizations for suggestion list (#67326)
Prioritize preferred visualizations for suggestion list.
2023-06-20 14:40:28 +02:00
Giordano Ricci
d5d3db9a6e
DSPicker: Respect datasource & mixed props (#70377) 2023-06-20 14:21:49 +02:00
Torkel Ödegaard
7b9e047ffd
TopNav: Cleanup theme flags (#67990)
* TopNav: Cleanup theme flags

* Update

* update
2023-06-20 13:58:57 +02:00
Sven Grossmann
bdc1d666f4
Insights: Fix optional buildInfo type (#70372)
fix unnecessary optional type
2023-06-20 13:04:54 +02:00
Sven Grossmann
ae1da1a38d
Insights: Add Grafana version to rudderstack events (#70105)
add build info to rudderstack
2023-06-20 12:25:37 +02:00
Gilles De Mey
87884f4d41
Alerting: Allow selecting the same custom group when swapping folders (#70337) 2023-06-20 11:28:24 +02:00
Sven Grossmann
fc39dadf62
Logs: Change permalink icon back to link (#70362)
change icon to link-icon
2023-06-20 11:50:43 +03:00
Gareth Dawson
b552595e0a
Logs: Add new scroll behaviour to logs samples panel (#70320)
update log sample scroll with new bahaviour
2023-06-20 09:40:10 +01:00
Ivana Huckova
750630626e
Loki: Add step input field validation (#70319)
* Loki: Add step inpout field validation

* Show invalid step in Options

* Update public/app/plugins/datasource/loki/querybuilder/components/LokiQueryBuilderOptions.tsx

Co-authored-by: Matias Chomicki <matyax@gmail.com>

* Update test

---------

Co-authored-by: Matias Chomicki <matyax@gmail.com>
2023-06-20 09:24:01 +02:00
Zoltán Bedi
39433b5b9a
Candlestick: Migrate to schema (#62113)
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2023-06-20 07:18:40 +03:00
Andrej Ocenas
5ca03a82f0
FlameGraph: Add sandwich view (#70268) 2023-06-19 16:34:06 +02:00
Ashley Harrison
db44ba305e
Command palette: Include help links (#70234)
enrich help node with frontend links
2023-06-19 13:29:26 +01:00
Joey
06a4b6da62
Tempo: Use pipe in TraceQL by default for multi-value variables (#70051)
* Use pipe in traceQL by default for multi value variables

* Use constant
2023-06-19 13:28:56 +01:00
Sonia Aguilar
9a252c763a
Alerting: Add notification policies preview in alert creation (#68839)
* Add notification policies preview in alert rule form
Co-authored-by: Konrad Lalik <konrad.lalik@grafana.com>

* Refactor using new useGetPotentialInstances hook and apply some style changes

* Add notification policy detail modal

* Use backtesting api for simulating  potential alert instances

* Fix logic to travserse all the children from the root route

* Split notification preview by alert manager

* Add instance count to matching policy header and fix some styles

* Move some logic to a new hook useGetAlertManagersSourceNames to make the code more clean

* Fix some tests

* Add initial test for NotificationPreview

* Use button to preview potential instances

* Add link to contact point details

* Add route matching result details

* Show AlertManager image in the routing preview list

* Add tests setup, add single AM preview test

* Handle no matchers and no labels use case

* Update some style in collapse component and fix policy path in modal

* Update modal styles

* Update styles

* Update collapse header styling

* Normalize tree nodes should happen before findMatchingRoutes call

* Fix findMatchingRoutes and findMatchingAlertGroups methods after reabasing

* Move instances matching to the web worker code

* Fix config fetching for vanilla prometheus AMs

* Add tests

* Add tests mocks

* Fix tests after adding web worker

* Display matching labels for each matching alert instance

* Add minor css improvements

* Revert changes added in Collapse component as we don't use it anymore

* Move the route details modal to a separate file

* Move NotificationRoute and preview hook into separate files

* Fix Alertmanager preview tests

* Fix tests

* Move matcher code to a separate file, improve matcher mock

* Add permissions control for contact point edit view link

* Fix from and to for the temporal use of backtesting api

* Fix tests, add lazy loading of the preview component

Co-authored-by: Sonia Aguilar <soniaaguilarpeiron@gmail.com>

* Fix preview test

* Add onclick on the header div so it collapse and expands when clicking on it, and update styles to be consistent with the rest of tables

* Adapt the code to the new rule testing endpoint definition

* Fix tests

* small changes after reviewing the final code

* compute entire inherited tree before computing the routes map

* Throw error in case of not having receiver in routesByIdMap and add test for the use case of inheriting receiver from parent to check UI throws no errors

* Add list of labels in the policy route path that produces the policy matchers to match potential instances

* Use color determined by the key, in label tags when hovering matchers in the policy tree

* Remove labels in modal and handle empty string as receiver to inherit from parent as we do with undefined

* Revert "Add list of labels in the policy route path that produces the policy matchers to match potential instances"

This reverts commit ee73ae9cf9.

* fix inheritance for computeInheritedTree

* Fix message shown when preview has not been executed yet

* First round for adressing PR review comments

* Adress the rest of PR review commments

* Update texts and rename id prop in NotificaitonStep to alertUid

---------

Co-authored-by: Konrad Lalik <konrad.lalik@grafana.com>
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2023-06-19 13:32:17 +02:00
Sven Grossmann
1a985c488c
Logs: Fix scrolling with exploreScrollableLogsContainer feature flag (#70164)
correct scrolling with `exploreScrollableLogsContainer`
2023-06-19 13:15:22 +02:00
Gábor Farkas
271cdb4baa
loki: rename experimental feature flag (#70306) 2023-06-19 10:03:51 +00:00
Giordano Ricci
6a3c6eb174
Explore: Ensure datasource is present in the URL for every query (#70307) 2023-06-19 10:46:59 +01:00
Matias Chomicki
a75752b085
Elasticsearch: remove usages of any (#69575)
* Elasticsearch: remove usages of any

* Elasticsearch: check for filter type when accessing field aggs

* Elasticsearch: use type guards instead of checking types

* Use unknown for isPrimitive function

* Add deprecation notice

* Remove unused type

* Fix bug in "isPrimitive" function

* Remove unused import

* Revert "Fix bug in "isPrimitive" function"

This reverts commit 27f9874cce.
2023-06-19 11:01:08 +02:00
Nicolas DUPEUX
cb7e18938b
[opentsdb] Allow custom tag key in OpenTSDB Query editor (#62762) 2023-06-17 10:01:14 -04:00
Ivan Ortega Alba
565ed09f6b
Explore: Use new DS picker (#70054) 2023-06-17 10:12:29 +02:00
Nathan Marrs
d7a8892f3a
Canvas: Migrate to schema (#70205) 2023-06-17 05:56:23 +03:00