* Refactor: initial commit
* Tests: updates tests
* Tests: updates snapshots
* Chore: updates after PR comments
* Chore: renamed initVariablesBatch
* Tests: adds transactionReducer tests
* Chore: updates after PR comments
* Refactor: renames cancelAllDataSourceRequests
* Refactor: reduces cancellation complexity
* Tests: adds tests for cancelAllInFlightRequests
* Tests: adds initVariablesTransaction tests
* Tests: adds tests for cleanUpVariables and cancelVariables
* Always cleanup dashboard on unmount, even if init is in progress. Check if init phase has changed after services init is completed
* fixed failing tests and added some more to test new scenario.
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>
* Update CHANGELOG.md
* updated according to feedback.
* Update CHANGELOG.md
Co-authored-by: Sofia Papagiannaki <papagian@users.noreply.github.com>
Co-authored-by: Sofia Papagiannaki <papagian@users.noreply.github.com>
* uses plugin-sdk-go v0.66.0, which adds adds the ExecutedQueryString property to FrameMeta and changes s/Title/DisplayName in FieldConfig
* go mod tidy
* Updated templating code to support the $__user variable to expose the current
userid, username, email and login.
Fixed the $__org variable as it was returning the user id instead of the ordId.
Updated the documentation to match
* Updated solution to retrieving $__user variables to pull directly from user record (thereby allowing future access to properties that
might not exist in the contextSvr).
Replicated this initialisation in the variables feature
Corrected typo's in documentation.
* Repaired typecheck issues.
* Updated patch to pull entirely from contextSrv without API calls.
* ... And removed the redundant comments.
* Updated documentation.
note: This is just Azure Monitor within the Azure Monitor datasource (not insights, insights analytics, or log analytics yet).
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
* added tests to verify flow.
* refactoring picker reducer.
* made all the tests green.
* removed console.log's
* fixed toggle all and making sure the correct values are set on picker open.
* added more tets.
* refactored and added table tests.
* fixed so we select values from selectedValues instead of options.
* fixed so you can navigate and select even after you have filtered a variable.
* adding tests to verify flows when toggling by highlight.
* fixed so enter always selects value before closing.
* improved the code for tags.
* Cleanup
* addPanel now supports (optional) custom dashboardUid
* addPanel now supports (optional) visualization name
* Added CLI option for updating screenshot fixtures
* Added support for console.* functions within tests
* Refactored screenshot command for greater simplicity
* addPanel now sets a unique title
* Updated lockfile
* Fix Loki and Prometheus query fields on mobile devices
* Add min widt to Elasticsearch Query Field
* Remove width for Elastic, works nicely without updating it
* Update public/app/plugins/datasource/loki/components/LokiQueryFieldForm.tsx
Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
* Logs: Use result range instead of timepicker range for log histogram
If a logs datasource does not send histogram data for the requested
time range, the logs model computes a timeseries based on the log row
counts, bucketed by an automcatically calculated time interval. Even
when this histogram time series did not span the whole requested time
range it was still rendered in the graph across the whole range, leaving
an empty area at its start. Users find this confusing and are lead to
believe their log data is missing.
This change fixes this by anchoring the start of the timeseries on the
first log row's timestamp from the result, and adds this smaller range
as `visibleRange` to the logs model and passes it through to the logs
component that optionally takes it into account to not render the empty
area.
The interval (bucket size) is also adjusted to account for a potentially
finer resolution on the shorter visible time interval.
The bucketsize multiplier was also changed from 10 to 20 to account for
the space between the chart's bars.
* Aligned visible range with buckets
* Extract bucket size calculation and add test
Fixes so that ini-sections containing hyphen is replaced with
underscore. Fixes an issue with backend plugin settings.
Ref grafana/grafana-image-renderer#147