Domas
cf64adf156
Alerting: hide private labels, collapse query json by default ( #33284 )
2021-04-23 09:22:41 +03:00
Ryan McKinley
7627b55ef4
TSDB: add deprecation comments to many tsdb structs ( #33281 )
2021-04-23 03:03:11 +02:00
David Parrott
aa5bdff97d
Call server.Shutdown() as go routine ( #33288 )
...
server.Shutdown() blocks trying to write to s.shutdownFinished in some cases when using a test Grafana instance for a series of integration tests.
See https://github.com/grafana/grafana/blob/master/pkg/server/server.go#L222-L224
2021-04-22 13:23:08 -07:00
achatterjee-grafana
463520c03c
Updated label for add panel. ( #33285 )
2021-04-22 14:21:55 -04:00
Ganesh Vernekar
a0e567f80f
AlertingNG: Add Dingding notification channel ( #32995 )
...
Signed-off-by: Ganesh Vernekar <ganeshvern@gmail.com >
2021-04-22 19:30:49 +02:00
Ganesh Vernekar
4ec1edfca3
AlertingNG: Add Teams notification channel ( #32979 )
...
Signed-off-by: Ganesh Vernekar <ganeshvern@gmail.com >
2021-04-22 18:16:26 +02:00
Ganesh Vernekar
c9cd7ea701
AlertingNG: Add Telegram notification channel ( #32795 )
...
Signed-off-by: Ganesh Vernekar <ganeshvern@gmail.com >
2021-04-22 17:24:59 +02:00
Ganesh Vernekar
0a03d5c29e
AlertingNG: Correctly set StartsAt, EndsAt, UpdatedAt after alert reception ( #33109 )
...
Signed-off-by: Ganesh Vernekar <ganeshvern@gmail.com >
2021-04-22 20:42:18 +05:30
Ryan McKinley
e7fd30be17
PanelEdit: update configRev on close ( #33240 )
2021-04-22 07:23:51 -07:00
Ganesh Vernekar
3056f86f76
AlertingNG: Fix TODOs in email notification channel ( #33169 )
...
* AlertingNG: Fix TODOs in email notification channel
Signed-off-by: Ganesh Vernekar <ganeshvern@gmail.com >
* Test fixup
* Remove the receiver field it is not needed for the email notification
Co-authored-by: Josue Abreu <josue@grafana.com >
2021-04-22 10:01:55 -04:00
Arve Knudsen
6408b55a7c
Slack: Use chat.postMessage API by default ( #32511 )
...
* Slack: Use only chat.postMessage API
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
* Slack: Check for response error
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
* Slack: Support custom webhook URL
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
* Simplify
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
* Fix tests
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
* Rewrite tests to use stdlib
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
* Update pkg/services/alerting/notifiers/slack.go
Co-authored-by: Dimitris Sotirakis <sotirakis.dim@gmail.com >
* Clarify URL field name
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
* Fix linting issue
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
* Fix test
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
* Fix up new Slack notifier
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
* Improve tests
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
* Fix lint
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
* Slack: Make token not required
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
* Alerting: Send validation errors back to client
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
* Document how token is required
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
* Make recipient required when using Slack API
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
* Fix field description
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
Co-authored-by: Dimitris Sotirakis <sotirakis.dim@gmail.com >
2021-04-22 16:00:21 +02:00
Uchechukwu Obasi
9774a429b9
creates Themeable v2 type ( #33268 )
2021-04-22 15:45:35 +02:00
Alexander Zobnin
0e020a40a5
Access control: Fix invite endpoint permissions ( #33262 )
2021-04-22 16:15:57 +03:00
Ganesh Vernekar
6cc7a20789
NGAlert: Remove all pending references to the old API package ( #33269 )
...
Signed-off-by: Ganesh Vernekar <ganeshvern@gmail.com >
2021-04-22 18:36:32 +05:30
Erik Sundell
743b77771f
fix dimension name ( #33271 )
2021-04-22 15:02:40 +02:00
kay delaney
57e9b11fda
DashboardQueryRunner: Add dataSupport to PanelModel & PanelPlugin ( #33253 )
...
* DashboardQueryRunner: Add dataSupport to PanelModel & PanelPlugin
Relates to #32834
2021-04-22 11:56:32 +01:00
Alexander Zobnin
dd9f701cd9
Access control: Fix predefined roles ( #33260 )
2021-04-22 12:49:24 +02:00
Torkel Ödegaard
36aeb9b9a1
PanelChrome: Restore previous panel chrome story ( #33258 )
...
* PanelChrome: Restore previous panel chrome story
* Update story name
2021-04-22 12:24:48 +02:00
Alexander Zobnin
a7e721e987
Access control: Make Admin/Users UI working with the permissions ( #33176 )
...
* API: authorize admin/users views
* Render admin/users components based on user's permissions
* Add LDAP permissions (required by admin/user page)
* Extend default admin role by LDAP permissions
* Show/hide LDAP debug views
* Render LDAP debug page if user has access
* Authorize LDAP debug view
* fix permissions definitions
* Add LDAP page permissions
* remove ambiguous permissions check
* Hide logout buttons in sessions table
* Add org/users permissions
* Use org permissions for managing user roles in orgs
* Apply permissions to org/users
* Apply suggestions from review
* Fix tests
* remove scopes from the frontend
* Tweaks according to review
* Handle /invites endpoints
2021-04-22 13:19:41 +03:00
Arve Knudsen
66020b419c
NGAlert: Consolidate on standard errors package ( #33249 )
...
* NGAlert: Don't use pkg/errors
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
* Update pkg/services/ngalert/notifier/alertmanager.go
Co-authored-by: Will Browne <wbrowne@users.noreply.github.com >
* Fix logging
Signed-off-by: Arve Knudsen <arve.knudsen@gmail.com >
Co-authored-by: Will Browne <wbrowne@users.noreply.github.com >
2021-04-22 11:18:25 +02:00
Torkel Ödegaard
0027097772
Overlays: Style tweaks to modal & drawer overlays ( #33251 )
...
* Overlays: Style tweaks to modal & drawer overlays
* style fix
2021-04-22 10:57:10 +02:00
Roman
561fd4162e
Azure Monitor: Add support for Microsoft.SignalRService/SignalR metrics ( #33246 )
...
* Add Microsoft.SignalRService/SignalR to supported namespaces.
For Azure Monitor.
* Add missing comma.
2021-04-22 09:32:42 +02:00
Torkel Ödegaard
44cf2f8efe
Theme: Update theme layering ( #33217 )
...
* Theme: Update theme layering
* More updates
* Updates to shadows and dropdowns
* Moved panel option group to emotion global styles
* more minor fixes
2021-04-22 09:18:32 +02:00
Dimitris Sotirakis
6acb99afde
Bug: Add git to Dockerfile.ubuntu ( #33247 )
...
* Add git to Dockerfile.ubuntu
* Use apt-get
* Add quiet flag
* Update Dockerfile.ubuntu
Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com >
Co-authored-by: Arve Knudsen <arve.knudsen@gmail.com >
2021-04-22 09:11:29 +02:00
Gábor Farkas
7ff6665ac2
Alerting: InfluxDB: InfluxQL: convert backend-code to use dataframes ( #32950 )
...
* alerting: influxdb: refactor unit-tests
* alerting: influxdb: converted code from timeseries-mode to dataframe-mode
* influxdb: simplify code
* influxdb: better function name
* influxdb: alerting: more tests
* influxdb: alerting: more tests
* influxdb: refactor
* influxdb: improved unit-test
* influxdb: simplified code
* influxdb: refactor reponse-parser code
* influxdb: refactor unit tests
* influxdb: alerting: use nicer names
Co-authored-by: dsotirakis <sotirakis.dim@gmail.com >
2021-04-22 08:43:17 +02:00
Diana Payton
8ea1470893
Docs: Update getting-started-influxdb.md ( #33234 )
...
* Update getting-started-influxdb.md
* Merge branch 'master' into oddlittlebird-patch-6
2021-04-21 13:08:34 -07:00
Sofia Papagiannaki
b2288f7ef9
[Alerting]: Add alerting endpoint for Query Evaluation ( #33174 )
...
* [Alerting]: Add alerting endpoint for Query Evaluation
* Fix passing down now parameter
* Add validations and test
* Fix eval queries and expressions test
* Add eval tests
2021-04-21 22:44:50 +03:00
Leon Sorokin
ed3f5e6ca3
Build: drop TS checking from yarn build ( #33235 )
2021-04-21 14:40:51 -05:00
Carrie Crowe
d97e1b685b
Minor Changes in Auditing.md ( #31435 )
...
* Improved glossary
* Minor Changes Test
Co-authored-by: achatterjee-grafana <aparajita.chatterjee@grafana.com >
2021-04-21 15:37:15 -04:00
Tania B
711cf47b41
Docs: Add license check endpoint doc ( #32987 )
...
* Docs: Add license check endpoint doc
* Change request example
Co-authored-by: Emil Tullstedt <emil.tullstedt@grafana.com >
* Change response example
Co-authored-by: Emil Tullstedt <emil.tullstedt@grafana.com >
Co-authored-by: Emil Tullstedt <emil.tullstedt@grafana.com >
Co-authored-by: achatterjee-grafana <aparajita.chatterjee@grafana.com >
2021-04-21 15:31:38 -04:00
gotjosh
de0802cf3b
Alerting: Fixes the integration test currently failing at master ( #33233 )
...
* Alerting: Fixes the integration test currently failing at master
* Skip the state tracker test for now
2021-04-21 14:57:17 -04:00
David Parrott
4be1d84f23
Alerting: Enhancements to /rules ( #33085 )
...
* set processing time
* merge labels and set on response
* use state cache for adding alerts to rules
* minor cleanup
* pr feedback
* Do not initialize mutex unnecessarily
Co-authored-by: Ganesh Vernekar <15064823+codesome@users.noreply.github.com >
* linter
Co-authored-by: Ganesh Vernekar <15064823+codesome@users.noreply.github.com >
2021-04-21 09:30:03 -07:00
ying-jeanne
7480d9e2be
Doc: Document the X-Grafana-Org-Id HTTP header ( #32478 )
...
* Doc: Document the X-Grafana-Org-Id HTTP header
* Update docs/sources/http_api/auth.md
Co-authored-by: achatterjee-grafana <70489351+achatterjee-grafana@users.noreply.github.com >
* update the auth.md with X-Grafana-Org-Id
* remove empty line
* Update docs/sources/http_api/auth.md
* Update docs/sources/http_api/auth.md
Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com >
Co-authored-by: achatterjee-grafana <70489351+achatterjee-grafana@users.noreply.github.com >
Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com >
2021-04-21 18:24:56 +02:00
Uchechukwu Obasi
438b403acc
Migrates old Card sass file to GlobalStyles ( #33183 )
...
* Card: migrates styles from sass to emotion
* removed LayoutSelector component since it's not used in the codebase
* updates card styles with new color name
2021-04-21 16:39:56 +02:00
Sofia Papagiannaki
87a70af7eb
[Alerting]: Fix updating rule group and add tests ( #33074 )
...
* [Alerting]: Fix updating rule group and add test
* Fix updating rule labels
* Set default values for rule no data and error states
if they are missing
* Add test for updating rule
* Test updating annotations
* Apply suggestions from code review
Co-authored-by: gotjosh <josue@grafana.com >
* add test for posting an unknown rule UID
* Fix alert rule validation and add tests
* Remove org id from PostableGrafanaRule
This field was not used; each rule gets the organisation of the user making
the rerquest
* Update pkg/tests/api/alerting/api_alertmanager_test.go
Co-authored-by: gotjosh <josue@grafana.com >
2021-04-21 17:22:58 +03:00
Torkel Ödegaard
b929822d72
Theme: Renames theme.palette to theme.colors ( #33214 )
...
* Theme: Rename theme.palette to theme.colors
* renaming files
2021-04-21 15:34:08 +02:00
Will Browne
c37a3bebb7
Plugins: Serve static assets directly instead of through middleware handler ( #32779 )
...
* removed static routes from macaron
* move path src to plugins pkg
* use plugin details
* remove dead code
* fixes
* use clean from std lib
* reformat imports
* remove caching headers + add security checks
* revert using no cache header middleware
* add cache-control headers
* add 404 check
* use new var for subsequent file handling
2021-04-21 15:17:23 +02:00
Torkel Ödegaard
7e2bf4f6c3
Theming: Make new theme exposed by ThemeContext and make new theme include v1 for compatability (to pass to useTheme) ( #33207 )
...
* WIP: Making new theme the default
* Progress
* Updates, lots of updates
* Things are working
* Fixed issues with storybook
* Fixed tests
2021-04-21 14:25:43 +02:00
Peter Holmberg
569fb3f112
Alerting: adding query editor when creating threshold rule. ( #33123 )
...
* fix viz
* add datasource picker on query rows in mixed mode
* add timerange, handle add/remove queryrunners
* multiqueryrunner test
* trying things out.
* adding another test to verify running a induvidual query runner will update multirunner.
* cleaned up tests a bit.
* draft version working ok.
* fixing so we base the refId from request targets.
* reenable adding expression
* layout fixes for alerting page
* some cleanup
* cleaning up code that we won't use
* changed so we don't display the time range if params not passed.
* remove unused things in querygroup
* changed button to type button.
* removed timerange from dataQuery and removed multiquery runner.
* minor refactoring.
* renamed callback function to make it more clear what it does.
* renamed droppable area.
* changed so we only display the query editor when selecting threshold.
* removed the refresh picker.
* revert
* wip
* extending with data query.
* timerange fixes
* it is now possible to add grafana queries.
* removed unused type.
* removed expect import.
* added docs.
* moved range converting methods to rangeUtil.
* clean up some typings, remove file
* making sure we don't blow up on component being unmounted.
Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com >
2021-04-21 13:57:17 +02:00
gamab
a151dfaa04
ProvisioningService: Change the ProvisioningService interface for easier extension ( #32910 )
...
* Made a public constructor in order to instantiate it from the service override
* Removed unused plugins.DataRequestHandler
* Added a Run and RunInitProvisioners methods that can be run from Enterprise
* Adding a mock for Run and RunInitProvisioners as well
2021-04-21 13:41:34 +02:00
Uchechukwu Obasi
63e2977837
DashboardPanel: migrates styling from sass to emotion ( #33115 )
...
* DashboardPanel: migrates styling from sass to emotion
* fixes frontend test
* removed the theme since it doesn't have any use case in the styles
* updates frontend snapshot test
2021-04-21 12:24:44 +01:00
Marcus Efraimsson
dd0ba96d7c
Postgres: Fix time group macro when TimescaleDB is enabled and interval is less than a second ( #33153 )
...
Fixing a special case with time group macro when
using TimescaleDB and interval is lower than a second.
Fixes #33124
2021-04-21 12:54:49 +02:00
gotjosh
23c7e7ab60
Alerting: Various fixes for the alerts endpoint ( #33182 )
...
A set of fixes for the GET alert and groups endpoints.
- First, is the fact that the default values where not being for the query params. I've introduced a new method in the Grafana context that allow us to do this.
- Second, is the fact that alerts were never being transitioned to active. To my surprise this is actually done by the inhibitor in the pipeline - if an alert is not muted, or inhibited then it's active.
- Third, I have added an integration test to cover for regressions.
Signed-off-by: Josue Abreu <josue@grafana.com >
2021-04-21 06:34:42 -04:00
Ivana Huckova
1c838f5872
Explore: Add more meta information when line limit is hit ( #33069 )
...
* WIP: Add more info ro log line limit, remove redundant info
* Refactor
* Clean up
* Adjust tests
* Adjust spacing
* Add test for new functionality
* Update snapshot
* Change solution, simplify
* Remove redundant variables, makees it more clear
* Update public/app/core/logs_model.ts
Co-authored-by: Piotr Jamróz <pm.jamroz@gmail.com >
Co-authored-by: Piotr Jamróz <pm.jamroz@gmail.com >
2021-04-21 12:02:34 +02:00
Josh Hunt
0463164f8c
Grafana-UI: Type onEditorDidMount ( #33178 )
2021-04-21 11:16:54 +02:00
Dafydd
0dcd0281ab
Chore: avoid hard-coding IDs in integration tests ( #33152 )
...
* use dynamic user Ids in test
* use dynamic IDs in alert tests
* use dynamic IDs in dashboard test queries
* use dynamic IDs in org test queries
2021-04-21 11:22:46 +03:00
dependabot[bot]
2cd6c0565b
Chore(deps): Bump react-dev-utils from 10.2.1 to 11.0.4 ( #31932 )
...
Bumps [react-dev-utils](https://github.com/facebook/create-react-app/tree/HEAD/packages/react-dev-utils ) from 10.2.1 to 11.0.4.
- [Release notes](https://github.com/facebook/create-react-app/releases )
- [Changelog](https://github.com/facebook/create-react-app/blob/master/CHANGELOG-1.x.md )
- [Commits](https://github.com/facebook/create-react-app/commits/HEAD/packages/react-dev-utils )
Signed-off-by: dependabot[bot] <support@github.com >
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2021-04-21 10:07:42 +02:00
Torkel Ödegaard
dc6d134276
Storybook: Fixes theming of the padded story (that makes stories use primary background by default) ( #33166 )
2021-04-21 09:45:12 +02:00
kay delaney
bad048b7ba
Performance: Standardize lodash imports to use destructured members ( #33040 )
...
* Performance: Standardize lodash imports to use destructured members
Changes lodash imports of the form `import x from 'lodash/x'` to
`import { x } from 'lodash'` to reduce bundle size.
* Remove unnecessary _ import from Graph component
* Enforce lodash import style
* Fix remaining lodash imports
2021-04-21 09:38:00 +02:00
Torkel Ödegaard
2bb7eb18d1
PanelEdit: Fixes showIf for panel level options, fixes configRev when switching panels ( #33173 )
2021-04-20 21:22:58 +02:00