Commit Graph

8804 Commits

Author SHA1 Message Date
Matias Chomicki
edbe45efc2
Elasticsearch: HTTP settings migration (#72840)
* Elasticsearch: migrate data source http settings

* Elasticsearch: migrate data source http settings

* Remove test code

* Update unit test

* Connection settings: add url placeholder

* Elasticsearch config editor: improve on-change handling of custom auth

* Config editor: add missing oauthPassThru option
2023-09-26 17:17:17 +02:00
Leon Sorokin
ade0de5ae9
Dashboard: Reduce scope of contain: strict to TextPanel (#75329) 2023-09-25 23:47:38 +03:00
Galen Kistler
a996f3b4a7
Loki Query Builder: Throw warning in query builder when order of operations is ambiguous (#75198)
* flag vector aggregations containing metric expressions (i.e.`(...)`) containing binary operation expressions with ambiguous error in the UI when switching between code and visual query builders.
2023-09-25 21:28:51 +03:00
Sarah Zinger
ef441f02d0
Cloudwatch: Fix Unexpected error (#74420)
Fix unexpected error when creating a new cloudwatch datasource.

Involves a fair amount of refactoring, so if this causes unexpected issues related to region fetching we can turn this off with the cloudwatchNewRegionsHandler feature toggle, although we do not predict it will so we are enabling it to default to true and hope to remove it shortly.
2023-09-25 14:19:12 -04:00
Juan Luis Peña Wagner
ffb15ef363
NodeGraph: Allow to set node radius in dataframe (#74963)
Allow to set node radius in dataframe
2023-09-25 16:55:52 +02:00
Andreas Christou
61e3f3a059
MSSQL: ConfigEditor updates (#75275)
* Add secure json data type

* Update Azure credentials form with Field components

- Update labels
- Update widths
- Remove excess code

* Update config editor

* Fix lint
2023-09-25 14:14:41 +01:00
Leon Sorokin
0668820259
StateTimeline: Refactor hover markers (#75326) 2023-09-23 05:35:17 +03:00
Leon Sorokin
aadd5bacfa
Chore: uPlot v1.6.26 (#75199) 2023-09-22 11:33:39 -05:00
ismail simsek
a64bfdfb94
InfluxDB SQL: Provide raw query preview for query history (#75030)
* log the sql query

* render the raw sql

* Update rawQuery

* unit tests
2023-09-22 17:40:18 +02:00
ismail simsek
d076f733e9
Prometheus: Fix applying ad-hoc filters to the expression that has a template variable (#75250)
* Interpolate first and then apply ad-hoc filters

* More tests
2023-09-22 17:32:19 +02:00
Ashley Harrison
ff0642bf6e
Chore: Type improvements 🧹 (#75271)
* fix some e2e flows types

* some type fixes

* must... fix... more...

* MOAR

* MOREMOREMORE

* 1 more
2023-09-22 15:06:49 +01:00
Galen Kistler
ac98197132
Loki Query Builder: binary expression and numeric literal bugs (#74950)
* Following similar changes made to prometheus in #47198, reverse the order of binary operator parameter array, and fix bugs introduced by importing prometheus lezer constants into loki parser

* add unit test asserting buildVisualQueryFromString does not properly parse queries with nested binary operations

* fix onOrIgnoring parsing logic which was always stripping out the value of the matcher when a boolean was found
2023-09-22 07:17:01 -05:00
Andres Martinez Gotor
c70623fb85
Chore: Rename testdata plugin with a fully qualified name (#75104) 2023-09-22 15:00:40 +03:00
Ivana Huckova
28b4d7fa0c
Loki: Remove unused methods (#75106)
* Loki: Remove unused imports in dataosurce.ts

* Extract range from props, fix lint

* Fix naming

* Remove unused types
2023-09-22 12:41:54 +02:00
Matias Chomicki
91ed2a6afe
Loki Query Editor: Add support for new logfmt features (#74619)
* Loki autocomplete: add IN_LOGFMT situation for log queries

* Loki autocomplete: add IN_LOGFMT situation for metric queries

* Loki autocomplete: improve handling of trailing pipes and spaces

* Loki autocomplete: add logfmt arguments completion

* Loki autocomplete: add flags support to IN_LOGFMT

* Loki autocomplete: extend IN_LOGFMT situation with labels and flag

* Loki autocomplete: return logQuery in IN_LOGFMT situation

* Loki autocomplete: offer label completions when IN_LOGFMT

* Query utils: update parser detection method

* Validation: update test

* Loki autocomplete: improve IN_LOGFMT detection when in metric query

* Loki autocomplete: improve logfmt suggestions

* Loki autocomplete: improve logfmt suggestions in different scenarios

* Loki autocomplete situation: refactor resolvers to support multiple paths

* Situation: add test case

* Loki autocomplete: allow user to use 2 flags

* Situation: change flag to flags

* Remove console log

* Validation: import test parser

* Completions: better handling of trailing comma scenario

* Upgrade lezer-logql

* Revert temporary imports

* Loki Query Builder: Add support for new logfmt features (#74858)

* Query builder: add params to logfmt definition

* Logfmt operation: add default params

* Query builder: update deprecated JsonExpression

* Operation utils: update logfmt renderer

* Query builder: parse LogfmtParser

* Query builder: parse LogfmtExpressionParser

* Remove console log

* Remove unused variable

* Remove extra character from render

* Update unit tests

* Fix unit tests

* Operations: remove restParams from logfmt booleans

* Parsing: group cases

* Formatting

* Formatting

* Update modifyQuery

* LogContextProvider: update with parser changes

* LogContextProvider: remove unnecessary type castings

It takes more energy to write `as unknow as LokiQuery` than to write a refId.

* Formatting

* Situation: use charAt instead of substring with endsWith

* Situation: explain logfmt suggestions

* Logfmt: improve flag suggestions

* Remove console log

* Completions: update test
2023-09-22 12:34:17 +03:00
Joao Silva
42cc6b1842
GrafanaUI: Create Box component (#73637) 2023-09-21 17:13:19 +01:00
John Martins
8585a2fcbd
Add postgreSQL Flexible Server Monitoring Dashboard (#74953)
* Add postgreSQL Flexible Server Monitoring Dashboard

* Fix grammatical errors
2023-09-21 11:44:18 +01:00
Leon Sorokin
492ba97ba1
BarChart: Axes centered zero, borders, and colors (#75136) 2023-09-20 11:15:29 -05:00
Gareth Dawson
9def0d2305
Loki: Fix timerange for query stats request (#72193)
* call query stats with whole query

* call stats when query type changes

* fix stats request timerange

* feedback: extract functions from component

* feedback: remove "or string" types

* feedback: use ds timerange picker end

* partial: fix broken test

* changes

* update test comment

* rename variable

* add comment explain message prop

* make getStatsTimeRange a datasource method

* update tests for getStatsTimeRange

* make getStats a datasource method

* update failing tests

* update failing tests

* remove import

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

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

---------

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2023-09-20 16:47:21 +01:00
Sven Grossmann
480aa1ccca
Loki: Fix filters not being added with multiple expressions and parsers (#75152)
* determine last positions per expr

* fix lint
2023-09-20 16:54:24 +02:00
Andrej Ocenas
15e54df9f2
Pyroscope: Remove "phlare" from variable, types, strings etc (#75140) 2023-09-20 16:31:22 +02:00
Fabrizio
d1296f7213
Use const assertion instead of type assertion (#75165) 2023-09-20 17:31:09 +03:00
Andrej Ocenas
b622ac2a66
Flamegraph: Remove unused code after move to package (#75103) 2023-09-20 14:51:23 +02:00
Andrej Ocenas
501e547bea
Pyroscope: Fix error when no profile types are returned (#75143) 2023-09-20 12:29:56 +02:00
Leon Sorokin
9dc0c8be11
TimeSeries: Rename axisShow -> axisBorderShow (#75127)
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2023-09-19 23:43:15 +03:00
Leon Sorokin
780b60dc81
XYChart: Fix numerous axis options (#75044) 2023-09-19 14:44:50 -05:00
ismail simsek
64dd8df441
InfluxDB: Fix applying ad-hoc filters when querying with backend mode (#74973)
* Add adhoc filters to tags when querying with backend mode

* betterer

* Remove unnecessary parameters
2023-09-19 16:23:01 +02:00
Andreas Christou
1386725251
CloudMonitoring: Use EditorField components (#75102)
* Use EditorField

* Fix lint
2023-09-19 14:53:20 +01:00
Andrej Ocenas
f7aab06e23
Pyroscope: Remove support for old pyroscope (#74683) 2023-09-19 10:09:28 +02:00
Fabrizio
9113c6d959
Tempo: Improve autocompletion for TraceQL editor (#74790) 2023-09-19 09:23:35 +02:00
Torkel Ödegaard
1105b93104
AdhocFilters: Improve typing and signature of getTagKeys and getTagValues and behaviors (#74962)
* Add adhocFilters to DataQueryRequest

* More changes

* Progress

* Working

* added baseFilters to picker

* Remove unused code

* minor fix
2023-09-19 08:24:45 +02:00
Adela Almasan
5caf4e1485
Canvas: Button API Editor support template variables (#74779) 2023-09-19 00:16:21 +03:00
Andreas Christou
b779ce5687
AzureMonitor: Improve Log Analytics query efficiency (#74675)
* Promisify loading schema

- Move schema loading to LogsQueryEditor
- Improve typing
- Switch callbacks to promises

* Update types

* Refactor backend for new props

- Rename intersectTime
- Support setting timeColumn
- Add additional properties to logs request body

* Update applyTemplateVariables

* Update set functions

* Add new TimeManagement component

* Update LogsQueryEditor

* Hardcode timestamp column for traces queries

* Ensure timeColumn is always set for log queries

* Update tests

* Update frontend tests

* Readd type to make migration easier

* Add migration

* Add fake schema

* Use predefined type

* Update checks and defaults

* Add tests

* README updates

* README update

* Type update

* Lint

* More linting and type fixing

* Error silently

* More linting and typing

* Update betterer

* Update test

* Simplify default column setting

* Fix default column setting

* Add tracking

* Review

- Fix typo on comment
- Destructure and remove type assertion
- Break out await into two variables
- Remove lets and rename variable for clarity
2023-09-18 18:38:39 +01:00
Andrej Ocenas
f6f47678a4
QueryRunners: Bind the query function where it is passed on (#73399) 2023-09-18 17:00:43 +02:00
Adela Almasan
0815d7f627
Canvas: Button API Editor support setting parameters (#74637) 2023-09-18 09:25:35 -05:00
Torkel Ödegaard
ab75fbd009
TimeSeries: Old graph migration fix for series override lines: true (#74970) 2023-09-18 16:19:59 +02:00
Gareth Dawson
a2e1a7e2f7
MySQL: Update configuration page styling (#74902)
* config page update

* move SecureSocksProxySettings out of tls/ssl
2023-09-18 15:02:55 +01:00
ismail simsek
7f0570401e
InfluxDB: Fix adhoc filter call (#74961)
* Handle nullable parameters properly

* run prettier
2023-09-18 14:44:55 +02:00
Gábor Farkas
1f6f866a36
sql: do not use the getTimeSrv call (#74800)
* sql: eliminate the getTimeSrv call

* adjusted tests
2023-09-18 10:39:05 +02:00
Torkel Ödegaard
401ec3c4b0
DashboardScene: Meta data tab (#74810)
* DashboardScene: Inspect meta tab

* DashboardScene: Inspect meta tab

* fix casing

* Added meta data inspector to testdata data source
2023-09-18 09:00:59 +02:00
Adela Almasan
59b7789ada
Canvas: Add support for selecting the button variant (#74782) 2023-09-14 12:20:58 -05:00
Andre Pereira
fa2f0333f6
Tempo: Added not regex operator (#74907)
Added not regex operator
2023-09-14 16:18:05 +01:00
Adela Almasan
a0e6e76ca6
Canvas: Button API Editor support setting content-type (#74682) 2023-09-14 10:17:21 -05:00
Andre Pereira
a046c043d7
Tempo: Fix traceID converted to infinity (∞) (#74913)
Fixes the traceid to be sent as the infinity symbol for span links
2023-09-14 15:12:39 +01:00
Torkel Ödegaard
ed3fb71f7b
DashboardScene: Panel menu tracking, adding explore menu action and unit tests (#74867)
* DashboardScene: Panel menu updates, adding explore action

* DashboardScene: Panel menu updates, adding explore action

* Fix test

* Update test
2023-09-14 16:12:20 +02:00
Andre Pereira
dc44ac7b78
Tempo: Added spss config - spans per span set (#74832)
* Added spss config - spans per span set

* Set default spss when calling Tempo
2023-09-14 10:49:18 +01:00
Brendan O'Handley
9d4b19af48
add feature tracking for regex and null metadata (#74763) 2023-09-13 09:42:30 -04:00
Joey
a8a8c9849d
Tempo: Metrics summary update sorting no values (#74818)
* Update sorting when there is no value

* Update test
2023-09-13 14:23:17 +01:00
Joey
a12c224cc0
Tempo: Metrics summary no value (#74582)
Metrics summary no value
2023-09-13 10:22:22 +01:00
Javier Ruiz
3bae1c564d
Tempo Service Map: Fix context menu links in service map when namespace is present (#74186)
* Add necessary fields to edges

* Add information about name and namespace to edge when available

* Use new fields to build search taking into account namespace

* Remove new fields from NodeGraphDataFrameFieldNames, define them locally
2023-09-13 10:17:31 +02:00
Ashley Harrison
0c44a6f9bb
Chore: Improve typings 🧹 (#74599)
* various type fixes

* candlestick panel type fixes

* few more fixes

* some fixes

* more :)

* moar!

* undo change to SilencesFilter

* undo change to configureStore
2023-09-13 09:17:07 +01:00
Joey
16bdd55696
Tempo: Fix metricSummary sorting in spanCount and errorPercentage (#74542)
* Fix sorting in spanCount and errorPercentage

* Update types

* Spelling

* Update errorPercentage
2023-09-13 08:48:58 +01:00
Victor Marin
b4851904ce
Add rudderstack tracking for table panel (#71836) 2023-09-13 10:32:00 +03:00
Andrej Ocenas
e4f26a5e4b
Flamegraph: Move to package (#73113) 2023-09-12 12:28:48 +02:00
Brendan O'Handley
951876b465
Prometheus: Add classic query option to variable query editor (#74060)
* add classic query to variable query editor

* copy fixes

* update test
2023-09-11 12:13:16 -04:00
Bryan Huhta
0f552053e9
Pyroscope: add public catalog description (#74630)
* Add readme

* Fix wrong link

* Update public/app/plugins/datasource/grafana-pyroscope-datasource/README.md

Co-authored-by: Dmitry Filimonov <dmitry.filimonov@grafana.com>

* Prettier fix

* Update plugins test

* Prettier fix

* updateSnapshotFlag = false

---------

Co-authored-by: Dmitry Filimonov <dmitry.filimonov@grafana.com>
2023-09-11 18:06:34 +02:00
Adela Almasan
89127d5ec9
Canvas: Button API - Add support for GET requests (#74566) 2023-09-11 08:03:52 -05:00
Fabrizio
a939dfadf2
Improve check on Tempo version (#74547) 2023-09-11 14:34:05 +02:00
Gábor Farkas
6e75c5d182
postgres/sql: fix imports (#74535)
* postgres/sql: fix imports

* nicer import

Co-authored-by: Adam Yeats <16296989+adamyeats@users.noreply.github.com>

---------

Co-authored-by: Adam Yeats <16296989+adamyeats@users.noreply.github.com>
2023-09-11 09:48:55 +02:00
Fabrizio
3bb4e24458
Dashboards: Escape tags (#74437) 2023-09-09 14:11:36 +02:00
ismail simsek
9c50296a07
InfluxDB: Fix multiple tag selection (#74205)
Return all tag keys
2023-09-08 20:57:11 +02:00
Josh Hunt
315a43da93
Dashlist: Fix panel not showing for Viewer users (#74596)
* Dashlist: Fix migration failing when API fails

* don't hit api to migrate general folder

* comment
2023-09-08 13:43:15 +00:00
Fabrizio
d19f75d499
Fix regex for Tempo version (#74541) 2023-09-07 16:53:33 +03:00
Josh Hunt
44e51ffe8b
Dashlist: Use new nested folder picker (#74011)
* Add new folderUID property

* Add nested folder picker + migration to UID

* fix folderUID

* comment
2023-09-07 13:57:31 +03:00
Fabrizio
96facbdfa2
Tempo: Improve autocompletion and syntax highlighting for TraceQL tab (#73707) 2023-09-07 12:36:23 +02:00
Oscar Kilhed
579709c7a6
MSSQL: Add support for MI authentication to MSSQL (#73597)
* Add support for MI authentication to MSSQL

This adds support for managed identity authentication for MSSQL managed
instances running in Azure.

Co-authored-by: baldm0mma <jev.forsberg@grafana.com>
2023-09-06 18:27:19 +02:00
Matias Chomicki
9310bb632e
Loki Query Builder: ensure unique ids for labelled fields (#74398)
* Loki Query Builder: ensure unique ids for labelled fields

* Rename refactored argument
2023-09-06 11:25:53 +03:00
Matias Chomicki
c3cbe220bb
Elasticsearch query editor: ensure unique ids on labelled fields (#74396) 2023-09-06 10:17:11 +02:00
Fabrizio
79b421e8c8
Retrieve and use Tempo version (#72747) 2023-09-06 09:40:37 +02:00
Brendan O'Handley
c946bcdd75
Prometheus: Add flag to SigV4 auth for styles in auth component (#73959)
add flag to sigv4 for custom styles to fit in auth component
2023-09-05 08:51:42 -04:00
Sven Grossmann
a403027608
Loki: Add backend healthcheck (#74330)
* add loki healthcheck

* remove `testDatasource` call

* remove unused error check

* change success message

* improve error messages
2023-09-05 08:59:13 +02:00
Joey
7f2841aeca
Tempo: Update default editor to TraceQL tab (#74153)
Update default editor to TraceQL tab
2023-09-04 15:53:03 +01:00
Torkel Ödegaard
39b3b08926
PromLink: Fixes promlink test failing in CI and locally (#74299) 2023-09-03 19:01:05 +02:00
Sarah Zinger
34a831c83e
Cloudwatch: Add back support for old Log Group picker (#73524)
Cloudwatch: Add back support for old Log Group picker behind feature toggle. 

Fixes issue for aws gov cloud users
2023-08-31 10:13:24 -04:00
Sven Grossmann
423a451858
Loki: Fix filtering with structured metadata (#73955)
* check languageProvider to work with non-indexed metadata

* change loki devenv to work with non-indexed metadata

* trigger ci

* add forced labels after parsers

* add comment

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

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

---------

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2023-08-31 15:24:03 +02:00
Ihor Yeromin
f97e1c81e6
Axis: Add separate show axis option (#74117)
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2023-08-30 18:57:44 -07:00
Brendan O'Handley
42662667d1
Prometheus: Query variable editor persist query type on clicking run query (#74045)
run query to save query type selection
2023-08-30 09:52:23 -04:00
Fabrizio
5038137662
Dashboard: Add support for Tempo query variables (#72745) 2023-08-30 13:45:39 +02:00
Joey
dc26cdf6c9
Tempo: Reset metrics summary tag when scope changes (#74028)
Reset tag when scope changes
2023-08-30 11:26:09 +01:00
Andrej Ocenas
a6ff50300e
Pyroscope: Template variable support (#73572) 2023-08-30 10:48:39 +02:00
Joey
61fd34ca2b
Tempo Config editor updates (#73992)
Config editor updates
2023-08-30 08:53:13 +01:00
Joey
e8aa74aba2
Rename Group By Metrics to Aggregate by (#73980)
* Rename Group By Metrics to Aggregate by

* Update test
2023-08-29 09:28:55 +01:00
Ashley Harrison
0853819ff7
Chore: friday typings 5 (#73844)
* fix some event.target as stuff

* segment async story

* segmentinput story

* SegmentSelect

* fixing some tests

* more test fixes

* undo change to SilencesFilter
2023-08-29 09:14:15 +01:00
Ihor Yeromin
384a6ad54d
ArrayVector: Add vector field value warning (#73692) 2023-08-28 12:11:16 -07:00
Sven Grossmann
07eb4b1b90
Loki: Remove distinct operation (#73938)
* remove distinct

* trigger ci

* update yarn.lock

* fix import
2023-08-28 19:26:59 +02:00
Brendan O'Handley
4e2710670e
Prometheus: fix auth component select for sigv4 option (#73647)
* fix sigV4 selected auth option bug

* use precommit hooks
2023-08-28 11:47:44 -04:00
Ivana Huckova
a80fd02f95
Elasticsearch: Unify default value for geo hash grid precision across the code to 3 (#73922)
* Unify default value

* Use variable to keep default precisions in sync

* Use default precision variable

* Update precision description

* Update defaultPrecisionString and move

* Be more specific in naming of variabkle

* Revert "Merge remote-tracking branch 'origin' into ivana/es-precision-default-value"

This reverts commit 599f236a77, reversing
changes made to 6742be0c6d.

* Revert wrong merge

* Revert wrong merge with turned off lefthook
2023-08-28 16:38:44 +02:00
Joey
59e4c257bb
Tempo: Metrics summary (#73201)
* Metrics summary

* Update query

* Remove colors

* Update states

* Add group by into its own component

* Add group by to search and traceql tabs

* Add spacing for group by

* Update span kind values

* Update span status code values

* Update query based on target + group by

* Cleanup

* Only add targetQuery if not empty

* Add kind=server to table

* Update groupBy query logic

* Add feature toggle

* Use feature toggle

* Self review

* Update target query

* Make gen-cue

* Tweak query

* Update states

* useRef for onChange

* Fix for steaming in search tab

* Add loading state tests

* metricsSummary tests

* Datasource tests

* Review updates

* Update aria-label

* Update test

* Simplify response state

* More manual testing and feedback from sync call

* Prettier and fix test

* Remove group by component from traceql tab

* Cleanup, tests, error messages

* Add feature tracking
2023-08-28 15:02:12 +01:00
Torkel Ödegaard
74d453f056
DashboardSchema: Remove old unused legacy props style and timepicker.enable (#73879)
* DashboardScheam: Remove old unused legacy props style and timepicker.enable

* Update

* fix test
2023-08-28 12:18:17 +02:00
Joao Silva
6c7b46ed1d
DashList: Add tooltip for star dashboard icon (#73490) 2023-08-28 10:37:42 +01:00
Torkel Ödegaard
3ee26df41e
PublicDashboards: Variables refactor (#73476)
Co-authored-by: Juan Cabanas <juan.cabanas@grafana.com>
Co-authored-by: Ezequiel Victorero <ezequiel.victorero@grafana.com>
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2023-08-25 13:56:02 -05:00
Galen Kistler
5ed3ddf344
Prometheus: Fix dropdowns truncating from start of array (#73643)
* move truncating to helper function, to start of array

* Prometheus: Add 1000 result warning as sticky footer in metric select (#73649)

add 1000 result warning as sticky footer in metric select

* Prometheus: Only show truncated results warning if results have been truncated (#73650)

only show truncated warning if results have been truncated

* add test to metric select

---------

Co-authored-by: Brendan O'Handley <brendan.ohandley@grafana.com>
Co-authored-by: bohandley <brendan.ohandley@gmail.com>
2023-08-25 12:58:35 -04:00
Matias Chomicki
3170ed2dcc
Loki config: update doc links (#73690) 2023-08-25 15:54:53 +03:00
Alex Godbehere
e17928c194
InfluxDB: Add delete buttons to measurement, part and tag in query editor (#72825)
* InfluxDB/QueryEditor: Add delete buttons to measurement, part and tag sections

The diff provides an additional "delete" button to measurement section, part list section and tags section in the influxdb datasource editor. This improves user experience by allowing users to delete measurements, parts and tags directly from the user interface. The commit also slightly refactors the options generation for these sections, removing the "-- remove filter --" option as it becomes redundant with the new delete button.

* InfluxDB/QueryEditor: Replace Button with AccessoryButton

Changed the Button components to AccessoryButton from the '@grafana/experimental' package, used for the delete functionality in data source components for influxdb query editor. The AccessoryButton is more visually consistent with our current Grafana UI aesthetic and provides better user experience. The change was implemented in FromSection.tsx, PartListSection.tsx, and TagsSection.tsx files.

* Update public/app/plugins/datasource/influxdb/components/editor/query/influxql/visual/FromSection.tsx

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>

* Update public/app/plugins/datasource/influxdb/components/editor/query/influxql/visual/PartListSection.tsx

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>

---------

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
2023-08-24 17:19:01 +02:00
Fabrizio
d293b08e52
Tempo: Replace template variables in TraceQL tab when streaming is enabled (#73259) 2023-08-24 14:10:14 +02:00
Fabrizio
ed8ca02e0f
Dashboard: Support template variables in Search tab for Tempo (#72867) 2023-08-24 13:06:46 +02:00
Ivana Huckova
fc9b8f6be1
Loki: Implement keep and drop operations (#73636)
* Update lezer

* Add functionalities for code and builder

* Add comment
2023-08-23 14:52:19 +02:00
Nathan Marrs
65df5a0d7e
Gauge: Add overflow scrolling support for vertical and horizontal orientations (#71690)
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2023-08-23 03:08:11 +03:00
Ihor Yeromin
6db5ef2b82
A11y: Fix exemplar marker accessibility (#73493)
* fix(a11y): exemplar marker
2023-08-22 18:59:36 +02:00
Andreas Christou
3256f7dd0c
CloudMonitoring: ConfigEditor updates (#73561)
Update GCM config
2023-08-22 12:51:04 +01:00
aishyandapalli
d913723451
[10.2.x] Exemplars: Move all the exemplar fields with links to the top in ExemplarMarker (#72697)
Exemplars - add fields with links to the top
2023-08-21 14:56:23 -04:00
Matias Chomicki
f7355668e7
Query splitting: combine nanos attribute con time fields (#73505) 2023-08-21 14:19:20 +02:00
Matias Chomicki
4c37ba494e
Elasticsearch: Add missing tooltips to the configuration page (#73552)
* Add missing tooltips

* Update X-Pack tooltip

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

---------

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2023-08-21 14:13:23 +02:00
Andrew Hackmann
42f4306251
Google Cloud Monitor: Prom query editor (#73503)
* revert

* works but needs clean up and tests

* clean up

* remove any

* change confusing query var to expr

* oops

* add test

* lint

* cleanup

* update docs

* Update public/app/plugins/datasource/cloud-monitoring/components/PromQLEditor.tsx

Co-authored-by: Andreas Christou <andreas.christou@grafana.com>

* nit

* lint fix?

* remove comment from cue

* go linter

* removing parsing stuff parseresponse func

---------

Co-authored-by: Andreas Christou <andreas.christou@grafana.com>
2023-08-18 11:14:43 -05:00
Andreas Christou
b0ed67a306
AzureMonitor: ConfigEditor updates (#73402)
Update config editor

- Use Field instead of InlineField
- Make use of new ConfigSection structural components
- Add DataSourceDescription component
- Add secureSocksProxy to types
2023-08-18 13:11:10 +01:00
Joey
ab94c9d730
Tempo: Only add option to values dropdown if there is a value (#72524)
Only add option to list if there is a values
2023-08-18 08:17:56 +01:00
Galen Kistler
f33f3a55a0
Loki: Label browser sticky footer (#73243)
* Create sticky footer section in loki metrics browser for query preview and action buttons
2023-08-17 11:01:30 -05:00
Matias Chomicki
c8a9adf52a
Config editor: add url placeholder (#73391) 2023-08-17 14:43:59 +02:00
Adela Almasan
451d5a25b2
Canvas: Fix data links (#73332) 2023-08-16 18:32:20 +02:00
Sven Grossmann
c006ea18fb
Loki: Fix validation of step values to also allow e.g. ms values (#73270)
* use go duration validation

* add `isValidGrafanaDuration`

* use `isValidGrafanaDuration`

* improve jsdoc
2023-08-16 17:57:26 +02:00
Galen Kistler
1e07c7c874
InfluxDB: Tests for #73247 (#73250)
* add test assertions to cover default config UI state in influxDB plugin
2023-08-15 11:50:50 -05:00
Alexander Zobnin
b0790063b2
Geomap: Fix crosshair glitch (#72909) 2023-08-15 13:22:19 +02:00
Galen Kistler
873ebc58b4
InfluxDB: make influxql options the default if nothing defined (#73247)
make influxql options the default if nothing defined
2023-08-14 22:31:11 +03:00
Sarah Zinger
09d5483c6c
Cloudwatch: Upgrade aws-sdk and display external ids for temporary credentials (#72821)
(under a feature toggle, not yet ready for public testing)
2023-08-14 13:42:30 -04:00
Sarah Zinger
c2aeb9882d
Cloudwatch: reorg files in components (#73176) 2023-08-14 12:18:58 -04:00
Matias Chomicki
7c098c59fd
Loki: Migrate HTTP settings to new components (#72831)
* Loki: migrate data source http settings

* Remove unused export

* Update e2e tests

* Update unit test
2023-08-14 14:42:14 +02:00
Joey
e6c96e7308
Tracing: Split name column in search results (#72449)
* Split name column

* Add tests

* Update test
2023-08-14 13:26:08 +01:00
Andre Pereira
039ed7a5bd
Tempo: Integrate context aware autocomplete API (#67845)
* Send query in search tag values call

* Make sure to send the full query when using the code editor

* Fix merge conflicts

* Remove unused params
2023-08-11 10:31:09 +01:00
Alyssa Bull
eeefa7dd22
Cloud Monitoring: Support AliasBy property in MQL mode (#73116) 2023-08-10 10:55:09 -06:00
Joey
8c2f439cd7
Table: Support display of multiple sub tables (#71953)
* Add nested option to DataFrame. Refactor Table to use nested dataframes for sub-tables

* Use nested frames for TraceQL response

* debugging

* Fix cell text and table position

* Update getItemSize

* noHeader size

* Update sub table renderer

* Update table container height

* Cleanup and fix RawPrometheusContainer height

* Update resultTransformer and docker script

* Updates to TableContainer, resultTransformer after merge

* Fixes for table pagination in dashboards

* Cell height and show footer enhancement/fix

* Sub table links

* Update RawPrometheusContainer

* Remove console log

* Update tests

* Update storybook

* Remove Tempo demo

* Store nested data in single field via its values

* Move nested prop into custom

* Tempo demo

* Add field type & update incorrect logic

* Update docker compose image for Tempo

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

Co-authored-by: Piotr Jamróz <pm.jamroz@gmail.com>

* Simplify logic for getting nestedFrames and rendering sub tables

* Update docs for table

* Update nested table bg color

* Lighten nested table bg color

* Renames

* Migrate frames using parentRowIndex and add deprecation notice

* Update title

* Align expander icon size between Table and interactive table

* Table: Refactor out the expanded rows bits

* fix spacing

* Add line along left side for expanded rows

* Disable hover row background when expanded

---------

Co-authored-by: André Pereira <adrapereira@gmail.com>
Co-authored-by: Piotr Jamróz <pm.jamroz@gmail.com>
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2023-08-10 12:33:46 +01:00
faust
e1d239a86e
Docs: make it clear that MariaDB is also supported as datasource (#71832)
* Make it clear that MariaDB is also supported as datasource

MariaDB is now the default relational DB on lots of Linux distribution,
it's important to make it clear that it is perfectly supported.

* Fix 404 and make MySQL docs URL more robust

And lint with prettier.

* Review from lwandz13
2023-08-08 07:31:20 -06:00
Uri Okrent
27a8328d3a
Plugins: opentsdb ds: interpolate filter variables in expressions (#71232)
Use the same code path to interpolate both metric variables and
filter/tag variables when the data source is accessed either directly or
via the expressions datasource.

partial fix for #48141 (opentsdb datasource only)

Signed-off-by: Uri Okrent <uokrent@gmail.com>
2023-08-07 18:05:13 +02:00
ismail simsek
29906847e1
Prometheus: Fix fetching label values when datasource has no labels match api support (#72960)
* interpolate match string

* provide unit test

* add the third parameter back to fix the unit test
2023-08-07 15:13:08 +02:00
Sarah Zinger
6ac3348021
Datasource Plugins: Allow tracking for configuration usage (#72650)
Datasource Plugins: Allow tracking for configuration usage
2023-08-07 08:31:13 -04:00
Nathan Marrs
9328febbab
Trend: Fix x field matching logic (#72862) 2023-08-04 10:12:51 -07:00
Drew Slobodnjak
92e7829e7a
Geomap: Fix fixed edge text for network layer (#72863)
Geomap: Fix fixed edge text
2023-08-04 08:21:13 -07:00
ismail simsek
c344b0e427
Chore: Use the const instead of hardcoded string (#72925)
* Use the const instead of hardcoded string

* Use the const instead of hardcoded string

* Fix unit test
2023-08-04 16:55:33 +02:00
ismail simsek
3395ad03a7
InfluxDB: Fix retention policy handling for InfluxDB 3.0 engine by bringing back the hardcoded default (#72467)
* Revert retention policy handling

* Remove comment

* Send retention policy with request when it's possible
2023-08-04 15:57:41 +02:00
Ida Štambuk
abff6e20e9
Cloudwatch Logs: Set Alerting timeout to datasource config's logsTimeout (#72611) 2023-08-03 19:35:30 +02:00
Ivana Huckova
7bb0ff7055
Loki: Introduce $__auto range variable for metric queries (#72690)
* Loki: Add  interpolation to backend

* Loki: Replace default variable  with  in frontend

* Loki: Update docs in query builder fro __auto

* Loki: Update test for change default __auto

* Loki: Remove  and  from suggestions as  should be used

* Update docs

* Update pkg/tsdb/loki/parse_query.go

* Fix backend lint

* Fix lint and test

* Update

* Update docs/sources/datasources/loki/template-variables/index.md

Co-authored-by: lwandz13 <126723338+lwandz13@users.noreply.github.com>

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

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

---------

Co-authored-by: lwandz13 <126723338+lwandz13@users.noreply.github.com>
Co-authored-by: Matias Chomicki <matyax@gmail.com>
2023-08-03 16:27:23 +02:00
Fabrizio
6314cf9588
Fix typos in Loki template variable tests (#72721) 2023-08-03 14:26:54 +03:00
Joey
b4c55765fe
Tempo: Only get span_names when they are in the response (#72663)
* Only get span names when they are in the response

* Find span_name field/labels
2023-08-03 07:55:32 +01:00
ismail simsek
d333c09418
InfluxDB: SQL Query Editor (#72168)
* Add influxdbSqlSupport feature toggle

* Add SQL option to the config page

* Add SQL backend

* Add metadata support in config page

* Implement unified querying

* Fix healthcheck query

* fsql tests

* secure grpc by default

* code cleanup

* Query handing for sql mode

* Implement a placeholder sql editor

* Fix query language dropdown

* drop in SQL editor

* switch to use rawSql, get sql editor working

* fix healthcheck

* WIP

* memoize component to stop unwanted rerender onQuery

* dont reinit datasource on each render of the editor

* remove useless memo

* clean up

* Fix the link

* Alpha state warning

* Remove console.logs

* update model for fsql

* remove unused

---------

Co-authored-by: Galen <galen.kistler@grafana.com>
2023-08-02 19:04:16 +02:00
ismail simsek
77e7ae2a1b
InfluxDB: SQL Support (#72167)
* Add influxdbSqlSupport feature toggle

* Add SQL option to the config page

* Add SQL backend

* Add metadata support in config page

* Implement unified querying

* Fix healthcheck query

* fsql tests

* secure grpc by default

* code cleanup

* Query handing for sql mode

* Implement a placeholder sql editor

* Fix query language dropdown

* go mod updates

* make lint-go

* more make lint-go

* remove unused runQuery

* switch statements with default case

* linting again
2023-08-02 18:27:43 +02:00
Andrej Ocenas
58314e6414
Flamegraph: Remove feature flag and code to switch to pyroscope version (#72689) 2023-08-02 17:01:12 +02:00
Laura Fernández
7ec9a0c9da
GLDS: Move Text component from the unstable package to grafana-ui (#72660) 2023-08-02 14:58:00 +02:00
Andreas Christou
95f8cc09c7
AzureMonitor: Add hardcoded namespaces to improve coverage (#72629)
Add hardcoded resources
2023-08-02 10:33:50 +01:00
Andrej Ocenas
91c7096eda
Flamegraph: Diff profile support (#72383) 2023-08-01 16:08:46 +02:00
Ashley Harrison
e0587dfb30
Chore: Replace deprecated usage of shape.borderRadius() (#72672)
* properly mark borderRadius() as deprecated, replace borderRadius() with default

* undo a couple of changes

* use radius.pill in FilterPill
2023-08-01 14:46:07 +01:00
Andre Pereira
5c14a07ec3
Tempo: Integrate TraceQL grammar (#72516)
* Replacing the regex based approach and integrating the lezer-traceql grammar in the editor

* Added some tests

* Added path to capture error in filter root

* Tests are great and help fix issues 👍

* Fix autocomplete tests
2023-08-01 14:15:05 +01:00
Andrej Ocenas
09c7190bfe
Flamegraph: Add nice empty state for dashboard panel (#72583) 2023-08-01 10:49:52 +02:00
Joey
7612f3d955
Tempo: If no search tag then do not query API for tag values (#72522)
* If no tag then do not query api for tag values

* Update test
2023-08-01 08:44:13 +01:00
Gábor Farkas
ed9dc63326
loki: logs-context: handle sorting for dataplane frames (#72286)
loki: context: better dataframe sorting algo
2023-08-01 09:38:41 +02:00
ismail simsek
31f4eddbb6
InfluxDB: Fix fetching retention policies after manually entering a non-existent retention policy (#72564)
Don't fetch tag keys before fetching policies
2023-07-31 20:38:46 +02:00
Alyssa Bull
adc3735122
Google Cloud Monitor: Use generated type from schema in backend (#67879) 2023-07-31 11:14:27 -06:00
alburthoffman
cdfbcb2ec6
passing time filters (#64086)
* passing time filters

* add settings

* Cleanup and merge fixes

---------

Co-authored-by: André Pereira <adrapereira@gmail.com>
2023-07-31 16:13:48 +01:00
Piotr Jamróz
2ae226de89
Explore: Decouple SplitOpen and getFieldLinksForExplore from Panel visualizations (#71811)
* Allow overriding internal data link supplier

* Remove SplitOpen and getFieldLinksForExplore dependencies

* Fix checking if row index is provided

* Fix unit test

* Add a comment

* Mark SplitOpen as deprecated

* Use Panel Context to provide internal data link supplier

* Update packages/grafana-ui/src/components/PanelChrome/PanelContext.ts

Co-authored-by: Haris Rozajac <58232930+harisrozajac@users.noreply.github.com>

* Update packages/grafana-data/src/utils/dataLinks.ts

Co-authored-by: Haris Rozajac <58232930+harisrozajac@users.noreply.github.com>

* Add missing eventsScope

* Fix infinite render loops

* Rename internal data link supplier to data link post processor

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

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>

---------

Co-authored-by: Haris Rozajac <58232930+harisrozajac@users.noreply.github.com>
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2023-07-31 14:10:03 +02:00
Matias Chomicki
0d121bab29
Elasticsearch: Implement modify query using a Lucene parser (#71954)
* Lucene: add dependency

* ModifyQuery: use Lucene parser to detect key:values in queries

* ModifyQuery: use Lucene parser to remove filters

* Remove test code

* Modify query: switch to recursive implementation

* Modify query: implement remove filter

* Update query normalizing function

* FlagElasticToggleableFilters: remove feature flag

* Remove unused feature flag from test

* Elasticsearch: escape quotes in filter values
2023-07-28 14:49:02 +02:00
Gábor Farkas
f63d829bf6
loki: tests: better nanosecond representation (#72456)
* logs: tests: test for nanosecond-only differences

* add nanos
2023-07-27 17:06:56 +03:00
Gilles De Mey
f10527cfe3
Alerting: Contact points v2 part 2 (#71135) 2023-07-27 13:28:00 +02:00
Galen Kistler
fbd2412f37
Prometheus: Update heatmap unit tests (#72404)
introduce tests for new potential heatmap response type, revert prior changes to tests
2023-07-26 14:47:13 -05:00
Galen Kistler
831e8acf15
Prometheus: Add support for day_of_year (#72403)
add querybuilder/code editor support for day_of_year
2023-07-26 14:03:17 -05:00
Drew Slobodnjak
59bed9e156
Geomap: Add network layer (#70192)
* Geomap: Add network layer

* Support text labels for nodes

* Add solid styling for edges

* Remove symbol option for edge style menu

* Add support for edge text labels

* Fix linter issues

* Simplify multiple data frame handling

* Add TODO notes

* Add node and edge style categories for options

* Remove data frame hardcoding

* Hide legend, attempt to hide tooltip by default

* Mark network layer as beta

* refactor updateEdge

* Fix some linter issues

* Remove attempt at disabling tooltip for network layer

* For edge text add a stroke and increase z index

* Restrict field selection based on frame type

* refactor

* add basic bad data handling (prevent entire panel from breaking)

* generate non hard coded graph frames for style editor filtering

* code cleanup; remove hardcoded reference to "edges" frame

* fix select clearing for Data option

* fix styling

* fix lookup

---------

Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
Co-authored-by: Adela Almasan <adela.almasan@grafana.com>
2023-07-26 11:58:55 -07:00
Ivan Ortega Alba
8415dd40d7
DSPicker: Use new DS picker everywhere in Grafana (#70609) 2023-07-26 18:40:51 +02:00
Brendan O'Handley
98cb3ce3b6
Prometheus: Config overhaul part two, auth and DataSourceHttpSettings overhaul (#71250)
* build httpsettings overhaul with new auth component

* remove test code

* add connection and advanced http settings components

* use tooltip with link

* add correct styling and spacing

* save option select for sigV4

* fix styles in Azure auth to fit new auth component

* add types in overhaul folder that are not available yet in grafana

* update e2e tests for new connection component

* update e2e tests for new connection component

* update width of azure inputs

* fix non custom auth selects

* add feature toggle

* wrap azure style changes behind the feature flag

* fix feature toggle rebase fix error

* move advanced http setting and wrap everything in the config subsection component to fix font

* fix input width

* use cx for conditional classes

* use cx for conditional class
2023-07-26 12:09:53 -04:00
Matias Chomicki
6f3dfb2d8b
Loki Query Splitting: Ignore empty queries like hidden queries (#72376)
Loki query splitting: ignore empty queries like hidden queries
2023-07-26 15:18:55 +01:00
Adam Simpson
51b199e986
AzureMonitor: revert Variable Editor region changes (#72306)
* Revert "remove regions/locations from variable editor"

This reverts commit 41dc6a8bfb.

* Revert "remove region pieces from e2e"

This reverts commit 6b1f82f14a.

* e2e: open resource picker correctly
2023-07-26 14:04:18 +00:00
Gareth Dawson
34ee3b09de
Loki / Prometheus: Fix query builder select component in safari (#71966)
* partial fix

* remove unused import

* fix that doesnt remove error message
2023-07-26 14:50:52 +01:00
Andre Pereira
89092a1e69
Tempo: Use feature toggle to control TraceQL streaming (#72288)
Rename traceql streaming feature toggle. Remove the manual toggle from Options component and use the feature toggle
2023-07-26 13:33:16 +00:00
stratomonitor
d96067985b
Prometheus: Add present_over_time syntax highlighting (#72283)
add prometheus present_over_time syntax highlighting

to color present_over_time keyword for prometheus
2023-07-26 13:21:14 +00:00
Konrad Lalik
e094adb5a1
Alerting: Fix refetching grafana rules on alert list panel (#72242) 2023-07-26 10:37:22 +02:00
Coen van Leeuwen
88988e4337
XYChart: Prevent crash on point hover (#70225) 2023-07-25 14:20:00 -07:00
Nathan Marrs
67a6a99e04
Heatmap: Clean up datalink code (#72296) 2023-07-25 14:13:59 -07:00
Krešimir Bačić
4ef5c33af9
Heatmap: Add datalink support (#71016) 2023-07-25 09:27:44 -07:00
Adam Simpson
722f787eaa
AzureMonitor: Fix ResourcePicker hanging (#71886)
* AzureMonitor: Fix ResourcePicker hanging

Removed location fetching for every subscription.

Fixes #70523

* fix region for multi metricnames

* fix tests

* fix e2e

* remove regions/locations from variable editor

* remove region pieces from e2e
2023-07-25 14:18:03 +00:00
Ivana Huckova
2a5a4ded53
Loki: Run logs volume for query when switching from trace to logs (#72268)
Loki: Run logs volume for query that has no queryType (defaults to range)
2023-07-25 14:33:33 +02:00
Joey
e4f419b84f
Tempo: Use new configuration editor components (#71288)
* Use new config components in Tempo

* Update Grafana experimental version
2023-07-25 12:50:12 +01:00
Konrad Lalik
32e2304f10
Alerting: Improve alerts names visibility on narrow panels (#72104) 2023-07-25 12:26:53 +02:00
ismail simsek
376ab3f3ca
InfluxDB: Fix setting retention policy on visual query editor (#72248)
Prevent fetch loop
2023-07-25 11:21:35 +02:00
Nathan Marrs
bc0bf0ee4b
Geomap: Promote route + photos layer to beta, promote geojson layer to stable (#72233) 2023-07-24 18:07:30 -07:00
Kevin Yu
4c42632ab8
CloudWatch Logs: Add Monaco-based query field editor behind feature flag (#71799) 2023-07-24 14:33:45 -07:00
Andre Pereira
bd59a27b99
Tempo: Remove traceqlSearch feature toggle (#72029)
* Remove feature flag from registry.go

* Remove usages of toggle

* Refactor and cleanup Tempo's query field components

* Added deprecation alert

* Mark nativeSearch fields as deprecated

* Also show deprecated search tab if queryType is nativeSearch

* Update deprecation message to list grafana version

* Fix merge conflict

* Remove mention of toggle from docs
2023-07-24 16:26:10 +01:00
renovate[bot]
c280f884f0
Update dependency @grafana/experimental to v1.6.1 (#68681)
* Update dependency @grafana/experimental to v1.6.1

* chore(mssql-datasource): update completion provider to work with experimental type changes

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
2023-07-24 15:47:55 +02:00
Andres Martinez Gotor
987624f8cf
Chore: Move StreamingDataFrame to @grafana/data (#72014) 2023-07-24 13:30:52 +02:00
Matias Chomicki
84f94cdc24
Logs: Show active state of "filter for value" buttons in Logs Details (#70328)
* 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: add functions to detect the presence of a label and remove it

* Remove label: handle escaped values

* Logs: create props to check for label filters in the query

* Log Details Row: use label state props to show visual feedback

* Make isCallbacks async

* Explore: add placeholder for checking for filter in query

* Datasource: define new API method

* Inspect query: add base implementation

* Remove isFilterOutLabelActive as it will not be needed

* Check for "isActive" on every render

Otherwise the active state will be out of sync

* Elasticsearch: implement inspectQuery in the datasource

* Logs: update test

* Log details: update test

* Datasources: update tests

* Inspect query: rename to analize query to prevent confusion

* Datasource types: mark method as alpha

* Explore: add comment to log-specific functions

* Remove duplicated code from bad rebase

* Remove label filter: check node type

* getMatchersWithFilter: rename argument

* Fix bad rebase

* Create DataSourceWithQueryManipulationSupport interface

* Implement type guard for DataSourceWithQueryManipulationSupport

* DataSourceWithQueryManipulationSupport: move to logs module

* hasQueryManipulationSupport: change implementation

`modifyQuery` comes from the prototype.

* DataSourceWithQueryManipulationSupport: expand code comments

* AnalyzeQueryOptions: move to logs module

* DataSourceWithQueryManipulationSupport: add support for more return types

* Fix merge error

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

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>

* DatasourceAPI: deprecate modifyQuery

* Explore: refactor isFilterLabelActive

* DataSourceWithQueryModificationSupport: rename interface

* Split interfaces into Analyze and Modify

* Query analysis: better name for interface

* Fix guard

* Create feature flag for active state

* Use new feature flag in Explore

* DataSourceToggleableQueryFiltersSupport: create a specific interface for this feature

* Rename feature flag

* De-deprecate modifyQuery

* DataSourceToggleableQueryFiltersSupport: Rethink types and methods

* Explore: adjust modifyQuery and isFilterLabelActive to new methods

* Loki: implement new interface and revert modifyQuery

* DataSourceToggleableQueryFiltersSupport: better name for arguments

* Elasticsearch: implement new interface and revert modifyQuery

* Loki: better name for arguments

* Explore: document current limitation on isFilterLabelActive

* Explore: place toggleable filters under feature flag

* Loki: add tests for the new methods

* Loki: add legacy modifyQuery tests

* Elasticsearch: add tests for the new methods

* Elasticsearch: add legacy modifyQuery tests

* Toggle filter action: improve type values

* Logs types: update interface description

* DataSourceWithToggleableQueryFiltersSupport: update interface name

* Update feature flag description

* Explore: add todo comment for isFilterLabelActive

---------

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
2023-07-24 11:22:47 +03:00
Nathan Marrs
8c86a46440
Phlare: Set enum field type to enum instead of integer (#72078)
Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
2023-07-21 13:08:23 -05:00
Nathan Marrs
9a6a739003
TestData: Update Flame Graph scenario to use enum field type for label (#72082)
Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
2023-07-21 20:27:23 +03:00
Leon Sorokin
1de35bf3c3
TimeSeries / StateTimeline: Add support for rendering enum fields (#64179)
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2023-07-21 11:38:11 -05:00
Josh Hunt
f3235ba959
NestedFolders: Rename FolderPicker to OldFolderPicker (#72098)
* Rename FolderPicker to OldFolderPicker

* fix jest mock

* fix jest mock
2023-07-21 13:24:43 +00:00
Gareth Dawson
4e42f9b619
Loki: Add the ability to prettify logql queries (#64337)
* pushed to get help of a genius

* fix: error response is not json

* feat: make request on click

* refactor: remove print statement

* refactor: remove unnecessary code

* feat: convert grafana variables to value for API request

* use the parser to interpolate and recover the original query (#64591)

* Prettify query: use the parser to interpolate and recover the original query

* Fix typo

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

* Fix typo

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

* fix: reverse transformation not working

---------

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
Co-authored-by: Gareth Dawson <gwdawson.work@gmail.com>

* fix: bugs created from merge

* refactor: move prettify code out of monaco editor

* fix: variables with the same value get converted back to the incorect variable

* refactor

* use consistent styling with bigquery

* fix: only allow text/plain and application/json

* fix: only make the request if the query is valid

* endpoint now returns application/json

* prettify from js

* WIP: not all cases are handles, code still needs cleaning up

* WIP

* large refactor, finished support for all pipeline expressions

* add tests for all format functions

* idk why these files changed

* add support for range aggregation expr & refactor

* add support for vector aggregation expressions

* add support for bin op expression

* add support for literal and vector expressions

* add tests and fix some bugs

* add support for distinct and decolorize

* feat: update variable replace and return

* fix: lezer throws an errow when using a range variable

* remove api implementation

* remove api implementation

* remove type assertions

* add feature flag

* update naming

* fix: bug incorrectly formatting unwrap with labelfilter

* support label replace expr

* remove duplicate code (after migration)

* add more tests

* validate query before formatting

* move tests to lezer repo

* add feature tracking

* populate feature tracking with some data

* upgrade lezer version to 0.1.7

* bump lezer to 0.1.8

* add tests

---------

Co-authored-by: Matias Chomicki <matyax@gmail.com>
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2023-07-21 13:03:56 +01:00
Matias Chomicki
c84d689ce0
Loki: Enable Query Splitting by default (#72094)
* lokiQuerySplitting: enable feature flag by default

* Query stats: add special note for stats + splitting
2023-07-21 13:53:10 +02:00
Ashley Harrison
01369e6aff
Chore: fix .eslintignore to only ignore folder paths at the root (#72032)
fix eslintignore to only ignore folder paths at the root
2023-07-21 09:17:42 +01:00
Andres Martinez Gotor
6f445eca8a
Chore: Remove liveTimer reference from testdata (#71997) 2023-07-21 09:18:41 +02:00
Galen Kistler
1c358de190
Prometheus: Fix heatmap query format (#71971)
Check first numeric field instead of name: Value 

---------

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
2023-07-20 15:09:40 +03:00
Laura Fernández
47f70bdb00
GLDS: Text component (#71439) 2023-07-20 12:59:42 +02:00
Agnès Toulet
ac445a25d5
Kindsys: update generated doc and add check in CI (#71871)
* clean up docs

* fix Windows path issue

* add verify-gen-cue to doc pipeline

* fix linting error
2023-07-20 11:48:12 +02:00
Andres Martinez Gotor
47f1c5d084
Chore: Avoid Grafana core imports for the test data source (#71956) 2023-07-20 09:34:19 +02:00
Joey
090b8d61e2
Tracing: Remove newTraceViewHeader feature toggle (#71818)
* Remove TracePageHeader, uiFind, setTrace and many spanFindMatches

* Removed TracePageSearchBar

* Update useSearch

* Update filterSpans

* Update docs

* Updated tests

* Add trace to tests

* Remove feature toggle

* Renames in useSearch

* Renames in filter-spans

* Cleanup fixes

* Rename TracePageHeader

* Rename TracePageSearchBar

* Update test

* Update style for long urls

* Style and check
2023-07-19 14:31:58 +01:00
Andres Martinez Gotor
5d07b1c884
Chore: Move getSearchFilterScopedVar to @grafana/data (#71839) 2023-07-19 13:56:14 +02:00
Selene
f75a3d04cf
Chore: Remove pfs.GrafanaPlugin from schemas (#71884)
Remove pfs.GrafanaPlugin from schemas
2023-07-19 03:46:13 -04:00
Kevin Yu
44a1f10b10
Cloudwatch Logs: Add autosuggest to logs query editor (#71800)
* Cloudwatch: Add autosuggest to logs query editor

* move getSuggestion to LogsCompletionItemProvider

* remove debug stuff

* add tests

* fix lint
2023-07-18 14:26:11 -07:00
ismail simsek
dfb94ff396
Chore: Influxdb variable type cleanup (#71874)
type cleanup
2023-07-18 18:43:30 +02:00
Dominik Prokop
34c9faf140
PanelContext: Provide events scope identifier (#71561)
* PanelContext: Provide events scope identifier

* What a console log
2023-07-18 06:27:33 -07:00
Domas
1347d85b50
Tempo Service Map: Optionally group nodes also by service.namespace (#70803)
* tempo service map: optionally handle namespace

* undo escape attempt

* regen cue
2023-07-18 13:11:12 +03:00
Andre Pereira
72118e372c
Tempo: TraceQL streaming improvements (#71736)
* Remove unneeded log

* Add elapsed time to streaming progress table

* Use disableTraceQLStreaming toggle to determine default status of streaming
2023-07-18 12:45:35 +03:00
社长长
fed3c97dc1
Bugfix: Pie chart legend width doesn't works (#68351) 2023-07-18 12:37:53 +03:00
Andrej Ocenas
c2778325f6
FlameGraph: Add column in table with buttons to filter and sandwich a symbol (#71773) 2023-07-18 09:54:25 +02:00
Kevin Yu
31e142633d
CloudWatch Logs: Add getStatementPosition function for Monaco editor (#70724)
* CloudWatch Logs: Add getStatementPosition function for Monaco editor

* Add test cases

* add command and function arg positions

* remove unneeded statement position

* remove debug stuff

* remove unneeded cases

* add filterarg

* remove editor changes

* fix tests

* fix lint

* add debug for testing

* Revert "add debug for testing"

This reverts commit 22dd0e7a77eb43dbed7c065c246da04cddfa1afc.
2023-07-17 13:43:48 -07:00
Andrej Ocenas
dd41c7c262
Flamegraph: Fix wrong positioning of tooltip in dashboards (#71396) 2023-07-17 22:29:39 +02:00
Ashley Harrison
9852b24d61
Chore: Upgrade prettier to v3 (#71764)
* Update dependency prettier to v3 (#71586)

* Update dependency prettier to v3

* run prettier

* ignore prettier update in legacy select scss

* update command line arg

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>

* unplug prettier

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-07-17 15:58:22 +01:00
Ashley Harrison
5ca382c88a
Revert "Update dependency prettier to v3 (#71586)" (#71755)
This reverts commit 2e8cd1c021.
2023-07-17 14:46:15 +01:00
Andreas Christou
722cf0ab68
Fix accessibility issues in traces query editor (#71045)
* Fix accessibility issues

- Ensure key events exist and role is appropriately set
- Ensure that when the filter field is cleared the query is updated

* Review
2023-07-17 16:24:43 +03:00
Adam Yeats
409eae6ff9
AzureMonitor: Fix resource selection growing over resource selection table (#71463)
* AzureMonitor: Fix resource selection growing over resource selection table

* Unstick ResourcePicker footer, fix sizing
2023-07-17 14:01:51 +02:00
Andreas Christou
480ccf6e8f
AzureMonitor: Add switch to control time-range for Logs queries (#71278)
* Update types

* Update migration

- Default intersectTime property to false

* Update frontend components

- Add intersectTime field
- Update tests
- Update mocks
- Add onChange function

* Update backend

- Appropriately set intersectTime for logs queries
- intersectTime is always true for Traces queries
- Update tests

* Update docs

* Fix test and lint
2023-07-17 12:02:16 +01:00
renovate[bot]
2e8cd1c021
Update dependency prettier to v3 (#71586)
* Update dependency prettier to v3

* run prettier

* ignore prettier update in legacy select scss

* update command line arg

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-07-17 09:19:27 +01:00
ismail simsek
a8819dedcf
Chore: Remove prometheusAzureOverrideAudience feature toggle (#71599)
* Remove prometheusAzureOverrideAudience feature toggle

* Remove overrideAudienceAllowed flag
2023-07-16 23:30:14 +02:00
Ivana Huckova
b346c9b283
Loki: Fix duplicated rendering of resolution (#71670) 2023-07-15 11:13:12 +02:00
Leon Sorokin
72a332685a
Heatmap: Use displayName to test if numeric bucket fields (#71407) 2023-07-14 18:19:36 -05:00
Andre Pereira
c1709c9301
Tempo: TraceQL query response streaming (#69212)
* Refactor Tempo datasource backend to support multiple queryData types.
Added traceId query type that is set when performing the request but doesn't map to a tab.

* WIP data is reaching the frontend

* WIP

* Use channels and goroutines

* Some fixes

* Simplify backend code.
Return traces, metrics, state and error in a dataframe.
Shared state type between FE and BE.
Use getStream() instead of getQueryData()

* Handle errors in frontend

* Update Tempo and use same URL for RPC and HTTP

* Cleanup backend code

* Merge main

* Create grpc client only with host and authenticate

* Create grpc client only with host and authenticate

* Cleanup

* Add streaming to TraceQL Search tab

* Fix merge conflicts

* Added tests for processStream

* make gen-cue

* make gen-cue

* goimports

* lint

* Cleanup go.mod

* Comments

* Addressing PR comments

* Fix streaming for tracel search tab

* Added streaming kill switch as the disableTraceQLStreaming feature toggle

* Small comment

* Fix conflicts

* Correctly capture and send all errors as a DF to client

* Fix infinite error loop

* Fix merge conflicts

* Fix test

* Update deprecated import

* Fix feature toggles gen

* Fix merge conflicts
2023-07-14 15:10:46 +01:00
Piotr Jamróz
dc4cedd298
TestDatasource: Generate refId for the flame graph (#71547)
* Remove hardcoded refId

* Generate correct refId for flameGraph
2023-07-14 15:15:50 +02:00
renovate[bot]
1cacc78eda
Update dependency lru-cache to v10 (#71585)
* Update dependency lru-cache to v10

* use named import

* remove outdated type definitions and actually use named import

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-07-14 10:26:58 +01:00
Nathan Marrs
16e5d442ba
Geomap: Address tooltip performance issue (#71607) 2023-07-13 20:21:06 -07:00
Drew Slobodnjak
1a857552a1
Trend: Support disconnect values and connect nulls options (#70616)
Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2023-07-13 19:28:58 -07:00
renovate[bot]
cbc44751b2
Update dependency immer to v10 (#71583)
* Update dependency immer to v10

* use named export now that the default has been removed

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-07-13 18:52:59 +03:00
Nathan Marrs
bd4f8fd280
Chore: Remove console.log from heatmap util file (#71515) 2023-07-12 17:12:36 -07:00
Leon Sorokin
46c5e5417b
Heatmap: Build cell colors during data prep instead of render (#71509) 2023-07-12 18:23:30 -05:00
Kevin Yu
ee28e9320c
Cloudwatch Logs: Update language definition for Monaco editor (#71402) 2023-07-12 09:25:24 -07:00
Gábor Farkas
fdb8257007
Elasticsearch: Fix histogram colors in backend mode (#71442)
elastic: backend-mode: fix histogram colors
2023-07-12 13:59:51 +02:00
Joey
6615418df8
Tracing: Show next/prev buttons when span filters are collapsed (#71025)
* Show next/prev buttons when span filters are collapsed

* Update test

* Remove imports

* Update lint

* Prettier

* Update test

* Update styling
2023-07-12 07:52:07 +01:00
Kevin Yu
a2a890e85b
Cloudwatch: Add comment and regexp to TokenTypes interface (#71399)
* Cloudwatch: Add comment and regexp to TokenTypes interface

* fix lint
2023-07-11 14:43:08 -07:00
Andrej Ocenas
6f102ccad0
Flamegraph: Remove feature toggle for sandwich view and color schemes (#71305) 2023-07-11 14:58:43 +02:00
Ryan McKinley
09cc63329f
XYChart: Improve base options setup (#67878) 2023-07-10 17:54:01 -07:00
Gilles De Mey
1945f2b64e
Alerting: Use new "Label" components for alert instance labels (#70997) 2023-07-10 13:03:35 +02:00
Drew Slobodnjak
2b7af7798c
StateTimeline: Add disconnect value option (#70610)
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
2023-07-07 13:24:22 -07:00
Ihor Yeromin
d92d3ede79
XYChart: Point size editor should reflect correct default (5) (#71126)
fix(xychart): reconcile point size editors
2023-07-07 18:43:49 +02:00
Galen Kistler
7dc071f46b
Prometheus: Version detect bug (#71198)
* remove redundant request copy in backend, add more versions to semver lists
2023-07-07 09:39:20 -05:00
Matias Chomicki
92c94710cd
Loki/Elasticsearch config: Add DataSourceDescription component (#71206)
* Loki config: add data source description component

* Elastic config: add data source description component
2023-07-07 14:22:52 +01:00
Adela Almasan
bde9478c5e
BarChart: Check by displayName (#71161)
Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
2023-07-06 20:56:36 -05:00
Matias Chomicki
1b80df0168
Loki: add additional settings section (#71035)
* Loki: add additional settings section

* Derived fields: add config subsection

* Query settings: add config subsection

* Loki config: use divider instead of hr

* Derived fields: refactor legacy styles

* Loki config: add divider between derived fields and query settings

* Loki config: create alerting settings for Loki
2023-07-06 10:20:38 +02:00
Adela Almasan
901495a54a
BarChart: Fix legend for fields with labels (#71098) 2023-07-05 14:54:10 -05:00
Galen Kistler
daf9f9cd19
Prometheus: Incremental querying profile data updates (#70701)
* add prometheusIncrementalQueryInstrumentation feature flag, update instrumentation data
2023-07-05 14:39:49 -05:00
Andre Pereira
340c536d0e
Tempo: TraceQL editor - Match type of new values with values in dropdown (#69468)
Tempo: TraceQL editor - set type of added values to match the type of the other values in the dropdown
2023-07-05 15:34:22 +01:00
fabrizio-grafana
d31e96104a
Dashboard: Add suggestion box for Flame Graph (#70763)
Co-authored-by: Andrej Ocenas <mr.ocenas@gmail.com>
2023-07-05 14:25:00 +02:00
Galen Kistler
927393633c
Prometheus: Code editor autocomplete returns bad results when text is highlighted (#70856)
* adjust cursor when text is selected to give better autocomplete results in prometheus code editor
2023-07-05 07:22:23 -05:00
Matias Chomicki
d153fd434a
Elasticsearch: add additional settings section (#71037)
* Elasticsearch: add additional settings section

* Remove extra lines

* Elastic config: add divider between name and http settings

* Data links: fix subsection title

* Remove unused import
2023-07-05 10:45:10 +02:00
Laura Benz
9a8125ca3b
Elasticsearch: Replace duplicate IconButton component (#71050)
* refactor: replace IconButtons

* refactor: replace tooltip text in order to make it more universal

* refactor: remove additional IconButton

* refactor: add aria-labels

* refactor: fix test
2023-07-05 08:47:38 +02:00
Gábor Farkas
a62ae10a02
logs: refactor: move logsModel to the logs folder (#70989)
* move files

* fixed imports in the moved files

* updated imports pointing to the moved files
2023-07-04 13:27:52 +02:00
Gilles De Mey
df3888ba60
Alerting: Refactor Alertmanager picker (#70720) 2023-07-04 13:07:05 +03:00
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
Andrej Ocenas
3eaee12e3e
Flamegraph: Add switch for color scheme by value or by package (#70770) 2023-06-30 17:01:11 +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
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
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
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
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