Commit Graph

859 Commits

Author SHA1 Message Date
Peter Holmberg
f445369d68
grafana/ui: Add disabled prop on LinkButton (#19192) 2019-09-19 08:59:36 +02:00
Ryan McKinley
14f1cf29f0 FieldDisplay: Update title variable syntax (#19217) 2019-09-19 08:17:15 +02:00
Hugo Häggmark
38e948a1ad Dashboard: Fixes back button styles in kiosk mode (#19165)
Fixes: #18114
2019-09-18 08:58:08 +02:00
Dominik Prokop
503dccb771 Revert "Chore: Update Slate to 0.47.8 (#18412)" (#19167)
This reverts commit 601853fc84.
2019-09-17 13:21:50 +02:00
kay delaney
601853fc84 Chore: Update Slate to 0.47.8 (#18412)
* Chore: Update Slate to 0.47.8
Closes #17430

* Add slate and immutable to grafana-ui deps

* Fixes some small regressions introduced

* Fix suggestions for multiple query fields

* Pin upgraded dependencies

* Prettier fix

* Remove original slate-react dependency

* Fix tiny-invariant dep

* (Temporarily) comments out source maps for grafana-ui
2019-09-17 13:16:24 +02:00
Andrej Ocenas
359404eb77
Explore: Update live tail buttons (#19143) 2019-09-17 11:25:12 +02:00
Hugo Häggmark
3952083bdb TimePicker: Fixes onBlur issue with FireFox on MacOS (#19154)
Fixes: #18531
2019-09-17 09:48:47 +02:00
Dominik Prokop
5c0f424d1b
grafana/data: Reorganise code (#19136)
* Organise data frame and vectors code

* Organise transformations

* Move dataframe utils to dataframe dir

* Organise datetime utils

* Organise text utils

* Organise logs utils

* Revert "Organise logs utils"

This reverts commit c24115c755.

* registry -> Registry

* Transformations reorg
2019-09-17 08:23:47 +02:00
Ivana Huckova
85e128fede Explore: No logs should show an empty graph (#19132)
* Explore: add no data points text to graph

* Explore: add console log for error (accidentaly removed)

* Explore: refactor, created getYAxes method for better readability

* Explore: remove unnecessary console.log

* Explore: fix getYAxes method to return value

* Graph: Simplify warning from no data points to No data
2019-09-16 18:55:52 +02:00
Dominik Prokop
1a71501440
Chore: cross-package security bumps (#19131)
* Bump lodash to 4.17.15

* Bump pretty-format to 24.9.0
2019-09-16 15:50:15 +02:00
David
a28aefa370
Graph: constant series as override (#19102)
* Graph: constant series as override

- ability to define a series override that takes the first value of a
timeseries and produces constant series from it.

* Moved constant series override logic to grafana-ui

* Added docs for instant queries and constant series override
2019-09-16 13:49:55 +02:00
Hugo Häggmark
7ace80c71c Graph: Adds onHorizontalRegionSelected (#19083)
* Refactor: Renamed and changed Signature for OnHorizontalRegionSelected

* Refactor: Adds onHorizontalRegionSelected to GraphPanelController

* Refactor: Moves TimeSrv call to PanelChrome instead
2019-09-16 09:31:22 +02:00
David
b392bba745
Loki: Updated cheat sheet with new filter syntax (#18947)
* Loki: Updated cheat sheet with new filter syntax

- updated cheat sheet with new filter syntax
- added user-specific examples from the user's label set
- added link to LogQL docs
- separated styles for examples (clickable) and expressions

* Review feedback
2019-09-16 07:17:34 +02:00
Torkel Ödegaard
fd21e0ba14
DataLinks: enable access to labels & field names (#18918)
* POC: trying to see if there is a way to support objects in template interpolations

* Added support for nested objects, and arrays

* Added accessor cache

* fixed unit tests

* First take

* Use links supplier in graph

* Add field's index to cache items

* Get field index from field cache

* CHange FiledCacheItem to FieldWithIndex

* Add refId to TimeSeries class

* Make field link supplier work with _series, _field and _value vars

* use field link supplier in graph

* Fix yaxis settings

* Update dashboard schema version and add migration for data links variables

* Update snapshots

* Update build in data link variables

* FieldCache - idx -> index

* Add current query results to panel editor

* WIP Updated data links dropdown to display new variables

* Fix build

* Update variables syntac in field display, update migration

* Field links supplier: review updates

* Add data frame view and field name to TimeSeries for later inspection

* Retrieve data frame from TimeSeries when clicking on plot graph

* Use data frame's index instead of view

* Retrieve data frame by index instead of view on TimeSeries

* Update data links prism regex

* Fix typecheck

* Add value variables to suggestions list

* UI update

* Rename field to config in DisplayProcessorOptions

* Proces single value of a field instead of entire data frame

* Updated font size from 10px to 12px for auto complete

* Replace fieldName with fieldIndex in TimeSeries

* Don't use .entries() for iterating in field cache

* Don't use FieldCache when retrieving field for datalinks in graph

* Add value calculation variable to data links (#19031)

* Add support for labels with dots in the name (#19033)

* Docs update

* Use field name instead of removed series.fieldName

* Add test dashboard

* Typos fix

* Make visualization tab subscribe to query results

* Added tags to dashboard so it shows up in lists

* minor docs fix

* Update singlestat-ish variables suggestions to contain series variables

* Decrease suggestions update debounce

* Enable whitespace characters(new line, space) in links and strip them when processing the data link

* minor data links UI update

* DataLinks: Add __from and __to variables suggestions to data links (#19093)

* Add from and to variables suggestions to data links

* Update docs

* UI update and added info text

* Change ESC global bind to bind (doesn't capture ESC on input)

* Close datalinks suggestions on ESC

* Remove unnecessary fragment
2019-09-13 16:38:21 +02:00
lzd
fc10bd7b8e Singlestat: fix format messes up on negative values if select duratio… (#19044)
* Singlestat: fix format messes up on negative values if select duration (hh:mm:ss) unit

* Added test for 0
2019-09-13 16:15:31 +02:00
Torkel Ödegaard
140ecbcf79
QueryProcessing: Observable query interface and RxJS for query & stream processing (#18899)
* I needed to learn some rxjs and understand this more, so just playing around

* Updated

* Removed all the complete calls

* Refactoring

* StreamHandler -> observable start

* progress

* simple singal works

* Handle update time range

* added error handling

* wrap old function

* minor changes

* handle data format in the subscribe function

* Use replay subject to return last value to subscribers

* Set loading state after no response in 50ms

* added missing file

* updated comment

* Added cancelation of network requests

* runRequest: Added unit test scenario framework

* Progress on tests

* minor refactor of unit tests

* updated test

* removed some old code

* Shared queries work again, and also became so much simplier

* unified query and observe methods

* implict any fix

* Fixed closed subject issue

* removed comment

* Use last returned data for loading state

* WIP: Explore to runRequest makover step1

* Minor progress

* Minor progress on explore and runRequest

* minor progress

* Things are starting to work in explore

* Updated prometheus to use new observable query response, greatly simplified code

* Revert refId change

* Found better solution for key/refId/requestId problem

* use observable with loki

* tests compile

* fix loki query prep

* Explore: correct first response handling

* Refactorings

* Refactoring

* Explore: Fixes LoadingState and GraphResults between runs (#18986)

* Refactor: Adds state to DataQueryResponse

* Fix: Fixes so we do not empty results before new data arrives
Fixes: #17409

* Transformations work

* observable test data

* remove single() from loki promise

* Fixed comment

* Explore: Fixes failing Loki and Prometheus unit tests (#18995)

* Tests: Makes datasource tests work again

* Fix: Fixes loki datasource so highligthing works

* Chore: Runs Prettier

* Fixed query runner tests

* Delay loading state indication to 200ms

* Fixed test

* fixed unit tests

* Clear cached calcs

* Fixed bug getProcesedDataFrames

* Fix the correct test is a better idea

* Fix: Fixes so queries in Explore are only run if Graph/Table is shown (#19000)

* Fix: Fixes so queries in Explore are only run if Graph/Table is shown
Fixes: #18618

* Refactor: Removes unnecessary condition

* PanelData: provide legacy data only when needed  (#19018)

* no legacy

* invert logic... now compiles

* merge getQueryResponseData and getDataRaw

* update comment about query editor

* use single getData() function

* only send legacy when it is used in explore

* pre process rather than post process

* pre process rather than post process

* Minor refactoring

* Add missing tags to test datasource response

* MixedDatasource: Adds query observable pattern to MixedDatasource (#19037)

* start mixed datasource

* Refactor: Refactors into observable parttern

* Tests: Fixes tests

* Tests: Removes console.log

* Refactor: Adds unique requestId
2019-09-12 17:28:46 +02:00
Peter Holmberg
dc0bfb26cf
Fix: Align buttons and label in ToggleButtonGroup (#19036) 2019-09-12 14:42:28 +02:00
Dominik Prokop
c66a23ea31
DataLinksInput - change the way enter key is handled (#18985) 2019-09-12 09:36:57 +02:00
Dominik Prokop
c2dea633e6
Packages: update versioning and release process (#18195) 2019-09-12 08:00:31 +02:00
Torkel Ödegaard
f2ca3abf07
AlphaNotice: replaced big popover tooltip with native tooltip (#18997) 2019-09-11 09:02:17 +02:00
Peter Holmberg
196f8503a8
grafana/ui: Add Time of day picker (#18894)
* Adding DashboardPicker component

* fix prop names

* fix prop names pt2

* add component and modify utils

* add showHour prop

* add minuteStep to TimeOfDayPicker, add value to DashboardPicker

* fix for dashboard picker, missed adding file

* Adding story

* add another story for hiding hour and style fixes

* fix these generated files

* fixes after review

* rename current value

* fix type issue on onChange

* fix story
2019-09-11 09:00:14 +02:00
Ryan McKinley
7520ebadac
Refactor: move ScopedVars to grafana/data (#18992) 2019-09-10 12:06:01 -07:00
Omar Ahmad
ca96d794e2 Units: Adding T,P,E,Z,and Y bytes (#18706)
* Adding T and P for bytes

Luckily, all the hard work was done before; just added in these prefixes for our production environment.

* Future-proofing with other values (why not?)

* Yottaflops?

* Cutting back down to Peta sizes, except for hashes
2019-09-10 20:30:38 +02:00
Ivana Huckova
2c5d1745ca
Explore: Unify background color for fresh logs (#18973) 2019-09-10 11:30:25 +02:00
Andrej Ocenas
0e3e874eee
Annotations: Add annotations support to Loki (#18949) 2019-09-10 11:04:44 +02:00
Ivana Huckova
14a740572d
Explore: UX/UI improvements for pausing and resuming of live tailing (#18931) 2019-09-09 19:09:06 +02:00
Anirudh Ramesh
6968fab437 Units: Add electrical charge - ampere-hour unit 2019-09-09 10:04:35 +02:00
Ryan McKinley
7d32caeac2 Transformers: configure result transformations after query(alpha) (#18740) 2019-09-09 08:58:57 +02:00
Dominik Prokop
5f1bb3947c
Storybook: fix type error (#18934)
* Use window.setTimeout/Interval instead of nodejs versions

* Remove awesome-typescript-loader dependency
2019-09-06 10:23:24 +02:00
Patrick O'Carroll
d21415a936 Sass: changed color in gradient in template files to lower case (#18921) 2019-09-05 21:46:26 +02:00
kay delaney
a838d2b30a
Explore: Adds ability to save a panel's query from Explore (#17982)
* Explore: Adds ability to return to origin dashboard
2019-09-05 13:44:37 +01:00
Torkel Ödegaard
3f0862a7d1
Sass: Align generated file with tmpl (#18896) 2019-09-04 17:40:06 +02:00
Neo
a5d8b0212b Add South African Rand (ZAR) to currencies (#18893)
This change adds formal support for the South African Rand in the list of currencies.
2019-09-04 15:18:19 +02:00
Torkel Ödegaard
490a1d6fc9
ErrorHandling: Error boundary for every container (#18845)
* ErrorHandling: Error boundary for every container

* Remvoe custom query editor errors
2019-09-04 13:59:30 +02:00
Patrick O'Carroll
00c8bf4f2f Styles: fixed gradient in logo so it doesn't go outside the logo and get a defined start and end color, changed brand gradient to be the same as in logo, created new variable for vertical gradient (#18882)
Fixes #18856
2019-09-04 11:28:35 +02:00
Andrej Ocenas
aab224ef29
Explore: elastic small fixes (#18879)
- Fix cancellation error showing in UI
- Fix display of object values in log rows
2019-09-04 10:49:09 +02:00
kay delaney
7985aa1e57
Performance/Webpack: Introduces more aggressive code-splitting and other perf improvements (#18544)
* Performance/Webpack: Introduces more aggressive code-splitting and other perf improvements
- Introduces dynamic imports for built-in plugins
- Uses dynamic imports for various packages (rst2html, brace)
- Introduces route-based dynamic imports
- Splits angular and moment into separate bundles
2019-09-03 09:29:02 +01:00
Torkel Ödegaard
fe658d7ac2
Prometheus: Fixed Prometheus query editor error (plus new ErrorBoundaryAlert component) (#18838)
* ErrorHandling: Fixed Prometheus query editor error and added error boundary

* Update public/app/core/components/ErrorBoundary/ErrorBoundary.tsx

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

* Fixed ts error
2019-09-02 20:45:18 +02:00
Ivana Huckova
29ff8e6018
Explore: Style panel containers (#18834) 2019-09-02 17:19:30 +02:00
Ryan McKinley
c777301535 DataFrame: split DataFrameHelper into MutableDataFrame and FieldCache (#18795)
* add appending utility

* add appending utility

* update comment

* rename to mutable

* move mutable functions out of DataFrameHelper

* move mutable functions out of DataFrameHelper

* move mutable functions out of DataFrameHelper

* turn DataFrameHelper into FieldCache

* guess time from name

* graph the numbers

* return the timeField, not just the index

* just warn on duplicate field names

* only use a parser if the input is a string

* append init all fields to the same length

* typo

* only parse string if value is a string

* DataFrame: test fixes

* Switch to null for missing values

* Fixed tests
2019-09-01 14:44:22 +02:00
Torkel Ödegaard
d9a3601094
Singlestat: Various fixes to singlestat and DataFrame (#18783)
* Singlestat: Various fixes to singlestat and DataFrame

* removed comment
2019-08-29 19:04:33 +02:00
Ryan McKinley
ff6b8c5adc DataLinks: enable data links in Gauge, BarGauge and SingleStat2 panel (#18605)
* datalink on field

* add dataFrame to view

* Use scoped variables to pass series name and value time to data links interpolation

* Use scoped variables to pass series name and value time to data links interpolation

* Enable value specific variable suggestions when Gauge is displaying values

* Fix prettier

* Add basic context menu with data links to GaugePanel

* Fix incorrect import in grafana/ui

* Add custom cursor indicating datalinks available via context menu (in Gauge only now)

* Add data links to SingleStat2

* Minor refactor

* Retrieve data links in a lazy way

* Update test to respect links retrieval being lazy

* delay link creation

* cleanup

* Add origin to LinkModel and introduce field & panel links suppliers

* Add value time and series name field link supplier

* Remove links prop from visualization and implement common UI for data links context menu

* Update snapshot

* Rename className prop to clickTargetClassName

* Simplify condition

* Updated drilldown dashboard and minor changes

* Use class name an onClick handler on the top level dom element in visualization

* Enable series name interpolation when presented value is a calculation
2019-08-28 08:50:43 +02:00
Ryan McKinley
8ce509f3b4
Plugins: show a clear error on the plugin page when it failed to load (#18733) 2019-08-26 23:43:45 -07:00
Hugo Häggmark
e5e7bd3153
Dashboard: Adds Logs Panel (alpha) as visualization option for Dashboards (#18641)
* WIP: intial commit

* Switch: Adds tooltip

* Refactor: Adds props to LogsPanelEditor

* Refactor: Moves LogRowContextProvider to grafana/ui

* Refactor: Moves LogRowContext and Alert to grafana/ui

* Refactor: Moves LogLabelStats to grafana/ui

* Refactor: Moves LogLabels and LogLabel to grafana/ui

* Refactor: Moves LogMessageAnsi and ansicolor to grafana/ui

* Refactor: Moves calculateFieldStats, LogsParsers and getParser to grafana/data

* Refactor: Moves findHighlightChunksInText to grafana/data

* Refactor: Moves LogRow to grafana/ui

* Refactor: Moving ExploreGraphPanel to grafana/ui

* Refactor: Copies Logs to grafana/ui

* Refactor: Moves ToggleButtonGroup to grafana/ui

* Refactor: Adds Logs to LogsPanel

* Refactor: Moves styles to emotion

* Feature: Adds LogsRows

* Refactor: Introduces render limit

* Styles: Moves styles to emotion

* Styles: Moves styles to emotion

* Styles: Moves styles to emotion

* Styles: Moves styles to emotion

* Refactor: Adds sorting to LogsPanelEditor

* Tests: Adds tests for sorting

* Refactor: Changes according to PR comments

* Refactor: Changes according to PR comments

* Refactor: Moves Logs and ExploreGraphPanel out of grafana/ui

* Fix: Shows the Show context label again
2019-08-26 08:11:07 +02:00
Franz Schwartau
8cf5c4dbe9 Units: add counts/sec (cps) and counts/min (cpm) in Throughput (#18702) 2019-08-25 16:23:33 +02:00
Torkel Ödegaard
e50a75f25f
Singlestat/Gauge/BarGauge: Improvements to decimals logic and added test dashboard (#18676)
* Singlevalue: Improvements to decimals logic and added test dashboard

* updated

* Fixed tests
2019-08-23 09:28:12 +02:00
Ryan McKinley
ca778363bf
Streaming: improve JSDocs for DataSourceAPI streaming support (#18672) 2019-08-22 10:00:19 -07:00
Andrej Ocenas
d4382ad906
Add typings to package.json in packages (#18640)
Fixes Go to definition in webstorm
2019-08-22 10:20:17 +02:00
Dominik Prokop
6c34936aee Packages: Fix path import from grafana/data (#18667) 2019-08-21 13:19:11 -07:00
Ryan McKinley
68f7413566
SingleStat: use DataFrame results rather than TimeSeries/TableData (#18580) 2019-08-21 07:56:53 -07:00