Compare commits

..

4458 Commits

Author SHA1 Message Date
Horst Gutmann
d24c8aa315 [v9.4.x] Chore: Upgrade Go to 1.20.10 (#76370)
Chore: Upgrade Go to 1.20.10 (#76355)

* [v10.1.x] Chore: Upgrade Go to 1.20.10

* Rebuild .drone.yml

(cherry picked from commit 4287686420)
2023-10-11 18:05:32 +02:00
Dimitris Sotirakis
f7685bafec Bug: Exclude 32-bit arm builds (#75448)
* Exclude 32 bit arm builds

* Bump grabpl - remove arm/v7 from build.star
2023-10-11 09:47:06 +02:00
Horst Gutmann
ddcd6dad88 [v9.4.x] Building: Remove dependency to urw-fonts in RPM packages (#76223)
Building: Remove dependency to urw-fonts in RPM packages (#76198)

(cherry picked from commit 1355660313)
2023-10-11 09:43:52 +02:00
grafana-delivery-bot[bot]
3e90f6e1d5 Release: Bump version to 9.4.17 (#55)
Co-authored-by: grafana-delivery-bot[bot] <132647405+grafana-delivery-bot[bot]@users.noreply.github.com>
2023-10-11 09:42:19 +02:00
grafana-delivery-bot[bot]
a5a8208b2d Release: Bump version to 9.4.16 (#75050)
"Release: Updated versions in package to 9.4.16"

Co-authored-by: grafana-delivery-bot[bot] <132647405+grafana-delivery-bot[bot]@users.noreply.github.com>
2023-09-19 08:53:45 +03:00
Horst Gutmann
b6d733e755 [v9.4.x] Changelog: Updated changelog for 9.4.15 (#75051)
Changelog: Updated changelog for 9.4.15 (#75049)

Co-authored-by: grafanabot <bot@grafana.com>
(cherry picked from commit bc02197f06)

Co-authored-by: grafana-delivery-bot[bot] <132647405+grafana-delivery-bot[bot]@users.noreply.github.com>
2023-09-19 06:52:35 +01:00
Horst Gutmann
78ec819807 [v9.4.x] Chore: Upgrade Alpine base image to 3.18.3 (#74996)
Chore: Upgrade Alpine base image to 3.18.3 (#74984)

(cherry picked from commit 85abf2bebd)
2023-09-18 13:28:43 +03:00
Horst Gutmann
0ceb86a4c4 [v9.4.x] Chore: Upgrade Go to 1.20.8 (#74981)
Chore: Upgrade Go to 1.20.8 (#74978)

chore: Update to Go 1.20.8
(cherry picked from commit 39dbd98458)
2023-09-18 11:48:43 +03:00
Yuri Tseretyan
6d1747ff16 [v9.4.x] SSE: Fix DSNode to not panic when response has empty response (#74870)
Fix DSNode to not panic when response has empty response (#74866)
2023-09-13 15:17:07 -04:00
grafana-delivery-bot[bot]
d442068cdc [v9.4.x] Alerting docs: adds roll back warning to config grafana (#74828)
Alerting docs: adds roll back warning to config grafana (#74785)

(cherry picked from commit 38c3483594)

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
2023-09-13 15:35:54 +03:00
Josh Hunt
a86847aff2 [v9.4.x] BrowseDashboards: Only remember the most recent expanded folder (#74812)
BrowseDashboards: Only remember the most recent expanded folder (#74617)

* BrowseDashboards: Only remember the most recent expanded folder

* set to null

* cleanup

* only clear removed folder if it was the most recently opened

* comments + variable

(cherry picked from commit 5cb7eb5884)
2023-09-13 10:55:53 +00:00
grafana-delivery-bot[bot]
ff961d322e [v9.4.x] Fix absolute aliases in contact points page (#74803)
Fix absolute aliases in contact points page (#74672)

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
(cherry picked from commit 5ff999bdae)

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
2023-09-13 10:40:22 +01:00
Dimitris Sotirakis
d868da883e [v9.4.x] Chore: Remove unused secret enterprise2-cdn-path - Nightlies: Push windows artifacts to GCS on main builds (#74789)
* Nightlies: Push windows artifacts to GCS on main builds (#74709)

* Push windows artifacts to gcs

* Lint starlark

* Sign drone

(cherry picked from commit 02f617a20d)

# Conflicts:
#	.drone.yml

* Chore: Remove unused secret `enterprise2-cdn-path` (#74741)

Remove unused secret

# Conflicts:
#	.drone.yml

(cherry picked from commit 49165d35ad)

# Conflicts:
#	.drone.yml
2023-09-13 10:19:24 +02:00
Dimitris Sotirakis
a55a38d191 [v9.4.x] Nightlies: Bring back windows installers for main builds (#74705)
Bring back windows installers for main builds (#74698)

(cherry picked from commit 36728dd671)

# Conflicts:
#	.drone.yml
2023-09-12 12:00:50 +03:00
Ieva
c37cebb26f [v9.4.x] Search: Improvements for starred dashboard search (#74662)
* fix merge conflicts

* fix test
2023-09-11 16:54:51 +03:00
ismail simsek
aa758499ea [v9.4.x] Prometheus: Handle the response with different field key order (#74623)
Prometheus: Handle the response with different field key order (#74567)

* Handle the response with different field key order

* More unit tests to cover edge cases

* Cover more edge cases

* make it simpler

* Better test inputs

(cherry picked from commit 3107459e57)
2023-09-11 13:41:29 +02:00
Yuri Tseretyan
82ac2432d4 SSE: DSNode to update result with names to make each value identifiable by labels (only Graphite and TestData) (#74615)
SSE: DSNode to update result with names to make each value identifiable by labels (only Graphite and TestData) (#73642)

* SSE: DSNode to update result with names to make each value identifiable by labels (only Graphite and TestData) (#71246)

* introduce a function checkIfSeriesNeedToBeFixed to scan all value fields in the response and provide a function that updates Series so they can be uniquely identifiable. Only Graphite and TestData are checked.

* update `DSNode.Execute` to run this function and provide it to WideToMany
* update WideToMany to run the fix function if it is not nil
2023-09-08 15:04:24 -04:00
grafana-delivery-bot[bot]
0f6c2b6954 [v9.4.x] SQL Datasources: Fix variable throwing error if query returns no data (#74609)
SQL Datasources: Fix variable throwing error if query returns no data (#65937)

* Fix SQL query variable throwing error if query returns no data

* Tests to verify that metricFindQuery returns properly and doesn't throw error

* Fix all codepaths that might throw errors because of undefined backendSrv response

(cherry picked from commit 02a8bc76d2)

Co-authored-by: Victor Marin <36818606+mdvictor@users.noreply.github.com>
2023-09-08 18:06:45 +03:00
Julien Duchesne
56a1bf85ea [v9.4.x] CI: Get Github Token and Docker username/password from Vault (#74570)
CI: Get Github Token and Docker username/password from Vault (#74555)

CI: Get Docker username/password from Vault
Not Drone secrets

(cherry picked from commit 566215c22c)
2023-09-08 08:31:35 +03:00
Horst Gutmann
b887f7eca6 [v9.4.x] CI: Run auto-milestone workflow also on reopened pull-requests (#74524)
CI: Run auto-milestone workflow also on reopened pull-requests (#74390)

(cherry picked from commit 94c9bee181)
2023-09-07 14:40:23 +03:00
grafana-delivery-bot[bot]
cc532753be [v9.4.x] Documentation linting on library_element docs (#74481)
Documentation linting on library_element docs (#74407)

* vale lint documentation changes

* run prettier

---------

Co-authored-by: unknown <antonio.caleromerello@grafana.com>
(cherry picked from commit b0715816d8)

Co-authored-by: David Allen <david.allen@grafana.com>
2023-09-06 22:30:41 +02:00
Christopher Moyer
0eb06914bd Docs: updates relref (#74413)
* updates relref

* Update docs/sources/setup-grafana/installation/redhat-rhel-fedora/index.md

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>

---------

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
2023-09-06 08:49:37 -05:00
Horst Gutmann
8562a9732c [v9.4.x] Changelog: Updated changelog for 9.4.14 (#74369)
Changelog: Updated changelog for 9.4.14 (#74367)

Co-authored-by: grafanabot <bot@grafana.com>
(cherry picked from commit c8c9b6b767)

Co-authored-by: grafana-delivery-bot[bot] <132647405+grafana-delivery-bot[bot]@users.noreply.github.com>
2023-09-05 15:11:22 +03:00
grafana-delivery-bot[bot]
7911bfe2d0 Release: Bump version to 9.4.15 (#74370)
"Release: Updated versions in package to 9.4.15"

Co-authored-by: grafana-delivery-bot[bot] <132647405+grafana-delivery-bot[bot]@users.noreply.github.com>
2023-09-05 14:18:43 +03:00
Gabriel MABILLE
49d3cf745f [v9.4.x] LDAP: Fix user disabling (#74318)
* [LDAP] Disable removed users on login (#74016)

* manual backport of #74016 on legacy code

* LDAP: Fix active sync with large quantities of users (#73834)

* Fix authenticate user test
2023-09-04 16:14:20 +02:00
grafana-delivery-bot[bot]
1e00f2e0ab [v9.4.x] Docs: Fix broken link (#74185)
Docs: Fix broken link (#74141)

* Replaced partial URL with relref

* Changed link path

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>

---------

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
(cherry picked from commit a45d292bf6)

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
2023-08-31 13:29:46 -04:00
Jack Baldry
ac29b6662d [v9.4.x] Update docs/shared shortcode usage to use keyword argument interface (#73765)
* Update all use of docs/shared in Grafana to use keyword arguments

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Add version inference to remaining Grafana docs/shared usage

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

---------

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2023-08-31 11:06:43 +01:00
grafana-delivery-bot[bot]
fa6ddc2fba [v9.4.x] Update make docs procedure (#74158)
Update `make docs` procedure (#74152)

Co-authored-by: grafanabot <bot@grafana.com>
(cherry picked from commit 485f07cb7d)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-08-31 10:20:55 +01:00
grafana-delivery-bot[bot]
e04c22c3b7 [v9.4.x] Docker: Add musl as a ubuntu dependency (#74130)
Docker: Add musl as a ubuntu dependency (#74127)

Add musl as a ubuntu dependency

(cherry picked from commit 364ca3daa0)

Co-authored-by: Kevin Minehart <kmineh0151@gmail.com>
2023-08-30 22:02:54 +03:00
grafana-delivery-bot[bot]
b0e2eae439 [v9.4.x] Add LICENSE file to generated Docker images (#74099)
Add LICENSE file to generated Docker images (#74082)

(cherry picked from commit 6277c04caf)

Co-authored-by: Horst Gutmann <horst.gutmann@grafana.com>
2023-08-30 14:37:35 +03:00
Dimitris Sotirakis
01466f0fd9 [v9.4.x] CI: Mount /root/.docker/ dir in authenticate-gcr step (#74076)
CI: Mount /root/.docker/ dir in authenticate-gcr step  (#73977)

Mount /root/.docker/ dir

(cherry picked from commit eea4adea29)

# Conflicts:
#	.drone.yml
2023-08-30 11:15:02 +03:00
Guilherme Caulada
b68e5715e8 [v9.4.x] CI: Use new release eng managed grafanacom api key (#74032)
CI: Use new release eng managed grafanacom api key (#74017)

Use new release eng managed grafanacom api key

(cherry picked from commit ab7e655737)
2023-08-29 12:07:39 -03:00
Dimitris Sotirakis
bd1c66f220 [v9.4.x] Security: Authenticate to GCR for trivy scans (#73926)
Security: Authenticate to GCR for trivy scans (#72658)

* Authenticate to GCR for trivy scans

# Conflicts:
#	.drone.yml

* verify-starlark

* Change secret

# Conflicts:
#	.drone.yml

(cherry picked from commit e100fc927e)

# Conflicts:
#	.drone.yml
#	scripts/drone/vault.star
2023-08-28 16:00:24 +03:00
Dimitris Sotirakis
9aeb1db384 [v9.4.x] CI: Update secrets for publishing steps (#73663)
CI: Update secrets for publishing steps (#73658)

Update secrets

(cherry picked from commit de118a3736)

# Conflicts:
#	.drone.yml
2023-08-23 11:41:49 +03:00
Horst Gutmann
d1485fed57 [v9.4.x] CI: Different secret for verification and do not ignore build failures (#73618)
CI: Different secret for verification and do not ignore build failures (#73613)

(cherry picked from commit 8fc3be6b5a)
2023-08-22 16:34:04 +03:00
grafana-delivery-bot[bot]
135c74bd95 [v9.4.x] Update make docs procedure (#73544)
Update `make docs` procedure (#73540)

Co-authored-by: grafanabot <bot@grafana.com>
(cherry picked from commit 88d3f27b6b)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-08-21 09:18:44 +01:00
grafana-delivery-bot[bot]
b347249fa9 [v9.4.x] CI: Improve error handling in gcloud copy operations (#73536)
CI: Improve error handling in gcloud copy operations (#73474)

(cherry picked from commit 220ea869be)

Co-authored-by: Horst Gutmann <horst.gutmann@grafana.com>
2023-08-21 09:26:20 +03:00
grafana-delivery-bot[bot]
56ad16ffc4 [v9.4.x] Sync-mirror GHA updates (#73508)
Sync-mirror GHA updates (#73504)

fixing sync-mirror run-name and altering concurrency to use branch name

(cherry picked from commit 4047cdb213)

Co-authored-by: Ricky Whitaker <ricky.whitaker@grafana.com>
2023-08-18 12:47:24 -05:00
Horst Gutmann
7165da76cb [v9.4.x] CI: Move npm token to Vault (#73457)
CI: Move npm token to Vault (#73407)

(cherry picked from commit c86a73c794)
2023-08-18 09:00:08 +03:00
grafana-delivery-bot[bot]
c583fc795e [v9.4.x] Docs: Update dashboards api create/update (#73417)
Docs: Update dashboards api create/update (#73345)

(cherry picked from commit bb3a2d31d7)

Co-authored-by: Ezequiel Victorero <ezequiel.victorero@grafana.com>
2023-08-17 12:35:58 -05:00
grafana-delivery-bot[bot]
d7ba054f30 [v9.4.x] Update make docs procedure (#73386)
Update `make docs` procedure (#73359)

Co-authored-by: grafanabot <bot@grafana.com>
(cherry picked from commit 355917e755)

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-08-17 15:48:38 +01:00
Dimitris Sotirakis
67c5afb44b [v9.4.x] CI: Update grabpl to v3.0.41 (#73373) (#73376)
CI: Update `grabpl` to `v3.0.41` (#73373)

Update grabpl

(cherry picked from commit 3463dc8e48)

# Conflicts:
#	.drone.yml
2023-08-17 13:08:42 +03:00
grafana-delivery-bot[bot]
a9bae1ad62 [v9.4.x] Grafana versioning: Remove pre suffix from Grafana version (#73364)
Grafana versioning: Remove `pre` suffix from Grafana version (#73357)

* Remove pre suffix from version

* Fix tests

(cherry picked from commit 0aba319ea0)

Co-authored-by: Dimitris Sotirakis <dimitrios.sotirakis@grafana.com>
2023-08-17 11:29:10 +03:00
grafana-delivery-bot[bot]
e0806338ab [v9.4.x] docs: add default value workaround (#73001)
docs: add default value workaround (#72545)

* Update _index.md

Fixes #https://github.com/grafana/support-escalations/issues/6376

Variables : Added Default values

* Update docs/sources/dashboards/variables/_index.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Ran prettier to resolve build errors

---------

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
Co-authored-by: Isabel Matwawana <isabel.matwawana@grafana.com>
Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
(cherry picked from commit 54f0de313f)

Co-authored-by: arunkg2787 <131352769+arunkg2787@users.noreply.github.com>
2023-08-07 12:49:12 -04:00
Christopher Moyer
257a489d38 [Docs 9.4x] - Manual backport, Clarify necessary rediss scheme for TLS with redis caching (#72122) (#72647)
Clarify necessary rediss scheme for TLS with redis caching (#72122)

Update index.md

To enable TLS with Redis you must use the `rediss` scheme, not the `redis` scheme. This is documented here: https://www.iana.org/assignments/uri-schemes/prov/rediss

(cherry picked from commit e03303997a)

Co-authored-by: chrisharbro <102977229+chrisharbro@users.noreply.github.com>
2023-07-31 15:13:38 -05:00
Christopher Moyer
14ca449530 [Docs v9.4x] Manual backport - Update _index.md (#72068) (#72195)
* Update _index.md (#72068)

* Update _index.md

Edits to the "Set up image rendering" doc.

1. First section, "Set up Image Rendering," last paragraph:
"You can also render a PNG by clicking hovering..." -- I removed "clicking" from that sentence.

2. "Alerting and Render Limits" section, link for "concurrent_render_limit" takes you to the page but not the section. This seems to be the case for all section links on this "Configure Grafana" page. I'm not sure how to fix it but switched from a relative link to a full path to see if that would help.

3. "Install Grafana Image Renderer Plugin," the link goes to the plugin overview page instead of the installation page. I tried adding the full path to see if that would go to the installation tab.

4. "Configuration" section, the same as the second edit I made, the first link, "Grafana configuration file," goes to the page but not the section link. I switched the relative path to a full path to see if it would work.

5. "Security" section, the very last sentence has the same Grafana configuration page link that goes to the correct page but not the correct section, "Grafana configuration" for the renderer token section. Same as previous ones, I switched out the relative path for the full path.

6. "Start browser with additional arguments," the second link in the first paragraph that goes to Puppeteer list of Chromium flags went to a 404 page. I couldn't figure out where they had moved it so I found a different site with a list of default flags and used that link instead.

* corrects links

* updates links

* fixes anchor link

---------

Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
(cherry picked from commit b88a321ad2)

* Apply suggestions from code review

---------

Co-authored-by: Eva <ebuchala@gmail.com>
2023-07-31 12:06:57 -07:00
Ieva
8aa4245fe4 [v9.4.x] Docs: remove references to groups_attribute_path for Okta and GitLab docs (#72591)
Docs: remove references to `groups_attribute_path` for Okta and GitLab docs (#72588)

remove references to groups_attribute_path for Okta and GitLab

(cherry picked from commit b96d6e2c8d)
2023-07-31 13:09:31 +02:00
Guilherme Caulada
abd2ccc250 [v9.4.x] CI: Update secret refs to vault ones; update downstream repo origin (#72547)
CI: Update secret refs to vault ones; update downstream repo origin (#72515)

Update secret refs to vault ones; update downstream repo origin

(cherry picked from commit 6669d0a704)

Co-authored-by: Kevin Minehart <kmineh0151@gmail.com>
2023-07-28 16:00:23 -03:00
Kevin Minehart
b8120d421d [v9.4.x] CI: Make RGM the main pipeline for prerelease (#72530)
CI: Make RGM the main pipeline for prerelease (#72295)

* Make RGM the main pipeline for prerelease

* Use grafana/grafana-build:dev-bd41660

* Use grafana/grafana-build:dev-fda506a

* Fix destination url

* Update vault secrets

* Move bucket path to environment

* Use grafana/grafana-build:dev-2f36afa

* Revert to grafana/grafana-build:main

* Add repo to rgm_main trigger

(cherry picked from commit 971f5f14be)

Co-authored-by: Guilherme Caulada <guilherme.caulada@grafana.com>
2023-07-28 12:31:10 -03:00
Kevin Minehart
4201e7faea [v9.4.x] CI: use base64 key in windows installer build step (#72452)
CI: use base64 key in windows installer build step (#72413)

use base64 key

(cherry picked from commit b019ef9a89)
2023-07-27 16:29:58 +03:00
Dimitris Sotirakis
9203d5b116 [v9.4.x] CI: Fix deb/rpm bug for linux package publishing (#72422)
CI: Fix `deb/rpm` bug for linux package publishing (#72336)

Fix deb/rpm

(cherry picked from commit c3ebd388e3)
(cherry picked from commit 4c9bdef98dcfb24d8d24dac8117c9d3feb921a06)

# Conflicts:
#	.drone.yml
(cherry picked from commit e3ec53b418)

# Conflicts:
#	.drone.yml
2023-07-27 09:58:24 +03:00
Kevin Minehart
d5d838eaa1 [v9.4.x] CI: use the base64 key in the windows installer steps (#72379)
CI: use the base64 key in the windows installer steps (#72372)

use the base64 key in the windows installer steps

(cherry picked from commit 0c2b2219bb)
2023-07-26 12:04:00 -03:00
grafana-delivery-bot[bot]
549387b831 [v9.4.x] Prometheus: Add present_over_time syntax highlighting (#72366)
Prometheus: Add present_over_time syntax highlighting (#72283)

add prometheus present_over_time syntax highlighting

to color present_over_time keyword for prometheus

(cherry picked from commit d96067985b)

Co-authored-by: stratomonitor <arnaud_lemaignen@yahoo.com>
2023-07-26 08:41:26 -05:00
Ieva
c8687a78ff [v9.4.x] Docs: update GitLab OAuth2 documentation (#72343)
* backport

* linting
2023-07-26 11:06:45 +00:00
Guilherme Caulada
f35d160b67 [v9.4.x] CI: Fix verify-prerelease-assets pipeline (#72230)
CI: Fix verify-prerelease-assets pipeline (#72226)

* Fix verify-prerelease-assets pipeline

* Comment out unused assets

(cherry picked from commit 142cbc2ec6)
2023-07-25 00:56:54 +03:00
Christopher Moyer
7e71245181 [Docs v9.4x]: Manual backport, adds link to HA docs Update _index.md (#71400) (#72136)
Update _index.md (#71400)

* Update _index.md

Added missing hyperlink for high availability and a small typo

* updates link

---------

Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
(cherry picked from commit 4e50115d95)

Co-authored-by: Usman Ahmad <usman.ahmad@grafana.com>
2023-07-24 10:43:23 -04:00
Kevin Minehart
41c04aecbb [v9.4.x] CI: Run only Grafana builds on RGM for grafana/grafana (#72159)
* CI: Try setting the vault secret for 'grafana_api_key' (#71981)

* Try setting the vault secret

* Maybe?

* forgot .drone.yml

* CI: Use GCP keys in vault and not drone secrets (#72023)

* CI: Run only Grafana builds on RGM for grafana/grafana (#72144)

* Run only OSS builds on RGM for grafana/grafana

* Update script name

* Ignore windows step failure for RGM

---------

Co-authored-by: Guilherme Caulada <guilherme.caulada@grafana.com>
2023-07-21 18:27:36 -03:00
grafana-delivery-bot[bot]
e925841872 [v9.4.x] docs: fix broken link (#72154)
docs: fix broken link (#72114)

(cherry picked from commit 0589060041)

Co-authored-by: David Harris <david.harris@grafana.com>
2023-07-21 16:56:16 -04:00
grafana-delivery-bot[bot]
3c987bd8c4 [v9.4.x] Docs: adds mimir and oncall (#72047)
Docs: adds mimir and oncall (#72042)

adds mimir and oncall

(cherry picked from commit 46c49aa7ff)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-07-20 12:09:58 -05:00
lwandz13
64307da9ea Docs: add alias to data sources index file 9.4 (#71985)
added features alias to front matter
2023-07-20 09:34:15 -05:00
grafana-delivery-bot[bot]
95a61e652a [v9.4.x] AuthNZ documentation revamp (#71967)
AuthNZ documentation revamp (#62581)

* init for base branch

* Add authnz code ownership

* Fix docs ownsership path

* docs revamp: Plan IAM strategy (#62582)

* Add planning page

* Add teams definition

* Expand on planning and benefits

* Add reasons to organize users

* Add description of User Teams

* Add Grafana organizations info

* Add a section between Teams and Orgs

* Add a section for external systems

* planning your role strategy

* Add service account documentation

* Add Auth Setup to index sidebar

* Address PR comments

* Add planning for API keys

* Add team and org sync

* Docs: role and permission section for planning docs (#64702)

* docs revamp: Service accounts (#63710)

* docs revamp: Add new documentation to sidebar index (#66104)

* docs revamp: synchronisation planning (#66409)

* Docs: api keys (#64803)

* Remove personal access tokens section

* Move auth integration planning page

* Remove auth folder

* Restore codeowners file

* reword and update info on user management and grouping

* Rename iam strategy page

* extend the section on teams and organizations

* Rename planning your IAM section

* Move to administration section

* Add definition for role sync

* Relocate planning

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
(cherry picked from commit 63346674e6)

Co-authored-by: linoman <2051016+linoman@users.noreply.github.com>
2023-07-19 16:17:55 -05:00
Guilherme Caulada
32830edc60 [v9.4.x] CI: Allow RGM to create msi for multiple editions (#71892)
CI: Allow RGM to create msi for multiple editions (#71883)

* Allow RGM to create msi for multiple editions

* Remove suffix from build-windows-installer step

* Invert exit code on verify_release_pipeline

(cherry picked from commit 4c80bcf35f)
2023-07-19 13:35:16 -03:00
Isabel
97aabc8497 [v9.4.x] docs: add docker commands for enabling alpha layers (#71963)
docs: add docker commands for enabling alpha layers (#71897)

added docker commands for enabling alpha layers

(cherry picked from commit ef0de1af32)
2023-07-19 12:34:52 -04:00
Dimitris Sotirakis
c6634f3780 [v9.4.x] Bug: Compare semver digits for frontend packages config (#71906)
Bug: Compare `semver` digits for frontend packages config (#71829)

* Compare semver digits

* Fix lint

(cherry picked from commit 5f8ace33fb)

# Conflicts:
#	pkg/build/frontend/config_test.go
2023-07-19 10:21:47 +03:00
grafana-delivery-bot[bot]
da681e13f2 [v9.4.x] Update _index.md (#71796)
Update _index.md (#71792)

* Update _index.md

* makes prettier

---------

Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
(cherry picked from commit 03c2efa2d6)

Co-authored-by: Melori Arellano <melori.arellano@grafana.com>
2023-07-18 14:29:37 -05:00
Guilherme Caulada
e3be6812ce [v9.4.x] CI: Add rgm compatible windows msi pipeline (#71857)
CI: Add rgm compatible windows msi pipeline (#71678)

* Add rgm compatible windows msi pipeline

* Fix dependencies and platform

* Fix missing arg comment

* Fix linting issues

* Try to fix version on file path

* Fix dependency on verify release pipeline

(cherry picked from commit 4caa773401)
2023-07-18 13:51:07 -03:00
linoman
0817676d9e [v9.4.x] Rework Okta OAuth2 (#71860)
Rework Okta OAuth2 (#71349)

* Rework Okta OAuth2

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
(cherry picked from commit 130f142c7f)
2023-07-18 17:36:33 +02:00
grafana-delivery-bot[bot]
4333d651e1 [v9.4.x] docs: Update Transform Data (#71852)
docs: Update Transform Data (#71013)

* Update Transform Data :docs:

* Apply suggestions from code review Update Transform Data

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Fix link

* Various suggestions

* Various suggestions

* Various suggestions

* Reset make file

* Add example for extract field

* Add example for field lookup

* Add example for histogram

* Update

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

---------

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
Co-authored-by: ludovio <ludovic.viaud@gmail.com>
(cherry picked from commit 679365960b)

Co-authored-by: Jara Suárez de Puga García <jara.suarezdepuga@grafana.com>
2023-07-18 10:37:46 -04:00
Guilherme Caulada
20f001649e [v9.4.x] CI: Removes enterprise specific pipelines and steps (#71775)
[WIP] CI: Removes enterprise specific pipelines and steps (#70815)

* Removes enterprise specific pipelines and steps (#123)

* Comment out enterprise related pipelines and steps

* Suppress unused variable warning

* Removes all edition arguments

* Remove leftover comments

* Remove redundant oss on pipelines and steps names

* Remove leftover unused variable

* Remove leftovers

* Remove pipeline dependencies

* Rename pipelines

* Fix starlark

---------

Co-authored-by: dsotirakis <dimitrios.sotirakis@grafana.com>
(cherry picked from commit 642a81ba75e79138246797302aba5c35575f030d)

* Add editions for static assets

(cherry picked from commit b13939b9af)

Co-authored-by: Dimitris Sotirakis <dimitrios.sotirakis@grafana.com>
2023-07-18 11:17:11 -03:00
linoman
c465fa856e [v9.4.x] Auth: update generic OAuth documentation (#71639)
* Auth: update generic OAuth documentation (#70330)

* update generic OAuth docs

* some more fixes and corrections

* update examples and sync sections

* fix a link

* linting

* formatting and adding more links to OAuth integrations

* add a section with config walkthrough

* fix link

* move examples to the end of the doc

* extend role mapping

* small improvements

* add a before you begin section, clean up steps, remove some text

* remove unnecessary section

* merge main 2

* OAuth -> OAuth2

* remove Centrify example because it's likely outdated

* add shared intro content

* indentation

* add refresh token to tasks, clean up more sections

* linting

* linting

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-security/configure-authentication/generic-oauth/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* indentation and small descriptions under headings

* add a table for config options

* clean up more sections

* rewrite email address section

* rewriting login and display name sections, plus adding line breaks

* clean up more sections

* update role mapping section

* indentation again

* update section names

* incorporates final edits

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* pr feedback

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* PR feedback: rewording

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
(cherry picked from commit 276c63a656)

* linting

---------

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
2023-07-17 12:27:21 +00:00
grafana-delivery-bot[bot]
98d339bc12 [v9.4.x] Plugins: Only configure plugin proxy transport once (#71740)
Plugins: Only configure plugin proxy transport once (#71735)

only configure plugin proxy transport once

(cherry picked from commit b59ca7fb22)

Co-authored-by: Will Browne <wbrowne@users.noreply.github.com>
2023-07-17 14:54:03 +03:00
grafana-delivery-bot[bot]
55abd83948 [v9.4.x] CI: Re-enable milestone-check (#71721)
CI: Re-enable milestone-check (#71718)

This will hopefully resolve stuck PRs until we find a better way to
disable that check.

(cherry picked from commit 44b55a1ca6)

Co-authored-by: Horst Gutmann <horst.gutmann@grafana.com>
2023-07-17 12:18:00 +03:00
Dimitris Sotirakis
be7557306c [v9.4.x] CI: Fix broken env vars in publish-artifacts step (#71645)
CI: Fix broken env vars in publish-artifacts step (#71471)

Fix env vars

(cherry picked from commit 64d2ff03c80c807c03390f63ba1834c5605fc96d)

# Conflicts:
#	.drone.yml
(cherry picked from commit fd90737884)

# Conflicts:
#	.drone.yml
2023-07-17 11:53:31 +03:00
Horst Gutmann
5481d29428 [v9.4.x] Chore: Add auto-milestone workflow for pull-requests (#71709)
Chore: Add auto-milestone workflow for pull-requests (#71177)

This adds a new auto-milestone workflow that will set the milestone for
a PR when it is closed. This way, contributors no longer have to think
about milestone at all.

(cherry picked from commit 8ae92db53d)
2023-07-17 10:30:41 +02:00
linoman
093ea7cd47 [v9.4.x] Docs: reorder auth provider pages (#71642)
Docs: reorder auth provider pages (#70764)

* order auth provider pages

* add shorter menu titles

* linting

* update reference

* rename Grafana auth section to basic auth

(cherry picked from commit fc290281cb)

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
2023-07-17 09:58:25 +02:00
linoman
3ecbd728b3 [v9.4.x] Auth: update GitHub OAuth documentation (#70459) (#71649)
Auth: update GitHub OAuth documentation (#70459)

* github oauth doc improvements

* add skip_org_role_sync to config for github provider

* update links and section headings

* update the docs based on the first PR

* update references

(cherry picked from commit cb695cef8e)

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
2023-07-17 09:57:41 +02:00
grafana-delivery-bot[bot]
aff2783e68 [v9.4.x] Docs: Add reference to Grafana Cloud doc (#71666)
Docs: Add reference to Grafana Cloud doc (#71653)

Add reference to Grafana Cloud doc

(cherry picked from commit 6b40fe75f5)

Co-authored-by: Fabrizio <135109076+fabrizio-grafana@users.noreply.github.com>
2023-07-14 10:26:33 -05:00
Kevin Minehart
14484c46ad [v9.4.x] CI: Update and rename pr-patch-mirror-and-apply.yml to sync-mirror.yml (#71613)
CI: Update and rename pr-patch-mirror-and-apply.yml to sync-mirror.yml (#71608)

* CI: Update and rename pr-patch-mirror-and-apply.yml to sync-mirror.yml

* update CODEOWNERS

(cherry picked from commit 3afc20fae9)
2023-07-14 11:50:01 +01:00
Isabel
672a4d1590 [v9.4.x] docs: restructure dashboard annotations page (#71514)
* docs: restructure dashboard annotations page (#70208)

* restructured page, updated and removed images, replaced a paragraph with a procedure

* Clarify language

* Apply suggestions from code review

* removed native annotation language, added missing link, added text from UI

* fixed relref

* replaced relref with simple link

* updated links and link text in whats new for annotations updates

* fixed some grammar/wording and style issues

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* fix typo

Co-authored-by: Ezequiel Victorero <ezequiel.victorero@grafana.com>

* make link text more clear

* fix typo

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Ezequiel Victorero <ezequiel.victorero@grafana.com>
(cherry picked from commit adc7f65453)

* fixed backport
2023-07-13 10:11:16 -04:00
Isabel
211bfd2f4d [v9.4.x] docs: add alphaPanels feature toggle information (#71508)
fix backport conflict
2023-07-13 01:25:32 +03:00
grafana-delivery-bot[bot]
89c1e4c35e [v9.4.x] CI: Rename the patch GHA workflows (#71475)
CI: Rename the patch GHA workflows (#71470)

* Rename the patch workflows

* Update codeowners

(cherry picked from commit 428f63518a)

Co-authored-by: Kevin Minehart <kmineh0151@gmail.com>
2023-07-12 10:35:17 -05:00
Christopher Moyer
c922a5f956 [DOC] Fix tracing links in explore/tracing (#71383) (#71392)
* [DOC] Fix tracing links in explore/tracing (#71383)

Fix tracing links

(cherry picked from commit 41def2e346)

* Update docs/sources/explore/trace-integration.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

---------

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>
2023-07-11 11:57:41 -05:00
Emil Tullstedt
a4ab5bfaad [v9.4.x] CI: Provide a Drone promotion to build the build-container (#71350)
CI: Provide a Drone promotion to build the build-container (#71133)

(cherry picked from commit 7a9847e196)
2023-07-11 14:04:23 +02:00
grafana-delivery-bot[bot]
6480b50187 [v9.4.x] Docs: Fix broken links to play (#71294)
Docs: Fix broken links to play (#71112)

* fix broken links to play

* Update docs/sources/dashboards/variables/_index.md

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

---------

Co-authored-by: lwandz13 <126723338+lwandz13@users.noreply.github.com>
(cherry picked from commit 69d8e3d8dc)

Co-authored-by: matt abrams <37156449+zuchka@users.noreply.github.com>
2023-07-10 14:47:47 -04:00
grafana-delivery-bot[bot]
6ab231d61d [v9.4.x] Prometheus: Version detect bug (#71242)
Prometheus: Version detect bug (#71198)

* remove redundant request copy in backend, add more versions to semver lists

(cherry picked from commit 7dc071f46b)

Co-authored-by: Galen Kistler <109082771+gtk-grafana@users.noreply.github.com>
2023-07-07 14:21:31 -05:00
Kevin Minehart
19ea031bbd [v9.4.x] CI: Add GPG keys to rgm, don't clone RGM just use the docker image (#71231)
* CI: Add rgm to drone (#66991)

* add drone stub that build grafana using 'grafana/build' (dagger)

---------

Co-authored-by: Ricky Whitaker <ricky.whitaker@grafana.com>
(cherry picked from commit 768efe9748)

* Add dagger token to rgm builds (#68651)

(cherry picked from commit a870b227db)

* CI: Add GPG keys to rgm, don't clone RGM just use the docker image (#71143)

* Add GPG keys to rgm, dont' clone RGM just use the docker image

(cherry picked from commit d5a4c81fa1)
2023-07-07 20:23:39 +03:00
Christopher Moyer
f09edce739 Docs: update the word "integration" in Okta config (#71181) (#71210)
(cherry picked from commit ac78146091)

Co-authored-by: Mitch Seaman <mjseaman@users.noreply.github.com>
2023-07-07 09:39:49 -05:00
grafana-delivery-bot[bot]
fe5305ffeb [v9.4.x] InfluxDB: Interpolate retention policies (#71202)
InfluxDB: Interpolate retention policies (#69202)

Interpolate retention policies

(cherry picked from commit f610e37aec)

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
2023-07-07 15:14:24 +02:00
grafana-delivery-bot[bot]
fa72114b45 [v9.4.x] Docs: Updates Grafana alerting link text on Panel Editor Overview page (#71195)
Docs: Updates Grafana alerting link text on Panel Editor Overview page (#71146)

* Updates Grafana alerting link text on panel editor overview page

* fixed wording of link text

---------

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
(cherry picked from commit 217265baee)

Co-authored-by: Leanna Shippy <11079957+lshippy@users.noreply.github.com>
2023-07-07 08:24:55 -04:00
grafana-delivery-bot[bot]
51b8889874 [v9.4.x] Added security patch delivery workflows (#71147)
Added security patch delivery workflows (#71101)

* adding security patch workflows

* adding grafana-delivery as codeowners for new pr-security-check workflows

* adding release branch triggers to PR security patch github action

* joined security patching mirror and apply jobs

* remove temp files

(cherry picked from commit d88046d3d4)

Co-authored-by: Ricky Whitaker <ricky.whitaker@grafana.com>
2023-07-06 11:11:27 -05:00
grafana-delivery-bot[bot]
3e8916aa81 [v9.4.x] Docs: update heatmap panel options (#71095)
Docs: update heatmap panel options (#71058)

Added some heatmap panel configuration options which were missing from the docs

(cherry picked from commit bdf60d69de)

Co-authored-by: prenzlern <88067634+prenzlern@users.noreply.github.com>
2023-07-05 13:52:18 -04:00
grafana-delivery-bot[bot]
edba3a2467 [v9.4.x] standardize docs copyright (#70829)
standardize docs copyright (#70732)

(cherry picked from commit 3e3bcf510b)

Co-authored-by: Robby Milo <robbymilo@fastmail.com>
2023-06-28 09:47:10 -04:00
grafana-delivery-bot[bot]
8dcfb83de4 [v9.4.x] CI: Ignore .pr-body.txt file (#70806)
CI: Ignore .pr-body.txt file (#70798)

This file is used during the backporting process but should never be
committed.

(cherry picked from commit 2b10d31bac)

Co-authored-by: Horst Gutmann <horst.gutmann@grafana.com>
2023-06-28 12:22:35 +03:00
Dimitris Sotirakis
4486f323ec [v9.4.x] CI: Cleanup - Remove security related steps (#70793)
CI: Cleanup - Remove security related steps (#70788)

* Remove security related steps

* More cleanup

(cherry picked from commit 7f55ba9c6e)
2023-06-28 11:38:03 +03:00
grafana-delivery-bot[bot]
1d34f16a3f [v9.4.x] Update to docs - index.md (#70751)
Update to docs -  index.md (#70699)

Update index.md

Minor correction.

(cherry picked from commit b32cea7929)

Co-authored-by: marybelvargas <107340764+marybelvargas@users.noreply.github.com>
2023-06-27 17:01:03 -05:00
Horst Gutmann
db737d1d96 [v9.4.x] Docs: Add missing entries to changelog for 9.4.9 (#70744) 2023-06-27 14:33:23 +03:00
grafana-delivery-bot[bot]
47e4a2f886 [v9.4.x] docs: fix broken links in Configure legend (#70709)
docs: fix broken links in Configure legend (#70696)

* fix broken links

* fix remaining broken links

(cherry picked from commit 2d261e7aef)

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
2023-06-26 13:54:38 -04:00
grafana-delivery-bot[bot]
fda6f03ec9 [v9.4.x] Docs: removes-yum (#70640)
Docs: removes-yum (#70634)

* removes-yum

* Update docs/sources/setup-grafana/installation/redhat-rhel-fedora/index.md

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/redhat-rhel-fedora/index.md

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/redhat-rhel-fedora/index.md

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>

* incorporates feedback

* adds GPG key step

* removes duplicate addrepo command

---------

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>
(cherry picked from commit 262af2c473)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-06-23 14:35:22 -05:00
grafana-delivery-bot[bot]
b1d68dc18d [v9.4.x] Docs: removes references to Redhat, adds import GPG key step (#70630)
Docs: removes references to Redhat, adds import GPG key step (#70625)

removes references to Redhat, adds import GPG key step

(cherry picked from commit 06b1b6f552)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-06-23 12:47:11 -05:00
grafana-delivery-bot[bot]
54e65f25b7 [v9.4.x] docs: clarifies that only OSS or Enterprise are installed (#70626)
docs: clarifies that only OSS or Enterprise are installed (#70619)

* clarifies that only OSS or Enterprise are installed,  not both

* Apply suggestions from code review

(cherry picked from commit f77a886f0e)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-06-23 12:39:19 -05:00
grafana-delivery-bot[bot]
3db20d0149 [v9.4.x] formatting fix for line 72 (#70621)
formatting fix for line 72 (#70618)

(cherry picked from commit cbf4fe9d23)

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>
2023-06-23 10:04:26 -07:00
grafana-delivery-bot[bot]
cb7a0bb612 [v9.4.x] Changelog: Updated changelog for 9.4.13 (#70596)
Changelog: Updated changelog for 9.4.13 (#70595)

Co-authored-by: grafanabot <bot@grafana.com>
(cherry picked from commit 15e134215a)

Co-authored-by: grafana-delivery-bot[bot] <132647405+grafana-delivery-bot[bot]@users.noreply.github.com>
2023-06-23 15:07:56 +03:00
Horst Gutmann
28005f8baa [v9.4.x] Auth: Fixed CVE-2023-3128 (#70579)
Auth: Fixed CVE-2023-3128 (#70571)

Fixed CVE-2023-3128

(cherry picked from commit 789ee2121e)

Co-authored-by: Misi <mgyongyosi@users.noreply.github.com>
2023-06-23 12:10:30 +02:00
Vardan Torosyan
1a333623cf [v9.4.x] Add and document option for enabling email lookup (#916)
Add and document option for enabling email lookup (#913)

* Docs: Document option for enabling email lookup

* Add the new config in the config files

* Apply suggestions from code review

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>

* Don't capitalize identity providers

* Apply suggestions from code review

Co-authored-by: Jo <joao.guerreiro@grafana.com>

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

---------

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
Co-authored-by: Jo <joao.guerreiro@grafana.com>
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
(cherry picked from commit 8380bc7d6a79794cc260bf1c427e2b4e849adbf6)
2023-06-23 08:58:43 +02:00
Ieva
5829fdd399 Auth: Remove Email Lookup from oauth integrations 9.4 (#896)
backport https://github.com/grafana/grafana-private-mirror/pull/894 to 9.4.x
2023-06-23 08:58:42 +02:00
grafana-delivery-bot[bot]
1a07dc5db0 [v9.4.x] Changelog: Add CVE to 9.4.13 changelog (#70559)
Changelog: Add CVE to 9.4.13 changelog (#70558)

Add CVE to 9.4.13 changelog

(cherry picked from commit 69fc4e6bc0)

Co-authored-by: Guilherme Caulada <guilherme.caulada@grafana.com>
2023-06-22 18:17:55 -03:00
grafana-delivery-bot[bot]
f829ae71db Release: Bump version to 9.4.14 (#70557)
"Release: Updated versions in package to 9.4.14"

Co-authored-by: grafana-delivery-bot[bot] <132647405+grafana-delivery-bot[bot]@users.noreply.github.com>
2023-06-22 18:01:46 -03:00
Guilherme Caulada
43e78fa1a6 [v9.4.x] Changelog: Updated changelog for 9.4.13 (#70555)
* Changelog: Updated changelog for 9.4.13 (#70553)

Co-authored-by: grafanabot <bot@grafana.com>
(cherry picked from commit 58145908f4)

* Fix changelog conflict

---------

Co-authored-by: grafana-delivery-bot[bot] <132647405+grafana-delivery-bot[bot]@users.noreply.github.com>
2023-06-22 17:49:03 -03:00
grafana-delivery-bot[bot]
351450bfe0 [v9.4.x] Github Actions: Fix milestone GH action (#70497)
Github Actions: Fix milestone GH action (#70490)

* Remove secret from the caller action

* Inherit secrets for reusable actions

(cherry picked from commit 37db29db63)

Co-authored-by: Dimitris Sotirakis <dimitrios.sotirakis@grafana.com>
2023-06-22 19:17:40 +03:00
grafana-delivery-bot[bot]
69848e4349 [v9.4.x] docs: table panel: modified support section regarding alerts (#70532)
table panel: modified support section regarding alerts (#70421)

* modified support section

* Update docs/sources/panels-visualizations/visualizations/table/index.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update docs/sources/panels-visualizations/visualizations/table/index.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* fixing linting error

---------

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
Co-authored-by: Isabel Matwawana <isabel.matwawana@grafana.com>
(cherry picked from commit 8079c1456f)

Co-authored-by: tonypowa <45235678+tonypowa@users.noreply.github.com>
2023-06-22 11:34:13 -04:00
grafana-delivery-bot[bot]
28767f8a67 [v9.4.x] Docs: changes link text and adds link to the download page (#70507)
Docs: changes link text and adds link to the download page (#70477)

achanges link text and add link to the download page

(cherry picked from commit 5426d519c6)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-06-22 06:55:17 -05:00
grafana-delivery-bot[bot]
ccbd6d0afb [v9.4.x] Docs: removes references to YUM (#70473)
Docs: removes references to YUM (#70471)

removes references to YUM

(cherry picked from commit ebdba3b359)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-06-21 14:18:32 -05:00
Dimitris Sotirakis
b8ad4e0bb4 [v9.4.x] GitHub Apps: Replace grafanabot token with grafana-delivery-bot GitHub App (#70457)
* GitHub Apps: Replace `grafanabot` token with `grafana-delivery-bot` GitHub App (#70242)

* Update bump-version.yml

* Fix secret

* [REVERTME] Remove check

* Test without grafana-delivery-bot prefix

* Check if token exists

* Cleanup bump-version

* Update gh actions to use app key

(cherry picked from commit 15a85686c2)

# Conflicts:
#	.github/workflows/backport.yml
#	.github/workflows/bump-version.yml
#	.github/workflows/milestone.yml
#	.github/workflows/update-changelog.yml

* Bug: Fix `yaml` identation for github action yamls (#70445)

* Fix yaml identation

* Fix the rest of the yamls

(cherry picked from commit 31b9f9d235)
2023-06-21 16:32:58 +03:00
Grot (@grafanabot)
4add393ff0 [v9.4.x] docs: Fix bad markup in time series docs (#70388)
Fix bad markup in time series docs (#70352)

(cherry picked from commit d8a74ab1b7)

Co-authored-by: John Spurlock <john.spurlock@gmail.com>
2023-06-20 13:53:10 -04:00
Isabel
b640eb0c85 [v9.4.x] docs: Use "or" to convey that OS options are unique (#70353)
* Fix merge conflict
* Update relrefs

---------
Co-authored-by: Ursula Kallio <ursula.kallio@grafana.com>
2023-06-20 11:15:28 +02:00
Grot (@grafanabot)
ed6169688e [v9.4.x] Docs: List packages together, and fix or add menuTitles. (#70341)
Docs: List packages together, and fix or add menuTitles. (#70338)

List packages together, and fix or add menuTitles.

(cherry picked from commit a50afe67d3)

Co-authored-by: Ursula Kallio <ursula.kallio@grafana.com>
2023-06-19 11:34:49 -04:00
Dimitris Sotirakis
85637f0355 [v9.4.x] What's New: Bump whatsnewurl link (#70313)
Bump whatsNewUrl link
2023-06-19 13:11:11 +03:00
Jack Baldry
b3b5a9a999 [v9.4.x] Update make-docs procedure (#70275)
Update make-docs procedure (#70265)

## 4.1.0 (2023-06-16)

### Added

- Mounts of `layouts` and `config` directories for the `website` project.
  Ensures that local changes to mounts or shortcodes are reflected in the development server.

### Fixed

- Version inference for versioned docs pages.
  Pages in versioned projects now have the `versioned: true` front matter set to ensure that "version" in $.Page.Scratch is set on builds.

## 4.0.0 (2023-06-06)

### Removed

- `doc-validator/%` target.
  The behavior of the target was not as described.
  Instead, to limit `doc-validator` to only specific files, refer to https://grafana.com/docs/writers-toolkit/writing-guide/tooling-and-workflows/validate-technical-documentation/#run-on-specific-files.

## 3.0.0 (2023-05-18)

### Fixed

- Compatibility with the updated Make targets in the `website` repository.
  `docs` now runs this script itself, `server-docs` builds the site with the `docs` Hugo environment.


(cherry picked from commit a4a16b62c7)

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2023-06-16 21:53:29 +01:00
Jack Baldry
4c56cef6af [v9.4.x] Use docs/reference for flexible linking for content reused in Grafana Cloud (#70270)
Use docs/reference for flexible linking for content reused in Grafana Cloud (#70253)

* Use docs/reference for flexible linking for content reused in Grafana Cloud

Documented in https://github.com/grafana/website/pull/13878



* Use docs-base image that has docs/reference shortcode



---------


(cherry picked from commit 3d15d54a71)

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2023-06-16 18:45:27 +01:00
Grot (@grafanabot)
4c7ff6cff3 [v9.4.x] Changelog: Updated changelog for 9.4.10 (#70184)
Changelog: Updated changelog for 9.4.10 (#70181)

(cherry picked from commit 44c87c5b32)

Co-authored-by: Horst Gutmann <horst.gutmann@grafana.com>
2023-06-15 15:06:19 +00:00
Grot (@grafanabot)
1bb101b1ce [v9.4.x] Changelog: Updated changelog for 9.4.12 (#70171)
Changelog: Updated changelog for 9.4.12 (#70167)

(cherry picked from commit c82baf68a5)

Co-authored-by: Horst Gutmann <horst.gutmann@grafana.com>
2023-06-15 17:21:03 +03:00
Dimitris Sotirakis
ca2c251be6 [v9.4.x] CI: Update grabpl to v3.0.39 (#70134)
CI: Update `grabpl` to `v3.0.39` (#70126)

Update grabpl to v3.0.39

(cherry picked from commit b1e219e72c)

# Conflicts:
#	.drone.yml
2023-06-15 13:11:38 +03:00
Dimitris Sotirakis
c251570039 [v9.4.x] Bug: Fix build-frontend* config checks (#70076) (#70118)
Bug: Fix `build-frontend*` config checks (#70076)

* Fix frontend config checks

* Exclude test tag events

(cherry picked from commit 5a36fa5f8a)

# Conflicts:
#	pkg/build/cmd/buildfrontendpackages.go
2023-06-15 09:44:30 +03:00
Dimitris Sotirakis
c1cddece45 [v9.4.x] CI: Add CI check for what's new link (#70046) (#70121)
CI: Add CI check for `what's new` link (#70046)

* Add whatsnewchecker

* Add whatsnewchecker_test

* Small fixes

* Add step in CI

* Fix lint

* Fix starlark

* t.Cleanup instead of separate func

* Skip check for test tags

(cherry picked from commit 91272ee4f9)

# Conflicts:
#	.drone.yml
#	scripts/drone/events/release.star
2023-06-15 09:43:55 +03:00
Grot (@grafanabot)
37fc161fd9 [v9.4.x] AzureMonitor: Update docs to detail Azure logs query changes (#70086)
AzureMonitor: Update docs to detail Azure logs query changes (#69987)

Update docs to detail Azure logs query changes

(cherry picked from commit 068236c37f)

Co-authored-by: Andreas Christou <andreas.christou@grafana.com>
2023-06-14 19:14:11 +03:00
Dimitris Sotirakis
9117cec064 [v9.4.x] NPM packages: Fail build-frontend-packages step if package.json and input tag differ (#70011) (#70041)
* NPM packages: Fail `build-frontend-packages` step if `package.json` and input tag differ (#70011)

* Fail if package.json version is different than the tag

* Add tests

* Update message

* Small refactoring

* Fix lint

(cherry picked from commit a6b524fd56)

* Bump urfave/cli/v2

* go mod tidy
2023-06-14 12:42:05 +03:00
Dimitris Sotirakis
1a714ed0f5 [v9.4.x] Security Scans: Exclude windows container scans (#69977) (#69983)
Security Scans: Exclude windows container scans (#69977)

* Exclude windows container scans

* Fixes according to reviewer's comments

(cherry picked from commit fa70fba0e3)

# Conflicts:
#	.drone.yml
2023-06-13 10:57:32 +03:00
Isabel
f4064da4b5 [v9.4.x] docs: general edits to dashboard overview (#69747) (#69933)
docs: general edits to dashboard overview (#69747)

* general edits

* style edits - contractions

* Update docs/sources/fundamentals/dashboards-overview/index.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update docs/sources/fundamentals/dashboards-overview/index.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Apply suggestions from code review

* fixed linting error

---------

Co-authored-by: David Allen <david.allen@grafana.com>
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
(cherry picked from commit a169cdd5ec)

# Conflicts:
#	docs/sources/fundamentals/dashboards-overview/index.md
2023-06-12 11:32:08 -04:00
Dimitris Sotirakis
0850edc137 [v9.4.x] Security Scans: Add trivy scans to every docker image used for building/testing/publishing (#69911) (#69920)
* Security Scans: Add trivy scans to every docker image used for building/testing/publishing (#69911)

* Created images.star

* Fix typo

* Add cronjobs for build-images

(cherry picked from commit 2cda971796)

# Conflicts:
#	.drone.yml
#	scripts/drone/services/services.star
#	scripts/drone/steps/lib.star

* Fix rebasing issue
2023-06-12 17:32:09 +03:00
Jack Westbrook
12c6626a42 [v9.4.x] Docs: fix broken migration-guide (#69896)
docs: fix broken migration-guide
2023-06-12 12:02:20 +02:00
Grot (@grafanabot)
e5d8b486a6 [v9.4.x] docs: Azure doc link update (#69751)
docs: Azure doc link update (#69749)

Update index.md

Link update

(cherry picked from commit 3e48c0b570)

Co-authored-by: Jan Garaj <jan.garaj@gmail.com>
2023-06-08 09:29:25 -05:00
Christopher Moyer
66f195ca77 [9.4.x] Backport 64565 to v9.4.x (#69746)
Docs/docker compose update (#64565)

* added CLI in heading for clearity

* added new heading

* new change

* updated final version for review

* fix small line breaks

* copy edit, restructuring

* Apply suggestions from code review

* Apply suggestions from code review

* removed internal notes

* updateding the docker configuraiton file which have advanced instructions

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* updated persistent stroage section

* updated heading typo

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* fixed code identation and minor typos

* added yaml file validation check in the troubleshooting section

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

added "also"

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* add more details to apline, cloudwatch and default path sections

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* added more detailes about docker ubuntu image, fixed headings, added more clarity to the persistent vs bind stroage

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* added more improvements for the examples

* Update docs/sources/setup-grafana/installation/docker/index.md

* Update docs/sources/setup-grafana/installation/docker/index.md

* Update docs/sources/setup-grafana/installation/docker/index.md

* Update docs/sources/setup-grafana/configure-docker.md

* updates links, edits Troubleshooting section

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Dan Cech <dcech@grafana.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Dan Cech <dcech@grafana.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Dan Cech <dcech@grafana.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Dan Cech <dcech@grafana.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Dan Cech <dcech@grafana.com>

* fixes doc-validator issues

* adds link to plugin install instructions

* added improvement in the AWS cloudwatch example

* Update docs/sources/setup-grafana/configure-docker.md

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Apply suggestions from code review

suggestions looks good

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* added dan suggestion for the tags, but skip the longer description part as not really useful for end user

* Update docs/sources/setup-grafana/installation/docker/index.md

Co-authored-by: Dan Cech <dcech@grafana.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Dan Cech <dcech@grafana.com>

* Update docs/sources/setup-grafana/configure-docker.md

Co-authored-by: Dan Cech <dcech@grafana.com>

* Apply suggestions from code review

looks good

Co-authored-by: Dan Cech <dcech@grafana.com>

* added missing version

* fixed identation and small typo

* fixed the pwd data folder instruction

* fixed persistent volume creating and identation

* fixed identation

* fixed typo to get debug logs

* fixed custom plugin installation section

* created docker secret command instructions

* fixed missing path

* fixed code in docker secret and other minor typos

* incorporates feedback, copy edits secrets section

* fixed small typo in docker secrets section

* remove the additonal info command for secrets

* combined custom docker pre-installed plugin section as one

* fixed the build link typo

* various updates/fixes

* another fix

* added more clarity to the volume creating command

* fixed command for bind mounts

* fixed missing comman in the plugin command

* fixed small typo

* improve and simplifly the steps instructions

* fixed validation command

* Apply suggestions from code review

looks good!!

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* fixed typo in docker secret command explaination

* fixed minor stuff

* makes prettier

---------

Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Dan Cech <dcech@grafana.com>
(cherry picked from commit d50e50be28)

Co-authored-by: Usman Ahmad <usman.ahmad@grafana.com>
2023-06-07 15:06:30 -05:00
Isabel
c659f65ac0 [v9.4.x] docs: improvements to visualizations docs (#69740)
fixing merge conflict
2023-06-07 14:18:20 -04:00
Grot (@grafanabot)
5cbce7b951 [v9.4.x] docs: add product labels for reporting page (#69726)
docs: add product labels for reporting page (#69717)

add product labels for reporting page

(cherry picked from commit 994defeeb4)

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
2023-06-07 12:04:52 -04:00
Grot (@grafanabot)
8c42bef420 [v9.4.x] Docker: Add ARM64 architecture for Docker, for PRs (#69713)
Docker: Add ARM64 architecture for Docker, for PRs (#68295)

* Add ARM64 architecture for Docker

* Add arm64 variants

(cherry picked from commit bbd83cbaeb)

Co-authored-by: Dimitris Sotirakis <dimitrios.sotirakis@grafana.com>
2023-06-07 17:35:23 +03:00
Grot (@grafanabot)
d3d03312c3 [v9.4.x] Docs: Remove duplicate word in edit panel of configure panel options (#69666)
Docs: Remove duplicate word in edit panel of configure panel options (#69592)

Documentation: Remove duplicate word in edit panel of configure panel options
(cherry picked from commit f20a8eb2a7)

Co-authored-by: SatVeer Singh <developer.satveer@gmail.com>
2023-06-06 16:53:37 -04:00
Grot (@grafanabot)
c97d52e238 [v9.4.x] docs: update use dashboards descriptions (#69492)
* docs: update use dashboards descriptions (#67360)

* Update index.md

* fix wording

---------

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
(cherry picked from commit eeb08a4662)

* reverting incorrectly backported changes

* add changes intended for backport

* revert incorrectly backported change

---------

Co-authored-by: MattiasSegerdahl <102952046+MattiasSegerdahl@users.noreply.github.com>
Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
2023-06-06 16:37:13 -04:00
Grot (@grafanabot)
8faf41ff7f [v9.4.x] Prevent crash while executing concurrent mixed queries (#876)
Prevent crash while executing concurrent mixed queries (#874)

limit parallel query execution to 1 at a time

(cherry picked from commit 96579a60e19e2a9f2d6bdaeba64e0e702211eb73)

Co-authored-by: Michael Mandrus <41969079+mmandrus@users.noreply.github.com>
2023-06-06 13:27:09 +02:00
George Robinson
f30c03c281 [v9.4.x] Require alert.notifications:write permissions to test receivers and templates (#868)
Require alert.notifications:write permissions to test receivers and templates (#865)

(cherry picked from commit 3c21ab70075256d4ba8e4fbfdcb15f5a394161fa)
2023-06-06 13:27:08 +02:00
Grot (@grafanabot)
1e75a11e6b Release: Bump version to 9.4.13 (#69618)
"Release: Updated versions in package to 9.4.13"
2023-06-06 10:11:42 +00:00
Horst Gutmann
ce81d3d30a [v9.4.x] Changelog: Updated changelog for 9.4.12 (#69619)
* Changelog: Updated changelog for 9.4.12

* Add missing changes

Backport of #69617

---------

Co-authored-by: Horst Gutmann <horst.gutmann@grafana.com>
(cherry picked from commit 997c5e2348)

Co-authored-by: Grot (@grafanabot) <43478413+grafanabot@users.noreply.github.com>
2023-06-06 11:49:02 +02:00
Grot (@grafanabot)
92f437a5f2 [v9.4.x] Chore: Update @grafana/e2e (#66881)
Chore: Update @grafana/e2e (#66365)

* Update e2e package

- Ensure health request is monitored for addDatasource flow
- Add custom timeout to configurePanel flow

* Make health check optional

(cherry picked from commit b2e32a70b9)

Co-authored-by: Andreas Christou <andreas.christou@grafana.com>
2023-06-05 09:33:22 +00:00
Grot (@grafanabot)
16b542a3e6 [v9.4.x] [docs] typo fixes in expression queries (#69505)
[docs] typo fixes in expression queries (#65665)

* Update index.md

Fixing some minor typos.

* make language clearer

---------

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
(cherry picked from commit 6e501b9c07)

Co-authored-by: marybelvargas <107340764+marybelvargas@users.noreply.github.com>
2023-06-02 18:19:23 -04:00
Grot (@grafanabot)
0167cb7ff8 [v9.4.x] docs: update add-template-variables docs (#69500)
docs: update add-template-variables docs (#65682)

correcting typo in "Filter and modify using named text and value capture groups" section

(cherry picked from commit 921bc0324e)

Co-authored-by: annelaurefroment <49911675+annelaurefroment@users.noreply.github.com>
2023-06-02 17:56:08 -04:00
Grot (@grafanabot)
f6273ebb06 [v9.4.x] docs: fix grafana play link (#69496)
docs: fix grafana play link (#65763)

* Update index.md

Fixed the link for a grafana play reference

* fix link text

* fix wording for flow

---------

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
(cherry picked from commit 5dc07dedaa)

Co-authored-by: ashley <97468854+ansomerv@users.noreply.github.com>
2023-06-02 17:51:56 -04:00
Grot (@grafanabot)
4c1f6cca24 [v9.4.x] docs: update TestData screenshots (#69481)
docs: update TestData screenshots (#69472)

updated screenshots

(cherry picked from commit 52da729c83)

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
2023-06-02 16:25:39 -04:00
Grot (@grafanabot)
de801f532d [v9.4.x] Docs: Bring back the alias for external group sync HTTP API page (#69455)
Docs: Bring back the alias for external group sync HTTP API page (#69434)

* Docs: Bring back the alias for external group sync HTTP API page

* Update docs/sources/developers/http_api/team_sync.md

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>

---------

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
(cherry picked from commit 0e5e5175b1)

Co-authored-by: Vardan Torosyan <vardants@gmail.com>
2023-06-02 13:08:05 +00:00
Grot (@grafanabot)
457b4b208b [v9.4.x] remove incorrect state changes statement (#69446)
remove incorrect state changes statement (#65785)

Update index.md

(cherry picked from commit e789c2bf03)

Co-authored-by: Stefan Dunkler <stefan.dun@gmail.com>
2023-06-02 13:58:09 +02:00
Grot (@grafanabot)
0828eaa14c [v9.4.x] Docs: Rename External Group Sync references to Team Sync (#69398)
Docs: Rename External Group Sync references to Team Sync (#69395)

(cherry picked from commit 8235f774aa)

Co-authored-by: Vardan Torosyan <vardants@gmail.com>
2023-06-02 11:01:57 +02:00
Grot (@grafanabot)
832e89dad0 [v9.4.x] Dashboard: Fix library panels in collapsed rows not getting updated (#68535)
Dashboard: Fix library panels in collapsed rows not getting updated (#66643)

(cherry picked from commit f478504bc9)

Co-authored-by: Victor Colomb <51762123+VictorColomb@users.noreply.github.com>
2023-06-01 11:56:20 +03:00
Grot (@grafanabot)
caa6545292 [v9.4.x] Fix opentsdb table format (#69283)
Fix opentsdb table format (#69281)

* fixed table formatting

* changed opentsdb to OpenTSDB

* cleaned up wording

(cherry picked from commit 4a84633773)

Co-authored-by: lwandz13 <126723338+lwandz13@users.noreply.github.com>
2023-05-30 13:44:49 -07:00
Grot (@grafanabot)
0ac3eb956b [v9.4.x] Auth: Update docs on use PKCE by default (#69267)
Auth: Update docs on use PKCE by default (#68638)

* Auth: Update docs on use PKCE by default. (#68073)

Signed-off-by: junya koyama <arukiidou@yahoo.co.jp>

* Fix: docs review - from introduces to provides https://github.com/grafana/grafana/pull/68638/files#r1200506006

Signed-off-by: junya koyama <arukiidou@yahoo.co.jp>

* Fix docs - Remove note about a version https://github.com/grafana/grafana/pull/68638/files#r1200508038

Signed-off-by: junya koyama <arukiidou@yahoo.co.jp>

* Update docs/sources/setup-grafana/configure-security/configure-authentication/azuread/index.md

---------

Signed-off-by: junya koyama <arukiidou@yahoo.co.jp>
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
(cherry picked from commit 345b7fadc9)

Co-authored-by: arukiidou <arukiidou@yahoo.co.jp>
2023-05-30 11:41:53 -05:00
Grot (@grafanabot)
4cf03f5004 [v9.4.x] Docs: adds intro to prometheus (#69263)
Docs: adds intro to prometheus (#64352)

* adds topic content

* adjusts weights

* Update docs/sources/fundamentals/intro-to-prometheus/index.md

Co-authored-by: Fiona Artiaga <89225282+GrafanaWriter@users.noreply.github.com>

* Update docs/sources/fundamentals/intro-to-prometheus/index.md

* Apply suggestions from code review

Co-authored-by: Fiona Artiaga <89225282+GrafanaWriter@users.noreply.github.com>
Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* Update docs/sources/fundamentals/intro-to-prometheus/index.md

* Apply suggestions from code review

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* Apply suggestions from code review

* adds sentence about agent

* reworks prometheus as deployment section based on feedback

---------

Co-authored-by: Fiona Artiaga <89225282+GrafanaWriter@users.noreply.github.com>
Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>
(cherry picked from commit 59a62353dd)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-05-30 10:58:12 -05:00
Grot (@grafanabot)
e3f05514d3 [v9.4.x] Docs: Updates Grafana [smtp](#63311) (#69215)
Docs: Updates Grafana [smtp](#63311) (#63332)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Emil Tullstedt <emil.tullstedt@grafana.com>
(cherry picked from commit 89088d6aa2)

Co-authored-by: chenbt <34958405+chenbt-hz@users.noreply.github.com>
2023-05-30 09:14:55 -05:00
Grot (@grafanabot)
6d94ee5411 [v9.4.x] fix: Chef cookbook has moved to sous-chefs (#69240)
fix: Chef cookbook has moved to sous-chefs (#68425)

* fix: Chef cookbook has moved to sous-chefs

Updates the github link for the chef configuration option.

* Update docs/sources/administration/provisioning/index.md

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>

---------

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
(cherry picked from commit 1ff5170c83)

Co-authored-by: Jason Field <Jason@avon-lea.co.uk>
2023-05-30 08:32:05 +01:00
Ricky Whitaker
8be48da766 Backport 69191 to v9.4.x (#69197)
* fix verify_release_pipeline script execution (#69191)

* fix verify_release_pipeline script execution

* forgot to run make drone

(cherry picked from commit 68fe1e1cb0)

* make drone

---------

Co-authored-by: Kevin Minehart <kmineh0151@gmail.com>
2023-05-26 17:20:21 -05:00
Joseph Perez
ef87202878 [v9.4.x] Docs: Plugins doc review chunk 1-B (#68926)
Docs: Plugin doc review changes from chunk 1-B with corrected set of files (#67164)

* Re-pushing doc review changes from 1-B with fewer files

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Fix for URL examples

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Data frames fixes

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Fixes from doc review

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* More doc review changes

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Doc fixes

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Doc fix

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Prettier

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Fix migration index

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Fix screenshot

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Doc fixes

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Quick fix

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

---------

Signed-off-by: Joe Perez <joseph.perez@grafana.com>
(cherry picked from commit d6ba522c3c)
2023-05-26 19:29:32 +02:00
Grot (@grafanabot)
d448263073 [v9.4.x] Docs: Plugin doc review - backend topics - chunk 5 (#69161)
Docs: Plugin doc review - backend topics - chunk 5 (#68662)

* Initial commit

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Minor fixes

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Prettier fixes

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Incorporating review feedback

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Minor fix

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Update docs/sources/developers/plugins/backend/_index.md

Co-authored-by: Giuseppe Guerra <giuseppe.guerra@grafana.com>

* Update docs/sources/developers/plugins/backend/_index.md

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>

* Update docs/sources/developers/plugins/backend/_index.md

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>

* Update docs/sources/developers/plugins/backend/_index.md

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>

* Update docs/sources/developers/plugins/backend/_index.md

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>

* Update docs/sources/developers/plugins/backend/_index.md

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>

* Update docs/sources/developers/plugins/backend/_index.md

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>

* Update docs/sources/developers/plugins/backend/_index.md

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>

* Update docs/sources/developers/plugins/backend/_index.md

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>

* Update docs/sources/developers/plugins/backend/_index.md

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>

* Update docs/sources/developers/plugins/backend/grafana-plugin-sdk-for-go.md

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>

* Update docs/sources/developers/plugins/backend/grafana-plugin-sdk-for-go.md

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>

* Update docs/sources/developers/plugins/backend/plugin-protocol.md

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>

* Update docs/sources/developers/plugins/backend/plugin-protocol.md

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>

* Update docs/sources/developers/plugins/backend/plugin-protocol.md

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>

* Update docs/sources/developers/plugins/backend/_index.md

Co-authored-by: David Harris <david.harris@grafana.com>

* Indentation fix

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Review feedback

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Bug fix

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

---------

Signed-off-by: Joe Perez <joseph.perez@grafana.com>
Co-authored-by: Giuseppe Guerra <giuseppe.guerra@grafana.com>
Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>
Co-authored-by: David Harris <david.harris@grafana.com>
(cherry picked from commit b7e2f3ad3f)

Co-authored-by: Joseph Perez <45749060+josmperez@users.noreply.github.com>
2023-05-26 16:48:37 +00:00
Grot (@grafanabot)
fc447be8ac [v9.4.x] Docs: Update the service account HTTP API documentation (#69187)
Docs: Update the service account HTTP API documentation (#63235)

* doc: Add the service account deletion function

* doc: Add new service account documentation

(cherry picked from commit 4aa207ed83)

Co-authored-by: Pascal Zimmermann <pascal.zimmermann@theiotstudio.com>
2023-05-26 09:39:11 -07:00
Grot (@grafanabot)
f498b4d821 [v9.4.x] Docs: corrects circular reference in links (#69169)
Docs: corrects circular reference in links (#69165)

corrects circular reference in links

(cherry picked from commit 521d5f86dc)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-05-26 08:57:12 -05:00
Grot (@grafanabot)
f781e6fb7e [v9.4.x] Docs: fix 2 broken links on 'Publish a plugin' topic (#69157)
Docs: fix 2 broken links on 'Publish a plugin' topic (#68666)

* Initial commit

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Delete Reference folder for now

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

---------

Signed-off-by: Joe Perez <joseph.perez@grafana.com>
(cherry picked from commit 0600c5f5e7)

Co-authored-by: Joseph Perez <45749060+josmperez@users.noreply.github.com>
2023-05-26 08:25:11 -05:00
Grot (@grafanabot)
e6ed9908e3 [v9.4.x] GoogleAPI: Add retries functionallity to GoogleAPI calls (#69142)
GoogleAPI: Add retries functionallity to GoogleAPI calls (#69129)

* Add retryer to GoogleAPI calls

* Add comment

(cherry picked from commit 515270f5fd)

Co-authored-by: Dimitris Sotirakis <dimitrios.sotirakis@grafana.com>
2023-05-26 10:21:16 +00:00
Grot (@grafanabot)
37a8711985 [v9.4.x] docs: Update "Create reports" doc to clarify custom time ranges and add information about drafts (#69090)
docs: Update "Create reports" doc to clarify custom time ranges and add information about drafts (#69015)

* Update index.md

Clarify that changes to dashboard time range are only reflected in the report if they are not using a custom time range.

Add information regarding saving a report as a draft.

* Update docs/sources/dashboards/create-reports/index.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* running prettier

---------

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
Co-authored-by: Isabel Matwawana <isabel.matwawana@grafana.com>
(cherry picked from commit 9a5262d5c8)

Co-authored-by: chrisharbro <102977229+chrisharbro@users.noreply.github.com>
2023-05-25 19:02:19 -04:00
Grot (@grafanabot)
cd0854f1bc [v9.4.x] docs: update logs integration and calculation types content (#68915)
* Jasuade docs patch 1 (#68074)

* Docs update Logs in Explore

* Include new Calculation Types :docs:

* Update docs/sources/explore/logs-integration.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update docs/sources/explore/logs-integration.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update docs/sources/explore/logs-integration.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update docs/sources/explore/logs-integration.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Eye icon instead of Toggle field visibility

* running prettier

---------

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
Co-authored-by: Isabel Matwawana <isabel.matwawana@grafana.com>
(cherry picked from commit 753c9c262c)

* fixing erroneously updated content

* remove extra line break

---------

Co-authored-by: Jara Suárez de Puga García <jara.suarezdepuga@grafana.com>
Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
2023-05-26 01:33:43 +03:00
Grot (@grafanabot)
0d7c6950b9 [v9.4.x] Docs: Add JSON format for webhook notifications to differences (#69054)
Docs: Add JSON format for webhook notifications to differences (#68786)

(cherry picked from commit 65e2df7a2e)

Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-05-25 11:17:48 +02:00
Horst Gutmann
58b306eacf [v9.4.x] CI: Pin the google/cloud-sdk image (#69041)
[v9.4.x] CI: Pin the google/cloud-sdk image (#69037)

(cherry picked from commit f22d1d14a0)

Backport of #69037
2023-05-25 10:56:33 +03:00
Grot (@grafanabot)
0d80fc0da0 [v9.4.x] update prometheus query editor doc (#69012)
update prometheus query editor doc (#68595)

* initial updates to outdated info

* minor edits prior to draft PR

* commented out options no longer available

* additional edits

* removed tables, changed format to list

* updated code mode section

* finished edits to builder mode

* added revisions per Brendan

* removed commented out section

* added note short codes

(cherry picked from commit 3edeafa663)

Co-authored-by: lwandz13 <126723338+lwandz13@users.noreply.github.com>
2023-05-24 13:38:11 -07:00
Grot (@grafanabot)
14d0a0cfd5 [v9.4.x] Edit global time variable - custom date formats use browser time (#69019)
Edit global time variable - custom date formats use browser time (#69016)

* Edit global time variable - custom date formats use browser time

Fixes https://github.com/grafana/grafana/issues/68748

* run prettier

---------

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>
(cherry picked from commit 7c2358862e)

Co-authored-by: Melori Arellano <melori.arellano@grafana.com>
2023-05-24 13:37:09 -07:00
Grot (@grafanabot)
8ba86ce233 [v9.4.x] "Anatomy of a Dashboard" intro docs (#68833)
"Anatomy of a Dashboard" intro docs (#68011)

* first commit

* Update docs/sources/fundamentals/dashboards-overview/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/fundamentals/dashboards-overview/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/fundamentals/dashboards-overview/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/fundamentals/dashboards-overview/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/fundamentals/dashboards-overview/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/fundamentals/dashboards-overview/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* applying edited suggestions

* applying edit changes

* Update docs/sources/fundamentals/dashboards-overview/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/fundamentals/dashboards-overview/index.md

* Update docs/sources/fundamentals/dashboards-overview/index.md

* Update docs/sources/fundamentals/dashboards-overview/index.md

* Update docs/sources/fundamentals/dashboards-overview/index.md

* Update docs/sources/fundamentals/dashboards-overview/index.md

* Update docs/sources/fundamentals/dashboards-overview/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/fundamentals/dashboards-overview/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/fundamentals/dashboards-overview/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/fundamentals/dashboards-overview/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/fundamentals/dashboards-overview/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* makes prettier

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
(cherry picked from commit 26c59ddc70)

Co-authored-by: David Allen <david.allen@grafana.com>
2023-05-24 09:51:35 -05:00
Jack Baldry
7daa240753 Revert "[v9.4.x] [feat] docs; update admonition syntax" (#68982)
Revert "[v9.4.x] [feat] docs; update admonition syntax (#68855)"

This reverts commit 048de5d09a.
2023-05-24 14:53:21 +01:00
Kevin Minehart
136cb16a52 [9.4.x] Backport 68756 to v9.4.x (#68932)
CI: Add release verify pipeline (#68756)

(cherry picked from commit 79f49c9649)
2023-05-24 15:20:48 +02:00
Dimitris Sotirakis
324ba5c62b [v9.4.x] G10: Replace beta with preview references (#68347) (#68948)
G10: Replace `beta` with `preview` references (#68347)

* Update references

* Update grabpl to v3.0.38

(cherry picked from commit 7e816d010c)

# Conflicts:
#	.drone.yml
2023-05-24 02:21:50 -07:00
Dimitris Sotirakis
81d4d8f228 [v9.4.x] Remove code to publish to RPM and deb repos (#61786) (#68952)
Remove code to publish to RPM and deb repos (#61786)

This was replaced here: https://github.com/grafana/grafana/pull/53553 and it's no longer used

(cherry picked from commit a190e03133)

Co-authored-by: Julien Duchesne <julien.duchesne@grafana.com>
2023-05-24 10:49:30 +02:00
Grot (@grafanabot)
70d0b7a0d2 [v9.4.x] Docs: Plugins doc review chunk 3 (#68919)
Docs: Plugins doc review chunk 3 (#68159)

* Initial commit

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Minor fix

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Review changes

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Doc fixes

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Minor fix

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Update docs/sources/developers/plugins/cross-plugin-linking.md

Co-authored-by: Matt Dodson <47385188+MattDodsonEnglish@users.noreply.github.com>

* Update docs/sources/developers/plugins/development-with-local-grafana.md

Co-authored-by: Matt Dodson <47385188+MattDodsonEnglish@users.noreply.github.com>

* Update docs/sources/developers/plugins/cross-plugin-linking.md

Co-authored-by: Matt Dodson <47385188+MattDodsonEnglish@users.noreply.github.com>

* Update docs/sources/developers/plugins/cross-plugin-linking.md

Co-authored-by: Matt Dodson <47385188+MattDodsonEnglish@users.noreply.github.com>

* Update docs/sources/developers/plugins/development-with-local-grafana.md

Co-authored-by: Matt Dodson <47385188+MattDodsonEnglish@users.noreply.github.com>

* Incorporating review feedback

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Update docs/sources/developers/plugins/development-with-local-grafana.md

Co-authored-by: Matt Dodson <47385188+MattDodsonEnglish@users.noreply.github.com>

* Test commit

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

---------

Signed-off-by: Joe Perez <joseph.perez@grafana.com>
Co-authored-by: Matt Dodson <47385188+MattDodsonEnglish@users.noreply.github.com>
(cherry picked from commit d68079e927)

Co-authored-by: Joseph Perez <45749060+josmperez@users.noreply.github.com>
2023-05-23 14:23:38 -05:00
Grot (@grafanabot)
4b802788f5 [v9.4.x] Update enterprise plugins list (#68911)
Update enterprise plugins list (#68730)

Updated to reflect a couple missing plugins from https://grafana.com/docs/plugins/

(cherry picked from commit 34d294bf56)

Co-authored-by: Ron D <106610617+rgnvldr@users.noreply.github.com>
2023-05-23 14:14:30 -05:00
Grot (@grafanabot)
048de5d09a [v9.4.x] [feat] docs; update admonition syntax (#68855)
[feat] docs; update admonition syntax (#68842)

* [feat] docs; update admonition syntax

- Standardizes according to style conventions: https://grafana.com/docs/writers-toolkit/style-guide/style-conventions/#admonitions
- Prepares docs for better, uniform admonition style.

* Remove false positives and irregularities

* false positive removal

* Update docs/sources/datasources/mysql/_index.md

* Update docs/sources/developers/angular_deprecation/angular-plugins.md

* fix link errors

* Prettify some nested blockquotes

* remoe unnecessary admonition

(cherry picked from commit 1c4bb9ca00)

Co-authored-by: Matt Dodson <47385188+MattDodsonEnglish@users.noreply.github.com>
2023-05-23 07:46:19 -05:00
Grot (@grafanabot)
ad2a920191 [v9.4.x] Azure Monitor: Fix bug that did not show alert rule preview (#68561)
Azure Monitor: Fix bug that did not show alert rule preview (#68339)

(cherry picked from commit f9601f8f27)

Co-authored-by: Alyssa Bull <58453566+alyssabull@users.noreply.github.com>
2023-05-23 13:33:39 +01:00
Grot (@grafanabot)
c794e68ea2 [v9.4.x] Docker: Add mode label when building docker images (#68868)
Docker: Add `mode` label when building docker images (#68865)

Add mode label when building docker image

(cherry picked from commit bad570ee86)

Co-authored-by: Dimitris Sotirakis <dimitrios.sotirakis@grafana.com>
2023-05-23 10:56:06 +02:00
Grot (@grafanabot)
4d944081bc [v9.4.x] Utils: Reimplement util.GetRandomString to avoid modulo bias (#66969)
Utils: Reimplement util.GetRandomString to avoid modulo bias (#64481)

* reimplement GetRandomString, add tests that results are unbiased

(cherry picked from commit 7e765c870a)

Co-authored-by: Dan Cech <dcech@grafana.com>
2023-05-22 14:55:20 -04:00
Dimitris Sotirakis
3b6ed3340d [v9.4.x] CI: Run trigger-test-release only on PRs against main (#68794) (#68811)
CI: Run `trigger-test-release` only on PRs against main (#68794)

Run trigger-test-release only on PRs against main

(cherry picked from commit 623c014cda)

# Conflicts:
#	.drone.yml
2023-05-22 15:09:55 +02:00
Dimitris Sotirakis
bba6777982 [v9.4.x] Docker images: Don't fail if a PR comes from a fork (#68765) (#68782)
Docker images: Don't fail if a PR comes from a fork (#68765)

* Update grabpl

* Allow publish images to fail for PRs

(cherry picked from commit 04e2d9055d)

# Conflicts:
#	.drone.yml
2023-05-22 12:04:59 +02:00
Grot (@grafanabot)
1c1be82eb9 [v9.4.x] RBAC: Remove legacy AC editor and admin role on new dashboard route (#68775)
RBAC: Remove legacy AC editor and admin role on new dashboard route (#68762)

remove legacy AC editor and admin role on new dashboard route

(cherry picked from commit 94283f5039)

Co-authored-by: Eric Leijonmarck <eric.leijonmarck@gmail.com>
2023-05-22 10:37:43 +01:00
Dimitris Sotirakis
409cec2e41 [v9.4.x] G10: Post docker pull commands for local testing (#67489) (#68684)
* G10: Post `docker pull` commands for local testing (#67489)

* Add grabpl publish images

Update grabpl - add github pr token

* Replace github_pr_token with gh app

# Conflicts:
#	.drone.yml
#	scripts/drone/vault.star

# Conflicts:
#	.drone.yml

# Conflicts:
#	.drone.yml

* Lint starlark

Add forgotten secrets

Lint starlark

Change secrets

* Update grabpl to v3.0.35

* Lint starlark

* Remove unnecessary secrets

(cherry picked from commit 26bacf6d4c)

# Conflicts:
#	.drone.yml

* Update grabpl to v3.0.36
2023-05-22 09:48:24 +02:00
Grot (@grafanabot)
55e05cc833 [v9.4.x] Clarify Graphite version and type to set if using Grafana Cloud (#68719)
Clarify Graphite version and type to set if using Grafana Cloud (#68239)

* Clarify Graphite version and type to set if using Grafana Cloud

* Update _index.md

(cherry picked from commit 9f7f82c3cc)

Co-authored-by: Fiona Liao <fiona.y.liao@gmail.com>
2023-05-18 18:14:53 +02:00
Grot (@grafanabot)
0fb2bd25d3 [v9.4.x] Revert: Allow editors to access GET /datasources (#68653)
Revert: Allow editors to access GET /datasources (#68632)

Revert "Allow editors to access GET /datasources"

This reverts commit 5a830c43c0.

(cherry picked from commit 6a2bcba078)

Co-authored-by: Eric Leijonmarck <eric.leijonmarck@gmail.com>
2023-05-17 19:18:07 +01:00
Ivan Ortega Alba
c0ca04e9a3 [v9.4.x] Dashboards: Remove no-datasource screen (#68574) (#68646)
Dashboards: Remove no-datasource screen (#68574)

* Dashboards: Remove non-ds configured landing page

* Remove `datasourceOnboarding` feature toggle

(cherry picked from commit 1505a188eb)
2023-05-17 19:26:52 +03:00
Grot (@grafanabot)
bcf4e758dc [v9.4.x] Explore: Remove data source onboarding page (#68642)
Explore: Remove data source onboarding page (#68131)

* Remove EmptyStateWrapper

(cherry picked from commit cee838c8a8)

Co-authored-by: Haris Rozajac <58232930+harisrozajac@users.noreply.github.com>
2023-05-17 09:55:07 -06:00
Andreas Christou
c8077a982e [v9.4.x] AzureMonitor: Fix Log Analytics portal links (#65482) (#68523)
AzureMonitor: Fix Log Analytics portal links (#65482)

* Fix and update Log Analytics portal links

- Build portal URL in backend
- Correctly set multiple resource value
- Move AddConfigLinks util function
- Add necessary types
- Remove unused functions

* Fix lint issue

* Remove unused cache variable

(cherry picked from commit e27cb67776)

# Conflicts:
#	.betterer.results
2023-05-16 17:12:01 +00:00
Christopher Moyer
53d8071192 [v9.4 backport] Docs: Plugin doc review for chunk 1-A (#67070) (#68134)
Docs: Plugin doc review for chunk 1-A (#67070)

* Plugin doc review for chunk 1-A

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Group of fixes in response to review comments

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Updates for review comments

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Fixed extra space

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Additional doc fixes

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* More doc fixes

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Fixes from doc review

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Doc review fixes

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* More changes from doc review

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Fix links and relrefs using doc-validator advice

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Publishing criteria update

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Markdown fix

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Fixes

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Testing

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Testing

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Testing

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Link fix

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Prettier

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Fix to publishing criteria

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Doc fix

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Doc fix

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Doc fix

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Update docs/sources/developers/plugins/_index.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/developers/plugins/_index.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/developers/plugins/_index.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/developers/plugins/_index.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/developers/plugins/_index.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/developers/plugins/_index.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/developers/plugins/_index.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/developers/plugins/_index.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/developers/plugins/_index.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/developers/plugins/build-a-logs-data-source-plugin.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/developers/plugins/build-a-streaming-data-source-plugin.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/developers/plugins/build-a-streaming-data-source-plugin.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/developers/plugins/get-started-with-plugins/_index.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/developers/plugins/publish-a-plugin.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/developers/plugins/publish-a-plugin.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/developers/plugins/publish-a-plugin.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/developers/plugins/sign-a-plugin.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Prettier

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

---------

Signed-off-by: Joe Perez <joseph.perez@grafana.com>
Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>
(cherry picked from commit 13be068919)

Co-authored-by: Joseph Perez <45749060+josmperez@users.noreply.github.com>
2023-05-15 12:48:52 -05:00
Dimitris Sotirakis
b31c0b7897 [v9.4.x] CI: Add delivery bot secrets to publish images step (#68467) (#68471)
CI: Add delivery bot secrets to publish images step (#68467)

Add delivery bot secrets

(cherry picked from commit 55622615de)

# Conflicts:
#	.drone.yml
#	scripts/drone/vault.star
2023-05-15 18:18:09 +03:00
Horst Gutmann
cd2ea25f54 [v9.4.x] CI: Update grabpl to 3.0.34 (#68456) (#68466)
* CI: Port of init-enterprise fix from 9.4.10

* CI: Update grabpl to 3.0.34

(cherry picked from commit 35ccfa6131)

Backport of https://github.com/grafana/grafana/pull/68456
2023-05-15 17:53:13 +03:00
ismail simsek
fb9429b1f7 [v9.4.x] Prometheus: Fix fallback http method when no http method specified in jsonData (#68434)
Prometheus: Fix fallback http method when no http method specified in jsonData (#65229)

Use POST as default if no http method specified in jsonData

(cherry picked from commit 959349d191)
2023-05-14 15:52:31 +02:00
Grot (@grafanabot)
f5da579af9 [v9.4.x] Alerting: Migration to not fail if alert_configuration table is not empty (#68404)
Co-authored-by: Yuri Tseretyan <yuriy.tseretyan@grafana.com>
2023-05-12 22:30:27 +03:00
Grot (@grafanabot)
ec973b648a [v9.4.x] Plugins doc review chunk 2 (#68411)
Plugins doc review chunk 2 (#67691)

* Doc style edit for 7 topics

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Proofread topics

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Prettier

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Doc fix

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Update docs/sources/developers/plugins/add-query-editor-help.md

Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>

* Doc fixes

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Changes from doc review

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Incorporate review feedback

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* More fixes

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* More doc fixes

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

---------

Signed-off-by: Joe Perez <joseph.perez@grafana.com>
Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
(cherry picked from commit 49a18bc8e2)

Co-authored-by: Joseph Perez <45749060+josmperez@users.noreply.github.com>
2023-05-12 14:00:40 -05:00
Grot (@grafanabot)
b3b956b01e [v9.4.x] Wording changes to improve clarity. (#68399)
Wording changes to improve clarity. (#66045)

* Wording changes to improve clarity.

* Update docs/sources/setup-grafana/set-up-for-high-availability.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/set-up-for-high-availability.md

* Update docs/sources/setup-grafana/set-up-for-high-availability.md

* Update docs/sources/setup-grafana/set-up-for-high-availability.md

* Update docs/sources/setup-grafana/set-up-for-high-availability.md

* Update docs/sources/setup-grafana/set-up-for-high-availability.md

* ran doc validator, make corrections

---------

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
(cherry picked from commit fd83b17b7f)

Co-authored-by: colinedwardwood <colin.wood@grafana.com>
2023-05-12 11:20:07 -05:00
Grot (@grafanabot)
9fa0ec2047 [v9.4.x] CloudMonitor: Show template variables by default (#68382)
CloudMonitor: Show template variables by default (#68331)

CloudMonitor: show template variables by default
(cherry picked from commit 9503f22f53)

Co-authored-by: Adam Simpson <adam@adamsimpson.net>
2023-05-12 14:03:14 +00:00
Dimitris Sotirakis
eacc0bafea [v9.4.x] CI: Add .drone.yml in pathschanged trigger for lint_backend pipeline (#68348) (#68367)
CI: Add `.drone.yml` in pathschanged trigger for `lint_backend` pipeline (#68348)

Add .drone.yml in pathschanged for lint_backend

(cherry picked from commit b7b13067a5)

# Conflicts:
#	.drone.yml
2023-05-12 13:25:08 +01:00
Grot (@grafanabot)
11b98de351 [v9.4.x] Docs: Correct capitalization of openSUSE (#68335)
Docs: Correct capitalization of openSUSE (#67567)

Correct capitalization of openSUSE

(cherry picked from commit 7e0031ec36)

Co-authored-by: Clayton Cornell <131809008+clayton-cornell@users.noreply.github.com>
2023-05-11 15:28:03 -05:00
Adam Simpson
4a07a2dc5d Google Cloud Monitor: Fix mem usage for dropdown (#67683) (#67950)
Previously the Metric name dropdown would attempt to load _all_ the
available metric names into the Select which would eventually crash the
browser if the dataset was large enough.

We can fix this by using AsyncSelect and making another query once a
Service is selected _and_ the user types a few characters.

* fix: update tests for AsyncSelect

* fix lint

* fix: add subset of metrics on initial load
2023-05-11 19:26:51 +00:00
Andreas Christou
9cb76776af AzureMonitor: Add health check retry logic (#68120) (#68198)
AzureMonitor: Bump credential wait time (#68120)

Bump credential wait time as 15s seems too short

(cherry picked from commit 0d3a78d86d)

# Conflicts:
#	e2e/cloud-plugins-suite/azure-monitor.spec.ts
2023-05-11 11:22:41 -05:00
Grot (@grafanabot)
a0be1550eb Release: Bump version to 9.4.11 (#68272)
"Release: Updated versions in package to 9.4.11"
2023-05-10 17:03:29 -05:00
Ricky Whitaker
9daf1363df [9.4.x] Changelog: Updated changelog for 9.4.10 (#68267) (#68270)
* Changelog: Updated changelog for 9.4.10 (#68267)

(cherry picked from commit 2dbdebaae9)

* Update CHANGELOG.md

Co-authored-by: Kevin Minehart <kmineh0151@gmail.com>

---------

Co-authored-by: Grot (@grafanabot) <43478413+grafanabot@users.noreply.github.com>
Co-authored-by: Kevin Minehart <kmineh0151@gmail.com>
2023-05-10 16:45:11 -05:00
Horst Gutmann
93af60149d [v9.4.x] CI: Move windows-tests into promotion pipeline (#68218) (#68233)
(cherry picked from commit acd02e8a48)

Backport of https://github.com/grafana/grafana/pull/68218
2023-05-10 17:53:09 +03:00
Jack Baldry
203becbf33 [v9.4.x] Use expected types for admonition (#68179)
All types are declared lowercased.


(cherry picked from commit 356eabc24c)

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2023-05-10 14:12:26 +01:00
Grot (@grafanabot)
896f2ce04f [v9.4.x] updated screenshots, links and some wording (#68144)
updated screenshots, links and some wording (#67864)

(cherry picked from commit c9e5c229ec)

Co-authored-by: lwandz13 <126723338+lwandz13@users.noreply.github.com>
2023-05-09 14:28:18 -07:00
Grot (@grafanabot)
2ea3929354 [v9.4.x] Fix Enterprise Datasources link on Grafana Enterprise page (#68116)
Fix Enterprise Datasources link on Grafana Enterprise page (#67962)

fix-enterprise-datasources-link

(cherry picked from commit 18d4fda613)

Co-authored-by: Andriy <andriy.urbanas@grafana.com>
2023-05-09 10:34:24 -05:00
Adam Simpson
126426e15e AzureMonitor: Correct series name accounting for dimensions (#67050) (#68033)
Correct displayName accounting for dimensions

Co-authored-by: Andreas Christou <andreas.christou@grafana.com>
2023-05-09 13:06:36 +00:00
Dimitris Sotirakis
ef6fdcd710 [v9.4.x] CI: Remove custom enterprise2 pipelines (#68056) (#68059)
CI: Remove custom enterprise2 pipelines (#68056)

Remove custom enterprise2 pipelines

(cherry picked from commit 6ae952c7c5)
2023-05-09 12:07:01 +03:00
Galen Kistler
a2fea9af76 [v9.4.x] Prometheus: bug in creating autocomplete queries with labels (#68031)
* Prometheus: bug in creating autocomplete queries with labels (#68003)
(cherry picked from commit a1bc1bd368)
2023-05-08 21:40:50 +03:00
Horst Gutmann
d12a747a5d [v9.4.x] CI: Add Windows backend tests in more places (#66438) (#68008)
* CI: Add Windows backend tests in more places

* CI: Add promotion pipeline for publishing new windows-test-images

* CI: Ignore windows backend-test failures for now

* CI: Fix linting issue in ci_images.star file

(cherry picked from commit b2fc285a5d)

Backport of https://github.com/grafana/grafana/pull/66438
2023-05-08 17:04:37 +03:00
Grot (@grafanabot)
bcdc8cd5ab [v9.4.x] AzureMonitor: Fix logs query multi-resource and timespan values (#67931)
AzureMonitor: Fix logs query multi-resource and timespan values (#67914)

* Update TimeGrain interface methods

- Make them util functions because it's simpler

* Update logs ds to appropiately set resources and timespan

* Set timespan using RCF times

* Update tests

(cherry picked from commit 9d16718acc)

Co-authored-by: Andreas Christou <andreas.christou@grafana.com>
2023-05-05 20:19:04 +03:00
Isabel
1b2f5a3798 [v9.4.x] docs: fix create dashboard steps (#67865)
fixed merge conflict for backport
2023-05-04 13:07:27 -04:00
Grot (@grafanabot)
eafc315dc1 [v9.4.x] Docs: updates Grafana installation for Red Hat, Fedora, RHEL, SUSE, and OpenSUSE (#67773)
Docs: updates Grafana installation for Red Hat, Fedora, RHEL, SUSE, and OpenSUSE (#65232)

* removes references to CentOS

* starts reorg

* complete restructure

* updates alias

* Update docs/sources/setup-grafana/installation/rpm/index.md

* Apply suggestions from code review

Co-authored-by: Dan Cech <dcech@grafana.com>

* incorporates review feedback

* adds install on suse/opensuse

* updates aliases

* Apply suggestions from code review

Co-authored-by: Dan Cech <dcech@grafana.com>

* removes start server content from both topics; adds link to start server docs in Next steps

* Apply suggestions from code review

Co-authored-by: Dan Cech <dcech@grafana.com>

* incorporates review feedback

* Apply suggestions from code review

* typo fix

---------

Co-authored-by: Dan Cech <dcech@grafana.com>
(cherry picked from commit fcdbb7a86f)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-05-04 12:04:01 -05:00
Grot (@grafanabot)
2760aa808d [v9.4.x] Docs/updates install landing page (#67774)
Docs/updates install landing page (#64809)

* copy edit

* copy edits plus some restructuring

* Apply suggestions from code review

Co-authored-by: Dan Cech <dcech@grafana.com>

---------

Co-authored-by: Dan Cech <dcech@grafana.com>
(cherry picked from commit 3b37135b5b)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-05-04 11:59:14 -05:00
Christopher Moyer
9b77be4a08 [Docs v9.4x] Manual backport - Link to config exemplars leads goes to top of page (#67687) (#67856)
Link to config exemplars leads goes to top of page (#67687)

* Link to config exemplars leads goes to top of page

The link to the configure exemplars in a Prometheus datasource leads to the top of the page.  I have referenced the correct link that would take it to the right section.

https://grafana.com/docs/grafana/latest/datasources/prometheus/#configure-exemplars

* Update docs/sources/fundamentals/exemplars/index.md

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
(cherry picked from commit 681925fb63)

Co-authored-by: samu6851 <samuel.oswalt@grafana.com>
2023-05-04 11:53:07 -05:00
Grot (@grafanabot)
2ca13f2b57 [v9.4.x] docs: updates windows/mac install topics (#67775)
docs: updates windows/mac install topics (#64740)

* updates windows/mac install topics

* corrects typo

* Apply suggestions from code review

Co-authored-by: Dan Cech <dcech@grafana.com>

* tweaks

---------

Co-authored-by: Dan Cech <dcech@grafana.com>
(cherry picked from commit d67ad9efc4)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-05-04 11:46:49 -05:00
Grot (@grafanabot)
fbb48cb826 [v9.4.x] docs: Updates installation instruction for Debian/Ubuntu (#67776)
docs: Updates installation instruction for Debian/Ubuntu (#64232)

* draft changes

* Apply suggestions from code review

Co-authored-by: Dan Cech <dcech@grafana.com>

* reworks debian/ubuntu instructions, updates start server topic

* Apply suggestions from code review

Co-authored-by: Dan Cech <dcech@grafana.com>

* incorporates feedback; restructures to align with writers toolkit guidelines

* Apply suggestions from code review

Co-authored-by: Dan Cech <dcech@grafana.com>

* tweaks structure of server topic; renames directory, corrects relrefs

* corrects spelling

* Apply suggestions from code review

Co-authored-by: Dan Cech <dcech@grafana.com>

* removed web parameter

* removes unnecessary word

* incorporates feedback from internal reviewer

* updates alias

* updates alias

* adjust alias

---------

Co-authored-by: Dan Cech <dcech@grafana.com>
(cherry picked from commit 13af5afaf3)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-05-04 11:30:33 -05:00
Grot (@grafanabot)
a567819719 [v9.4.x] InfluxDB: Fix adding FROM statement when the measurement is an empty string (#67834)
InfluxDB: Fix adding FROM statement when the measurement is an empty string (#67827)

* If the measurement empty don't add FROM statement

* Add comment line

(cherry picked from commit 764f87b485)

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
2023-05-04 17:09:17 +03:00
Sofia Papagiannaki
ff88bb0102 [v9.4.x] Chore: Upgrade Go to 1.20.4 (#67760)
Chore: Upgrade Go to 1.20.4
2023-05-04 10:53:16 +03:00
Grot (@grafanabot)
6a80a658b8 [v9.4.x] docs: add semi relative time ranges (#67753)
docs: add semi relative time ranges (#67559)

* add semi-relative time range section

* added second example and reworded

* formatting fixes

* added alerting note and fixed formatting

* wording fix

(cherry picked from commit 0271a1d094)

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
2023-05-03 11:55:43 -04:00
Grot (@grafanabot)
30504b6857 [v9.4.x] Update index.md (#67727)
Update index.md (#67172)

Clarified some of the intro text and added JSON outer element to make the samples clearer

(cherry picked from commit 66ad704292)

Co-authored-by: Nabeel Saad <saadnabs@hotmail.com>
2023-05-03 08:46:51 -05:00
Grot (@grafanabot)
be58e9f116 [v9.4.x] InfluxDB: Fix querying retention policies on flux mode (#67724)
InfluxDB: Fix querying retention policies on flux mode (#67722)

Query retention policies only on InfluxQL mode

(cherry picked from commit 373e4cab9a)

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
2023-05-03 16:11:03 +03:00
Grot (@grafanabot)
ad4357b07e [v9.4.x] docs: move misplaced Configure legend page (#67670)
docs: move misplaced Configure legend page (#67597)

* move configure legend page and add alias

* updated page weight and tried fixing alias

* fixed alias

* add preemptive alias for current page location

* apply suggestion from review

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>

* apply suggestions from review

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>

* apply suggestions from review

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>

---------

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
(cherry picked from commit 688459f25c)

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
2023-05-02 11:51:44 -04:00
Grot (@grafanabot)
04d7c5f790 [v9.4.x] Theme: Fix wrong code segment in theme.md (#65438)
Theme: Fix wrong code segment in theme.md (#62488)

* fix wrong markdown

* fix prettier

(cherry picked from commit 3335d46c5f)

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
2023-05-02 12:16:26 +00:00
Isabel
ee278fe3b9 [9.4.x] docs: reverse what's new order in TOC (#67605)
fixed merge conflict for backport
2023-05-01 17:37:34 -04:00
Grot (@grafanabot)
101927cf04 [v9.4.x] Add Grafana Free as supporting Enterprise features (#67600)
Add Grafana Free as supporting Enterprise features (#67568)

Per https://docs.google.com/document/d/14aOVLPq0FNqQKN4axTTEvjraY_OafhiDM_2NYSHF33A/edit#heading=h.lo4c6e71q7vo Grafana Cloud Free will include all the features of Grafana Advanced in Q2

(cherry picked from commit 999a2ce92d)

Co-authored-by: Ron D <106610617+rgnvldr@users.noreply.github.com>
2023-05-01 15:11:14 -05:00
Leon Sorokin
9ec538568a [v9.4.x] TimeSeries: Fix leading null-fill for missing intervals (#67572)
* TimeSeries: Fix leading null-fill for missing intervals (#67570)

(cherry picked from commit e5aeb7c322)

# Conflicts:
#	packages/grafana-ui/src/components/GraphNG/nullInsertThreshold.ts

* fix jest
2023-04-29 04:15:14 -06:00
Isabel
63ecb1c359 [v9.4.x] docs: fixing merge conflict for backport (#67564)
fixing merge conflict for backport

Co-authored-by: sarah-spang <86264026+sarah-spang@users.noreply.github.com>
2023-04-28 17:03:34 -04:00
Grot (@grafanabot)
885057c4d2 [v9.4.x] Grafana Cloud: Put cloud artifacts to */release dir (#67530)
Grafana Cloud: Put cloud artifacts to `*/release` dir (#66168)

Put cloud artifacts to */release dir

(cherry picked from commit a2634495e5)

Co-authored-by: Dimitris Sotirakis <dimitrios.sotirakis@grafana.com>
2023-04-28 18:23:20 +03:00
Grot (@grafanabot)
8f169dc42d [v9.4.x] Grafana Cloud: Add VariantLinuxAmd64 in build variants (#67527)
Grafana Cloud: Add `VariantLinuxAmd64` in build variants (#66167)

Add VariantLinuxAmd64 in build variants

(cherry picked from commit 8dd87a79f7)

Co-authored-by: Dimitris Sotirakis <dimitrios.sotirakis@grafana.com>
2023-04-28 18:22:13 +03:00
Grot (@grafanabot)
1e7a0c9738 [v9.4.x] Influxdb: Handle legacy Influxdb influxql annotations with target in migration (#67503)
Influxdb: Handle legacy Influxdb influxql annotations with target in migration (#63225)

* handle legacy influxdb annotations with target in migration

* add types

* don't check tags that are empty strings and give annotation a type

(cherry picked from commit 7a3f7e26ce)

Co-authored-by: Brendan O'Handley <brendan.ohandley@grafana.com>
2023-04-28 08:55:26 -04:00
Grot (@grafanabot)
82f3e6f5a7 [v9.4.x] docs: update dashboard settings page (#67430)
docs: update dashboard settings page (#67359)

Update index.md

(cherry picked from commit 55c36b04ca)

Co-authored-by: MattiasSegerdahl <102952046+MattiasSegerdahl@users.noreply.github.com>
2023-04-27 13:49:22 -04:00
Christopher Moyer
f5f29e203b [Docs 9.4x] Update configure tracing (#67163) (#67414)
Update configure tracing (#67163)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
(cherry picked from commit 97ddfa631b)

Co-authored-by: MattiasSegerdahl <102952046+MattiasSegerdahl@users.noreply.github.com>
2023-04-27 11:53:06 -05:00
Grot (@grafanabot)
59898b231c [v9.4.x] Docs: Fix broken links to section on Variable syntax page (#67409)
Docs: Fix broken links to section on Variable syntax page (#67340)

These links have a trailing slash which don't work when linking to a
specific element.

(cherry picked from commit 278a8fccc9)

Co-authored-by: Eric Wang <2069450+ericdwang@users.noreply.github.com>
2023-04-27 12:09:24 -04:00
Horst Gutmann
0fdb063576 [v9.4.x] Chore: Update SAML lib (#828)
Update SAML lib
2023-04-27 14:36:34 +03:00
Horst Gutmann
6d1b00c745 AuthJWT: Fix JWT query param leak (CVE-2023-1387) [9.4.x] (#823)
* fix JWT query param leak

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
Co-authored-by: Kalle Persson <kalle.persson@grafana.com>
(cherry picked from commit 9e205a0)

* skip broken test

(cherry picked from commit 58e235a)
2023-04-27 14:36:34 +03:00
Grot (@grafanabot)
44c3c5f269 [v9.4.x] Alerting: Fix misleading status code in provisioning API (#67357)
Alerting: Fix misleading status code in provisioning API (#67331)

Fixes #66249

(cherry picked from commit dfc99cdd19)

Co-authored-by: Uwe Sommerlatt <uwe.sommerlatt@gmail.com>
2023-04-27 11:41:38 +03:00
Grot (@grafanabot)
ded351dc79 [v9.4.x] Azure Monitor: Fix bug that was not showing resources for certain locations (#66617)
Azure Monitor: Fix bug that was not showing resources for certain locations (#66502)

(cherry picked from commit d43482a463)

Co-authored-by: Alyssa Bull <58453566+alyssabull@users.noreply.github.com>
2023-04-26 15:38:46 +03:00
Grot (@grafanabot)
2a6ac647d2 [v9.4.x] Changelog: Updated changelog for 9.4.9 (#67265)
Changelog: Updated changelog for 9.4.9 (#67264)

(cherry picked from commit d5bad429dd)
2023-04-26 12:22:47 +03:00
Grot (@grafanabot)
ac8fd7966a Release: Bump version to 9.4.9 (#67261)
"Release: Updated versions in package to 9.4.9"
2023-04-26 12:09:29 +03:00
Grot (@grafanabot)
eb2d0db641 [v9.4.x] Doc: Fix typo (#67242)
Doc: Fix typo (#66929)

Update index.md

(cherry picked from commit ff61772218)

Co-authored-by: oneoneonepig <oneoneonepig@users.noreply.github.com>
2023-04-25 14:28:10 -05:00
Grot (@grafanabot)
46232f03bb [v9.4.x] docs: Update Screenshot (#67235)
Update Screenshot (#67233)

(cherry picked from commit ad964a0e1d)

Co-authored-by: Stefan Dunkler <stefan.dun@gmail.com>
2023-04-25 14:47:38 -04:00
Grot (@grafanabot)
ffe711cb14 [v9.4.x] Expressions/threshold: Fix incorrect thresholds args length (#66925)
Expressions/threshold: Fix incorrect thresholds args length (#66859)

(cherry picked from commit 350de3f3bf)

Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2023-04-20 13:16:54 +02:00
Grot (@grafanabot)
63347e0da2 [v9.4.x] Docs: adds legacy wording to api docs (#66941)
Docs: adds legacy wording to api docs (#66937)

adds legacy wording to api docs

(cherry picked from commit 9b529ef0cd)

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
2023-04-20 11:13:24 +00:00
Gilles De Mey
647edf7f58 Alerting: Fix share URL for Prometheus rules on subpath (#66752) (#66802) 2023-04-20 11:29:37 +02:00
Grot (@grafanabot)
4a7153cabe [v9.4.x] AzureMonitor: Ensure dimension labels are consistent (#66873)
AzureMonitor: Ensure dimension labels are consistent (#66783)

Ensure dimension labels are consistent

(cherry picked from commit c161b28f29)

Co-authored-by: Andreas Christou <andreas.christou@grafana.com>
2023-04-19 19:17:52 +03:00
Grot (@grafanabot)
1f415749a0 [v9.4.x] [docs] remove auth/saml alias from team sync page (#66855)
[docs] remove auth/saml alias from team sync page (#66796)

removed auth/saml alias from team sync page

(cherry picked from commit 60e6ff1038)

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
2023-04-19 10:00:55 -04:00
Emil Tullstedt
e37bbc7178 Chore: Upgrade Go to 1.20.3 (#66836)
Backport of #66264.
2023-04-19 14:00:22 +02:00
Grot (@grafanabot)
50d9084d35 [v9.4.x] CloudMonitor: Correctly re-render VisualMetricQueryEditor on TimeRange updates (#66786)
CloudMonitor: Correctly re-render `VisualMetricQueryEditor` on `TimeRange` updates (#66756)

Compare string value rather than object

(cherry picked from commit adf12d0e90)

Co-authored-by: Andreas Christou <andreas.christou@grafana.com>
2023-04-18 16:34:55 +00:00
Grot (@grafanabot)
f650293066 [v9.4.x] Update index.md (#66717)
Update index.md (#66698)

The useful links were down as they were using /docs/grafana/next/ instead of /docs/grafana/latest/ in the path

(cherry picked from commit 58e3b3a90e)

Co-authored-by: Sébastien Dauphin <dauphin.sebastien@gmail.com>
2023-04-18 14:02:35 +02:00
Grot (@grafanabot)
a7ac9d0b3b [v9.4.x] Trace View: Update the queryType to traceql for checking if same trace when clicking span link (#66670)
Trace View: Update the queryType to traceql for checking if same trace when clicking span link (#66645)

* TraceView: update the queryType to traceql for checking if same trace when clicking span link

* TraceView: linting

* TraceView: remove traceid check completely

(cherry picked from commit 6462c81f81)

Co-authored-by: Eric Mustin <mustin.eric@gmail.com>
2023-04-18 01:01:36 +01:00
Grot (@grafanabot)
36470ebcf3 [v9.4.x] docs: add missing alias (#66675)
docs: add missing alias (#66621)

added missing alias

(cherry picked from commit 2b7f41f4df)

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
2023-04-17 10:09:14 -04:00
Grot (@grafanabot)
5d2034188b [v9.4.x] removed duplicate query data source section (#66681)
removed duplicate query data source section (#66605)

(cherry picked from commit 1e53b29eee)

Co-authored-by: lwandz13 <126723338+lwandz13@users.noreply.github.com>
2023-04-17 06:50:16 -07:00
Grot (@grafanabot)
b4d141ed1c [v9.4.x] Alerting: Update migration to put alerts to the default folder if dashboard folder is missing (#66593)
Alerting: Update migration to put alerts to the default folder if dashboard folder is missing (#65577)

* extract function

* use context logger

* put alert to general folder if folder is missing

* move folderHelper init

* add test

* Update pkg/services/sqlstore/migrations/ualert/ualert.go

Co-authored-by: Matthew Jacobson <matthew.jacobson@grafana.com>

---------

Co-authored-by: Matthew Jacobson <matthew.jacobson@grafana.com>
(cherry picked from commit 7b2f44762e)

Co-authored-by: Yuri Tseretyan <yuriy.tseretyan@grafana.com>
2023-04-15 08:08:57 +02:00
Isabel
8f761197a4 [v9.4.x] docs: put the numbers before dashboard elements (#66614)
resolving merge conflict for backport PR

Co-authored-by: samu6851 <samuel.oswalt@grafana.com>
2023-04-14 16:12:26 -04:00
Grot (@grafanabot)
d6785c9223 [v9.4.x] Google Cloud Monitoring: Fix project variable (#66602)
Google Cloud Monitoring: Fix project variable (#66524)

Google Cloud Monitoring: fix project variable

Also fix typo found while debugging

(cherry picked from commit 02951e8a26)

Co-authored-by: Adam Simpson <adam@adamsimpson.net>
2023-04-14 15:29:30 +00:00
Grot (@grafanabot)
6286cba8ee [v9.4.x] InfluxDB: Fix querying with hardcoded retention policy (#66587)
InfluxDB: Fix querying with hardcoded retention policy (#66466)

* Use default retention policy instead of hardcoded retention policy

* Load retention policies for the editor

* Fix the typo

* Add more comment line

* Update comment

* Better error message

* Put back getTagKeys and getTagValues

* Fix unit test

(cherry picked from commit 6d53c87862)

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
2023-04-14 16:18:37 +03:00
lwandz13
0ec31973de [v9.4.x]docs:remove duplicate exemplars section (#66398) (#66421)
remove duplicate exemplars section (#66398)

(cherry picked from commit 5197fca70c)
Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2023-04-13 06:53:35 -07:00
Grot (@grafanabot)
cd8cd0f246 [v9.4.x] Auth: Remove the session cookie only if it's invalid or revoked (#66430)
Auth: Remove the session cookie only if it's invalid or revoked (#65984)

Remove the cookie if it's invalid or revoked

(cherry picked from commit 4cac95d1c2)

Co-authored-by: Misi <mgyongyosi@users.noreply.github.com>
2023-04-13 09:53:31 +02:00
Grot (@grafanabot)
21e2f26688 [v9.4.x] InfluxDB: Fix Interpolation when querying variables (#66393)
InfluxDB: Fix Interpolation when querying variables (#65875)

Interpolate variables with InfluxQueryModel

(cherry picked from commit 4e71c91cfd)

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
2023-04-12 18:01:15 +03:00
Grot (@grafanabot)
49680128cd [v9.4.x] Expressions: Fix expression load with legacy UID -100 (#66387)
Expressions: Fix expression load with legacy UID -100 (#65950)

* Fix expressions instance settings loading

* Introduce a new method to get name or uid

* Update public/app/features/plugins/datasource_srv.ts

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>

* Move getNameOrUid method outside the class

---------

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
(cherry picked from commit d4bd024951)

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
2023-04-12 16:53:09 +02:00
Grot (@grafanabot)
edae149230 [v9.4.x] AccessControl: Allow editors to access GET /api/datasources (#66375)
AccessControl: Allow editors to access GET /api/datasources (#66343)

Allow editors to access GET /datasources

(cherry picked from commit 2c21090931)

Co-authored-by: Misi <mgyongyosi@users.noreply.github.com>
2023-04-12 15:55:33 +02:00
Dimitris Sotirakis
0366e6f469 [v9.4.x] CI: Split /bin/build artifacts * subcommand (#66005) (#66344)
CI: Split `/bin/build artifacts *` subcommand (#66005)

* Split go files

* Modify publishartifacts.go

* Split main

* FIXME: Temp add GCSCopy to gcloud/storage

* Fix lint

* Exported flags

* Update starlark - make drone

* Further backend lint fixes

* Add fallback_test.go

* Fix go imports order

* make drone

* Remove GCSCopy from static assets

* Remove GCSCopy from storybook

* Fix lint

* Remove GCSCopy

* Remove success logline

* drone yaml cleanup

* Add artifacts-editions flag

* Fix starlark

* Add default sting slice in artifacts packages command

(cherry picked from commit 24d348f804)

# Conflicts:
#	.drone.yml
2023-04-12 12:36:33 +03:00
Isabel
0a2401f393 [v9.4] docs: update broken link (#66321)
fixed merge conflict
2023-04-11 16:22:51 -04:00
Grot (@grafanabot)
bca5541355 [v9.4.x] Remove "Open source" label from all "RBAC" pages (#66247)
Remove "Open source" label from all "RBAC" pages (#66129)

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
(cherry picked from commit dec3361331)

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
2023-04-11 11:39:52 +03:00
Grot (@grafanabot)
a5b8b383e6 [v9.4.x] Remove "Open source" label from "Recorded queries" page (#66251)
Remove "Open source" label from "Recorded queries" page (#66127)

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
(cherry picked from commit a5499bbf70)

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
2023-04-11 11:38:44 +03:00
Grot (@grafanabot)
19cc5aae59 [v9.4.x] fixed broken links (#66178)
fixed broken links (#66153)

(cherry picked from commit ce00465d9b)

Co-authored-by: lwandz13 <126723338+lwandz13@users.noreply.github.com>
2023-04-07 19:06:30 +03:00
Grot (@grafanabot)
2a3f141ca5 [v9.4.x] Alerting: Fix explore link in alert detail view (#66165)
Alerting: Fix explore link in alert detail view (#66106)

(cherry picked from commit cb8a5b2c96)

Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2023-04-07 14:35:19 +02:00
Grot (@grafanabot)
bfb21e7621 [v9.4.x] Alerting: Fix docs link when creating or editing rules (#66163)
Alerting: Fix docs link when creating or editing rules (#66019)

(cherry picked from commit 3e12b72f58)

Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-04-07 14:41:38 +03:00
Grot (@grafanabot)
cd323622b7 [v9.4.x] CloudMonitoring: Add project selector for MQL editor[fix] (#65844)
CloudMonitoring: Add project selector for MQL editor[fix] (#65567)

(cherry picked from commit 81cb84d098)

Co-authored-by: Alyssa Bull <58453566+alyssabull@users.noreply.github.com>
2023-04-06 20:10:29 +00:00
Grot (@grafanabot)
b0c69c9eec [v9.4.x] Docs: Small fixes for Template Variables Doc (#66138)
Docs: Small fixes for Template Variables Doc (#65947)

* Docs: Small fixes for Template Variables Doc

* Docs: Minor fix to Variables Docs

- Added missing word

* Update docs/sources/dashboards/variables/add-template-variables/index.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* empty commit to trigger linting

* small change to trigger linting

---------

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
Co-authored-by: Isabel Matwawana <isabel.matwawana@grafana.com>
(cherry picked from commit 3685dd56e1)

Co-authored-by: sarah-spang <86264026+sarah-spang@users.noreply.github.com>
2023-04-06 14:35:33 -05:00
Grot (@grafanabot)
0c3bf3f0e9 [v9.4.x] Docs: Add content to what's new 9.4 (#66122)
Docs: Add content to what's new 9.4 (#65895)

* Docs: Add content to what's new 9.4

* Update docs/sources/whatsnew/whats-new-in-v9-4.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/whatsnew/whats-new-in-v9-4.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
(cherry picked from commit 75f5cb061e)

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
2023-04-06 07:50:58 -05:00
Grot (@grafanabot)
b40bf8b3f5 [v9.4.x] docs: fixes link (#66068)
docs: fixes link (#66051)

* fixes link

* Update docs/sources/setup-grafana/configure-security/configure-authentication/enhanced-ldap/index.md

Co-authored-by: melGL <81323402+melgl@users.noreply.github.com>

---------

Co-authored-by: melGL <81323402+melgl@users.noreply.github.com>
(cherry picked from commit 421b911c45)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-04-06 07:21:24 -05:00
Grot (@grafanabot)
876f6e8727 [v9.4.x] Docs: Add example to extract a specific label value (#66018)
Docs: Add the index function

(cherry picked from commit a39190b613)

Co-authored-by: Simon Crute <simonc6372@users.noreply.github.com>
2023-04-05 15:15:53 +01:00
Grot (@grafanabot)
1148da45d3 [v9.4.x] Docs: Updated Grafana OSS Introduction (#66024)
Docs: Updated Grafana OSS Introduction (#66004)

* Added Phlare and added static data sources to intro instead of it just being TSDB sources

* Update docs/sources/introduction/_index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/introduction/_index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
(cherry picked from commit e8813916c9)

Co-authored-by: Alex Close <alex.kirtley-close@grafana.com>
2023-04-05 08:23:53 -05:00
Eric Leijonmarck
d37fa06f05 [v9.4.x] Auth: Fix orgrole picker disabled if isSynced user (#65553)
Auth: Fix orgrole picker disabled if isSynced user (#64033)

* fix: disable orgrolepicker if externaluser is synced

* add disable to role picker

* just took me 2 hours to center the icon

* wip

* fix: check externallySyncedUser for API call

* remove check from store

* add: tests

* refactor authproxy and made tests run

* add: feature toggle

* set feature toggle for tests

* add: IsProviderEnabled

* refactor: featuretoggle name

* IsProviderEnabled tests

* add specific tests for isProviderEnabled

* fix: org_user tests

* add: owner to featuretoggle

* add missing authlabels

* remove fmt

* feature toggle

* change config

* add test for a different authmodule

* test refactor

* gen feature toggle again

* fix basic auth user able to change the org role

* test for basic auth role

* make err.base to error

* lowered lvl of log and input mesg

(cherry picked from commit 3cd952b8ba)
2023-04-05 09:55:43 +01:00
Grot (@grafanabot)
f9f0dd8b1b [v9.4.x] Build: Add CloudMode to build versions (#65987)
Build: Add CloudMode to build versions (#65651)

* Add CloudMode to build versions

* Use linux-amd64 variant without musl for cloud mode

* Add cloud mode to version folder on package upload

* Use musl variant for CloudMode

* Only sign rpm packages if there's any to sign

* Remove trailing whitespace

(cherry picked from commit 8f282b8a6e)

Co-authored-by: Guilherme Caulada <guilherme.caulada@grafana.com>
2023-04-05 11:37:03 +03:00
Grot (@grafanabot)
1daa365107 [v9.4.x] Docs: Added note to contact Support (#65958)
Docs: Added note to contact Support (#65235)

* Added note to contact Support

* Update docs/sources/setup-grafana/configure-security/configure-authentication/enhanced-ldap/index.md

* Update docs/sources/setup-grafana/configure-security/configure-authentication/enhanced-ldap/index.md

* makes prettier

* Apply suggestions from code review

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
(cherry picked from commit 445734888b)

Co-authored-by: melGL <81323402+melgl@users.noreply.github.com>
2023-04-04 21:42:47 +03:00
Konrad Lalik
cd4cb967a5 [v9.4.x] Alerting: Disable alerting incompatible panels in the dashboard picke… (#65780)
* Alerting: Disable alerting incompatible panels in the dashboard picker (#65341)

* Hide dashboard hint when dashboard already selected

* Disable panels of types other than graph and timeseries

* Add a test checking disabled panels

* Make all panels selectable

* Fix tests

(cherry picked from commit bde77e4f79)

* Skip flakey test
2023-04-04 09:54:01 +02:00
Dimitris Sotirakis
285d5809c5 [v9.4.x] Backport #65797 and #65806 to v9.4.x (#65857)
* CI: Make `init-enterprise` depend on `grabpl` (#65797)

Make init-enterprise depend on grabpl

# Conflicts:
#	.drone.yml

(cherry picked from commit 821633c796)

# Conflicts:
#	.drone.yml
#	scripts/drone/pipelines/test_frontend.star

* CI: Exclude cloud related tags from tag events  (#65806)

* Exclude cloud related tags

* Fix starlark lint errors

(cherry picked from commit a18ea77aac)

# Conflicts:
#	.drone.yml
2023-04-04 08:36:57 +02:00
Grot (@grafanabot)
7d7751d5b0 [v9.4.x] update enhanced-ldap (#65867)
update enhanced-ldap (#65687)

* update enhanced-ldap

documenting a potential issue with ldap active sync, when search filter and username attributes do not match.

* Update docs/sources/setup-grafana/configure-security/configure-authentication/enhanced-ldap/index.md

* formats example

* Update docs/sources/setup-grafana/configure-security/configure-authentication/enhanced-ldap/index.md

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
(cherry picked from commit 99ac39f0d2)

Co-authored-by: annelaurefroment <49911675+annelaurefroment@users.noreply.github.com>
2023-04-03 11:24:08 -05:00
Grot (@grafanabot)
53d2e59cff [v9.4.x] Docs: Add transformations doc link for What's New v9.2 (#65850)
Docs: Add transformations doc link for What's New v9.2 (#65673)

* Add transformations doc link

Add transformations doc link to `Transformations: INNER JOINs` section.

Related issue: https://github.com/grafana/grafana/issues/65671

* Apply suggestions from code review

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
(cherry picked from commit b86c0bc4fa)

Co-authored-by: Christine Wang <wang.christiney@gmail.com>
2023-04-03 11:17:54 -05:00
Horst Gutmann
bf3f1368a7 [v9.4.x] CI: Move release integration pipeline to standalone promotion pipeline (#65787) (#65800)
CI: Move release integration pipeline to standalone promotion pipeline (#65787)

(cherry picked from commit e9aef20eb4)
2023-04-03 14:08:05 +03:00
Grot (@grafanabot)
8500eb1c18 [v9.4.x] Alerting: Fix integration test for creating silences (#65790)
Alerting: Fix integration test for creating silences (#65722)

* fix integration test for creating silences

to create correct silence with endsAt in the future

* Update api_alertmanager_test.go

(cherry picked from commit ed8628e39d)

Co-authored-by: Yuri Tseretyan <yuriy.tseretyan@grafana.com>
2023-04-03 12:45:19 +03:00
Grot (@grafanabot)
f13eff4287 [v9.4.x] Angular: Prevent angular from loading when disabled (#65777)
* Angular: Prevent angular from loading when disabled (#65755)

* Angular: Prevent angular from loading when disabled

* remove stuff

(cherry picked from commit 093498a03b)

* Update

---------

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2023-04-03 12:10:06 +03:00
Sofia Papagiannaki
ecaeafd4f3 [9.4.x]: API: Fix "Updated by" Column in dashboard versions table (#65626)
* API: Fix  "Updated by" Column in dashboard versions table (#65351)

* API: Fix dashboard versions created by field

* Add tests

* Update OpenAPI specs

* Apply suggestion from code review

(cherry picked from commit 3cd3bb00ec)

* Fix guardian call
2023-03-31 11:56:36 +02:00
Alexander Weaver
e9d53761fb Alerting: Introduce proper feature toggles for common state history backend combinations (#65650)
* Alerting: Introduce proper feature toggles for common state history backend combinations (#65497)

* define 3 feature toggles for rollout phases

* Pass feature toggles along

* Implement first feature toggle

* Try a different strategy with fall-throughs to specific configurations

* Apply toggle overrides once outside of backend composition

* Emit log messages when we coerce backends

* Run code generator for feature toggle files

* Improve wording in flag descs

* Re-run generator

* Use code-generated constants instead of plain strings

* Use converted enum values rather than strings for pre-parsing

(cherry picked from commit b2abb63286)

* Remove generated file that is only present in future versions
2023-03-30 14:29:43 -05:00
Grot (@grafanabot)
66e3f8dc23 [v9.4.x] Docs: Fix markup for URL (#65649)
Docs: Fix markup for URL (#65576)

* Docs: Fix markup for URL

* updates absolute URL to a relref

---------

Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
(cherry picked from commit 940768cf76)

Co-authored-by: sarah-spang <86264026+sarah-spang@users.noreply.github.com>
2023-03-30 21:59:14 +03:00
Grot (@grafanabot)
fc6b8f9c6c [v9.4.x] Give more detail and context on http_addr in grafana.ini (#65644)
Give more detail and context on http_addr in grafana.ini (#65187)

* Give more detail and context on http_addr in grafana.ini

This particular configuration item is misleadingly named (it's about networking addresses rather than HTTP) and there are a bunch of ways users can misread, misconfigure, and create a situation where grafana won't start due to a bind error.

I'm trying to outline a couple of extra things about what this covers and provide good default advice, leaving room for specialists who know what they're doing to still use this, with more clarity.

* Update _index.md

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update _index.md

removed recommendation note about http_addr

* makes prettier

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
(cherry picked from commit 765073a776)

Co-authored-by: David Allen <david.allen@grafana.com>
2023-03-30 12:34:10 -05:00
Alexander Weaver
76c3e1863b Alerting: Fix and re-enable filters instance labels in log line test (#65622)
Alerting: Fix and re-enable `filters instance labels in log line` test (#65618)

Fix and reenable test

(cherry picked from commit 5e87ea745d)
2023-03-30 09:44:48 -05:00
Grot (@grafanabot)
a3ef453ff6 [v9.4.x] Docs: updates type to integration (#65592)
Docs: updates type to integration (#65591)

* Docs: updates type to integration

* fixes link

* fixes links

(cherry picked from commit c77aa11545)

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
2023-03-30 10:27:49 +02:00
Grot (@grafanabot)
37f2a0aa32 [v9.4.x] Docs: Fix Nightly Builds URL (#65570)
Docs: Fix Nightly Builds URL (#65552)

Update _index.md

URL for Nightly Builds leads to standard download page.
- Updated to direct to correct Nightly Downloads page: https://grafana.com/grafana/download/nightly?edition=oss

(cherry picked from commit 8717cd0761)

Co-authored-by: sarah-spang <86264026+sarah-spang@users.noreply.github.com>
2023-03-29 16:39:37 -05:00
Grot (@grafanabot)
1b9abfeec8 [v9.4.x] Docs: Update version for "What's New" section (#65571)
Docs: Update version for "What's New" section (#65554)

(cherry picked from commit 906086c91b)

Co-authored-by: sarah-spang <86264026+sarah-spang@users.noreply.github.com>
2023-03-29 16:39:17 -05:00
Alexander Weaver
3bf0352fbb Alerting: No longer index state history log streams by instance labels (#65563)
Alerting: No longer index state history log streams by instance labels (#65474)

* Remove private labels

* No longer index by instance labels

* Labels are now invariant, only build them once

* Remove bucketing since everything is in a single stream

* Refactor statesToStreams to only return a single unified log stream

* Don't query on labels that no longer exist

* Move selector logic to loki layer, genericize client to work in terms of straight logQL

* Add support for line-level label filters in query

* Combine existing selector tests for better parallelism

* Tests for logQL construction

* Underscore instead of dot for unwrapping labels in logql

(cherry picked from commit a416100abc)
2023-03-29 16:11:12 -05:00
ismail simsek
132900fe2e [v9.4.x] InfluxDB: Fix sending retention policy with InfluxQL queries (#65532)
InfluxDB: Fix sending retention policy with InfluxQL queries (#63820)

* Send retention policy if that is specified

* Define the type

* Update default retention policy name

* Update unit tests

* fix unit tests

* fix unit tests again

* Load retention policies at first

* Fix tests

* Fix Editor tests

* Remove unused code

* A simpler approach

* Even simpler

* Even simpler

(cherry picked from commit 0aee7338ad)
2023-03-29 21:57:44 +03:00
Grot (@grafanabot)
009fa712c2 [v9.4.x] configure HTTPS documentation (#65560)
configure HTTPS documentation  (#65271)

* configure HTTPS settings for grafana

* Apply suggestions from code review

* Apply suggestions from code review

* rewrites and restructures content

* Apply suggestions from code review

* PR feedback review; https docs

* Update docs/sources/setup-grafana/set-up-https.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/set-up-https.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/set-up-https.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/set-up-https.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/set-up-https.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/set-up-https.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/set-up-https.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* errata

* make prettier

* Apply suggestions from code review

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
(cherry picked from commit 4839f1543a)

Co-authored-by: David Allen <david.allen@grafana.com>
2023-03-29 13:23:49 -05:00
Yuri Tseretyan
413ac1ec7d Chore: Update alerting to commit 518e63bb07c5 (#65488)
* update alerting module to 518e63bb07c5
* update slack test to cover json and text response content-type cases
2023-03-29 13:07:06 -04:00
Grot (@grafanabot)
266a7407f6 [v9.4.x] Dashboards: Evaluate provisioned dashboard titles in a backwards compatible way (#65440)
Backport from #65184 using github.com/xorcare/pointer instead of the newer util.Pointer.

(cherry picked from commit b210a39cb7)

---------

Co-authored-by: Emil Tullstedt <emil.tullstedt@grafana.com>
2023-03-29 11:25:44 +02:00
Grot (@grafanabot)
90db06d65b [v9.4.x] docs: fix enhanced ldap alias (#65485)
docs: fix enhanced ldap alias (#65478)

fixed alias

(cherry picked from commit 4b29b1d741)

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
2023-03-28 14:43:42 -05:00
Grot (@grafanabot)
a080d453b4 [v9.4.x] docs: update elasticsearch grafana play link (#65480)
docs: update elasticsearch grafana play link (#65280)

(cherry picked from commit 0d3e0e7cc4)

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
2023-03-28 14:30:33 -05:00
Grot (@grafanabot)
8374ef84df [v9.4.x] Remove redundant content or delete this page entirely (#65473)
Remove redundant content or delete this page entirely (#65446)

* Remove redundant content or delete this page entirely

The top of the page has redundant content pitching Grafana Cloud.

"You can also configure the MS SQL Server data source on a Grafana Cloud instance without having to host Grafana yourself."  Which is directly under the highlighted area explaining the same thing.  The same content is floating in the right side of all the pages as well.

Removed "> **Note:** You must install Grafana 5.1+ in order to use the integrated MS SQL data source."

Wait, why does this page exist if the data source page has the relevant updated content?  https://grafana.com/docs/grafana/latest/datasources/mssql/

* makes prettier

---------

Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
(cherry picked from commit 2b73f8cfd5)

Co-authored-by: mallettjared <110853992+mallettjared@users.noreply.github.com>
2023-03-28 12:58:52 -05:00
Gilles De Mey
ef6476d92b Alerting: Use displayNameFromDS if available in preview (#65342) (#65445) 2023-03-28 18:15:52 +02:00
Grot (@grafanabot)
144efd25b8 [v9.4.x] MegaMenu: Fixes mega menu showing scroll indicator when it shouldn't (#65465)
MegaMenu: Fixes mega menu showing scroll indicator when it shouldn't (#65452)

* MegaMenu: Fixes mega menu showing scroll indicator when it shouldn't

* fixing css

(cherry picked from commit 273e05a9a2)

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2023-03-28 18:55:09 +03:00
Grot (@grafanabot)
cb5c92a375 [v9.4.x] CI: Allow overwriting of existing GitHub release assets (#65459)
CI: Allow overwriting of existing GitHub release assets (#65127)

* CI: Allow overwriting of existing GitHub release assets

This closes #63698

* Use c for *cli.Context in publishgithub.go

(cherry picked from commit 4ab3bd6f7e)

Co-authored-by: Horst Gutmann <horst.gutmann@grafana.com>
2023-03-28 17:31:14 +02:00
Gilles De Mey
6a73b2b726 Email: Mark HTML comments as "safe" in email templates (#64546) (#65443) 2023-03-28 17:26:15 +02:00
Grot (@grafanabot)
d3c37d28ed [v9.4.x] Alerting: Add alert instance labels to Loki log lines in addition to stream labels (#65454)
Alerting: Add alert instance labels to Loki log lines in addition to stream labels (#65403)

Add instance labels to log line

(cherry picked from commit de1637afe5)

Co-authored-by: Alexander Weaver <weaver.alex.d@gmail.com>
2023-03-28 17:11:43 +03:00
Grot (@grafanabot)
1b8d220d96 [v9.4.x] Alerting: Add "backend" label to state history writes metrics (#65453)
Alerting: Add "backend" label to state history writes metrics (#65395)

* Add backend label to state history writes metrics

* Update test expectations

(cherry picked from commit dd04757fc9)

Co-authored-by: Alexander Weaver <weaver.alex.d@gmail.com>
2023-03-28 17:06:57 +03:00
Grot (@grafanabot)
8fad42fa6f [v9.4.x] DateTimePicker: Can now select time correctly (#65431) 2023-03-28 13:11:52 +02:00
Grot (@grafanabot)
9d00d07a6a [v9.4.x] Alerting: Fix wrong text in step4 (#65348)
Co-authored-by: Sonia Aguilar <33540275+soniaAguilarPeiron@users.noreply.github.com>
Fix wrong text in step4 (#65279)
2023-03-28 13:04:32 +02:00
Grot (@grafanabot)
7b874aa327 [v9.4.x] Increase coverage of 'Grafana Cloud' labels (#64752)
Increase coverage of 'Grafana Cloud' labels (#64646)

* Add 'Grafana Cloud' label to content

All pages are applicable to both 'Open source' and 'Grafana Cloud'

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Add 'Grafana Cloud' label to administration content with some exceptions

- Enterprise licensing is 'Open source' and 'Enterprise'.
- 'Manage Organizations', 'Provision Grafana', and 'Stats and License' are 'Open source' only.

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Remove OSS from enterprise-licensing content

* Apply suggestions from code review

---------

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
(cherry picked from commit dca5adeb98)

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
2023-03-28 11:51:36 +01:00
Will Browne
0d7efc076c [v9.4.x] Plugins: Markdown fetch retry with lowercase (#65388)
cherry pick
2023-03-28 12:19:20 +02:00
Grot (@grafanabot)
d14faf3cc0 [v9.4.x] Docs: Add 'tenant_id' for Loki clients (Auditing & Analytics) (#65401)
Docs: Add 'tenant_id' for Loki clients (Auditing & Analytics) (#63098)

* Docs: Add 'tenant_id' for Loki clients (Auditing & Analytics)

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: Mitch Seaman <mjseaman@users.noreply.github.com>

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Mitch Seaman <mjseaman@users.noreply.github.com>
(cherry picked from commit f9abd8608e)

Co-authored-by: Joan López de la Franca Beltran <5459617+joanlopez@users.noreply.github.com>
2023-03-27 23:49:19 +03:00
Sofia Papagiannaki
67dd929f5e [v9.4.x]: Upgrade golang.org/x/net to 0.7.0 (#65337)
* go mod tidy

* go get golang.org/x/net@v0.7.0
2023-03-27 17:57:49 +03:00
Grot (@grafanabot)
72dad41413 [v9.4.x] Navigation: Sanitize homeUrl (#65365)
Navigation: Sanitize homeUrl (#65293)

sanitize homeUrl

(cherry picked from commit f948482386)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-03-27 15:41:32 +01:00
Dimitris Sotirakis
84e9267612 [v9.4.x] CI: Cleanup unnecessary grabpl dependencies (#65330) (#65347)
CI: Cleanup unnecessary `grabpl` dependencies (#65330)

* Remove unnecessary grabpl dependencies

* Revert test-frontend change

(cherry picked from commit 89d642e001)

# Conflicts:
#	.drone.yml
2023-03-27 16:41:23 +03:00
Virginia Cepeda
9bafdcb72a Alerting: Improve showing nextEvaluationDate for rules (#65205) (#65227)
* Improve showing nextEvaluationDate for rules

Co-Authored-By: Konrad Lalik <konradlalik@gmail.com>

* Improve imports and comments

---------

Co-authored-by: Konrad Lalik <konradlalik@gmail.com>
(cherry picked from commit b90aed4fd7)
2023-03-27 10:32:20 -03:00
Grot (@grafanabot)
bb3e08a0a1 [v9.4.x] Alerting: Fix stats that display alert count when using unified alerting (#64951)
* Alerting: Fix stats that display alert count when using unified alerting (#64852)

* Alerting: Fix stats when using unified alerting

(cherry picked from commit 02a8f62021)

* bundle services is not needed for 9.4.x

---------

Co-authored-by: gotjosh <josue.abreu@gmail.com>
2023-03-27 14:30:27 +01:00
Grot (@grafanabot)
0680231781 [v9.4.x] Database: Don't sleep 10ms before every request (#65334)
Database: Don't sleep 10ms before every request (#64832)

Previously every DB operation would wait 10ms before even trying.
Now we try first, and defer creating the ticker until we need it.

(cherry picked from commit f4a5f91496)

Co-authored-by: Bryan Boreham <bjboreham@gmail.com>
2023-03-27 12:30:50 +03:00
Grot (@grafanabot)
8288d962ef [v9.4.x] Docs: Use correct function in labels and annotations docs (#65253)
Docs: Use correct function in labels and annotations docs (#65032)

Use correct function in labels and annotations docs

(cherry picked from commit 0464aebc8e)

Co-authored-by: Martin Beentjes <martinbeentjes@users.noreply.github.com>
2023-03-27 11:10:12 +02:00
Dimitris Sotirakis
bd37c60b50 [v9.4.x] CI: Remove grabpl dependency from publish-packages steps (#65329) (#65333)
CI: Remove `grabpl` dependency from `publish-packages` steps (#65329)

Remove grabpl dependency from publish packages

(cherry picked from commit 3b00d2c273)

# Conflicts:
#	.drone.yml
2023-03-27 11:29:02 +03:00
Jack Baldry
e37fb197b2 [v9.4.x] Add @imatwawana to CODEOWNERS for her area of responsibility (#65158)
Add @imatwawana to CODEOWNERS for her area of responsibility (#64963)


(cherry picked from commit 8941ca813c)

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2023-03-26 10:42:44 +01:00
Grot (@grafanabot)
0f87c31a2c [v9.4.x] Changelog: Updated changelog for 9.4.7 (#65296)
Changelog: Updated changelog for 9.4.7 (#65292)

(cherry picked from commit a02a28f229)
2023-03-23 12:52:45 -05:00
Grot (@grafanabot)
97fc76da27 [v9.4.x] Docs/updates amazon cloudwatch (#65282)
Docs/updates amazon cloudwatch (#64987)

* updated AWS to Amazon in the index file

* edited query editor index file -AWS with Amazon

(cherry picked from commit 0975e53fc0)

Co-authored-by: lwandz13 <126723338+lwandz13@users.noreply.github.com>
2023-03-23 08:50:55 -07:00
Gilles De Mey
54fe185e80 Alerting: Paginate result previews (#65257) (#65273)
Co-authored-by: konrad147 <konradlalik@gmail.com>
Co-authored-by: Sonia Aguilar <soniaaguilarpeiron@gmail.com>
2023-03-23 16:01:52 +01:00
Grot (@grafanabot)
96d1d9981d [v9.4.x] Changelog: Updated changelog for 9.4.7 (#65269)
Changelog: Updated changelog for 9.4.7 (#65268)

(cherry picked from commit da97139489)
2023-03-23 14:28:25 +01:00
Grot (@grafanabot)
f54cf0865a [v9.4.x] Expressions: More robust expression check (#65177)
Expressions: More robust expression check (#65006)

More robust expression check

(cherry picked from commit 1328878ace)

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
2023-03-22 20:57:17 +01:00
Dimitris Sotirakis
ffe9b71a27 [v9.4.x] CD: Remove fetch-images dependency from AWS marketplace automation (#65173) (#65197)
CD: Remove `fetch-images` dependency from AWS marketplace automation (#65173)

* Remove fetch-images dependency

* Fix starlark link

(cherry picked from commit d0be9610f0)

# Conflicts:
#	.drone.yml
2023-03-22 18:56:03 +02:00
Grot (@grafanabot)
4a825cad7b [v9.4.x] Changelog: Updated changelog for 9.4.7 (#65209)
Changelog: Updated changelog for 9.4.7 (#65208)

(cherry picked from commit adcdf190bb)
2023-03-22 17:47:28 +01:00
ismail simsek
ca91072d5b [v9.4.x] Fix xss in Graphite functions tooltip (#805)
Fix xss in Graphite functions tooltip (#804)

(cherry picked from commit 87aad3f11836f810ee1fdfee27827e746ef36055)

Co-authored-by: Ludovic Viaud <ludovic.viaud@gmail.com>
2023-03-22 17:41:54 +01:00
Grot (@grafanabot)
b1c73a9984 [v9.4.x] SQL Datasources: Prevent Call Stack Overflows with Large Numbers of Values for Variable (#65182)
SQL Datasources: Prevent Call Stack Overflows with Large Numbers of Values for Variable (#64937)

* Push values with every map call to avoid hitting the maximum call stack size.

* Add test and refactor to for of

* Use native fill instead of lodash

---------

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
(cherry picked from commit bf687fff45)

Co-authored-by: Kyle Cunningham <codeincarnate@users.noreply.github.com>
2023-03-22 15:17:47 +01:00
Konrad Lalik
721605af13 Alerting: Prometheus-compatible Alertmanager timings editor (#64526) (#65124)
* Alerting: Prometheus-compatible Alertmanager timings editor (#64526)

* Change Alertmanager timings editor

* Update timing inputs for default policy editor

* Switch prom duration inputs in notification policy form

* Fix a11y issues

* Fix validation

* Add timings forms tests

* Fix default policy form and add more tests

* Add notification policy form tests

* Add todo item

* Remove unused code

* Use default timings object to fill placeholder values

(cherry picked from commit d8e32cc929)

* Adjust code and tests to v.9.4 codebase

* Remove unused code, remove TODO item
2023-03-22 13:26:14 +01:00
Grot (@grafanabot)
950b15d0aa [v9.4.x] Alerting: Fix attachment of external labels to Loki state history log streams (#65142)
Alerting: Fix attachment of external labels to Loki state history log streams (#65140)

Fix attachment of external labels, add tests

(cherry picked from commit 07368dec74)

Co-authored-by: Alexander Weaver <weaver.alex.d@gmail.com>
2023-03-22 09:15:44 +02:00
Alexander Weaver
788dc25416 Alerting: Switch to snappy-compressed-protobuf for outgoing push requests to Loki (#65137)
* Alerting: Switch to snappy-compressed-protobuf for outgoing push requests to Loki (#65077)

* Encode with snappy, always

* JSON encoder type

* Headers

* Copy labels formatter from promtail

* Implement snappy-proto encoding

* Create encoder interface, test both encoders, choose snappy-proto by default

* Make encoder configurable at the LokiCfg level

* Export both encoders

* Touch up comment and tests

* Drop unnecessary conversions after move to plain strings to appease linter

(cherry picked from commit bf54f2672e)

* Sample fields got renamed between 9.4 and main
2023-03-21 16:42:01 -05:00
Alexander Weaver
744c1164e7 Alerting: Fix ambiguous handling of equals in labels when bucketing Loki state history streams (#65135)
Alerting: Fix ambiguous handling of equals in labels when bucketing Loki state history streams (#65013)

* Use JSON instead of data.Labels string format as label repr

* Drop debug log line

(cherry picked from commit cc7e5ce62e)
2023-03-21 19:59:57 +02:00
Brendan O'Handley
2c6ad8867f Prometheus: Feedback link for metric encyclopedia plus performance im… (#64773)
Prometheus: Feedback link for metric encyclopedia plus performance improvements (#64576)

* add filtered results

* add feedback link

* correctly debounce fuzzy search thank you leon

* reduce calls to filterMetrics()in letter search

* clean up the alphabet type

* bug fix, filter type should be subtractive

* each filter is don;t explicitly, subtracting from the results of each

* Revert "each filter is don;t explicitly, subtracting from the results of each"

This reverts commit 5648788451.

* each filter is filtered explicitly, one after the other, subtracting from the results of each

(cherry picked from commit 2e4b134743)
2023-03-21 11:56:49 -04:00
Grot (@grafanabot)
4b6a015256 [v9.4.x] Alerting: Elide requests to Loki if nothing should be recorded (#65118)
Alerting: Elide requests to Loki if nothing should be recorded (#65011)

Exit early if no log streams or annotations

(cherry picked from commit e39d7f44c9)

Co-authored-by: Alexander Weaver <weaver.alex.d@gmail.com>
2023-03-21 16:50:47 +02:00
Grot (@grafanabot)
4452c15714 [v9.4.x] Fix x-value being formatted as time when not necessary (#65114)
Fix x-value being formatted as time when not necessary (#65095)

(cherry picked from commit 24ecc7d0dc)

Co-authored-by: Victor Marin <36818606+mdvictor@users.noreply.github.com>
2023-03-21 16:13:14 +02:00
Grot (@grafanabot)
4b95a36e82 [v9.4.x] Docs: fix numbering and rename topic (#65107)
Docs: fix numbering and rename topic (#65093)

* Docs: fix numbering and rename topic

* fixes typo

* removes full stops

* deletes :

(cherry picked from commit 89c65e22d3)

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
2023-03-21 14:14:04 +01:00
Dimitris Sotirakis
612edc2665 [v9.4.x] CI: Update grabpl to 3.0.30 (#65028) (#65091)
CI: Update `grabpl` to `3.0.30` (#65028)

Update grabpl

(cherry picked from commit 4a80233bed)

# Conflicts:
#	.drone.yml
2023-03-21 12:14:17 +02:00
Grot (@grafanabot)
fa2a8b2bd5 [v9.4.x] Docs: Add documentation on how to debug backend plugins (#65088)
Docs: Add documentation on how to debug backend plugins (#64814)

* Docs: Add documentation on how to debug backend plugins

* Changes from PR reviews

* PR review changes

(cherry picked from commit 41b0c17aae)

Co-authored-by: Giuseppe Guerra <giuseppe.guerra@grafana.com>
2023-03-21 10:43:03 +01:00
Horst Gutmann
29d69eb16f [v9.4.x] Update CODEOWNERship for grafana-delivery team (#64973) (#65018)
Update CODEOWNERship for grafana-delivery team (#64973)

(cherry picked from commit 2897ee37bf)
2023-03-21 11:27:45 +02:00
Grot (@grafanabot)
553b90d1e7 [v9.4.x] CloudWatch Logs: Revert "Queries in an expression should run synchronously (#64443)" (#65067)
CloudWatch Logs: Revert "Queries in an expression should run synchronously (#64443)" (#65036)

Revert "CloudWatch Logs: Queries in an expression should run synchronously (#64443)"

This reverts commit 74436d31de.

(cherry picked from commit 972e611f76)

Co-authored-by: Shirley <4163034+fridgepoet@users.noreply.github.com>
2023-03-20 19:51:38 +01:00
Grot (@grafanabot)
50952f0a7a [v9.4.x] [Docs] - Add Warning about Version Downgrade and Alerting to Grafana … (#65062)
[Docs] - Add Warning about Version Downgrade and Alerting to Grafana … (#64896)

* [Docs] - Add Warning about Version Downgrade and Alerting to Grafana v9.4 Upgrade Instructions

Add Warning about Version Downgrade and Alerting to Grafana v9.4 Upgrade Instructions

* Update docs/sources/upgrade-guide/upgrade-v9.4/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/upgrade-guide/upgrade-v9.4/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* makes prettier

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
(cherry picked from commit 661e44ae6d)

Co-authored-by: SeamusGrafana <102023327+SeamusGrafana@users.noreply.github.com>
2023-03-20 13:03:28 -05:00
Grot (@grafanabot)
bc4e9e3215 [v9.4.x] Information about SQLite limitations (#65066)
Information about SQLite limitations (#64990)

* Update _index.md

I am creating this PR to add more content about the SQLite (the default database for Grafana) limitations. SQLite is fine for small environments but not suitable when monitoring many Dashboards and sending lots of alerts frequently.

For e.g. this issue is just from this week and then got followed up by 3-4 more similar issues (all related to SQLite and are linked with this issue)

Closes #64664

By adding more information, will have less frequency of such issues reported by users.

Also, once this PR get submitted, will also create a new PR about the possible workaround to not get the error message "database locked" while using SQLite.

* Update docs/sources/setup-grafana/installation/_index.md

Thank you. Also, can you please add this link to the High Availablity text as hyperlink.

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/installation/_index.md

* Update docs/sources/setup-grafana/installation/_index.md

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
(cherry picked from commit ccfe09d20e)

Co-authored-by: Usman Ahmad <69509548+usmangt@users.noreply.github.com>
2023-03-20 12:06:09 -05:00
Grot (@grafanabot)
6a1d736f03 [v9.4.x] KVStore: Include database field in migration (#65037)
KVStore: Include database field in migration (#62790)

(cherry picked from commit b0213a4877)

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
2023-03-20 12:44:03 +01:00
Konrad Lalik
bf3422740b Alerting: Fix notification policies matcher filter (#64967) 2023-03-20 07:55:50 +01:00
Grot (@grafanabot)
231cb2b835 [v9.4.x] AzureMonitor: Fix query variable migration (#64982)
AzureMonitor: Fix query variable migration (#63991)

* AzureMonitor: Fix query variable migration

Somehow the query object becomes "unwriteable" post 9.4. To workaround
this I clone the query object before doing any migrations which removes
the immutability and allows the migrations to function as they did.

Fixes #63943

* refactor deepClone out to keep object the same

(cherry picked from commit 3498785184)

Co-authored-by: Adam Simpson <adam@adamsimpson.net>
2023-03-18 21:21:40 +02:00
Grot (@grafanabot)
a440178397 [v9.4.x] Vendor errors.Join from Go standard library to avoid version incompatibilities (#64986)
Vendor errors.Join from Go standard library to avoid version incompatibilities (#64985)

Vendor errors.Join from std lib

(cherry picked from commit 40c5713cbd)

Co-authored-by: Alexander Weaver <weaver.alex.d@gmail.com>
2023-03-17 14:42:31 -05:00
Grot (@grafanabot)
85c794d932 [v9.4.x] Alerting: Create new state history "fanout" backend that dispatches to multiple other backends at once (#64983)
Alerting: Create new state history "fanout" backend that dispatches to multiple other backends at once (#64774)

* Rename RecordStatesAsync to Record

* Rename QueryStates to Query

* Implement fanout writes

* Implement primary queries

* Simplify error joining

* Add test for query path

* Add tests for writes and error propagation

* Allow fanout backend to be configured

* Touch up log messages and config validation

* Consistent documentation for all backend structs

* Parse and normalize backend names more consistently against an enum

* Touch-ups to documentation

* Improve clarity around multi-record blocking

* Keep primary and secondaries more distinct

* Rename fanout backend to multiple backend

* Simplify config keys for multi backend mode

(cherry picked from commit a31672fa40)

Co-authored-by: Alexander Weaver <weaver.alex.d@gmail.com>
2023-03-17 20:13:12 +02:00
Grot (@grafanabot)
1f498f9ff7 [v9.4.x] AzureMonitor: Increase wait for credentials to be ready in E2E test (#64980)
AzureMonitor: Increase wait for credentials to be ready in E2E test (#64969)

Increase wait for credentials to be ready

(cherry picked from commit edc47964b6)

Co-authored-by: Andreas Christou <andreas.christou@grafana.com>
2023-03-17 16:56:12 +00:00
Grot (@grafanabot)
7e5e3d78d0 [v9.4.x] SQLStore: Fix setting query retries for integration tests (#64972)
SQLStore: Fix setting query tries for integration tests (#64944)

* SQLStore: Pass testinfra database configuration to the test database

* Add test

* Bypass gocyclo check for initTestDB

(cherry picked from commit f5cb8c660e)

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>
2023-03-17 18:05:30 +02:00
Grot (@grafanabot)
c5f4ef6c3e [v9.4.x] Alerting: Handful of small adjustments to log levels and parameters (#64954)
Alerting: Handful of small adjustments to log levels and parameters (#64572)

Calculate duration earlier in scheduler

(cherry picked from commit 9bcf8819d3)

Co-authored-by: Alexander Weaver <weaver.alex.d@gmail.com>
2023-03-17 14:33:55 +02:00
Grot (@grafanabot)
69a7d5d6a6 [v9.4.x] SQLStore: Fix SQLite error propagation if query retries are disabled (#64948)
SQLStore: Fix SQLite error propagation if query retries are disabled (#64904)

* SQLStore: Add test when query retrying is disabled

* Fix condition

* Add test cases for sqlite3.ErrLocked

(cherry picked from commit 41843464d1)

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>
2023-03-17 13:33:37 +02:00
Grot (@grafanabot)
3d1085c6ad [v9.4.x] Navigation: handle case when there is no alerting node at all (#64950)
Navigation: handle case when there is no alerting node at all (#64941)

* handle case when there is no alerting node at all

* update backend tests

(cherry picked from commit f4c62a5c5d)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-03-17 13:27:40 +02:00
Grot (@grafanabot)
5d6a6677a2 [v9.4.x] Alerting: QoL improvements to the unified alerting multi-replica devenv (#64939)
Alerting: QoL improvements to the unified alerting multi-replica devenv (#64907)

(cherry picked from commit 406431df4e)

Co-authored-by: gotjosh <josue.abreu@gmail.com>
2023-03-17 10:59:13 +00:00
Grot (@grafanabot)
b5c092f03e [v9.4.x] Navigation: Correctly create Alerts and incidents section when using legacy alerting (#64926)
Navigation: Correctly create `Alerts and incidents` section when using legacy alerting (#64924)

check for legacy alerting node as well

(cherry picked from commit 54dd8943ca)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-03-16 20:17:48 +02:00
Grot (@grafanabot)
46030b3b69 [v9.4.x] LogContext: Fix height of upper group when using logsContextDatasourceUi (#64617)
LogContext: Fix height of upper group when using `logsContextDatasourceUi` (#64602)

fix wrong height being set

(cherry picked from commit 7cde6acbef)

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
2023-03-16 08:09:01 -07:00
Grot (@grafanabot)
0e11822954 [v9.4.x] Fix broken link in "Publish a plugin" page and lint the page with doc-validator (#64895)
Fix broken link in "Publish a plugin" page and lint the page with doc-validator (#64881)

* Use one sentence per line for better line based diffing

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Add missing and required description front matter

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Fix heading hierarchy

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Fix doc-validator linting errors

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Add doc-validator make target

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Fix nested lists

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

---------

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
(cherry picked from commit 68e38aad6a)

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
2023-03-16 12:22:47 +00:00
Grot (@grafanabot)
bf832c93e7 [v9.4.x] Fix website build errors both for Grafana and content mounted in Grafana Cloud (#64836)
Fix website build errors both for Grafana and content mounted in Grafana Cloud (#64794)

* Fix reference to Grafana CLI

- Make relref for relative permalink
- Use relative path for unambiguous resolution

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Fix alerting relref anchor format

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Avoid ambiguous relref lookups by forcing relative resolution

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Remove reference to non-existent shared page

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Fix links broken in Grafana Cloud using absolute relrefs

By resolving the relref absolutely, it refers to the same location
regardless of mounted directory.

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Remove trailing slash for bundle independent resolution

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Fix typo

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* For now, avoid Hugo checking cross repository /docs/grafana-cloud link

The path is unlikely to change in the short term and this makes CI
completely green for now.

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* No need to specify path for in page anchors

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Fix prose

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

---------

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
(cherry picked from commit ebb54aea8d)

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
2023-03-16 08:33:28 +00:00
ismail simsek
412f1c1cc6 Influxdb: Re-introduce backend migration feature toggle (#64842)
* Put feature toggle back

* Influxdb: Re-introduce backend migration feature toggle (#64829)

* Revert "Influxdb: Remove backend migration feature toggle (#61308)"

This reverts commit 67c02f66

* Put feature toggle back

(cherry picked from commit 0823672fce)
2023-03-15 19:15:55 +01:00
Yuri Tseretyan
10a2245f93 Alerting: Update scheduler to receive rule updates only from database (#64780)
Alerting: Update scheduler to get updates only from database (#64635)

* stop using the scheduler's Update and Delete methods all communication must be via the database
* update scheduler's registry to calculate diff before re-setting the cache
* update fetcher to return the diff generated by registry
* update processTick to update rule eval routine if the rule was updated and it is not going to be evaluated at this tick.
* remove references to the scheduler from api package
* remove unused methods in the scheduler

(cherry picked from commit 85a954cd81)

# Conflicts:
#	pkg/services/ngalert/schedule/schedule.go
#	pkg/services/ngalert/schedule/schedule_unit_test.go
2023-03-14 19:44:34 -04:00
Virginia Cepeda
12013e9aa4 Alerting: Display last & next rule eval date plus eval duration (#64767) (#64772)
* Display last & next rule eval date plus eval duration

* Show next evaluation date in a humanized format

Full date still visible on hover

* Only show next evaluation column is group has an interval

(cherry picked from commit 6b95b3f8aa)
2023-03-14 22:49:25 +01:00
Grot (@grafanabot)
56d1dcc9b3 [v9.4.x] Packaging: Dockerfile copy local folder (#64768)
Packaging: Dockerfile copy local folder (#64766)

Dockerfile copy local folder

(cherry picked from commit dfee4249e8)

Co-authored-by: Kevin Minehart <kmineh0151@gmail.com>
2023-03-14 15:11:08 -05:00
Grot (@grafanabot)
b5a274f392 [v9.4.x] CloudWatch Logs: Queries in an expression should run synchronously (#64707)
CloudWatch Logs: Queries in an expression should run synchronously (#64443)

(cherry picked from commit 74436d31de)

Co-authored-by: Isabella Siu <Isabella.siu@grafana.com>
2023-03-14 08:49:40 -04:00
Marco Schaefer
08acfafffd Upgrade faro-core and faro-web-sdk to 1.0.2 (#64407) (#64695)
* chore: upgrade faro-core and faro-web-sdk to 1.0.2 (#64407)

With v1.0.2 Faro explicitly closes fetch requests.
This fixes an issue were (headless) chrome browser
still considers those requests as open  which lead to timeouts.

(cherry picked from commit d8a497ee6e)

* fix: add missing setView and getView mocks
2023-03-14 11:05:10 +02:00
Grot (@grafanabot)
fc8002d9ab [v9.4.x] Alerting: Log error but don't fail initialization if state history connection test fails (#64719)
Alerting: Log error but don't fail initialization if state history connection test fails (#64699)

Don't return init error if ping fails, add tests

(cherry picked from commit faef3a8258)

Co-authored-by: Alexander Weaver <weaver.alex.d@gmail.com>
2023-03-13 23:59:21 +02:00
Grot (@grafanabot)
75a44af935 [v9.4.x] Dashboards: Filter out expressions when going to Explore (#64684)
Dashboards: Filter out expressions when going to Explore (#64654)

* Filter out expressions when going from dashboard to explore

* Move expression UID constant to types

(cherry picked from commit c363a81806)

Co-authored-by: Kristina <kristina.durivage@grafana.com>
2023-03-13 08:23:53 -05:00
Grot (@grafanabot)
53a06bf65f [v9.4.x] Frontend: Fix broken links in /plugins when pathname has a trailing slash (#64608)
Frontend: Fix broken links in /plugins when pathname has a trailing slash (#64348)

Fix broken links in /plugins when pathname has a trailing slash

(cherry picked from commit a05cb1e78e)

Co-authored-by: William Assis <35489495+gassiss@users.noreply.github.com>
2023-03-13 13:53:13 +01:00
Grot (@grafanabot)
7a26957f87 [v9.4.x] Navigation: Remove duplicate header on user invite page (#64678)
Navigation: Remove duplicate header on user invite page (#64677)

remove duplicated header in old navigation

(cherry picked from commit caf98101e7)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-03-13 13:53:54 +02:00
Grot (@grafanabot)
d75b8c13ef [v9.4.x] TimeSeries: fix time comparer not comparing date strings properly (#64674)
TimeSeries: fix time comparer not comparing date strings properly (#64622)

* fix time comparer not comparing times properly

* move isDateTime last as it's probably the most expensive check

(cherry picked from commit 3a1862f37f)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-03-13 05:43:31 -04:00
Grot (@grafanabot)
01917df71a [v9.4.x] InfluxDB: Fix type assertion panics for interface conversion: interface {} is nil (#64623)
InfluxDB: Fix type assertion panics for interface conversion: interface {} is nil (#64556)

* fix type assertions

* fix chk

* add nil and fix tests

* add test for null bool and strings in the JSON response to be parsed as nil in Go

* reduce complexity

* reduce complexity

* reduce complexity again

* switch case for valTypes

(cherry picked from commit 50ef183208)

Co-authored-by: Brendan O'Handley <brendan.ohandley@grafana.com>
2023-03-10 14:51:52 -05:00
Grot (@grafanabot)
b7ff4d1661 [v9.4.x] Cloudwatch Logs: Fix log group names not interpolating with multiple variables (#64631)
Cloudwatch Logs: Fix log group names not interpolating with multiple variables (#64567)

* Cloudwatch Logs: Fix log group names not interpolating with multiple variables

* fix test

(cherry picked from commit 75f89e67af)

Co-authored-by: Kevin Yu <kevinwcyu@users.noreply.github.com>
2023-03-10 14:12:28 -05:00
Timur Olzhabayev
eaace4fc45 [v9.4.x] Docs: Minor wording changes for plugin signing docs (#64615) (#64624)
Docs: Minor wording changes for plugin signing docs (#64615)

Minor wording changes

(cherry picked from commit f9b9041ad8)
2023-03-10 09:51:13 -08:00
Grot (@grafanabot)
039d9c379c [v9.4.x] Update page labels to better reflect contents (#64626)
Update page labels to better reflect contents (#64606)

* Set correct products labels on Grafana Cloud and Enterprise pages

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Add cloud label to all alerting docs

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

---------

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
(cherry picked from commit 72e50431df)

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
2023-03-10 17:47:45 +00:00
Grot (@grafanabot)
6bce4d516d [v9.4.x] Docs: Changes to angular deprecation announcement (#64619)
Docs: Changes to angular deprecation announcement (#63928)

Adjusting the content to reflect latest discussions. This page can now be used as reference for all things about angular deprecation.

(cherry picked from commit 9ca53d9596)

Co-authored-by: Timur Olzhabayev <timur.olzhabayev@grafana.com>
2023-03-10 17:47:45 +01:00
Grot (@grafanabot)
332e870086 [v9.4.x] Cloudwatch: Add expression field to interpolate variables in Metrics Code Builder (#64508)
Cloudwatch: Add expression field to interpolate variables in Metrics Code Builder (#64288)

(cherry picked from commit 1c8ad04f8d)

Co-authored-by: Ida Štambuk <ida.stambuk@grafana.com>
2023-03-10 15:02:07 +01:00
Grot (@grafanabot)
6f22584d26 [v9.4.x] Alerting: fix users call 403 by calling /user instead of /users/{id} (#64607)
Co-authored-by: Virginia Cepeda <virginia.cepeda@grafana.com>
fix users call 403 by calling /user instead of /users/{id} (#64544)
2023-03-10 14:29:43 +01:00
Grot (@grafanabot)
961446e7e1 [v9.4.x] Docs: Remove Alertmanager configuration rollback from What's New (#64588)
Docs: Remove Alertmanager configuration rollback from What's New (#64564)

* Docs: Remove Alertmanager configuration rollback from What's New

* Trigger Build

---------

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
(cherry picked from commit d21d498142)

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>
2023-03-10 10:04:15 -03:00
Grot (@grafanabot)
419e8d782c [v9.4.x] Alerting: Fix contact point name being URL-encoded in the title (#64596)
Alerting: Fix contact point name being URL-encoded in the title (#64590)

Fix contact point name being encoded in the title text

(cherry picked from commit 4c8855ed2d)

Co-authored-by: Sonia Aguilar <33540275+soniaAguilarPeiron@users.noreply.github.com>
2023-03-10 06:29:52 -05:00
Ashley Harrison
aa09499343 Backport 62658 to v9.4.x (#64545)
* Navigation: Fix Home logo always going to `/login` (#62658)

* only redirect to /login when anonymous access is disabled

* only search for dashboards when not logged in if anon access is enabled

* fix go logic

* add unit tests

(cherry picked from commit 3336327306)

* remove file i accidentally left in :/

* import correct method
2023-03-10 04:59:06 -05:00
Grot (@grafanabot)
cf3f234a54 [v9.4.x] Docs: Add a note on uploading report branding logos (#64539)
Docs: Add a note on uploading report branding logos (#64532)

* Docs: Add a note on uploading report branding logos

* Fix wording

(cherry picked from commit 6f67529a0a)

Co-authored-by: Tania <yalyna.ts@gmail.com>
2023-03-09 10:53:37 -05:00
Grot (@grafanabot)
de7d18d4e0 [v9.4.x] CI: Add PrereleaseBucket field in versions.go (#64524)
CI: Add `PrereleaseBucket` field in `versions.go` (#64519)

Add PrereleaseBucket in versions.go

(cherry picked from commit 29b3f3fbf4)

Co-authored-by: Dimitris Sotirakis <dimitrios.sotirakis@grafana.com>
2023-03-09 17:49:59 +02:00
Horst Gutmann
7f6c61f0bd [9.4.x] CI: Move some build settings (#64491) (#64513)
CI: Move some build settings (#64491)

* Move some build settings to Vault

* CI: Remove reference to DOWNSTREAM_REPO as it isn't used

(cherry picked from commit 4b241804b4)
2023-03-09 08:33:15 -05:00
Grot (@grafanabot)
47e1860e34 [v9.4.x] OptionsPicker: Correctly highlight template variable value when filtering (#64394)
OptionsPicker: Correctly highlight template variable value when filtering (#63495)

* VariablePicker: Correctly highlight items when filtering

* Change interactions for selecting values in variable options picker

* Review

(cherry picked from commit e4d591fc01)

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
2023-03-09 04:21:16 -08:00
Grot (@grafanabot)
db9dfc7aef [v9.4.x] Loki: Fix labels in LabelBrowser being wrongly cached (#64496)
Loki: Fix labels in LabelBrowser being wrongly cached  (#64482)

* remove label cache from label browser

* fix spelling

Co-authored-by: Gareth Dawson <gareth.dawson@grafana.com>

---------

Co-authored-by: Gareth Dawson <gareth.dawson@grafana.com>
(cherry picked from commit 976568a337)

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
2023-03-09 05:43:50 -05:00
George Robinson
0d561b6c24 [v9.4.x] Docs: Updates default template link (#64495)
Docs: Updates default template link (#64485)

Updates default template link

(cherry picked from commit 14208c4c42)

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
2023-03-09 05:21:48 -05:00
Grot (@grafanabot)
9bccf165be [v9.4.x] Docs: Last iteration on docs for images in notifications (#64494)
Docs: Last iteration on docs for images in notifications (#64392)

This commit includes some minor rephrasing to the Requirements and
Limitations of the Images in notification feature.

(cherry picked from commit 1898e76dd6)

Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-03-09 05:03:44 -05:00
Grot (@grafanabot)
936e72f1e6 [v9.4.x] CloudWatch Logs: Fix interpolation of scoped variables in queryString (#64405)
* CloudWatch Logs: Fix interpolation of scoped variables in queryString (#64267)

(cherry picked from commit af9a0dbe39)

* fix typecheck

---------

Co-authored-by: Isabella Siu <Isabella.siu@grafana.com>
2023-03-08 19:56:07 -05:00
Brendan O'Handley
b66e903439 Prometheus: Metric encyclopedia (#63423) (#64455)
* add metric encyclopedia feature toggle and component

* remove unused button

* move file, add test file

* add tests

* add pagination and tests

* test with 10,000,000 metrics

* remove unused import

* add filter by type

* search alphabetically and add switch to exclude metrics with no metadata

* add suggested functions and filter for functions

* allow user to select variables in encyclopedia

* fix style and tests

* add fuzzy search by either metric name or all metadata

* if missing metadata, remove metadata fuzzy search option, exclude metadata, and filter by type

* add encyclopedia feature tracking

* indicate that metrics are filtered by labels

* handle metric singular or plural

* add tooltips and fix language

* add filtering tests

* change 'search' to 'browse'

* remove functions filter and tests as not part of work flow

* add m.e. button and selected metric is a tag

* fix hanging search and update styles, padding, labels, and groupings

* small performance improvements

* fix tests

* add backend metrics query option

* add loading spinner for start load and backend search

* autofocus search input

* Update docs/sources/setup-grafana/configure-grafana/feature-toggles/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* run prettier

* run prettier

* fix text for feature toggle

* for license check since https://cla-assistant.io/check/grafana/grafana?pullRequest=<PR#> is not working

* fixing tests

* fix feature toggle docs

* fix feature toggle

* fix feature toggle

* add owner to feature toggle

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
(cherry picked from commit 9b6e531549)
2023-03-08 13:47:05 -05:00
Grot (@grafanabot)
2911eec518 [v9.4.x] Plugins: Fix bug with copying grafanaData (#64454)
Plugins: Fix bug with copying grafanaData (#64446)

(cherry picked from commit 39a4634ae9)

Co-authored-by: Stephanie Hingtgen <stephanie.hingtgen@grafana.com>
2023-03-08 13:40:21 -05:00
Grot (@grafanabot)
ea660e188e [v9.4.x] Snapshots: Fix deleting snapshot with non existent dashboard ID (#64371)
Snapshots: Fix deleting snapshot with non existent dashboard ID (#64345)

* Add test for deleting snapshot for non existent dashboard

* Add test for failure to fetch guardian other than ErrDashboardNotFound

* Fix dashboard snapshot delete

(cherry picked from commit 43095d84e4)

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>
2023-03-08 03:33:23 -05:00
Grot (@grafanabot)
3b523c13a7 [v9.4.x] OpenTSDB: Allow metric autocomplete to use suggest api on every input (#64361)
OpenTSDB: Allow metric autocomplete to use suggest api on every input (#62045)

* allow metric autocomplete by suggest api

* debounce sugggest metrics

* debounce sugggest metrics with debounce-promise

* commit for tests

(cherry picked from commit 70c1850888)

Co-authored-by: Brendan O'Handley <brendan.ohandley@grafana.com>
2023-03-07 18:02:26 -05:00
Grot (@grafanabot)
4474649869 [v9.4.x] Cloudwatch Logs: Make mixed type fields fallback to being strings (#64359)
Cloudwatch Logs: Make mixed type fields fallback to being strings (#63981)

* Cloudwatch Logs: make mixed type fields fallback to being strings

* addressing pr comments

(cherry picked from commit 70f600db10)

Co-authored-by: Kevin Yu <kevinwcyu@users.noreply.github.com>
2023-03-07 17:57:12 -05:00
Grot (@grafanabot)
772eb4b58a [v9.4.x] Alerting: Fix intermittency when seeding database in rule store tests (#64326)
Alerting: Fix intermittency when seeding database in rule store tests (#64322)

Force unique IDs when seeding database

(cherry picked from commit 4a1c18abf6)

Co-authored-by: Alexander Weaver <weaver.alex.d@gmail.com>
2023-03-07 11:00:50 -05:00
Grot (@grafanabot)
9e0cb259ee [v9.4.x] Logs sample: Fix scrolling for unwrapped log lines (#64291)
Logs sample: Fix scrolling for unwrapped log lines (#64163)

Fix scrolling for logs sample

(cherry picked from commit 7b01668729)

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2023-03-07 12:34:38 +01:00
Grot (@grafanabot)
e272ce8274 [v9.4.x] Docs: Update Images in notifications docs to be more readable and instructive (#64294)
Docs: Update Images in notifications docs to be more readable and instructive (#64227)

(cherry picked from commit 9d9421154e)

Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-03-07 10:58:29 +00:00
Will Browne
2d0324ec70 [v9.4.x] Plugins: Fix Cache-Control header response for public/plugins/* assets API (#64255)
resolve conflicts
2023-03-06 19:20:54 +01:00
Galen Kistler
5a6471c01f TimeSeries: Fix overflowing exemplar modals causing content shifts (#… (#64254)
TimeSeries: Fix overflowing exemplar modals causing content shifts (#64037)

*  fix overflowing exemplar modals causing content shifts

(cherry picked from commit b9ebd5757a)
2023-03-06 12:18:05 -06:00
Grot (@grafanabot)
0d2a01f03f [v9.4.x] Alerting: Fix Classic Conditions $values variable (#64249)
Alerting: Fix Classic Conditions $values variable (#64243)

This commit fixes a bug in the $values variable in notification
templates when using Classic Conditions. Since Classic Conditions
are not multi-dimensional, the values of each series that exceeded
the condition should be available as a RefID and offset. For example,
B0, B1, etc. However, this bug meant that instead just a single
condition would be printed as B, not B0.

(cherry picked from commit ed71012ced)

Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-03-06 12:33:30 -05:00
Alexander Weaver
4c38e25ecd Alerting: Expose Prometheus metrics for persisting state history (#64246)
Alerting: Expose Prometheus metrics for persisting state history (#63157)

* Create historian metrics and dependency inject

* Record counter for total number of state transitions logged

* Track write failures

* Track current number of active write goroutines

* Record histogram of how long it takes to write history data

* Don't copy the registerer

* Adjust naming of write failures metric

* Introduce WritesTotal to complement WritesFailedTotal

* Measure TransitionsFailedTotal to complement TransitionsTotal

* Rename all to state_history

* Remove redundant Total suffix

* Increment totals all the time, not just on success

* Drop ActiveWriteGoroutines

* Drop PersistDuration in favor of WriteDuration

* Drop unused gauge

* Make writes and writesFailed per org

* Add metric indicating backend and a spot for future metadata

* Drop _batch_ from names and update help

* Add metric for bytes written

* Better pairing of total + failure metric updates

* Few tweaks to wording and naming

* Record info metric during composition

* Create fakeRequester and simple happy path test using it

* Blocking test for the full historian and test for happy path metrics

* Add tests for failure case metrics

* Smoke test for full annotation persistence

* Create test for metrics on annotation persistence, both happy and failing paths

* Address linter complaints

* More linter complaints

* Remove unnecessary whitespace

* Consistency improvements to help texts

* Update tests to match new descs

(cherry picked from commit 19d01dff91)
2023-03-06 12:10:11 -05:00
Grot (@grafanabot)
52288b87aa [v9.4.x] LokiContextUi: Add loading indicator (#64244)
LokiContextUi: Add loading indicator (#64167)

add loading indicator to LokiContextUi

(cherry picked from commit 5db0d14606)

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
2023-03-06 17:38:35 +01:00
Grot (@grafanabot)
84e358660a [v9.4.x] Revert "Alerting: Fix alert form broken coming from panel (#64148)" (#64241)
Revert "Alerting: Fix alert form broken coming from panel (#64148)" (#64240)

(cherry picked from commit 282d021c53)

Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2023-03-06 10:39:46 -05:00
Grot (@grafanabot)
269ae0d7be [v9.4.x] Alerting: Fix queries not being previewed in detail view (#64235)
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
Fix queries not being previewed in detail view (#64198)
2023-03-06 09:58:52 -05:00
Grot (@grafanabot)
24e46f3ae7 [v9.4.x] Alerting: Disable "Declare Incident" button for open-source editions (#64234)
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2023-03-06 09:58:48 -05:00
Grot (@grafanabot)
232cbed853 [v9.4.x] GrafanaUI: reset ConfirmModal disabled state on re-open (#64207)
GrafanaUI: reset ConfirmModal disabled state on re-open (#63452)

(cherry picked from commit 88231c7cb8)

Co-authored-by: Uladzimir Dzmitračkoŭ <3773351+going-confetti@users.noreply.github.com>
2023-03-06 13:33:44 +01:00
Grot (@grafanabot)
c5583207ee [v9.4.x] Fix scenario where tooltip shows wrong value (#64199)
Fix scenario where tooltip shows wrong value (#64025)

* Fix scenario where tooltip shows wrong value

* refactor

(cherry picked from commit 211a999a2a)

Co-authored-by: Victor Marin <36818606+mdvictor@users.noreply.github.com>
2023-03-06 11:54:25 +00:00
Giordano Ricci
c48ca77815 [v9.4.x] Explore: Avoid changing queries twice when importing a query in mixed mode (#64206)
Explore: Avoid changing queries twice when importing a query in mixed mode (#63804)

* Explore: avoid changing queries twice when importing a query in mixed mode

* move logic to thunk

* add tests

* improve tests

(cherry picked from commit 24a4a24a89)
2023-03-06 11:33:39 +00:00
Dimitris Sotirakis
5fb2986aa5 [v9.4.x] Chore: Bump alpine version to 3.17.1 (#63252) (#63264)
Chore: Bump alpine version to `3.17.1` (#63252)

Bump alpine version to 3.17.1

(cherry picked from commit 24c60486f6)

# Conflicts:
#	.drone.yml
2023-03-06 04:40:47 -05:00
Sonia Aguilar
6772c060d8 Alerting: Fix alert form broken coming from panel (#64148) (#64200)
Fix alert form broken coming from panel

(cherry picked from commit a669b72641)
2023-03-06 04:14:33 -05:00
Grot (@grafanabot)
f918b3bf9d [v9.4.x] Alerting: Prevent resetting the form on evaluation group interval change (#63794)
Co-authored-by: Virginia Cepeda <virginia.cepeda@grafana.com>
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2023-03-06 10:00:00 +01:00
Grot (@grafanabot)
49ef18b2b7 [v9.4.x] Docs: Adding angular support deprecation to our plugin submission FAQ (#64201)
Docs: Adding angular support deprecation to our plugin submission FAQ (#64006)

Adding angular support deprecation to our faq

(cherry picked from commit 43e281271b)

Co-authored-by: Timur Olzhabayev <timur.olzhabayev@grafana.com>
2023-03-06 03:57:18 -05:00
Grot (@grafanabot)
f80239c21a [v9.4.x] update data source permissions instructions to match modern UI (#64181)
update data source permissions instructions to match modern UI (#63405)

* update data source permissions instructions to match modern UI

* Apply suggestions from code review

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
(cherry picked from commit adc8000b72)

Co-authored-by: chrisharbro <102977229+chrisharbro@users.noreply.github.com>
2023-03-03 16:26:27 -06:00
Grot (@grafanabot)
bf6e7d2abe [v9.4.x] Clarify that LDAP will create Grafana users by default when they log in for the first time (#64180)
Clarify that LDAP will create Grafana users by default when they log in for the first time (#63391)

* Clarify that enabling LDAP will create users by default when they log in

This proposed change to the doc was requested by a user in support ticket `79860`, as it was not clear to them that the OOTB behavior was for user accounts to be provisioned automatically in Grafana when signing in for the first time via LDAP.

* Update docs/sources/setup-grafana/configure-security/configure-authentication/ldap/index.md

Thanks!

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* fix boolean

Woops, `true` should be `false`

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
(cherry picked from commit b136d0dfcf)

Co-authored-by: chrisharbro <102977229+chrisharbro@users.noreply.github.com>
2023-03-03 16:26:04 -06:00
Jack Baldry
ddf5363aa6 [v9.4.x] Replace ambiguous relrefs with partial URIs to prevent 404s (#62468) (#64114)
* Replace ambiguous relrefs with partial URIs to prevent 404s



* Fix local builds that depend on latest content



* Fix broken relref



---------


(cherry picked from commit 66b54e2dbd)

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2023-03-03 18:59:09 +00:00
Grot (@grafanabot)
a9faf4b9f1 [v9.4.x] Influxdb: Fix missing columns with raw query (#64173)
Influxdb: Fix missing columns with raw query (#64058)

* add selected columns to table when select object is not in query model because of rawQuery

* handle * and SHOW raw queries

* handle metricFindQuery

* Update public/app/plugins/datasource/influxdb/response_parser.ts

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

* Update public/app/plugins/datasource/influxdb/response_parser.ts

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

* Update public/app/plugins/datasource/influxdb/response_parser.ts

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

---------

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
(cherry picked from commit aed020d9b5)

Co-authored-by: Brendan O'Handley <brendan.ohandley@grafana.com>
2023-03-03 13:40:39 -05:00
Sofia Papagiannaki
8c12f75b0b [v9.4.x] Chore: Remove CreateUserForTests() (#64125) (#64165)
Chore: Remove CreateUserForTests() (#64125)

* Chore: Remove CreateUserForTests

* Apply suggestion from code review

(cherry picked from commit e6e8351ee9)
2023-03-03 18:43:10 +02:00
Grot (@grafanabot)
5014df0521 [v9.4.x] fix: create temp user no longer sets ID to 0 for all users (#64160)
fix: create temp user no longer sets ID to 0 for all users (#64149)

* fix: create temp user no longer sets ID to 0 for all users

The xorm tag added to the tempuser ID field caused xorm to create all temp users with ID 0. Removing that tag allows xorm to set the ID based on the database result instead. I also added a test which was failing before this.

Fixes #63995

(cherry picked from commit dbb72f2c6e)

Co-authored-by: Kristin Laemmert <mildwonkey@users.noreply.github.com>
2023-03-03 11:24:21 -05:00
Grot (@grafanabot)
5ccddbe071 [v9.4.x] Changelog: Updated changelog for 9.4.0 (#63983)
Changelog: Updated changelog for 9.4.0 (#63978)

* Changelog: Updated changelog for 9.4.0

* Revert release date manually

---------

Co-authored-by: Michael Mandrus <41969079+mmandrus@users.noreply.github.com>
(cherry picked from commit 682a186676)
2023-03-03 11:14:08 -05:00
Grot (@grafanabot)
6d0beaedaf [v9.4.x] build: fix corss build (#63261)
build: fix corss build (#61121)

* build: fix corss build

* fix lint

(cherry picked from commit 37baae3699)

Co-authored-by: Jimmie Han <hanjinming@outlook.com>
2023-03-03 10:04:12 -06:00
Grot (@grafanabot)
8c1d16c879 [v9.4.x] Logs: Log samples not being ordered correctly (#64147)
Logs: Log samples not being ordered correctly (#64097)

* fix log samples being unsorted and multiple results when chunking

* use `SortDirection` enum

* changed to `sortDataFrame` to support other datasources than loki

* update tests

* change capitalization

(cherry picked from commit 2076282064)

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
2023-03-03 10:09:50 -05:00
Ashley Harrison
4ee064da11 Chore: Pass signed user_hash to Intercom via Rudderstack (#63921) (#64145)
* move analytics identifiers to backend

* implement hash function

* grab secret from env

* expose and retrieve intercom secret from config

* concat email with appUrl to ensure uniqueness

* revert to just using email

* Revert "revert to just using email"

This reverts commit 8f10f9b1bc.

* add docstring

(cherry picked from commit d61bcdf4ca)
2023-03-03 10:06:13 -05:00
Grot (@grafanabot)
1548edc40e [v9.4.x] Docs: Meta-monitoring docs for Grafana and Mimir (#64142)
Docs: Meta-monitoring docs for Grafana and Mimir (#63752)

* Docs: (WIP) Meta-monitoring docs for Grafana and Mimir

* Update metrics for Grafana Managed Alerts

* Fix spelling mistake

* Add docs for Alertamanager, including high-availability mode

* Comment undefined metrics

---------

Co-authored-by: Armand Grillet <2117580+armandgrillet@users.noreply.github.com>
(cherry picked from commit fed59b1d43)

Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-03-03 15:46:19 +01:00
Grot (@grafanabot)
aad839e5b9 [v9.4.x] Alerting: Fix client to external Alertmanager to correctly build URL for Mimir Alertmanager (#63684)
Alerting: Fix client to external Alertmanager to correctly build URL for Mimir Alertmanager (#63676)

(cherry picked from commit 98e1aeaebd)

Co-authored-by: Yuri Tseretyan <yuriy.tseretyan@grafana.com>
2023-03-03 09:14:33 -05:00
Grot (@grafanabot)
aa60a45f6b [v9.4.x] Docs: Pinning to latest for grafana plugin tools (#64141)
Docs: Pinning to latest for grafana plugin tools (#64140)

Pinning to latest for grafana plugin tools

(cherry picked from commit 92ee03db78)

Co-authored-by: Timur Olzhabayev <timur.olzhabayev@grafana.com>
2023-03-03 09:11:31 -05:00
Giordano Ricci
bdf8b7531b [9.4.x] Correlations: Fix flaky integration tests (#64004) (#64139)
Correlations: Fix flaky integration tests (#64004)

* Correlations: Fix flaky integration tests

* set explore-squad as correlations tests code owners

(cherry picked from commit 4a7fbea7a4)
2023-03-03 14:06:59 +00:00
Grot (@grafanabot)
9ef2e8d7da [v9.4.x] Alerting: Allow downloading alert rules from subpath (#64138)
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2023-03-03 08:44:03 -05:00
Grot (@grafanabot)
79fb770ca5 [v9.4.x] Alerting: Fix UI crashing when selecting custom grouping in alert panel (#64128)
Alerting: Fix UI crashing when selecting custom grouping in alert panel (#64124)

Fix UI crashing when selecting custom grouping in alert panel

(cherry picked from commit 9765c98b3d)

Co-authored-by: Sonia Aguilar <33540275+soniaAguilarPeiron@users.noreply.github.com>
2023-03-03 07:08:12 -05:00
Grot (@grafanabot)
b733b4fd5c [v9.4.x] Docker Build: Use tonistiigi/binfmt image for cross compilation (#64117)
Docker Build: Use `tonistiigi/binfmt` image for cross compilation (#64108)

* Change docker image used for cross-compilation

* Replace fmt.Println with log.Println

* Add specific tag for docker image

(cherry picked from commit b42fd92fad)

Co-authored-by: Dimitris Sotirakis <dimitrios.sotirakis@grafana.com>
2023-03-03 13:19:00 +02:00
Grot (@grafanabot)
a2b984cd7e [v9.4.x] docs: Prevent internal docs on setting up plugin spellcheck from appearing on public website (#64118)
docs: Prevent internal docs on setting up plugin spellcheck from appearing on public website (#64113)

(cherry picked from commit ab512fcf88)

Co-authored-by: Andriy <andriy.urbanas@grafana.com>
2023-03-03 10:55:31 +01:00
Grot (@grafanabot)
0d7de2bbda Release: Bump version to 9.4.4 (#64101)
"Release: Updated versions in package to 9.4.4"
2023-03-03 03:17:28 -05:00
Grot (@grafanabot)
1ad9362310 [v9.4.x] Changelog: Updated changelog for 9.4.3 (#64100)
Changelog: Updated changelog for 9.4.3 (#64099)

(cherry picked from commit a7a658ed1b)
2023-03-03 09:10:08 +01:00
Grot (@grafanabot)
8861a8a977 [v9.4.x] SQLStore: Enable clientFoundRows for MySQL connections (#64083)
SQLStore: Enable clientFoundRows for MySQL connections (#64070)

Enable clientFoundRows for MySQL connections

(cherry picked from commit 8ea71d37c2)

Co-authored-by: Alexander Weaver <weaver.alex.d@gmail.com>
2023-03-02 17:49:33 -06:00
Grot (@grafanabot)
f8df798afd [v9.4.x] NPM: Stop using the folder path before the name path (#64071)
NPM: Stop using the folder path before the name path (#63851)

Stop using the folder path before the name path

(cherry picked from commit 177aa254c5)

Co-authored-by: Dimitris Sotirakis <dimitrios.sotirakis@grafana.com>
2023-03-02 14:28:45 -06:00
Yuri Tseretyan
25c31c2c7c [v9.4.x] Alerting: Use background context for maintenance function (#64066)
Alerting: Use background context for maintenance function (#64065)

(cherry picked from commit e760f22402)

# Conflicts:
#	pkg/services/ngalert/notifier/alertmanager.go
2023-03-02 14:45:27 -05:00
Grot (@grafanabot)
3fe53ab222 [v9.4.x] StatPanel: Fix issue where sparkline chart was not being shown on resize (#64012) 2023-03-02 12:58:48 +01:00
Emil Tullstedt
4e687dfb6f [v9.4.x] Chore: Upgrade Go to 1.20.1 and Alpine to 3.17 (#63891) 2023-03-02 11:53:45 +01:00
Grot (@grafanabot)
eab26273d6 [v9.4.x] Docs [Search] update _index.md by replacing dashboardPreviews for panelTitleSearch feature toggle (#64003)
Co-authored-by: beateguia <70489000+beateguia@users.noreply.github.com>
2023-03-02 11:21:56 +01:00
Grot (@grafanabot)
35fe167f0d Release: Bump version to 9.4.3 (#64002)
"Release: Updated versions in package to 9.4.3"
2023-03-02 11:05:48 +01:00
Grot (@grafanabot)
5e48a1ad06 [v9.4.x] Changelog: Updated changelog for 9.4.2 (#64001)
Changelog: Updated changelog for 9.4.2 (#64000)

(cherry picked from commit ae90f73b78)
2023-03-02 10:54:28 +01:00
Grot (@grafanabot)
225128a5d9 [v9.4.x] Fix redirect from /setup-grafana/upgrade-grafana/ to /upgrade-guide/ (#63999)
Fix redirect from /setup-grafana/upgrade-grafana/ to /upgrade-guide/ (#63914)

Additionally fix redirect from `/installation/upgrading/` to
`/setup-grafana/upgrade-grafana/`.

The alias proposed in
https://github.com/grafana/grafana/pull/62402#discussion_r1090526464
was incorrect. It used the `../installation/upgrading/` alias as
reference but I did not check the redirect. As this page itself has
moved from `/setup-grafana/upgrade-grafana/` to `/upgrade-guide/` the
relative alias needed updating also.

To verify that this alias is working as expected:

1. Checkout this branch.
2. Run `make docs`
3. Browse to
http://localhost:3002/docs/grafana/latest/setup-grafana/upgrade-grafana/
4. Verify that you have been redirected to
http://localhost:3002/docs/grafana/latest/upgrade-guide/
5. Browse to
http://localhost:3002/docs/grafana/latest/installation/upgrading/
6. Verify that you have been redirected to
http://localhost:3002/docs/grafana/latest/upgrade-guide/

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
(cherry picked from commit f3e08a3560)

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
2023-03-02 04:13:05 -05:00
Grot (@grafanabot)
64412b1195 [v9.4.x] BarChart: Only apply radius to topmost bar segment when stacking (#63986)
BarChart: Only apply radius to topmost bar segment when stacking (#63906)

(cherry picked from commit 9314fe1056)

Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
2023-03-01 18:28:14 -05:00
Grot (@grafanabot)
0299b18b88 [v9.4.x] Reqcontext: Use err status code instead of always fallback (#63977)
Reqcontext: Use err status code instead of always fallback (#63974)

(cherry picked from commit 8bd4e2cb25)

Co-authored-by: Ezequiel Victorero <ezequiel.victorero@grafana.com>
2023-03-01 18:48:33 -03:00
Grot (@grafanabot)
8c483cca31 [v9.4.x] Alerting: Fix migration pauses all alert rules on PostgreSQL (#63968)
Alerting: Fix migration pauses all alert rules on PostgreSQL (#63951)

This commit fixes a serious bug in Grafana 9.4.1 where on upgrade
a migration would pause all existing alert rules and change the
default value of the column to true.

(cherry picked from commit 030f6c948f)

Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-03-01 18:00:08 +00:00
Grot (@grafanabot)
4c22a2b8fb [v9.4.x] Alerting: Fix boolean default in migration from false to 0 (#63963)
Alerting: Fix boolean default in migration from false to 0 (#63952)

Fix boolean default in migration from false to 0

(cherry picked from commit a05bf41ff9)

Co-authored-by: Alex Moreno <alexander.moreno@grafana.com>
2023-03-01 17:34:53 +00:00
Grot (@grafanabot)
0de3ceb47c [v9.4.x] TimeSeries: Ignore invalid, user-defined log-y-axis min/max limits (#63967)
TimeSeries: Ignore invalid, user-defined log-y-axis min/max limits (#59758)

(cherry picked from commit 5510fdc3ce)

Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
2023-03-01 12:25:54 -05:00
Grot (@grafanabot)
bb25297a9d [v9.4.x] Profile: Fix session table overflowing page layout in mobile (#63965)
Profile: Fix session table overflowing page layout in mobile (#63858)

handle table overflowing in mobile layout

(cherry picked from commit 4f01d55a3c)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-03-01 12:16:59 -05:00
Ashley Harrison
b5135d8144 Command Palette: Sign out link now works correctly (#63742) (#63960)
* pass target to command palette urls so sign out link works correctly

* improve types

(cherry picked from commit a534119c44)
2023-03-01 12:00:22 -05:00
Grot (@grafanabot)
1b0d442ca2 [v9.4.x] Navigation: Fix broken layout at 544px (#63950)
Navigation: Fix broken layout at 544px (#63793)

* ensure media queries transition properly

* fix unit tests

(cherry picked from commit 8e9ccfc66e)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-03-01 10:40:42 -05:00
Grot (@grafanabot)
38b5dd4486 [v9.4.x] Fix wrong texts in titles when cloning templates (#63944)
Fix wrong texts in titles when cloning templates (#63930)

(cherry picked from commit fa35ed8141)

Co-authored-by: Sonia Aguilar <33540275+soniaAguilarPeiron@users.noreply.github.com>
2023-03-01 09:47:52 -05:00
Grot (@grafanabot)
66b94cd468 [v9.4.x] [DOC] Change APM dashboard to Service Graph view (#63903)
[DOC] Change APM dashboard to Service Graph view (#63818)

* Change APM dashboard to Service View graph

* Apply suggestions from code review

* Update docs/sources/explore/trace-integration.md

* Update docs/sources/explore/trace-integration.md

(cherry picked from commit ac5dbf2632)

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>
2023-02-28 16:37:53 -05:00
Grot (@grafanabot)
a7c1598ca6 [v9.4.x] Navigation: reserve horizontal space for img in SectionNavItem to avoid layout shift (#63865)
Navigation: reserve horizontal space for img in SectionNavItem to avoid layout shift (#63722)

(cherry picked from commit 429d693a4a)

Co-authored-by: Uladzimir Dzmitračkoŭ <3773351+going-confetti@users.noreply.github.com>
2023-02-28 16:04:35 +01:00
Grot (@grafanabot)
437cf15105 [v9.4.x] TimeSeries: Fix legend and tooltip colors changing after data refreshes (#63871)
TimeSeries: Fix legend and tooltip colors changing after data refreshes (#63823)

(cherry picked from commit b2c0175777)

Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
2023-02-28 09:24:51 -05:00
Grot (@grafanabot)
6cab7f956c [v9.4.x] Alerting: Fix width in alerts table columns on EditGroupModal (#63849)
Co-authored-by: Sonia Aguilar <33540275+soniaAguilarPeiron@users.noreply.github.com>
Fix width in alerts table columns on EditGroupModal (#63845)
2023-02-28 08:48:50 -05:00
Grot (@grafanabot)
b23f3964e9 Release: Bump version to 9.4.2 (#63844)
"Release: Updated versions in package to 9.4.2"
2023-02-28 05:44:19 -05:00
Grot (@grafanabot)
0b98b4d241 [v9.4.x] Changelog: Updated changelog for 9.4.1 (#63843)
Changelog: Updated changelog for 9.4.1 (#63841)

* Changelog: Updated changelog for 9.4.1

---------

Co-authored-by: Horst Gutmann <horst.gutmann@grafana.com>
(cherry picked from commit 71d64f95da)
2023-02-28 05:32:43 -05:00
Grot (@grafanabot)
04a4774d4c [v9.4.x] Changelog: Updated changelog for 9.4.0 (#63839)
Changelog: Updated changelog for 9.4.0 (#63838)

(cherry picked from commit 321e4c0f99)
2023-02-28 11:20:23 +01:00
Grot (@grafanabot)
3c58b2c176 [v9.4.x] TraceView: Add key and url escaping of json tag values (#761)
TraceView: Add key and url escaping of json tag values (#751)

(cherry picked from commit 8b53b448bc24fbfc4492ce1f4e2b1708218f70b7)

Co-authored-by: Andrej Ocenas <mr.ocenas@gmail.com>
2023-02-28 11:02:22 +01:00
Grot (@grafanabot)
a1bceeb1d3 [v9.4.x] Geomap: Sanitize the attribution string (#755)
Geomap: Sanitize the attribution string (#745)

* SAML: Update grafana/saml library (#691)

Co-authored-by: jguer <joao.guerreiro@grafana.com>

* SVG: Add dompurify preprocessor step (#698)

* add sanitized SVG component

* add sanitize

* Fix frontend build

* Remove unnecessary yarn.lock changes

* Fix formatting

* Re-add yarn.lock message as I guess it is needed

---------

Co-authored-by: dsotirakis <dimitrios.sotirakis@grafana.com>
Co-authored-by: jguer <joao.guerreiro@grafana.com>
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
Co-authored-by: Drew Slobodnjak <60050885+drew08t@users.noreply.github.com>
(cherry picked from commit 37b4af7ffacfc24d5f24d190356a9ef32d99aa6f)

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2023-02-28 11:02:18 +01:00
Grot (@grafanabot)
bb7a485dbf [v9.4.x] Alerting: Fix AlertLabelDropdown to be case sensitive (#63832)
Alerting: Fix AlertLabelDropdown to be case sensitive (#63787)

Fix AlertLabelDropdown to be case sensitive

(cherry picked from commit 526cac60e5)

Co-authored-by: Sonia Aguilar <33540275+soniaAguilarPeiron@users.noreply.github.com>
2023-02-28 04:05:09 -05:00
Grot (@grafanabot)
b3682d498c [v9.4.x] Alerting: Improve Alertmanager data source docs (#63721)
Alerting: Improve Alertmanager data source docs (#63611)

Improve Alertmanager data source docs

(cherry picked from commit 6e39b7403d)

Co-authored-by: Konrad Lalik <konrad.lalik@grafana.com>
2023-02-28 08:29:17 +01:00
Timur Olzhabayev
183f9317c5 fix(dashboard version service): add DashboardUID to query and respons… (#63821)
fix(dashboard version service): add DashboardUID to query and responses (#60800)

* fix(dashboard version service): add DashboardUID to query and responses

The DashboardUID was not populated in the response from Get and ListDashboardVersions. This adds the DashboardUID to the Get query (it was already in List) and populated the DashboardUID in the returned DashboardVersionDTOs.

(cherry picked from commit 42be0e106f)

Co-authored-by: Kristin Laemmert <mildwonkey@users.noreply.github.com>
2023-02-27 23:01:48 +01:00
Grot (@grafanabot)
194dbead83 [v9.4.x] Alerting: Fix available labels in the alert panel groupby dropdown (#63799)
Alerting: Fix available labels in the alert panel groupby dropdown (#63573)

(cherry picked from commit 5f35995cd4)

Co-authored-by: Konrad Lalik <konrad.lalik@grafana.com>
2023-02-27 17:58:52 +01:00
Grot (@grafanabot)
53b5cf5288 [v9.4.x] AzureMonitor: Fix template variables in ARG subscription field (#63758)
AzureMonitor: Fix template variables in ARG subscription field (#63731)

Add support for template variables in sub field

(cherry picked from commit 823aaaeb7c)

Co-authored-by: Andreas Christou <andreas.christou@grafana.com>
2023-02-27 05:56:15 -05:00
Jo
7900e795f1 [9.4.x] Users: Fix org user always getting org id = 1 (#63759)
Users: Fix org user always getting org id = 1 on auto assign false (#63708)

* fix org user always getting org id = 1 on auto assign false

* make tests explicit

* use correct cfg in service accounts

* fix api tests

* fix database test of ac

* fix InsertOrgUser returning affected rows as orgID

(cherry picked from commit c8db771939)
2023-02-27 10:31:53 +01:00
Jack Baldry
0f1f842015 [v9.4.x] fix link to explore with logs and headings (#63665) (#63701)
* [v9.4.x] Logs: Rename dedup to deduplication (#62944)

* fix: rename dedup with deduplication

* docs: update documentation

* fix: update names

(cherry picked from commit 8a94688114)
Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* [v9.4.x] fix link to explore with logs and headings (#63665)

fixed links and eadings

(cherry picked from commit a0a2181e5a)
Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

---------

Co-authored-by: Gareth Dawson <gareth.dawson@grafana.com>
Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
2023-02-25 07:26:22 +00:00
Alexander Weaver
7e017790d2 Alerting: Instrument outgoing state history requests using weaveworks/common (#63689)
* Alerting: Instrument outgoing state history requests using weaveworks/common (#63600)

* Loki backend and client depend on a requester

* Instrument all requests to loki using weaveworks TimedClient

* Construct collector in metrics package

(cherry picked from commit e77621649d)

* Revert all changes to gomod and gosum
2023-02-24 15:49:36 -06:00
Grot (@grafanabot)
3531683e87 [v9.4.x] CloudMonitor: Add missing logger to TimeSeriesQuery (#63132)
CloudMonitor: Add missing logger to TimeSeriesQuery (#63110)

(cherry picked from commit ac9639daf8)

Co-authored-by: Alyssa Bull <58453566+alyssabull@users.noreply.github.com>
2023-02-24 21:32:06 +00:00
Grot (@grafanabot)
b5747d397d [v9.4.x] CloudMonitoring: Fix crash when inspecting data for MQL queries (#63756)
CloudMonitoring: Fix crash when inspecting data for MQL queries (#63747)

CloudMonitoring: Fix missing Field name

This happened for MQL queries that used an [aggregate function][1], e.g.
`sum`.

[1]: https://cloud.google.com/monitoring/mql/reference#aggr-function-group

(cherry picked from commit 3672e44c1c)

Co-authored-by: Adam Simpson <adam@adamsimpson.net>
2023-02-24 13:30:38 -05:00
Grot (@grafanabot)
f8120e9152 [v9.4.x] Bump coverage versions (#63757)
Bump coverage versions (#63755)

- Includes a fix to ensure only ts/tsx files have coverage generated

(cherry picked from commit 0a7474ac5c)

Co-authored-by: Andreas Christou <andreas.christou@grafana.com>
2023-02-24 13:27:31 -05:00
Grot (@grafanabot)
ae94a60981 [v9.4.x] Plugins: Fix plugins CDN not working when plugins are not in domain's root path (#63729)
Plugins: Fix plugins CDN not working when plugins are not in domain's root path (#63202)

* Plugins CDN: Add support for different CDN root path

* Plugins CDN: Make frontendsettings return the correct CDN base path

* Update comments

* Fix version detection

* Undo frontend changes

* Fix system.js asset path construction

* fix(plugins): translate all plugin css asset paths loaded via cdn

* refactor(plugins): rename extractPluginNameVersionFromUrl and add comments

* Fix typo in comment

Co-authored-by: Will Browne <wbrowne@users.noreply.github.com>

* Hardcode CDN URL structure

/{id}/{version}/public/plugins/{id}/{assetPath} is not required anymore in the cdn url template config

---------

Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
Co-authored-by: Will Browne <wbrowne@users.noreply.github.com>
(cherry picked from commit 966bcd3545)

Co-authored-by: Giuseppe Guerra <giuseppe.guerra@grafana.com>
2023-02-24 08:50:29 -05:00
Grot (@grafanabot)
65c2b4fea2 [v9.4.x] TestData: Fix bug when selecting "Log" streaming (#63725)
TestData: Fix bug when selecting "Log" streaming (#63190)

* fix wrong fields getting populated

* fix bug not being able to select another streaming type

* add correct arg type

* remove unused import

(cherry picked from commit b3c0e7e977)

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
2023-02-24 08:21:25 -05:00
Grot (@grafanabot)
f18c84af5a [v9.4.x] Alerting: Fix changing datasource and creating new query not using defaults. (#63720)
Alerting: Fix changing datasource and creating new query not  using defaults. (#63092)

* Set default query when changing data source or adding new alert query

* Set default query when creating new alert rule

* Set fefault query for cloud and recording rules

* Create hook for getting defaults in AlertRuleForm

* fixing tests

* Use conditionals with 'if' for more clarity and rename lazy to async

* Add loading indicator for default queries

* Fix tests

* Make newModel a sync method and fix tests error

* Use useAsync instead of useEffect for an async call

(cherry picked from commit b42f973a7a)

Co-authored-by: Sonia Aguilar <33540275+soniaAguilarPeiron@users.noreply.github.com>
2023-02-24 07:52:46 -05:00
Grot (@grafanabot)
c10b18d06e [v9.4.x] Datasource Onboarding: Prevent flickering of onboarding page after first load (#63715)
Datasource Onboarding: Prevent flickering of onboarding page after first load (#63360)

* Datasource Onboarding: Prevent flickering of onboarding page after first load

* add loading state to loadDatasources & refactor

* fix test

* avoid loading state when loading datasources on add

* fix test

* add explainer on why fetching datasources is needed

(cherry picked from commit c136ad1f16)

Co-authored-by: Giordano Ricci <me@giordanoricci.com>
2023-02-24 12:00:25 +00:00
Grot (@grafanabot)
a3b692e1c5 [v9.4.x] Loki ds: Interpolation breaks in Loki queries when no scoped vars (#63700)
Loki ds: Interpolation breaks in Loki queries when no scoped vars (#63694)

(cherry picked from commit 14e29451cf)

Co-authored-by: Ivan Ortega Alba <ivanortegaalba@gmail.com>
2023-02-24 10:28:34 +01:00
Grot (@grafanabot)
30f3f63bd6 [v9.4.x] InfluxDB datasource: Query variable breaks trying to interpolate __interval (#63685)
InfluxDB ds: Query variable breaks trying to interpolate `__interval` (#63682)

(cherry picked from commit ca4cd85504)

Co-authored-by: Ivan Ortega Alba <ivanortegaalba@gmail.com>
2023-02-23 14:42:20 -05:00
Grot (@grafanabot)
758783a2e2 [v9.4.x] Docs: Disambiguate auto_assign_org_role configuration option descriptions (#63681)
Docs: Disambiguate auto_assign_org_role configuration option descriptions (#61827)

(cherry picked from commit 5687d23b52)

Co-authored-by: zsrv <95176387+zsrv@users.noreply.github.com>
2023-02-23 13:41:49 -05:00
Grot (@grafanabot)
5585dc0ba1 [v9.4.x] Docs: Fix of typo and delete of unnecessary sentence in 'Sign a plugin' doc (#63683)
Docs: Fix of typo and delete of unnecessary sentence in 'Sign a plugin' doc (#63538)

* Typo fix, minor edit

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

* Prettier fixes

Signed-off-by: Joe Perez <joseph.perez@grafana.com>

---------

Signed-off-by: Joe Perez <joseph.perez@grafana.com>
(cherry picked from commit dd5b115164)

Co-authored-by: Joseph Perez <45749060+josmperez@users.noreply.github.com>
2023-02-23 13:33:31 -05:00
Grot (@grafanabot)
2012cd7954 [v9.4.x] Docs: Update old default values for configuration options (#63678)
Docs: Update old default values for configuration options (#61826)

(cherry picked from commit 0481c12bd5)

Co-authored-by: zsrv <95176387+zsrv@users.noreply.github.com>
2023-02-23 13:01:24 -05:00
Grot (@grafanabot)
77263b8e65 [v9.4.x] Docs: Update default value for geomaps enable_custom_baselayers option (#63675)
Docs: Update default value for geomaps enable_custom_baselayers option (#61880)

Docs: Update default value for geomaps disable_custom_baselayers option

The `disable_custom_baselayers` configuration option name and default
value were inverted in commit e604e69d93,
but the update to the description in the documentation was missed.

(cherry picked from commit 22f51602ba)

Co-authored-by: zsrv <95176387+zsrv@users.noreply.github.com>
2023-02-23 17:46:01 +00:00
Grot (@grafanabot)
3e30c2024c [v9.4.x] InfluxDB: Fix getting empty response when querying fields with retention policy (#63671)
InfluxDB: Fix getting empty response when querying fields with retention policy (#63669)

Revert "InfluxDB: Send retention policy with InfluxQL queries if its been specified. (#62149)"

This reverts commit a5a85e0398.

(cherry picked from commit ffed779879)

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
2023-02-23 12:28:43 -05:00
Grot (@grafanabot)
cb13b75c6b [v9.4.x] Docs: Clarify command palette changes are not behind feature flag (#63667)
Docs: Clarify command palette changes are not behind feature flag (#63576)

(cherry picked from commit 63ae343ba9)

Co-authored-by: Josh Hunt <joshhunt@users.noreply.github.com>
2023-02-23 17:08:09 +00:00
Grot (@grafanabot)
242e05f448 [v9.4.x] CloudWatch Logs: Fix query editor freezing (#63666)
CloudWatch Logs: Fix query editor freezing (#63661)

(cherry picked from commit 22537bec2e)

Co-authored-by: Isabella Siu <Isabella.siu@grafana.com>
2023-02-23 12:06:34 -05:00
Grot (@grafanabot)
7f6319393d [v9.4.x] Navigation: Add plugin upgrade guide to docs (#63616)
Navigation: Add plugin upgrade guide to docs (#63449)

* initial attempt at plugin upgrade guide

* fix link

* small tweaks based on feedback

* add basic skeleton for tabs documentation

(cherry picked from commit f6e92da402)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-02-23 05:15:05 -05:00
Grot (@grafanabot)
57ecd3d3d3 [v9.4.x] TimeRangeInput: Fix positioning of dropdown menu (#63612)
TimeRangeInput: Fix positioning of dropdown menu (#63472)

fix TimeRangeInput positioning

(cherry picked from commit bcaf4dc0b1)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-02-23 05:01:03 -05:00
Grot (@grafanabot)
edd755b834 [v9.4.x] Docs: Improved docs for templating labels and annotations (#63606)
Docs: Improved docs for templating labels and annotations (#63539)

(cherry picked from commit c9497dc533)

Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-02-23 03:58:52 -05:00
Grot (@grafanabot)
db978cd48a [v9.4.x] MSSQL Datasource: Revert functions within macros change (#63598)
MSSQL Datasource: Revert functions within macros change (#63592)

* Revert functions within macros change
* Add tests for function and macro for mssql
* Remove macro support tests

---------

Co-authored-by: Oscar Kilhed <oscar.kilhed@grafana.com>
(cherry picked from commit 356e2e1933)

Co-authored-by: Kyle Cunningham <codeincarnate@users.noreply.github.com>
2023-02-22 16:23:47 -05:00
Grot (@grafanabot)
6162e6f823 [v9.4.x] Docs: Fix numbering in templating docs (#63587)
Docs: Fix numbering in templating docs (#63577)

(cherry picked from commit 18fec707fd)

Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-02-22 12:38:28 -05:00
Grot (@grafanabot)
8e4fa99ec7 [v9.4.x] Authn: Add separate context for session tagging (#63571)
Authn: Add separate context for session tagging  (#63561)

add context

(cherry picked from commit 635a456fa4)

Co-authored-by: Jo <joao.guerreiro@grafana.com>
2023-02-22 17:17:44 +01:00
Grot (@grafanabot)
8aaca53a32 [v9.4.x] Docs: fix typo in 9.4 what's new (#63580)
Docs: fix typo in 9.4 what's new (#63545)

provides -> providers

(cherry picked from commit 33277fccde)

Co-authored-by: Mitch Seaman <mjseaman@users.noreply.github.com>
2023-02-22 09:15:51 -06:00
Grot (@grafanabot)
9eefd2e42a [v9.4.x] Prometheus: Handle annotation query with empty fields (#63574)
Prometheus: Handle annotation query with empty fields (#63560)

Handle annotation query with empty fields

(cherry picked from commit 3d75dbc31e)

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
2023-02-22 08:57:47 -05:00
Grot (@grafanabot)
045aff4009 [v9.4.x] Add --init to all podman invocations to ensure ^C works on MacOS (#63552)
[v9.4.x] Add --init to all podman invocations to ensure ^C works on MacOS (#61745)

(cherry picked from commit 5f5f51b3bf)

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
2023-02-22 11:19:05 +00:00
Grot (@grafanabot)
e9b269a5b8 [v9.4.x] Docs: Delete old templating notifications docs page (#63549)
Docs: Delete old templating notifications docs page (#63547)

(cherry picked from commit 740bcf64ce)

Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-02-22 05:16:21 -05:00
Grot (@grafanabot)
fcc6c7c486 [v9.4.x] CloudWatch: Remove error for multi-value variable in logs runner (#63546)
CloudWatch: Remove error for multi-value variable in logs runner (#63522)

Remove error for multi template variable in CW logs runner

(cherry picked from commit 3a57304ef0)

Co-authored-by: Shirley <4163034+fridgepoet@users.noreply.github.com>
2023-02-22 04:43:44 -05:00
Jo
92ac380621 [v9.4.x] Authn: Anon session service (#63520)
* Authn: Anon session service (#63052)

* add anon sessions package

* add usage stat fn

* implement count for cache

* add anonservice to authn broker

* lint

* add tests for remote cache count

* move anon service to services

* wrap tagging in goroutine

* make func used

(cherry picked from commit ff78103a24)

* add local cache to protect multiple writes to DB cache

(cherry picked from commit bdb084736b)
2023-02-22 09:55:17 +01:00
Grot (@grafanabot)
98489d5f81 [v9.4.x] Geomap: Fix default opacity for layers (#63526) 2023-02-21 22:04:03 +02:00
Grot (@grafanabot)
60e88ffcb7 [v9.4.x] CloudMonitor: Fix query migration (#63519)
CloudMonitor: Fix query migration (#63491)

* Update query and set required fields for explore queries

* Update test case

- Validate onChange is called with the new query

(cherry picked from commit 20591cc42b)

Co-authored-by: Andreas Christou <andreas.christou@grafana.com>
2023-02-21 17:11:00 +00:00
Grot (@grafanabot)
249c5b013e [v9.4.x] Alerting: Fix incorrect comment in eval.go (#63513)
Alerting: Fix incorrect comment in eval.go (#63510)

This commit fixes an incorrect comment in the Result struct in eval.go
that I had written some time ago. The comment now documents the
actual behaviour and content of this field.

(cherry picked from commit f93a9c794d)

Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-02-21 11:15:55 -05:00
Jo
4ddc76f73e Authn: Stat registration [9.4.x] (#63504)
Authn: Stat registration (#62934)

* reorganize auth usage stats

* usage stat privilege elevators

* stat count of modified role

* cfg related info

* add authn anon client

* kv store

* ensure anon enabled is collected even if client is not registered

* fix usage stats test

(cherry picked from commit 14a78b58e9)
2023-02-21 16:21:09 +01:00
Grot (@grafanabot)
b6dc902ec0 [v9.4.x] Alerting: Get alert rules on faults (#61248) (#63505)
Alerting: Get alert rules on faults (#61248) (#63051)

* Alerting: get alert rules on faults (#61248)

Two functions used to fetch alert rules from DB are updated:
- GetAlertRulesForScheduling
- ListAlertRules
Rows are scanned one by one so good ones are returned.
Common Error is logged with indication how many
rules failed on deserialization.

Resolved: #61248

* updates from review comments

(cherry picked from commit 56c8661929)

Co-authored-by: bla2ej <123992384+bla2ej@users.noreply.github.com>
2023-02-21 10:15:40 -05:00
Grot (@grafanabot)
479360e6bf [v9.4.x] Update navigationAppConfig to use new k6 plugin id (#63459)
Update navigationAppConfig to use new k6 plugin id (#63002)

(cherry picked from commit f9f80cff89)

Co-authored-by: Simon <simon.legander@gmail.com>
2023-02-21 09:30:34 +01:00
Grot (@grafanabot)
f9845a6d70 [v9.4.x] Docs: Remove duplicate docs on images in notifications (#63475)
Docs: Remove duplicate docs on images in notifications (#63474)

(cherry picked from commit 85457156e3)

Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-02-20 18:01:28 +00:00
Grot (@grafanabot)
96121adda2 [v9.4.x] Docs: Uploading images from disk supported in Slack (#63473)
Docs: Uploading images from disk supported in Slack (#63443)

(cherry picked from commit 0e9201c522)

Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-02-20 12:43:02 -05:00
Grot (@grafanabot)
56b478f84d [v9.4.x] Docs: Upload images from disk supported in Telegram (#63471)
Docs: Upload images from disk supported in Telegram (#63442)

(cherry picked from commit 92248fe977)

Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-02-20 12:37:20 -05:00
Grot (@grafanabot)
7451db3f26 [v9.4.x] Prometheus: Fix missing abs operation to query builder (#63462)
Prometheus: Fix missing abs operation to query builder (#63139)

Add abs operator to prometheus query builder

(cherry picked from commit 80292d3d1e)

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
2023-02-20 09:58:23 -05:00
Grot (@grafanabot)
0bddceb24c [v9.4.x] Alerting: Fix confusing comment about screenshots in default.ini and docs (#63440)
Alerting: Fix confusing comment about screenshots in default.ini and docs (#63346)

(cherry picked from commit 005f5ca1df)

Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-02-20 05:25:36 -05:00
Yuri Tseretyan
65de5b497b Chore: update alerting package to head of 9.4.x (508391225cd4) (#63210)
update alerting package to 9.4.x 508391225cd4
2023-02-10 17:41:10 +01:00
Grot (@grafanabot)
edd529c2cf [v9.4.x] Loki Context UI: Do not disable last label (#63253)
Loki Context UI: Do not disable last label (#62866)

* improved text

* prevent all labels removed

* use `structuredClone` instead of lodash

* update test

* get `structuredClone` in test?

* fix using structuredClone

(cherry picked from commit 00edc1c6b1)

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
2023-02-10 08:35:00 -05:00
Grot (@grafanabot)
17605f97af [v9.4.x] PanelChrome: Make loading animation speed the same across panels (#63242)
PanelChrome: Make loading animation speed the same across panels  (#62997)

Revert devenv dashboard change

(cherry picked from commit ed626427de)

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2023-02-10 10:20:35 +01:00
Grot (@grafanabot)
e5d80f21e9 [v9.4.x] Alerting: Fix a bug taking screenshots with Dashboard UID (#63222)
Alerting: Fix a bug taking screenshots with Dashboard UID (#63220)

This commit fixes a bug where Grafana would fail to take a screenshot if
the same Dashboard UID was present across two or more different orgs.

(cherry picked from commit 1f984409a2)

Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-02-09 21:24:05 +00:00
Grot (@grafanabot)
f69374abbd [v9.4.x] Docs: Fix redaction error in notification policies docs (#63140)
Docs: Fix redaction error in notification policies docs (#63112)

fix redaction error in notification policies docs

(cherry picked from commit f43993d43f)

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>
2023-02-09 13:03:59 -03:00
Grot (@grafanabot)
ec2082c172 [v9.4.x] docs: adds what's new video (#63207)
docs: adds what's new video (#63206)

adds what's new video

(cherry picked from commit 52cc6a8651)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-02-09 09:56:38 -06:00
Horst Gutmann
3574fa5996 [9.4.x] Add missing PRs to 9.4.0-beta1 changelog (#62596) (#62600)
Add missing PRs to 9.4.0-beta1 changelog (#62596)

(cherry picked from commit addfd1b5cf)
2023-02-09 15:31:22 +01:00
Grot (@grafanabot)
982624f7b1 [v9.4.x] Provisioning: Parse boolean and numeric values from environment variables (#63192)
Provisioning: Parse boolean and numeric values from environment variables (#63085)

(cherry picked from commit a33e316f40)

Co-authored-by: Andres Martinez Gotor <andres.martinez@grafana.com>
2023-02-09 09:04:33 -05:00
Grot (@grafanabot)
69453133e7 [v9.4.x] Fix MSSQL queries failing because of bad interpolation (#63172)
Fix MSSQL queries failing because of bad interpolation (#63167)

fix failing mssql queries

(cherry picked from commit 62b078e4e4)

Co-authored-by: Victor Marin <36818606+mdvictor@users.noreply.github.com>
2023-02-09 03:32:11 -05:00
Grot (@grafanabot)
8a489712cc [v9.4.x] docs: comments out video (#63152)
docs: comments out video (#63150)

comments out video

(cherry picked from commit bc93f45e9d)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-02-08 14:43:40 -06:00
Grot (@grafanabot)
87f6fef9d7 [v9.4.x] docs: fixes video link in what's new 9.4 (#63146)
docs: fixes video link in what's new 9.4 (#63145)

fixes video link

(cherry picked from commit b405874166)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-02-08 13:51:02 -06:00
Grot (@grafanabot)
371149fa02 [v9.4.x] fix broken envelope encryption link (#63143)
fix broken envelope encryption link (#63135)

(cherry picked from commit 72ca7fe7fe)

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
2023-02-08 11:41:47 -08:00
Grot (@grafanabot)
845b797b5b [v9.4.x] What's New in v9.4 (#63137)
What's New in v9.4 (#59614)

* What's New in v9.4

* moves alert email templating to v9.4 release

* Add whats new for SAT (#61151)

* Add whats new for SAT

* Logs: Add logdetails redesign to "whats new" (#61361)

* update whats new

* update text and add image

* change `logline` to `log line`

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

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

* add: skip org role sync

* add note about oncall rbac to whats new 9.4 docs

* Loki Datasource: Add query validation to What's new (#62012)

Loki Datasource: add query validation to what's new

* Add note about SAML auto login (#61926)

* Add note about SAML auto login

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* run prettier

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* What's New: Add image for the Loki Query Validation feature (#62358)

* What's new 9.4: add image for Loki query validation

* What's new 9.4: update image path

* Docs: Add logs sample to whats new in 9.4 (#62354)

* Add logs sample to whats new in 9.4

* Update path to image

* Update docs/sources/whatsnew/whats-new-in-v9-4.md

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

---------

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

* Add datasource connection page to whatsnew

* Update datasource connection whats new 9.4

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update datasource connection whats-new-in-v9-4.md

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>

* Update whats-new-in-v9-4.md

Enterprise features add on

* Added command palette, navigation

* Update whats-new-in-v9-4.md

* Update whats-new-in-v9-4.md

* enterprise updates

* add panel header redesign content

* Adds alerting content to whats new

* Fix typo

Nav navigation -> New Navigation

* adds image to pause alerts

* Updated cmd palette screenshot

* Update docs/sources/whatsnew/whats-new-in-v9-4.md

* Update docs/sources/whatsnew/whats-new-in-v9-4.md

* adds alerting screenshots

* reorder and begin adding availability

Re-ordered updates into groups, and added availability descriptions to the first few updates.

* Updated command palette availability

* fix capitalization

* copy edit

* add before you upgrade section

* add docs relref links

* makes prettier

* added before you begin boilerplate

* Add Enterprise Datasource updates / highlights

* Add what's new section on updates to the canvas panel

* Update canvas demo vid src to correct location

* Canvas: add small shoutout for new server element in whats new

* copy edit final contributions

---------

Co-authored-by: linoman <2051016+linoman@users.noreply.github.com>
Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
Co-authored-by: Eric Leijonmarck <eric.leijonmarck@gmail.com>
Co-authored-by: Joey Orlando <joseph.t.orlando@gmail.com>
Co-authored-by: Matias Chomicki <matyax@gmail.com>
Co-authored-by: Alexander Zobnin <alexanderzobnin@gmail.com>
Co-authored-by: natellium <natalia.bernarte@grafana.com>
Co-authored-by: Natalia Bernarte Oses <74534993+natellium@users.noreply.github.com>
Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
Co-authored-by: Fabrizia Rossano <117294258+frossano-grafana@users.noreply.github.com>
Co-authored-by: Zsofia <zsofia.komaromi@gmail.com>
Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
Co-authored-by: Mitch Seaman <mjseaman@users.noreply.github.com>
Co-authored-by: Mitchel Seaman <mitchel.seaman@gmail.com>
Co-authored-by: josiahg <jay@grafana.com>
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
(cherry picked from commit 4dba927b3a)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-02-08 14:16:20 -05:00
Grot (@grafanabot)
45dd9f9a9f [v9.4.x] Navigation: add a link to starred dashboards in the megamenu (#63106)
Navigation: add a link to starred dashboards in the megamenu (#62685)

add a link to starred dashboards in the megamenu

(cherry picked from commit fc2f7f90f8)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-02-08 15:41:10 +00:00
Grot (@grafanabot)
8a8180c44d [v9.4.x] Docs: incorporates feedback from PR #62402 (#63101)
Docs: incorporates feedback from PR #62402 (#63065)

incorporates feedback from original PR

(cherry picked from commit a7ae05285c)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-02-08 09:36:07 -06:00
Ashley Harrison
532fc8dd2c Navigation: Backport 61103 to v9.4.x (#63097)
Navigation: Ensure command palette is correctly translated (#61103)

* Navigation: Translate nav tree in store

* Remove usage of getNavTitle

* properly translate children

* add pubdash translation

* remove extraneous calls to translation in PageHeader

* empty commit

* correctly allow subtitle to be overrwitten (thank you tests!)

---------

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
(cherry picked from commit 504eabbe80)

Co-authored-by: Josh Hunt <joshhunt@users.noreply.github.com>
2023-02-08 13:41:37 +00:00
Horst Gutmann
0d648ea977 [9.4.x] CI: Do not clone repo in artifact-page step (#63077) (#63087)
CI: Do not clone repo in artifact-page step (#63077)

(cherry picked from commit 470be140dc)
2023-02-08 15:19:53 +02:00
Horst Gutmann
23ac2de4d3 [9.4.x] CI: Running Redis integration tests without grabpl (#63028) (#63074)
This restores some changes from
https://github.com/grafana/grafana/pull/61920 that were accidentally
deleted.

(cherry picked from commit 2804acd264)
2023-02-08 04:35:40 -05:00
Grot (@grafanabot)
87497a1afc [v9.4.x] Prometheus: Table format throwing error on empty result (#63062)
Prometheus: Table format throwing error on empty result (#63053)

* fix bug in prometheus table view which is throwing error when a query returns no results

(cherry picked from commit 79b750a4b2)

Co-authored-by: Galen Kistler <109082771+gtk-grafana@users.noreply.github.com>
2023-02-07 16:10:00 -05:00
Grot (@grafanabot)
3c7cfecf50 [v9.4.x] CommandPalette: Move quick add actions to top level (#63049)
CommandPalette: Move quick add actions to top level (#62900)

* Move quick actions to top level

* Change quick action verb to "Create"

* create to 'new'

* fix comment

* update translations

* undo changing alerting

(cherry picked from commit 5564b93e2f)

Co-authored-by: Josh Hunt <joshhunt@users.noreply.github.com>
2023-02-07 16:21:49 +00:00
Grot (@grafanabot)
63f1d95ed6 [v9.4.x] Update publishing workflows to use organization secret (#63046)
Update publishing workflows to use organization secret (#63001)

The new tokens are managed centrally and have a longer expiry.
Administrators of the grafanabot account will be
notified of the pending expiry and the secret can be rotated centrally
without the need for a repository administrator to update their
secrets.

The existing repository secrets can safely be removed. The tokens for
those secrets will be removed by the end of this week.

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
(cherry picked from commit ba9bdf3455)

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
2023-02-07 10:22:49 -05:00
Grot (@grafanabot)
238f51fb73 [v9.4.x] Docs: fix typo (#63038)
Docs: fix typo (#63032)

(cherry picked from commit c4909a6c2b)

Co-authored-by: Andres Martinez Gotor <andres.martinez@grafana.com>
2023-02-07 16:06:00 +01:00
Grot (@grafanabot)
88e8d97ad3 [v9.4.x] Search: Switch to list view when filtering by tags (#63017)
Search: Switch to list view when filtering by tags (#63004)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
(cherry picked from commit c9773e55b2)

Co-authored-by: Josh Hunt <joshhunt@users.noreply.github.com>
2023-02-07 07:12:56 -05:00
Marcus Efraimsson
bd14abb309 [v9.4.x] Docs: Fix 404 links in build a plugin page (#63006) (#63010)
Docs: Fix 404 links in build a plugin page (#63006)

(cherry picked from commit a2f8dd7f1f)
2023-02-07 12:22:12 +01:00
Dimitris Sotirakis
96fa91e113 [v9.4.x] CI: Remove variants arg from package step (#62858) (#62999)
CI: Remove variants arg from `package` step (#62858)

* Remove variants arg from package step

* Fix starlark lint

* Default to releaseModeConfig.Variants

* Check for empty variants arg

(cherry picked from commit e5c48ac945)
2023-02-07 11:19:05 +02:00
Grot (@grafanabot)
0ca7d1e210 [v9.4.x] docs: upgrade guide refactor organizes releases into their own pages; moves upgrade guide to the root (#62987)
docs: upgrade guide refactor organizes releases into their own pages; moves upgrade guide to the root (#62402)

* organizes releases into their own pages; moves upgrade guide to the root

* adds and removes aliases

* Update docs/sources/upgrade-guide/upgrade-v8.0/index.md

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>

* Update docs/sources/upgrade-guide/upgrade-v8.0/index.md

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>

* Update docs/sources/upgrade-guide/upgrade-v8.0/index.md

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>

* Update docs/sources/upgrade-guide/upgrade-v9.3/index.md

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>

* Update docs/sources/shared/upgrade/upgrade-common-tasks.md

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>

* Update docs/sources/shared/upgrade/upgrade-common-tasks.md

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>

* Update docs/sources/shared/upgrade/upgrade-common-tasks.md

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>

* corrects relrefs

---------

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
(cherry picked from commit ee2e294b4e)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-02-06 17:10:49 -06:00
Grot (@grafanabot)
200c94c722 [v9.4.x] Add canonical URL to all HTTP API docs (#62971)
Add canonical URL to all HTTP API docs (#62957)

Facilitates mounting these docs in the Grafana Cloud documentation set
without affecting SEO.

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
(cherry picked from commit 4037e5e325)

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
2023-02-06 17:21:50 +00:00
Grot (@grafanabot)
7589dbe784 [v9.4.x] docs: fix broken annotations link (#62968)
docs: fix broken annotations link (#62834)

* docs: fix broken annotations link

Link to annotations section is broken because the section was never added. A placeholder for it was removed on this commit, but the link wasn't. This seems like the best place to point to.

* fix relref formatting

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* removed TODOs from tables

* prettier linting

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
(cherry picked from commit 09943407e4)

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
2023-02-06 10:53:14 -06:00
Grot (@grafanabot)
005fb9586c [v9.4.x] Alerting: fix "policy" typo (#62955)
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2023-02-06 16:58:22 +01:00
Grot (@grafanabot)
cb898dfe66 [v9.4.x] Docs: corrects typo (#62961)
Docs: corrects typo (#62954)

corrects typo

(cherry picked from commit cf272186fb)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-02-06 09:42:26 -06:00
Grot (@grafanabot)
3dffe4099b [v9.4.x] Refactor: Use data source UID rather than ID (#62937)
Refactor: Use data source UID rather than ID (#62781)

(cherry picked from commit 9893408af9)

Co-authored-by: Andres Martinez Gotor <andres.martinez@grafana.com>
2023-02-06 05:36:00 -05:00
Grot (@grafanabot)
d9710139e1 [v9.4.x] Prometheus: Refactor. Use data source UID rather than the deprecated ID (#62936)
Prometheus: Refactor. Use data source UID rather than the deprecated ID (#62795)

(cherry picked from commit 32e6af966f)

Co-authored-by: Andres Martinez Gotor <andres.martinez@grafana.com>
2023-02-06 11:12:24 +01:00
Grot (@grafanabot)
8e9fb8cf93 [v9.4.x] SAML: Update library (fix single logout) (#62933)
SAML: Update library (fix single logout) (#62880)

* SAML: update library (fix single logout)

* Run go mod tidy

(cherry picked from commit 5205cfb11c)

Co-authored-by: Alexander Zobnin <alexanderzobnin@gmail.com>
2023-02-06 03:36:51 -05:00
Grot (@grafanabot)
fba376b347 [v9.4.x] Docs: removes Grafana Cloud CTA (#62905)
Docs: removes Grafana Cloud CTA (#62827)

removes Grafana Cloud CTA

(cherry picked from commit ebe54629e7)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-02-03 12:39:30 -06:00
Grot (@grafanabot)
6895e75f70 [v9.4.x] Canvas: Support color themes for arrows (#62896)
Canvas: Support color themes for arrows (#62829)

(cherry picked from commit db953c9a9c)

Co-authored-by: Drew Slobodnjak <60050885+drew08t@users.noreply.github.com>
2023-02-03 12:47:27 -05:00
Grot (@grafanabot)
4f826bc76c [v9.4.x] Canvas: Improve anchor UX (#62898)
Canvas: Improve anchor UX (#62409)

Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
(cherry picked from commit bbb572e73f)

Co-authored-by: Drew Slobodnjak <60050885+drew08t@users.noreply.github.com>
2023-02-03 12:09:51 -05:00
Grot (@grafanabot)
efaf4f5e09 [v9.4.x] Canvas: Update server element design (#62897)
Canvas: Update server element design (#62832)

(cherry picked from commit 43ce077133)

Co-authored-by: Drew Slobodnjak <60050885+drew08t@users.noreply.github.com>
2023-02-03 12:07:29 -05:00
Grot (@grafanabot)
907381ed5c [v9.4.x] MSSQL: Add support for macro function calls (#62890)
MSSQL: Add support for macro function calls (#62742)

* MSSQL: Add support for macro function calls

* Add tests

(cherry picked from commit 9fc3b360a4)

Co-authored-by: Victor Marin <36818606+mdvictor@users.noreply.github.com>
2023-02-03 11:03:24 -05:00
Grot (@grafanabot)
8c9cb8e839 [v9.4.x] PanelChrome: Implement hover header (#62875)
PanelChrome: Implement hover header (#61774)

Closes #59078

Co-authored-by: polinaboneva <polina.boneva@grafana.com>
Co-authored-by: Ivan Ortega <ivanortegaalba@gmail.com>
Co-authored-by: Alexandra Vargas <alexa1866@gmail.com>
(cherry picked from commit 40ec4ef5b8)

Co-authored-by: kay delaney <45561153+kaydelaney@users.noreply.github.com>
2023-02-03 15:30:08 +00:00
Grot (@grafanabot)
028cc7e72b [v9.4.x] Navigation: move Connections plugin to be just after apps (#62871)
Navigation: move Connections plugin to be just after apps (#62801)

move connections plugin to be just after apps

(cherry picked from commit c819e95687)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-02-03 09:06:18 -05:00
Grot (@grafanabot)
00555606d5 [v9.4.x] Search: Fix not being able to clear sort value (#62869)
Search: Fix not being able to clear sort value (#62557)

* user essentials mob! 🔱

lastFile:public/app/features/search/state/SearchStateManager.ts

* user essentials mob! 🔱

lastFile:public/app/features/search/page/components/ActionRow.tsx

* user essentials mob! 🔱

* remove searchSort state from localStorage when cleared

---------

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
Co-authored-by: Joao Silva <joao.silva@grafana.com>
(cherry picked from commit f8809eef59)

Co-authored-by: Josh Hunt <joshhunt@users.noreply.github.com>
2023-02-03 08:51:47 -05:00
Grot (@grafanabot)
9cf5b4eb9e [v9.4.x] Tempo: Fix span name being dropped from the query (#62846)
Tempo: Fix span name being dropped from the query (#62257)

(cherry picked from commit c3b476e1dc)

Co-authored-by: Hamas Shafiq <hamas.shafiq@grafana.com>
2023-02-03 05:34:09 -05:00
Grot (@grafanabot)
8637518540 [v9.4.x] Added pageZoomLevel option to image renderer setup documentation (#62842)
Added pageZoomLevel option to image renderer setup documentation (#59472)

* Added pageZoomLevel option to image renderer setup

* Update _index.md

* Update docs/sources/setup-grafana/image-rendering/_index.md

* chore: prettier run in docs

---------

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
(cherry picked from commit 8b017f5aa4)

Co-authored-by: Gabriel Goller <gabrielgoller123@gmail.com>
2023-02-03 10:25:14 +01:00
Grot (@grafanabot)
0c27df8b8c [v9.4.x] Alerting docs: updates to alert rules docs for 9.4 (#62810)
Alerting docs: updates to alert rules docs for 9.4 (#62744)

* Alerting docs: updates to alert rules docs for 9.4

* Adds updates to oncall contact point and pause alerts

* Adds view read-only query update 9.4

(cherry picked from commit d19803a0f0)

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
2023-02-03 07:17:00 +00:00
Grot (@grafanabot)
8fd1547edb [v9.4.x] Alerting: Add label query parameters to state history endpoint (#62835)
Alerting: Add label query parameters to state history endpoint (#62831)

* Allow equality-only matching of arbitrary labels via query params

* Pre-initialize map

(cherry picked from commit 9eeea8f5ea)

Co-authored-by: Alexander Weaver <weaver.alex.d@gmail.com>
2023-02-02 23:14:16 +00:00
Alexander Weaver
21f204d35a Alerting: implement loki query for alert state history (#62833)
Alerting: implement loki query for alert state history (#61992)

* Alerting: implement loki query for alert state history

* extract selector building

* add unit tests for selector creation

* backup

* give selectors their own type

* build dataframe

* add some tests

* small changes after manual testing

* use struct client

* golint

* more golint

* Make RuleUID optional for Loki implementation

* Drop initial assumption that we only have one series

* Pare down to three columns, fix timestamp overflows, improve failure cases in loki responses

* Embed structred log lines in the dataframe as objects rather than json strings

* Include state history label filter

* Remove dead code

---------

Co-authored-by: Jean-Philippe Quéméner <JohnnyQQQQ@users.noreply.github.com>
2023-02-02 16:56:26 -06:00
Grot (@grafanabot)
84da688400 [v9.4.x] Alerting: Pause dash alerts on migration (#62830)
Alerting: Pause dash alerts on migration (#62798)

* Alerting: Pause dash alerts on migration

(cherry picked from commit f49efa6e27)

Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-02-02 22:07:06 +00:00
Grot (@grafanabot)
b742567ade [v9.4.x] Alerting: Fix template validation in provisioning api (#62825)
Alerting: Fix template validation in provisioning api (#62530)

* Alerting: Fix template validation in provisioning api

Fix issue where provisioning API accepts a malformed template having extra
text outside of definition block and template name matching definition name.

(cherry picked from commit f9ec16e74f)

Co-authored-by: Matthew Jacobson <matthew.jacobson@grafana.com>
2023-02-02 20:45:21 +00:00
Grot (@grafanabot)
385b15bf69 [v9.4.x] Alerting: Add static label to all state history entries (#62819)
Alerting: Add static label to all state history entries (#62817)

* Add static label to all state history entries

* Separate label and value visually

(cherry picked from commit 647f73ddc5)

Co-authored-by: Alexander Weaver <weaver.alex.d@gmail.com>
2023-02-02 14:00:09 -06:00
Grot (@grafanabot)
94ec932d29 [v9.4.x] Docs: corrects incorrect redirect and fixes link (#62820)
Docs: corrects incorrect redirect and fixes link (#62815)

corrects incorrect redirect and fixes link

(cherry picked from commit 060e0a4d18)

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-02-02 13:52:26 -06:00
Grot (@grafanabot)
2525b30803 [v9.4.x] Alerting: Add endpoint for querying state history (#62813)
Alerting: Add endpoint for querying state history (#62166)

* Define endpoint and generate

* Wire up and register endpoint

* Cleanup, define authorization

* Forgot the leading slash

* Wire up query and SignedInUser

* Wire up timerange query params

* Add todo for label queries

* Drop comment

* Update path to rules subtree

(cherry picked from commit 6ad1cfef38)

Co-authored-by: Alexander Weaver <weaver.alex.d@gmail.com>
2023-02-02 12:32:30 -06:00
Grot (@grafanabot)
324964b86b [v9.4.x] Alerting: Usability adjustments to Loki representation of state history values (#62811)
Alerting: Usability adjustments to Loki representation of state history values (#62643)

* Extract label merge, add test file

* Extract error/NoData to first class fields, remove a layer from values

* Include dashUID and panelID as line-level fields

* Drop unnecessary object receiver

* Add tests for stream building

* Drop NoData field from log lines

(cherry picked from commit 9fa28c11c5)

Co-authored-by: Alexander Weaver <weaver.alex.d@gmail.com>
2023-02-02 11:15:51 -06:00
Grot (@grafanabot)
d31f932800 [v9.4.x] Auth: Rotate token patch (#62782)
Auth: Rotate token patch (#62676)

* Use singleflight.Group

* Align tests

* Cleanup

(cherry picked from commit 7c1d9769ca)

Co-authored-by: Misi <mgyongyosi@users.noreply.github.com>
2023-02-02 18:05:38 +01:00
Grot (@grafanabot)
363171b182 [v9.4.x] Alerting: Pass yaml as a query param in export request (#62806)
Alerting: Pass yaml as a query param in export request (#62751)

* Set YAML as default value for exporting alert rules

* use YAML format for rule list export

Co-authored-by: Sonia Aguilar <33540275+soniaAguilarPeiron@users.noreply.github.com>

* lint

* Add new format query param to swagger+docs

* Fix broken test

---------

Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
Co-authored-by: Matt Jacobson <matthew.jacobson@grafana.com>
(cherry picked from commit 753c84f825)

Co-authored-by: Sonia Aguilar <33540275+soniaAguilarPeiron@users.noreply.github.com>
2023-02-02 17:29:21 +01:00
Alexander Weaver
32e3cd7cbc Alerting: Refactor away a layer of indirection around the goroutine in Loki state history (#62802)
Alerting: Refactor away a layer of indirection around the goroutine in Loki state history (#62644)

Inline recordStreamsAsync in loki backend
2023-02-02 10:14:47 -06:00
Grot (@grafanabot)
2a223cbea2 [v9.4.x] Tempo: TraceQL syntax highlighting improvements (#62803)
Tempo: TraceQL syntax highlighting improvements (#62349)

* Better syntax highlighting for durations, floats and right-hand-side tags

* Remove hex rule in TraceQL syntax highlighting

(cherry picked from commit 60f2433a0f)

Co-authored-by: Andre Pereira <adrapereira@gmail.com>
2023-02-02 16:03:25 +00:00
Grot (@grafanabot)
c7a182e9d5 [v9.4.x] Tempo: Trace to logs update image (#62804)
Tempo: Trace to logs update image (#62796)

(cherry picked from commit 99a16d27c1)

Co-authored-by: Andrej Ocenas <mr.ocenas@gmail.com>
2023-02-02 17:02:43 +01:00
Grot (@grafanabot)
d8f757cb8c [v9.4.x] Tempo: Inject status and status.code for tags autocomplete (#62800)
Tempo: Inject status and status.code for tags autocomplete (#62794)

* Tempo: Inject status for v2 and status.code for v1 in the tags list for autocomplete

* Small comment fix

(cherry picked from commit b78af0b0f0)

Co-authored-by: Andre Pereira <adrapereira@gmail.com>
2023-02-02 15:53:17 +00:00
Grot (@grafanabot)
bfe6b520d7 [v9.4.x] Tempo: Update docs for trace to logs functionality (#62793)
Tempo: Update docs for trace to logs functionality (#62338)

(cherry picked from commit 1aae808723)

Co-authored-by: Andrej Ocenas <mr.ocenas@gmail.com>
2023-02-02 16:52:24 +01:00
Grot (@grafanabot)
190c3aad58 [v9.4.x] Plugins: Prefer to use the data source UID when querying (#62789)
Plugins: Prefer to use the data source UID when querying (#62776)

(cherry picked from commit 68862ce3e8)

Co-authored-by: Andres Martinez Gotor <andres.martinez@grafana.com>
2023-02-02 15:02:06 +00:00
Grot (@grafanabot)
022abcb47d [v9.4.x] SQLStore: Fix folder migration for MySQL < 5.7 (#62786)
SQLStore: Fix folder migration for MySQL < 5.7 (#62521)

* Nested folders: Do not skip integration tests

* SQLStore: Fix folder migration

It reduces the length of the title column to be equal with the respective
dashboard column.

(cherry picked from commit 4eaff63eda)

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>
2023-02-02 14:40:51 +00:00
Horst Gutmann
5b305cb696 [9.4.x] CI: Allow other modules to register build sub-commands (PR #62741) (#62774)
CI: Allow other modules to register build sub-commands (#62741)

* Allow other modules to register build sub-commands

* CI: Fix retries on artifacts-page clone

* Fix linting errors

* Fix golint issues

* Update to grabpl 3.0.21

(cherry picked from commit 312ea59e6d)
2023-02-02 15:14:41 +01:00
Grot (@grafanabot)
a03069fb08 [v9.4.x] Alerting: Set YAML as default value for exporting alert rules (#62770)
Alerting: Set YAML as default value for exporting alert rules (#62760)

Set YAML as default value for exporting alert rules

(cherry picked from commit 517e614661)

Co-authored-by: Sonia Aguilar <33540275+soniaAguilarPeiron@users.noreply.github.com>
2023-02-02 13:42:44 +01:00
Grot (@grafanabot)
0413fea8d2 [v9.4.x] Heatmap: Support heatmap rows with non-timeseries X axis (#62733)
Heatmap: Support heatmap rows with non-timeseries X axis (#60929)

Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
(cherry picked from commit 4a8763d7b6)

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2023-02-02 12:27:09 +01:00
Grot (@grafanabot)
30081ca04b [v9.4.x] Nested Folder: Fix for SQLite not to overwrite the parent on restarts (#62756)
Nested Folder: Fix for SQLite not to overwrite the parent on restarts (#62709)

Nested Folder: Fix for SQLite not to overwrite the arent on restarts

(cherry picked from commit adaf82ffb7)

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>
2023-02-02 10:26:55 +00:00
Grot (@grafanabot)
53a1e5b7e6 [v9.4.x] Fix/60084/save and test (#62750)
Fix: Save and test error message does not persist across datasource instance settings anymore

(cherry picked from commit ce50168b70)

Co-authored-by: Timur Olzhabayev <timur.olzhabayev@grafana.com>
2023-02-02 09:01:07 +00:00
Grot (@grafanabot)
29cc5f9c62 [v9.4.x] Elasticsearch: Fix consistent label order in alerting (#62743)
Elasticsearch: Fix consistent label order in alerting (#62497)

elasticsearch: backend: sort label-values
(cherry picked from commit d9fd807375)

Co-authored-by: Gábor Farkas <gabor.farkas@gmail.com>
2023-02-02 08:22:56 +00:00
Grot (@grafanabot)
b485d1cde9 [v9.4.x] Cloudwatch: Fix log group variable interpolation (#62713)
Cloudwatch: Fix log group variable interpolation (#62640)

(cherry picked from commit 1f09508d8c)

Co-authored-by: Isabella Siu <Isabella.siu@grafana.com>
2023-02-01 13:52:52 -05:00
Grot (@grafanabot)
045c2d4e59 [v9.4.x] docs: fix broken elasticsearch metrics play link (#62719)
docs: fix broken elasticsearch metrics play link (#62715)

fix broken elastic search play link

(cherry picked from commit 1225e8d6d8)

Co-authored-by: Isabel <76437239+imatwawana@users.noreply.github.com>
2023-02-01 12:05:00 -06:00
Grot (@grafanabot)
654af9a48d [v9.4.x] Explore: Fix graph not updating when changing config (#62706)
Explore: Fix graph not updating when changing config (#62473)

* Explore: Fix graph not updating when changing config

* move useStructureRev to a seprate hook and add specific tests

(cherry picked from commit 6b6b733229)

Co-authored-by: Giordano Ricci <me@giordanoricci.com>
2023-02-01 17:02:20 +00:00
Grot (@grafanabot)
5bb58c5172 [v9.4.x] Alerting docs: adds declare incident (#62710)
Alerting docs: adds declare incident (#62681)

* Alerting docs: adds declare incident

* adds alert detail view option

(cherry picked from commit 9d07b77532)

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
2023-02-01 16:59:26 +00:00
Grot (@grafanabot)
42b9c898bf [v9.4.x] Search: Fix alignment of checkbox in folder view (#62708) 2023-02-01 16:44:11 +00:00
Grot (@grafanabot)
795c86b045 [v9.4.x] Tempo: Remove tempoApmTable feature flag (#62702)
Tempo: Remove tempoApmTable feature flag (#62499)

Remove tempoApmTable feature flag

(cherry picked from commit 5e1506dea0)

Co-authored-by: Andre Pereira <adrapereira@gmail.com>
2023-02-01 16:15:58 +00:00
Grot (@grafanabot)
5d5e7f97e9 [v9.4.x] Navigation: wrap dashboard settings actions in ToolbarButtonRow for responsiveness (#62692)
Navigation: wrap dashboard settings actions in `ToolbarButtonRow` for responsiveness (#62475)

wrap dashboard actions in toolbarbuttonrow for responsiveness

(cherry picked from commit 0a780d978e)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-02-01 15:14:49 +00:00
Grot (@grafanabot)
c8cf18d8f6 [v9.4.x] Alerting: hide "silence" button for external AM setups (#62691)
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2023-02-01 15:10:51 +00:00
Grot (@grafanabot)
70e4499f83 [v9.4.x] Loki: Fix label filter expression treating int as string (#62687)
Loki: Fix label filter expression treating int as string (#62496)

* fix: label filter expression treats int as string

* refactor: labelFilterRenderer

* test: add tests to labelFilterRenderer

* refactor: use backticks based on the operator not the value

* test: labelFilterRenderer uses the correct value type based on the operator

* test: use it.every rather than having multiple repetitive tests

(cherry picked from commit 42f8f5a9ea)

Co-authored-by: Gareth Dawson <gareth.dawson@grafana.com>
2023-02-01 14:52:46 +00:00
Grot (@grafanabot)
2e251a2b20 [v9.4.x] Alerting: Add support for "normal" as state filter in rule search (#62679)
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2023-02-01 15:05:51 +01:00
Grot (@grafanabot)
cdec4eb6ab [v9.4.x] Alerting: Add Copy action to templates table (#62683)
Alerting: Add Copy action to templates table (#62135)

* Add duplicate action to templates table

Co-authored-by: Virginia Cepeda <virginia.cepeda@grafana.com>

* Move duplicate icon, and remove provenance when rendering TemplateForm

* Create generic generateCopiedName method to avoid duplication and use it also in the CloneRuleEditor

* Use 'Copy' for duplicating templates and cloning alert rules

* Improve updating the template content with new unique define values when copying

Co-authored-by: Konrad Lalik <konradlalik@gmail.com>

* Fix typo

---------

Co-authored-by: Virginia Cepeda <virginia.cepeda@grafana.com>
Co-authored-by: Konrad Lalik <konradlalik@gmail.com>
(cherry picked from commit 151e57df70)

Co-authored-by: Sonia Aguilar <33540275+soniaAguilarPeiron@users.noreply.github.com>
2023-02-01 14:57:12 +01:00
Grot (@grafanabot)
71a18da270 [v9.4.x] Command palette: section styling tweaks (#62682)
Command palette: section styling tweaks (#62671)

section styling tweaks

(cherry picked from commit 8d7e7693f2)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-02-01 13:12:55 +00:00
Grot (@grafanabot)
40354c6b40 [v9.4.x] Alerting: Allow alert rule pausing from API (#62675)
Alerting: Allow alert rule pausing from API (#62326)

* Add is_paused attr to the POST alert rule group endpoint

* Add is_paused to alerting API POST alert rule group

* Fixed tests

* Add is_paused to alerting gettable endpoints

* Fix integration tests

* Alerting: allow to pause existing rules (#62401)

* Display Pause Rule switch in Editing Rule form

* add isPaused property to form interface and dto

* map isPaused prop with is_paused value from DTO

Also update test snapshots

* Append '(Paused)' text on alert list state column when appropriate

* Change Switch styles according to discussion with UX

Also adding a tooltip with info what this means

* Adjust styles

* Fix alignment and isPaused type definition

Co-authored-by: gillesdemey <gilles.de.mey@gmail.com>

* Fix test

* Fix test

* Fix RuleList test

---------

Co-authored-by: gillesdemey <gilles.de.mey@gmail.com>

* wip

* Fix tests and add comments to clarify AlertRuleWithOptionals

* Fix one more test

* Fix tests

* Fix typo in comment

* Fix alert rule(s) cannot be paused via API

* Add integration tests for alerting api pausing flow

* Remove duplicated integration test

---------

Co-authored-by: Virginia Cepeda <virginia.cepeda@grafana.com>
Co-authored-by: gillesdemey <gilles.de.mey@gmail.com>
Co-authored-by: George Robinson <george.robinson@grafana.com>
(cherry picked from commit 53945afedf)

Co-authored-by: Alex Moreno <alexander.moreno@grafana.com>
2023-02-01 12:33:24 +00:00
Grot (@grafanabot)
68fb4da24a [v9.4.x] Alerting: Show 'start typing' message in evaluation group folder in case of empty options. (#62665)
Alerting: Show 'start typing' message in evaluation group folder in case of empty options. (#62611)

Show start typing message in evaluation group folder in case of empty options

(cherry picked from commit c0865c863d)

Co-authored-by: Sonia Aguilar <33540275+soniaAguilarPeiron@users.noreply.github.com>
2023-02-01 11:30:55 +00:00
Grot (@grafanabot)
89f9081658 [v9.4.x] CI: Replace grafana/grafana-oss with grafana-oss when publishing to dockerhub repo (#62653)
CI: Replace `grafana/grafana-oss` with `grafana-oss` when publishing to dockerhub repo (#62651)

Replace grafana/grafana-oss with grafana-oss

(cherry picked from commit 1a5b54cff3)

Co-authored-by: Dimitris Sotirakis <dimitrios.sotirakis@grafana.com>
2023-02-01 12:26:17 +02:00
Grot (@grafanabot)
84d2814f7c [v9.4.x] PanelChrome: Adds display mode to support transparent option (#62654)
PanelChrome: Adds display mode to support transparent option (#62647)

* PanelChrome: Add transparent displayMode

* Remove comment

* Fixes to storybook and new example

* no background on TitleItem

---------

Co-authored-by: polinaboneva <polina.boneva@grafana.com>
(cherry picked from commit 533c8e4b7a)

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2023-02-01 10:05:53 +00:00
Andreas Christou
193b671246 [v9.4.x] TemplateVariables: Fix custom variable function support (#62509) (#62573)
TemplateVariables: Fix custom variable function support (#62509)

Validate query values

(cherry picked from commit 3ac97dd396)

# Conflicts:
#	public/app/features/query/state/runRequest.ts
2023-02-01 10:25:03 +01:00
Grot (@grafanabot)
2bb672a7de [v9.4.x] Geomap: Ensure options work while in table view (#62635)
Geomap: Ensure options work while in table view (#62632)

(cherry picked from commit cf6952a963)

Co-authored-by: Drew Slobodnjak <60050885+drew08t@users.noreply.github.com>
2023-01-31 15:31:54 -08:00
Grot (@grafanabot)
c156621981 [v9.4.x] Transforms: Fix schema definition (#62623)
Transforms: Fix schema definition (#62619)

(cherry picked from commit 4186871390)

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2023-01-31 15:31:28 -08:00
Grot (@grafanabot)
9a8983e8e9 [v9.4.x] Alerting: Fix handling of special floating-point cases when writing observed values to annotations (#62637)
Alerting: Fix handling of special floating-point cases when writing observed values to annotations (#61074)

* Fix json serialization of state values

* Simplify two of the tests

* Fix linter complaint

* Don't return error if we fail to look up dashboard, just log it and move on

* Address linter complaint

(cherry picked from commit 03f3fbec0d)

Co-authored-by: Alexander Weaver <weaver.alex.d@gmail.com>
2023-01-31 21:51:52 +00:00
Grot (@grafanabot)
4bdfc2d926 [v9.4.x] Expressions: Fixes the issue showing expressions editor (#62622)
Expressions: Fixes the issue showing expressions editor (#62510)

* Use suggested value for uid

* update the snapshot

* use __expr__

* replace all -100 with __expr__

* update snapshot

* more changes

* revert redundant change

* Use expr.DatasourceUID where it's possible

* generate files

(cherry picked from commit 91221bc436)

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
2023-01-31 18:10:13 +00:00
Grot (@grafanabot)
bd9707e8f3 [v9.4.x] Use requires_buildifier build tag to avoid needing buildifier locally (#62621)
Use requires_buildifier build tag to avoid needing buildifier locally (#62597)

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
(cherry picked from commit fdb1a47ca2)

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
2023-01-31 18:03:03 +00:00
Grot (@grafanabot)
3023a43d4f [v9.4.x] TestData: Remove references to TestData "DB" (#62613)
TestData: Remove references to TestData "DB" (#62603)

* remove refs testdatadb

* fix trailing semi-colon

* remove pluginName completely

(cherry picked from commit e7bfc4e749)

Co-authored-by: Will Browne <wbrowne@users.noreply.github.com>
2023-01-31 18:02:42 +00:00
Grot (@grafanabot)
41b0393140 [v9.4.x] Transformations: Selectively apply transformation to queries (#62615)
Transformations: Selectively apply transformation to queries (#61735)

(cherry picked from commit bba80b6c7a)

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2023-01-31 09:48:18 -08:00
Grot (@grafanabot)
90a4c84bc2 [v9.4.x] MySQL: Quote identifiers that include special characters (#62618)
MySQL: Quote identifiers that include special characters (#61135)

* SQL: toRawSQL required and escape table

* Fix autocomplete for MySQL

* Change the way we escape for builder

* Rework escape ident to be smart instead

* Fix A11y for alias

* Add first e2e test

* Add test for code editor

* Add doc

* Review comments

* Move functions to sqlUtil

(cherry picked from commit 62c30dea4d)

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
2023-01-31 17:26:44 +00:00
Grot (@grafanabot)
6749e8667d [v9.4.x] TopNav: Fix right padding on signin link (#62606)
TopNav: Fix right padding on signin link (#62537)

* TopNav: Fix right padding on signin link

* revert yarn lock

* Update package.json

* Update

(cherry picked from commit c0f0c3d485)

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2023-01-31 16:31:45 +00:00
Grot (@grafanabot)
9727346e63 [v9.4.x] CI: Add artifacts publish build command (#62503)
CI: Add `artifacts publish` build command (#62445)

* CI: Add `artifacts publish` build command

* Lint release.star

(cherry picked from commit f23be415c5)

Co-authored-by: Horst Gutmann <horst.gutmann@grafana.com>
2023-01-31 16:29:34 +01:00
Grot (@grafanabot)
3683b7a5ff [v9.4.x] Alerting: Validate that tags are 100 characters or less (#62593)
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-01-31 14:41:06 +00:00
Grot (@grafanabot)
f9ca726290 [v9.4.x] Navigation: add event tracking for dashboard save as events (#62588)
Navigation: add event tracking for dashboard save as events (#62568)

* add event tracking for dashboard save as events

* emit a grafana_dashboard_copied event instead

(cherry picked from commit 029253d5f6)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-01-31 14:01:08 +00:00
Grot (@grafanabot)
15ec06b593 [v9.4.x] Azure Monitor: Return query error for metrics (#62577)
Azure Monitor: Return query error for metrics (#62570)

(cherry picked from commit 13f8ea2656)

Co-authored-by: Andres Martinez Gotor <andres.martinez@grafana.com>
2023-01-31 14:41:21 +01:00
Grot (@grafanabot)
953d9db30d [v9.4.x] Azure Monitor: Fix selection when using a search term (#62572)
Azure Monitor: Fix selection when using a search term (#62562)

(cherry picked from commit a0c3dcb8c6)

Co-authored-by: Andres Martinez Gotor <andres.martinez@grafana.com>
2023-01-31 13:29:59 +00:00
Grot (@grafanabot)
a7b9dcdce8 [v9.4.x] Navigation: add event tracking for navigation elements (#62583)
Navigation: add event tracking for navigation elements (#62563)

add user tracking for navigation elements

(cherry picked from commit 77a186879d)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-01-31 13:13:34 +00:00
Grot (@grafanabot)
76f3ed3c3f [v9.4.x] AzureMonitor: Fix dimension migration (#62579)
AzureMonitor: Fix dimension migration (#62485)

Remove unneeded properties post migration

(cherry picked from commit f77853f91e)

Co-authored-by: Andreas Christou <andreas.christou@grafana.com>
2023-01-31 13:11:18 +00:00
Grot (@grafanabot)
2ad87ce213 [v9.4.x] Plugins: Fix circular reference in customOptions leading to MarshalJSON errors (#62565)
Plugins: Fix circular reference in customOptions leading to MarshalJSON errors (#62328)

* Plugins: test ds.JsonData.MarshalJSON()

* CustomOptions: copy to avoid cyclic marshal

(cherry picked from commit c41f97029e)

Co-authored-by: Yasir Ekinci <ekinci.yasir@gmail.com>
2023-01-31 13:29:23 +01:00
Grot (@grafanabot)
cc5b3c11c4 [v9.4.x] Login: Fix panic when UpsertUser is called without ReqContext (#62555)
Login: Fix panic when UpsertUser is called without ReqContext (#62539)

(cherry picked from commit b1151dd118)

Co-authored-by: Emil Tullstedt <emil.tullstedt@grafana.com>
2023-01-31 12:25:11 +01:00
Grot (@grafanabot)
20731672ed [v9.4.x] Chore: Update latest.json to 9.4.0-beta1 (#62560)
Chore: Update latest.json to 9.4.0-beta1 (#62556)

Chore: update latest.json to 9.4.0-beta1
(cherry picked from commit ef7716d6b3)

Co-authored-by: Dimitris Sotirakis <dimitrios.sotirakis@grafana.com>
2023-01-31 13:00:57 +02:00
Grot (@grafanabot)
f9ec04bbb7 [v9.4.x] PanelChrome: Styling issues (#62550)
PanelChrome: Styling issues  (#62466)

* all panel icons are 16x16 in size; allow ToolbarButton to have its icon size set from outside;

* use TitleItem for streaming too, so that the style of focus-visible is the same

* allow menu icon to be visible when panel is focused

* remove some styling of title icons in panel header

* panel alert notices are too big

* PanelHeaderNotice: Fix styling issue with background and hover when
feature toggle is not enable

---------

Co-authored-by: Alexandra Vargas <alexa1866@gmail.com>
(cherry picked from commit d48a8fd227)

Co-authored-by: Polina Boneva <13227501+polibb@users.noreply.github.com>
2023-01-31 12:39:56 +02:00
Grot (@grafanabot)
0e6d038934 Release: Bump version to 9.4.0 (#62554)
"Release: Updated versions in package to 9.4.0"
2023-01-31 12:07:54 +02:00
Grot (@grafanabot)
b8c6ff611d [v9.4.x] Plugins: Update migration guide for 9.4/forwarded headers (#62549)
Plugins: Update migration guide for 9.4/forwarded headers (#62505)

Update plugin migration guide in regards to v9.4 and forwarding
of headers in grafana-plugin-sdk-go.

(cherry picked from commit 6c02c7079f)

Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
2023-01-31 10:55:56 +01:00
Grot (@grafanabot)
ecfd92ed30 [v9.4.x] Navigation: Sign in button now works correctly when served under a sub path (#62548)
Navigation: Sign in button now works correctly when served under a sub path (#62504)

make sure getUrlForPartial always includes the basePath + unit tests

(cherry picked from commit fd2641a542)

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-01-31 09:36:37 +00:00
Grot (@grafanabot)
8eb9971797 [v9.4.x] Azure Monitor: Docs update for multiple resources (#62543)
Azure Monitor: Docs update for multiple resources (#62454)

(cherry picked from commit d3897b612f)

Co-authored-by: Andres Martinez Gotor <andres.martinez@grafana.com>
2023-01-31 09:56:45 +01:00
Grot (@grafanabot)
c567e690ad [v9.4.x] Alerting: Clarify PagerDuty integrationKey format (#62513)
Alerting: Clarify PagerDuty integrationKey format (#62463)

**What is this feature?**

Simply a documentation update.

**Why do we need this feature?**

Clarify the doc, so people don't waste time integrating the wrong key,
e.g. #8979, #9036, https://community.librenms.org/t/19013

**Who is this feature for?**

Developers doing a PagerDuty integration.

(cherry picked from commit a7c4872bcd)

Co-authored-by: Andre Miras <AndreMiras@users.noreply.github.com>
2023-01-31 08:56:14 +00:00
Grot (@grafanabot)
acf1b1285b [v9.4.x] Canvas: Update connection info on element rename (#62536) 2023-01-31 04:44:52 +00:00
Grot (@grafanabot)
3d65500a4f [v9.4.x] Alerting: Allow separate read and write path URLs for Loki state history (#62528)
Alerting: Allow separate read and write path URLs for Loki state history (#62268)

Extract config parsing and add tests

(cherry picked from commit e7ace4ed62)

Co-authored-by: Alexander Weaver <weaver.alex.d@gmail.com>
2023-01-30 17:01:53 -06:00
Grot (@grafanabot)
589284778a [v9.4.x] Canvas: Connections positioning ux improvements (#62525)
Canvas: Connections positioning ux improvements (#62516)

(cherry picked from commit a92c081a33)

Co-authored-by: Adela Almasan <88068998+adela-almasan@users.noreply.github.com>
2023-01-30 13:59:51 -08:00
Grot (@grafanabot)
b9e989cbf2 [v9.4.x] Geomap: Maintain consistent control styling (#62522)
Geomap: Maintain consistent control styling (#62518)

Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
(cherry picked from commit bf2cf76cad)

Co-authored-by: Drew Slobodnjak <60050885+drew08t@users.noreply.github.com>
2023-01-30 13:35:54 -08:00
Grot (@grafanabot)
f39c46a1b5 [v9.4.x] Alerting: Configurable externalLabels for Loki state history (#62517)
Alerting: Configurable externalLabels for Loki state history (#62404)

* Add config option for external labels

* Remove redundant nilcheck

(cherry picked from commit b4682fe3cb)

Co-authored-by: Alexander Weaver <weaver.alex.d@gmail.com>
2023-01-30 15:34:40 -06:00
Grot (@grafanabot)
48bd8ebe92 [v9.4.x] Consider y coord when determining bottom collision (#62506)
Consider y coord when determining bottom collision (#62403)

(cherry picked from commit b6f477ae03)

Co-authored-by: Kristina <kristina.durivage@grafana.com>
2023-01-30 17:01:53 +00:00
Grot (@grafanabot)
34524d6dfa [v9.4.x] Azure Monitor: Enable multiple resource queries (#62502)
Azure Monitor: Enable multiple resource queries (#62467)

(cherry picked from commit 6d230d95eb)

Co-authored-by: Andres Martinez Gotor <andres.martinez@grafana.com>
2023-01-30 17:55:06 +01:00
Grot (@grafanabot)
6e861b19fa [v9.4.x] Alerting: allow to pause existing rules (#62491)
Co-authored-by: gillesdemey <gilles.de.mey@gmail.com>
Co-authored-by: Virginia Cepeda <virginia.cepeda@grafana.com>
2023-01-30 17:21:27 +01:00
Grot (@grafanabot)
26f7b8ee65 [v9.4.x] Alerting: Add Rule UID and Clone button to the rule details page (#62487)
Co-authored-by: Konrad Lalik <konrad.lalik@grafana.com>
2023-01-30 11:16:47 -05:00
Grot (@grafanabot)
04dd4e7f7c [v9.4.x] Alerting: Allow pausing alerts from provisioning (#62492)
Alerting: Allow pausing alerts from provisioning (#62263)

* Allow pausing alerts from provisioning

* Update swagger

* Add IsPaused to provision export endpoints

* Add pause field in sample.yml

* Add exception for reset state in first loop iteration of scheduler if rule is paused

* Update provision definition and swagger docs

* Fix provisioning export tests

* Suggestion: Simplify if condition

* Add more context to a comment

(cherry picked from commit 7a465f42a6)

Co-authored-by: Alex Moreno <alexander.moreno@grafana.com>
2023-01-30 17:01:37 +01:00
Grot (@grafanabot)
992e5d72ff [v9.4.x] Docs: Update wording / text and copy (#62490)
Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2023-01-30 15:46:25 +00:00
Grot (@grafanabot)
1b0f5f0a81 Release: Bump version to 9.4.0-beta1 (#62465)
"Release: Updated versions in package to 9.4.0-beta1"
2023-01-30 14:47:22 +02:00
Oscar Kilhed
e3bfc67d7b FileDropzone: Display max file size (#62334) 2023-01-30 12:17:30 +01:00
Oscar Kilhed
0bfdc42ffe Grafana DS: Limit dropzone to spreadsheet filetypes (#62329)
* Grafana DS: Limit dropzone to spreadsheet filetypes
2023-01-30 12:17:01 +01:00
renovate[bot]
355dc66bd9 Update dependency react-highlight-words to v0.20.0 (#62351)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-01-30 11:03:39 +00:00
Eric Leijonmarck
a232e7ceca Auth: Add skip_org_role_sync for Okta (#62106)
* WIP

* Update pkg/services/login/authinfo.go

* fix: merge

* change order to internal last

* adds: docs

* add: configuration for defaults and sample

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Jo <joao.guerreiro@grafana.com>

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

---------

Co-authored-by: Jo <joao.guerreiro@grafana.com>
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-01-30 10:54:14 +00:00
Sven Grossmann
d7026900bd LokiContext: Add feature tracking (#62344)
* add feature tracking to LokiContextUi

* only depend on `row.uid`

Co-authored-by: Gábor Farkas <gabor.farkas@gmail.com>

---------

Co-authored-by: Gábor Farkas <gabor.farkas@gmail.com>
2023-01-30 11:30:39 +01:00
Kyle Cunningham
38d7168921 Time Series Panel: Fix legend text selection in Firefox (#60809)
Add user-select property to legend items.
2023-01-30 11:18:07 +01:00
Sofia Papagiannaki
a502a2d1f8 Nested folders: Enable folder migration (#61936) 2023-01-30 10:17:40 +00:00
Sven Grossmann
7eb01b1813 MultiSelect: Fix actionMeta not available in onChange callback (#62339)
add `ActionMeta` to `onChange` callback
2023-01-30 11:17:02 +01:00
Sonia Aguilar
d44f250aea Alerting: Add export button for exporting all alert rules in alert list view (#62416)
* Add export button for exporting all alert rules in alert list view

* Add RBAC for export button

* Use provisioningPermissions.read in getRulesAccess method instead of directly using AccessControlAction.AlertingProvisioningRead
2023-01-30 11:13:08 +01:00
Ida Štambuk
a9d44aa795 Datasources: Add support for getDetDefaultQuery in variable editor (#62026)
+Cloudwatch implementation
2023-01-30 10:58:43 +01:00
Sven Grossmann
ae8c61c0b2 Logs: Fix stats not being updated when log results change (#62317)
update stats in logdetails
2023-01-30 10:54:20 +01:00
Josh Hunt
d51e7ec7ef Preferences: Add theme preference to match system theme (#61986)
* user essentials mob! 🔱

lastFile:pkg/api/preferences.go

* user essentials mob! 🔱

* user essentials mob! 🔱

lastFile:packages/grafana-data/src/types/config.ts

* user essentials mob! 🔱

lastFile:public/app/core/services/echo/utils.test.ts

* user essentials mob! 🔱

* user essentials mob! 🔱

lastFile:public/views/index-template.html

* user essentials mob! 🔱

* Restore currentUser.lightTheme for backwards compat

* fix types

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* cleanup

* cleanup

---------

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
Co-authored-by: Joao Silva <joao.silva@grafana.com>
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-01-30 10:51:51 +01:00
Andres Martinez Gotor
be7b90bbd1 Azure Monitor: Add info about multiple resource selection (#62327) 2023-01-30 10:49:57 +01:00
Andres Martinez Gotor
bed1bb1a73 Azure Monitor: Allow to specify a region when listing resources (#62306)
* Azure Monitor: Allow to specify a region when listing resources

* Add region template variable to e2e tests
2023-01-30 10:49:20 +01:00
Torkel Ödegaard
dae9808602 AppPlugins: Remove unused rootNav parameter (#62440) 2023-01-30 10:30:01 +01:00
Jack Baldry
8379a5338c CI: Lint starlark files with buildifier (#59157)
* Add verify-starlark build action that returns an error for starlark files with lint

Relies on `buildifier` tool.

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Add verify_starlark_step to PR pipeline

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Manually fetch buildifier in curl_image until a new build_image is created

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Format with buildifier

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Remove all unused variables retaining one unused function

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Use snake_case for variable

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Replace deprecated dictionary concatenation with .update() method

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Start adding docstrings for all modules and functions

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Prefer os.WriteFile as ioutil.WriteFile has been deprecated since go 1.16

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Attempt to document the behavior of the init_enterprise_step

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Document test_backend pipeline

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Document enterprise_downstream_step

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Document the pipeline utility function

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Document publish_images_step

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Document publish_images_steps

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Document enterprise2_pipelines function

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Add tags table for Starlark files.

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Document test_frontend

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Document windows function

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Add docstrings to verifystarlark functions

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Refactor error handling to be more clear and document complex behavior

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Split errors into execution errors and verification errors

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Document all other library functions

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Add local variables to TAGS

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Add blank line between all Args and Returns sections

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Fix new linting errors

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Lint new Starlark files

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Correct buildifier binary mv

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Document the need to set nofile ulimit to at least 2048

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Update build-container to include buildifier

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Ensure buildifier binary is executable

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Fix valid content test

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Simply return execution error

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Only check files rather than fixing them

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Use updated build-container with executable buildifier

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Test that context cancellation stops execution

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Simplify error handling

Return execution errors that short circuit WalkDir rather than
separately tracking that error.

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Remove fetching of buildifier binary now that it is in the build-container

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Use build image in verify-starlark step

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Use semver tag

The image is the same but uses a semver tag to make it clearer that
this is a forward upgrade from the old version.

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Use node 18 image with buildifier

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

---------

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2023-01-30 09:27:11 +00:00
Serge Zaitsev
907e2a840e Chore: Fix goimports grouping (#62429)
* fix goimports ordering

* fix goimports order
2023-01-30 09:57:50 +01:00
Serge Zaitsev
d6d4097567 Chore: Fix goimports grouping in alerting (#62424)
* fix goimports

* fix goimports order
2023-01-30 09:55:35 +01:00
Serge Zaitsev
0bf4093005 Chore: Fix goimports grouping (#62428)
* fix goimports order

* fix goimports order
2023-01-30 08:50:27 +00:00
Serge Zaitsev
f8ec35e643 Chore: Fix goimports grouping (#62427)
* fix goimports order

* fix goimports order
2023-01-30 09:38:51 +01:00
Serge Zaitsev
7dbd2cd139 Chore: Fix goimports grouping (#62426)
fix goimports ordering
2023-01-30 09:34:18 +01:00
Serge Zaitsev
f531074d89 Chore: Fix goimports grouping in pkg/infra (#62421)
* fix goimports

* fix goimports order
2023-01-30 08:32:25 +00:00
Serge Zaitsev
aebcecf538 Chore: Fix goimports grouping in other backend platform packages (#62422)
* fix goimports

* fix goimports order

* fix goimports order

* fix goimports order

* fix goimports order

* fix goimports order
2023-01-30 08:26:42 +00:00
Sven Grossmann
da7065d3dc LokiContext: Fix wrong queries being run when reopened (#62353)
* fix wrong query being run when reopened

* fix typo

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

* and test for `onClose`

* rename functions

---------

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2023-01-30 09:26:27 +01:00
Jan Garaj
2ff715cb7a CloudWatch: Add missing AWS/DX metric (#62405) 2023-01-30 09:26:14 +01:00
Serge Zaitsev
e2d49ea17f Chore: Fix goimports grouping (#62423)
* fix goimports

* fix goimports order
2023-01-30 08:25:58 +00:00
Serge Zaitsev
bc2813ef06 Chore: Fix goimports grouping in pkg/services (#62420)
* fix goimports

* fix goimports order
2023-01-30 08:21:27 +00:00
Serge Zaitsev
324310abbc Chore: Fix goimports grouping in pkg/api (#62419)
* fix goimports

* fix goimports order
2023-01-30 08:18:26 +00:00
Levente Balogh
9b2abe7613 Datasources: Extend properties for the datasource-test tracking event (#62292)
chore: extend properties for the test datasource tracking event
2023-01-30 08:29:13 +01:00
Ryan McKinley
0d2a786816 Schema: Add schema for library panels (#62169) 2023-01-30 04:14:12 +00:00
Gilles De Mey
13159d03ba Alerting: Use optional chaining for accessing frames (#61814) 2023-01-28 18:39:23 +01:00
Sarah Zinger
82e8ad8a0f Cloudwatch: Set CloudwatchCrossAccountQuery feature to stable (#62348)
* Cloudwatch: Set CloudwatchCrossAccountQuery feature to stable

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-01-27 16:46:08 -05:00
Yuri Tseretyan
0c4671e31f Alerting: Update historian to ignore transitions from Normal Paused and Updated (#62267) 2023-01-27 16:26:22 -05:00
Josh Hunt
6c990b461e SupportBundles: Feature flag + access control navtree item (#62337)
* SupportBundles: Feature flag + access control navtree item

* remove translation
2023-01-27 20:04:04 +00:00
Drew Slobodnjak
07dc994765 Canvas: Anchor highlight persistance (#62364)
* Canvas: Anchor highlight persistance

* Update public/app/plugins/panel/canvas/ConnectionAnchors.tsx

Co-authored-by: Nathan Marrs  <nathanielmarrs@gmail.com>

* Fix CONNECTION_ANCHOR_ALT dependencies

* Simplify anchor type assertion logic

* Ensure that anchor highlight is reset when anchors are hidden

* Add helpful comment on return bool of function

---------

Co-authored-by: Nathan Marrs  <nathanielmarrs@gmail.com>
2023-01-27 11:35:57 -08:00
Isabel
290f23a50b docs: clarify note re export dashboard as PDF (#62398)
clarify note re export dashboard as PDF

Update note under Export dashboard as PDF to indicate that it's only available on Enterprise and Cloud, as well as which version of Enterprise it's available on.
2023-01-27 13:31:55 -06:00
gotjosh
3c616da83f Alerting: Refactor metrics/ngalert.go into seperate files (#62362)
* Alerting: Refactor metrics/ngalert.go into seperate files
2023-01-27 18:49:49 +00:00
Kristin Laemmert
9256a520a4 chore: move user_auth models to (mostly) login service (#62269)
* chore: move user_auth models to (mostly) login service
2023-01-27 13:36:54 -05:00
Jack Baldry
4563111180 Move Grafana tutorials from grafana/tutorials repository (#62309)
* Add Grafana tutorials originally from tutorials repository

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Replace tutorials/step shortcode with ordinary headings

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Fix typos reported by codespell

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Fix doc-validator linting and run prettier

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Specify version in tutorials lookup as non-rendered pages do not have a relative permalink used to infer the version

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Use latest version

Ensures CI passes and only breaks one website build as the backport to
v9.3.x will solve the missing "latest" pages on publishing.

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

---------

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2023-01-27 17:53:50 +00:00
Gareth Dawson
b2c8126e6e Loki: Show query size approximation (#62109)
* feat: make api request to /loki/api/v1/index/stats

* fix: add /index/stats to callResource valid urls

* feat: make call to getQueryStats when the query changes

* feat: render user tooltip displaying the estimated value for processed data

* fix: add new props to component tests

* test: add tests for query size estimation

* fix: disable error message on request failure

* refactor: add suggestions from code review

* refactor: only pass required query string
2023-01-27 17:32:53 +00:00
Galen Kistler
5ad7cca9d4 Prometheus: Fix "-Instant" string showing up in prometheus instant query UI (#62265)
Add string constant and make sure to remove from name before outputting to frontend
2023-01-27 10:40:12 -06:00
Matthew Jacobson
c006df375a Alerting: Create endpoints for exporting in provisioning file format (#58623)
This adds provisioning endpoints for downloading alert rules and alert rule groups in a 
format that is compatible with file provisioning. Each endpoint supports both json and 
yaml response types via Accept header as well as a query parameter 
download=true/false that will set Content-Disposition to recommend initiating a download 
or inline display.

This also makes some package changes to keep structs with potential to drift closer 
together. Eventually, other alerting file structs should also move into this new file 
package, but the rest require some refactoring that is out of scope for this PR.
2023-01-27 11:39:16 -05:00
Ivana Huckova
d5294eb8fa Explore: Implement feature toggle for logs sample (#62291)
* Explore: Implement feature toggle for logs sample

* Run pkg/services/featuremgmt/toggles_gen_test.go

* Remove boolean

* Update copy
2023-01-27 17:30:25 +01:00
Ashley Harrison
1ef7cfda3f Navigation: more command palette tweaks (#62286)
* update placeholder text, only create search keybindings if topNavCommandPalette is disabled

* make search input wider
2023-01-27 16:21:48 +00:00
Josh Hunt
305209f4be CommandPalette: Render dashboard + nav actions as links (#62315)
* CommandPalette: Render links as links!

* Update public/app/features/commandPalette/KBarResults.tsx

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>

* Apply suggestions from code review

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>

* fix ellipsis showing

---------

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-01-27 16:10:05 +00:00
renovate[bot]
7f5ed9f59d Update dependency rc-tooltip to v5.3.1 (#62341)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-01-27 15:48:06 +00:00
Dominik Prokop
d4015602ca Dashboard schema: Update default value for timezone (#62340) 2023-01-27 15:43:13 +00:00
Ieva
1865205d68 Benchmarks for searchv2 (#60730)
* bench-test

* cleanup

* more simplification

* fix tests

* correct wrong argument ordering & use constant

* fix issues with tests setup

* add benchmark results

* reuse Gabriel's concurrent setup code

* correct error logs for ac benchmarks
2023-01-27 15:42:08 +00:00
Ivana Huckova
d0e95f8c95 Loki: Add X-Query-Tags header for logs sample and data sample (#62333) 2023-01-27 16:41:40 +01:00
Levente Balogh
9453bec819 FileDropzone: Revert introducing a new prop (#62324) 2023-01-27 16:40:54 +01:00
Andres Martinez Gotor
317ef1de86 Azure Monitor: Add variable function to list regions (#62297) 2023-01-27 16:29:05 +01:00
Gábor Farkas
88119ad6c3 Elasticsearch: Support nested aggregation (#62301)
* Add nested query support

* Add nested support for alerts

* update nested aggregation

* cleanup types

* Add nested integration test

* Move aggdef to nested

* fixed merge conflict

* fixed lint warning

* mark nested-mode experimental

---------

Co-authored-by: Ethan Gallant <ethan@ziax.com>
Co-authored-by: Ethan J. Gallant <ethan.gallant@acquia.com>
2023-01-27 16:18:36 +01:00
Ezequiel Victorero
d5433a488a Chore: Update code owners of public dashboards (#62332) 2023-01-27 12:17:18 -03:00
Dominik Prokop
83199c4bf5 Dashboard schema: Review and mature timezone property (#62090)
* Review and mature timezone property of Dashboard kind

* Update timezone type
2023-01-27 07:13:33 -08:00
Eric Leijonmarck
5531e22f46 Auth: Add disable of team sync for JWT Authentication (#62191)
* fix: disable team sync for JWT Authentication

* add: comment to test

* change test to conform to new expected behavior

* fix: spelling

* formatting
2023-01-27 16:05:25 +01:00
Sven Grossmann
df2db3bb23 LogContext: Fix setting wrong height for ElasticSearch (#62330)
fix wrong height for elastic
2023-01-27 15:41:16 +01:00
Andreas Christou
5bdfbd93a5 Bump code coverage version (#62322)
* Bump code coverage version

* Update codeowners to include aws-plugins

* Bump version further
2023-01-27 14:33:48 +00:00
Ezequiel Victorero
a128944471 PublicDashboards: moved tokens service and new repository method (#61806) 2023-01-27 11:20:22 -03:00
Sriram
89ef62f163 Chore: Removed unused grafana-plugin-ci images (#62219)
removed unused grafana-plugin-ci images
2023-01-27 14:19:42 +00:00
Andre Pereira
afd39c18ba Explore: Refactor trace view and move to core (#61938)
* Move TraceView to core grafana

* Remove unused code

* yarn install

* Remove jaeger-ui-components from CODEOWNERS and other tools

* Type fixes

* yarn install

* Remove mock that we no longer need

* Fix merge conflicts

* Re-add Apache license for trace view components

* Use an exclamation-circle instead of triangle to denote errors

* Remove eslint disables and update betterer results instead
2023-01-27 14:13:17 +00:00
Sven Grossmann
7c02d9bb8a Logs: Add experimental support to display a datasource custom UI in LogContext (#62189)
* add loki contextfilter component

* add `getLogRowContextUi` support to DataSourceAPI

* add `runContextQuery` to LogRowContextProvider

* pass `getRowContextUi` to `LogRowContext`

* adapt LogRowContext to show datasource ui

* implement LogRowContextUi in Loki

* add `logsContextDatasourceUi` feature flag

* change state to `Alpha`

* disable the feature if `logsContextDatasourceUi` is not set

* don't fetch labels in the constructor

* adjust to right height

* remove unnecessary eslint disable

* add test for LokiContextUi

* move code down in datasource.ts

* rename `refresh` to `runContextQuery`

* update datasource tests

* don't update if `updateFilter` fn changes

* organized imports in datasource.test.ts

* don't trigger on intialization changes

* change tag to `experimental`

* move `getLogRowContextUi` to props
2023-01-27 15:12:01 +01:00
Giuseppe Guerra
af1e2d68da Plugins: Allow loading panel plugins from a CDN (#59096)
* POC: Plugins CDN reverse proxy

* CDN proxy POC: changed env var names

* Add authorization: false for /public path in frontend plugin loader

* Moved CDN settings to Cfg, add some comments

* Fix error 500 in asset fetch if plugin is not using CDN

* Fix EnterpriseLicensePath declared twice

* Fix linter complaining about whitespaces

* Plugins CDN: Skip signature verification for CDN plugins

* Plugins CDN: Skip manifest and signature check for cdn plugins

* Plugins: use IsValid() and IsInternal() rather than equality checks

* Plugins CDN: remove comment

* Plugins CDN: Fix seeker can't seek when serving plugins from local fs

* Plugins CDN: add back error codes in getLocalPluginAssets

* Plugins CDN: call asset.Close() rather than asset.readSeekCloser.Close()

* Plugins CDN: Fix panic in JsonApiErr when errorMessageCoder wraps a nil error

* Plugins CDN: Add error handling to proxyCDNPluginAsset

* Plugins CDN: replace errorMessageCoder with errutil

* Plugins CDN POC: expose cdn plugin paths to frontend for system.js

* Plugins CDN: Fix cdn plugins showing as unsigned in frontend

* WIP: Add support for formatted URL

* Fix missing cdnPluginsBaseURLs in GrafanaConfig

* Plugins CDN: Remove reverse proxy mode and reverse proxy references

* Plugins CDN: Simplify asset serving logic

* Plugins CDN: sanitize redirect path

* Plugins CDN: Removed unused pluginAsset type

* Plugins CDN: Removed system.js changes

* Plugins CDN: Return different system.js baseURL and module for cdn plugins

* Plugins CDN: Ensure CDN is disabled for non-external plugins

* lint

* Plugins CDN: serve images and screenshots from CDN, refactoring

* Lint

* Plugins CDN: Fix URLs for system.js (baseUrl and module)

* Plugins CDN: Add more tests for RelativeURLForSystemJS

* Plugins CDN: Iterate only on apps when preloading

* Plugins CDN: Refactoring

* Plugins CDN: Add comments to url_constructor.go

* Plugins CDN: Update defaultHGPluginsCDNBaseURL

* Plugins CDN: undo extract meta from system js config

* refactor(plugins): migrate systemjs css plugin to typescript

* feat(plugins): introduce systemjs cdn loader plugin

* feat(plugins): add systemjs load type

* Plugins CDN: Removed RelativeURLForSystemJS

* Plugins CDN: Log backend redirect hits along with plugin info

* Plugins CDN: Add pluginsCDNBasePath to getFrontendSettingsMap

* feat(plugins): introduce cdn loading for angular plugins

* refactor(plugins): move systemjs cache buster into systemjsplugins directory

* Plugins CDN: Rename pluginsCDNBasePath to pluginsCDNBaseURL

* refactor(plugins): introduce pluginsCDNBaseURL to the frontend

* Plugins CDN: Renamed "cdn base path" to "cdn url template" in backend

* Plugins CDN: lint

* merge with main

* Instrumentation: Add prometheus counter for backend hits, log from Info to Warn

* Config: Changed key from plugins_cdn.url to plugins.plugins_cdn_base_url

* CDN: Add backend tests

* Lint: goimports

* Default CDN URL to empty string,

* Do not use CDN in setImages and module if the url template is empty

* CDN: Backend: Add test for frontend settings

* CDN: Do not log missing module.js warn if plugin is being loaded from CDN

* CDN: Add backend test for CDN plugin loader

* Removed 'cdn' signature level, switch to 'valid'

* Fix pfs.TestParseTreeTestdata for cdn plugin testdata dir

* Fix TestLoader_Load

* Fix gocyclo complexity of loadPlugins

* Plugins CDN: Moved prometheus metric to api package, removed asset_path label

* Fix missing  in config

* Changes after review

* Add pluginscdn.Service

* Fix tests

* Refactoring

* Moved all remaining CDN checks inside pluginscdn.Service

* CDN url constructor: Renamed stringURLFor to stringPath

* CDN: Moved asset URL functionality to assetpath service

* CDN: Renamed HasCDN() to IsEnabled()

* CDN: Replace assert with require

* CDN: Changes after review

* Assetpath: Handle url.Parse error

* Fix plugin_resource_test

* CDN: Change fallback redirect from 302 to 307

* goimports

* Fix tests

* Switch to contextmodel.ReqContext in plugins.go

Co-authored-by: Will Browne <will.browne@grafana.com>
Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
2023-01-27 15:08:17 +01:00
Karl Persson
c931b8031e SearchV2: Set correct batch limit when loading dashboards (#62314)
SearchV2: Set correct limit
2023-01-27 14:40:04 +01:00
Joey Tawadrous
591501ef3f Traces: Upgraded feature tracking (#62181)
Upgraded feature tracking
2023-01-27 13:33:27 +00:00
Eric Leijonmarck
27f0c9c70f Auth: Doc change url for getting JWT (#62319)
docs: change url for getting JWT
2023-01-27 14:26:35 +01:00
renovate[bot]
847a5ab195 Update dependency rc-slider to v10.1.0 (#62302)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-01-27 13:23:31 +00:00
Armand Grillet
f0a88e0609 Add SQLite performance limitation with alerting (#62296) 2023-01-27 14:22:47 +01:00
Gilles De Mey
54ff88463c Alerting: remove link to Grafana University (#62318) 2023-01-27 08:21:47 -05:00
Yaelle Chaudy
3281eb9223 [Navigation] Add user events for quick actions/dashboard actions (#62220)
Add fe events for quick actions/dashboard actions
2023-01-27 14:11:17 +01:00
Jack Westbrook
2f46317a2a Packages: Don't error if npm-artifacts directory already exists (#62303)
fix(packages): dont error if npm-artifacts directory already exists
2023-01-27 14:06:43 +01:00
Leon Sorokin
52955d88a7 TimeSeries: Fix log y scale when min/max settings don't land on divisors (#60768) 2023-01-27 05:52:01 -07:00
Oscar Kilhed
6bfd21ef0a FileDropzone: make a nicer looking error message when file size is exceeded (#62290)
* FileDropzone: make a nicer looking error message when file size is exceeded
2023-01-27 12:42:47 +00:00
George Robinson
b6db1ed524 Revert "Alerting: Add is_paused attr to the POST alert rule group endpoint" (#62310)
Revert "Alerting: Add is_paused attr to the POST alert rule group endpoint (#62253)"

This reverts commit 3ccafe3a5a.
2023-01-27 13:41:36 +01:00
Victor Marin
846acd28ff StateTimeline: Show correct legend label when value mappings set (#62282)
* StateTimeline: Show correct legend label when value mappings set

* Add test dashboard for thresholds and value mappings

* run stripnulls.sh
2023-01-27 14:30:42 +02:00
Torkel Ödegaard
bfcf936c38 QueryEditorRows: Remove double callback from onDataSourceChange (#62172)
* QueryEditorRows: Remove double callbacked from onDataSourceChange

* A few more updates

* Updated
2023-01-27 13:30:12 +01:00
renovate[bot]
1a28650aab Update dependency @testing-library/dom to v8.20.0 (#61677)
* Update dependency @testing-library/dom to v8.20.0

* do some lockfile surgery

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-01-27 12:28:09 +00:00
Ieva
eb9ef34272 RBAC: Permission check performance improvements for the new search (#60729)
* Add checker and update the resource filter function for new search

* Add tests for checker

* small fixes

* handle location for panels correctly

* clean up checker code and extend the tests for it

* more fixes, but tests don't quite work yet

* a small change to return error

* cleanup

* more simplification

* fix tests

* correct wrong argument ordering & use constant

* Apply suggestions from code review

Co-authored-by: Artur Wierzbicki <artur.wierzbicki@grafana.com>

* import

* check general folder from permission checker function

* handle root folder aka general folder properly

* update tests

* clean up

* lint

* add fix from main

Co-authored-by: Karl Persson <kalle.persson@grafana.com>
Co-authored-by: Artur Wierzbicki <artur.wierzbicki@grafana.com>
2023-01-27 12:12:30 +00:00
Oscar Kilhed
dab3fac01b Grafana DS: Fix dropzone showing upload file even if there is a file (#62200)
* Grafana DS: Fix dropzone showing upload file even if there is a file
2023-01-27 11:51:10 +00:00
Josh Hunt
960307e938 Search: Remember sorting preference between visits (#62248)
Search: Remember sort option between uses
2023-01-27 11:00:28 +00:00
Torkel Ödegaard
4deb10888e Revert "Transforms: Add join by fields" (#62278) 2023-01-27 11:58:18 +01:00
renovate[bot]
3d4cf06246 Update dependency rc-drawer to v6.1.2 (#62294)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-01-27 10:54:45 +00:00
Victor Marin
1464dd4095 Re-add RowHeight option to StatusHistory (#62293) 2023-01-27 12:52:32 +02:00
Josh Hunt
70f109526a Search: Store only search value in state, not the whole selectable value (#62228)
* Search: Store only search value in state, not the whole selectable value

* type sort to undefined-able
2023-01-27 10:50:48 +00:00
Andres Martinez Gotor
6292a41b24 Azure Monitor: Allow multi-value variables (#62238) 2023-01-27 11:40:49 +01:00
Karl Persson
3447ad2602 AuthN: support priority for post auth and post login hooks (#62208)
* AuthN: store post auth hooks in a priority list and update registration
function to take a priority

* AuthN: store post login hooks in a priority list and update registration function to take a priority

* AuthN: Change priority for sync user
2023-01-27 11:40:12 +01:00
renovate[bot]
14185ba819 Update d3 to v3 (#58315)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-01-27 11:19:35 +01:00
Joey Tawadrous
02098c1568 Tempo: Update docs and default Tempo metrics query (#62185)
Update docs and default tempo metrics query
2023-01-27 10:03:52 +00:00
Alex Moreno
3ccafe3a5a Alerting: Add is_paused attr to the POST alert rule group endpoint (#62253)
Add is_paused attr to the POST alert rule group endpoint
2023-01-27 10:50:06 +01:00
Levente Balogh
83ff974b86 Datasources: Add the props for the "add datasource" event (#62227)
chore: pass editLink to the add datasource user event
2023-01-27 10:47:18 +01:00
Jack Baldry
a54d18c1f5 Revert "Add Grafana tutorials originally from tutorials repository" (#62283)
Revert "Add Grafana tutorials originally from tutorials repository (#62124)"

This reverts commit f98ad926ac.
2023-01-27 09:25:57 +00:00
Ben Sully
5ff94e528b API: don't re-add /api suffix to grafana.com API URL (#62280)
The old GrafanaComURL setting didn't have the /api suffix so needed it
adding on by the proxy director, but the new GrafanaComAPIURL setting is
assumed to already point directly to the API and doesn't need an
additional suffix.

This is the only place in the codebase that GrafanaComAPIURL is used.
2023-01-27 10:20:55 +01:00
Jack Baldry
f98ad926ac Add Grafana tutorials originally from tutorials repository (#62124)
* Add Grafana tutorials originally from tutorials repository

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Replace tutorials/step shortcode with ordinary headings

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Fix typos reported by codespell

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Fix doc-validator linting and run prettier

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2023-01-27 09:14:24 +00:00
Yuri Tseretyan
05bf241952 Alerting: Update state manager to return StateTransitions when Delete or Reset (#62264)
* update Delete and Reset methods to return state transitions

this will be used by notifier code to decide whether alert needs to be sent or not.

* update scheduler to provide reason to delete states and use transitions

* update FromAlertsStateToStoppedAlert to accept StateTransition and filter by old state

* fixup

* fix tests
2023-01-27 09:46:21 +01:00
Jack Baldry
6706f08ecd Replace grafana/docs-squad with more specific group grafana/docs-grafana (#62174) 2023-01-27 08:27:36 +00:00
Leon Sorokin
4c45dea71d Chore: uPlot 1.6.24 (#62279) 2023-01-27 02:12:19 -06:00
idafurjes
6c5a573772 Chore: Move ReqContext to contexthandler service (#62102)
* Chore: Move ReqContext to contexthandler service

* Rename package to contextmodel

* Generate ngalert files

* Remove unused imports
2023-01-27 08:50:36 +01:00
Matthew Jacobson
8379a29b53 Alerting: Improve comments on alert table migration immutability (#62161)
* Alerting: Improve comments around alert migration immutability

* Reunite alerting config history migrations
2023-01-26 16:13:08 -05:00
Guilherme Caulada
9a25a03e49 Tests: Add boilerplate code to support e2e tests on enterprise (#61959)
* Add e2e boilerplate for enterprise tests

* Remove enterprise symlink file

* Add tsconfig to e2e extensions folder and gitignore

* Update run-suite to use extensions folder

* Remove unnecessary tsconfig file

* Update e2e enterprise paths on gitignore

* Copy symlinked e2e enterprise files on run-suite

* Add cleanup command to run-suite

* Improve cleanup and setup for enterprise e2e tests

* Update e2e path for enterprise tests on gitignore

* Support to run different e2e tests for each license
2023-01-26 18:04:13 -03:00
Brett Buddin
a5a85e0398 InfluxDB: Send retention policy with InfluxQL queries if its been specified. (#62149)
* InfluxDB: Send retention policy with InfluQL queries if it's been specified.

In InfluxDB v2, due to technical limitations of the InfluxDB v1
compatibility layer, retention policies in a query (e.g. "<retention
policy>.<measurement_name>") aren't honored and must be specified in the
URL query parameter `rp` to be applied. Grafana doesn't send this query
parameter which results in all queries resolving to the default
retention policy when querying InfluxDB v2 servers using InfluxQL.

This addresses the issue by sending the `rp` query parameter for queries
that have specified a retention policy in the `target` given to
`runExploreQuery`.

The outcomes are:

1. InfluxQL queries executed against InfluxDB v2 databases will have the
   necessary retention policy information for queries like `SHOW FIELD
   KEYS FROM measurement` to function correctly.
2. InfluxQL queries executed against InfluxDB v1 databases will be
   unaffected, because this `rp` query parameter is unsupported there.

You can read more about the rentention policy mapping behavior of
InfluxDB v2 in our documentation:

- https://docs.influxdata.com/influxdb/v2.6/reference/api/influxdb-1x/dbrp/#when-querying-data
- https://docs.influxdata.com/influxdb/v2.6/reference/api/influxdb-1x/query/#query-a-non-default-retention-policy

* Use the ? operator

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2023-01-26 19:14:02 +01:00
brendamuir
a273c232a1 Alerting: fix default template link (#62251) 2023-01-26 17:45:09 +00:00
Alex Moreno
531b439cf1 Alerting: Add alert pausing feature (#60734)
* Add field in alert_rule model, add state to alert_instance model, and state to eval

* Remove paused state from eval package

* Skip paused alert rules in scheduler

* Add migration to add is_paused field to alert_rule table

* Convert to postable alerts only if not normal, pernding, or paused

* Handle paused eval results in state manager

* Add Paused state to eval package

* Add paused alerts logic in scheduler

* Skip alert on scheduler

* Remove paused status from eval package

* Apply suggestions from code review

Co-authored-by: George Robinson <george.robinson@grafana.com>

* Remove state

* Rethink schedule and manager for paused alerts

* Change return to continue

* Remove unused var

* Rethink alert pausing

* Paused alerts storing annotations

* Only add one state transition

* Revert boolean method renaming refactor

* Revert take image refactor

* Make registry errors public

* Revert method extraction for getting a folder title

* Revert variable renaming refactor

* Undo unnecessary changes

* Revert changes in test

* Remove IsPause check in PatchPartiLAlertRule function

* Use SetNormal to set state

* Fix text by returning to old behaviour on alert rule deletion

* Add test in schedule_unit_test.go to test ticks with paused alerts

* Add coment to clarify usage of context.Background()

* Add comment to clarify resetStateByRuleUID method usage

* Move rule get to a more limited scope

* Update pkg/services/ngalert/schedule/schedule.go

Co-authored-by: George Robinson <george.robinson@grafana.com>

* rum gofmt on pkg/services/ngalert/schedule/schedule.go

* Remove defer cancel for context

* Update pkg/services/ngalert/models/instance_test.go

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>

* Update pkg/services/ngalert/models/testing.go

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>

* Update pkg/services/ngalert/schedule/schedule_unit_test.go

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>

* Update pkg/services/ngalert/schedule/schedule_unit_test.go

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>

* Update pkg/services/ngalert/models/instance_test.go

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>

* skip scheduler rule state clean up on paused alert rule

* Update pkg/services/ngalert/schedule/schedule.go

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>

* Fix mock in test

* Add (hopefully) final suggestions

* Use error channel from recordAnnotationsSync to cancel context

* Run make gen-cue

* Place pause alert check in channel update after version check

* Reduce branching un update channel select

* Add if for error and move code inside if in state manager ResetStateByRuleUID

* Add reason to logs

* Update pkg/services/ngalert/schedule/schedule.go

Co-authored-by: George Robinson <george.robinson@grafana.com>

* Do not delete alert rule routine, just exit on eval if is paused

* Reduce branching and create-close a channel to avoid deadlocks

* Separate state deletion and state reset (includes history saving)

* Add current pause state in rule route in scheduler

* Split clearState and bring errCh closer to RecordStatesAsync call

* Change rule to ruleMeta in RecordStatesAsync

* copy state to be able to modify it

* Add timeout to context creation

* Shorten the timeout

* Use resetState is rule is paused and deleteState if rule is not paused

* Remove Empty state reason

* Save every rule change in historian

* Add tests for DeleteStateByRuleUID and ResetStateByRuleUID

* Remove useless line

* Remove outdated comment

Co-authored-by: George Robinson <george.robinson@grafana.com>
Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>
Co-authored-by: Armand Grillet <2117580+armandgrillet@users.noreply.github.com>
2023-01-26 18:29:10 +01:00
Andrej Ocenas
039b30b1ea NodeGraph: Schema for panel options (#62121) 2023-01-26 18:02:41 +01:00
renovate[bot]
caaf7be2f2 Update dependency immutable to v4.2.2 (#62202)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-01-26 16:57:10 +00:00
Ashley Harrison
a344c88a01 Chore: don't create the npm-artifacts dir since yarn packages:pack does this… (#62246)
* don't create the npm-artifacts dir since yarn packages:pack does this already

* fix an any to trigger a canary build
2023-01-26 16:41:08 +00:00
Jo
284ca4eab4 AuthN: JWT remove unnecessary if (#62233)
remove unnecessary if
2023-01-26 17:32:20 +01:00
Jack Westbrook
5050822b9a Fix: NPM Package publishing (#62243)
* move packed packages to npm-artifacts dir

* remove unnecessary any to trigger canary build

* update canary script to create dir only if it does not exist

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-01-26 16:18:05 +00:00
Matias Chomicki
641a7182e3 Loki Docker Devenv: Fix undefined variable in error message (#62242)
fix(loki-docker-devenv): fix undefined variable in error message
2023-01-26 16:15:11 +00:00
Gábor Farkas
16b816972b Elasticsearch: Deprecate raw document mode (#62236)
elasticsearch: deprecate raw-document-mode
2023-01-26 16:05:37 +00:00
Ivana Huckova
07bc2c32e9 Explore: Add feature tracking for split open in logs sample (#62241)
Explore: Add tracking for split open in logs sample
2023-01-26 15:53:19 +00:00
Sven Grossmann
01e6a0b4df Codeowners: Assign logs files to @grafana/observability-logs (#62239)
assign "logs" files to logs squad
2023-01-26 16:50:56 +01:00
Andrej Ocenas
a414b07991 Tempo: Trace to logs custom query with interpolation (#61702) 2023-01-26 16:37:16 +01:00
Dimitris Sotirakis
931dcda559 Chore: Update latest.json to 9.3.6 (#62235)
Chore: update latest.json to 9.3.6
2023-01-26 17:33:45 +02:00
Will Browne
42732539ed TestData: Introduce schema types (#62130)
* schematize data query

* add the stuff you dingus

* feat(testdatasource): add scenario to generated types

* use generated testdata query in frontend

* update code owners

* Add path exception for testdata datasource

* use specific numeric data types

* fix test

* fix e2e smoketest

* add test data query type

* use test data query type

* fix betterer

* Fix typo

* move to experimental

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>

Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
Co-authored-by: sam boyer <sdboyer@grafana.com>
Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
2023-01-26 15:31:34 +00:00
Grot (@grafanabot)
0cd14091c4 Changelog: Updated changelog for 9.3.6 (#62231) 2023-01-26 17:25:21 +02:00
Ivana Huckova
8246fc64fa Explore: Trigger logs sample only when user click to see it (#62226)
LogSamples: Trigger log samples on user action
2023-01-26 16:23:13 +01:00
Jo
4bcd3b41ec Server: Remove unused services (#62015)
remove unused entries

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
2023-01-26 16:13:22 +01:00
Sonia Aguilar
8bbef70363 Alerting: Fix recording rules being shown in the rules table on edit group modal (#62171)
* Fix recording rules being shown in the rules table on edit group modal

* Show no alerts message when there is not some non-recording rules and add tests

* Move specific mock constants to the test file
2023-01-26 16:11:29 +01:00
Ivana Huckova
ea1fcbb866 Explore: Add feature to open log sample in split view (#62097)
* Add tests

* Implement split open to see logs functionality

* Fix imports in test

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

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

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

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

* Update default scneario to throw error

* Exit early in getSupplementaryQuery

* Update public/app/features/explore/LogsSamplePanel.tsx

Co-authored-by: Matias Chomicki <matyax@gmail.com>
2023-01-26 16:06:10 +01:00
Ieva
5e1dc22f88 Chore: fix builds on main (#62218)
fix builds
2023-01-26 14:39:52 +00:00
Jack Baldry
f4be855e30 Update doc-validator to latest release (#62170)
* Update doc-validator to latest release

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Skip image validation

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2023-01-26 14:29:26 +00:00
ying-jeanne
2eaa3fb4d2 [Xorm] remove oracle driver + unused function (#62125)
[Xorm] Some more clean up
2023-01-26 22:24:11 +08:00
Levente Balogh
995e2715ad Navigation: Fix finding the active nav item for plugins (#62123)
fix: look for the active page under children first
2023-01-26 14:10:09 +00:00
lean.dev
75ffbe422b Snapshots: Add new snapshot configuration to documentation (#62110)
* Add new snapshot configuration to documentation
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-01-26 11:06:35 -03:00
Ezequiel Victorero
354f6d9e23 Schema: Create PublicDashboard core kind (#62155) 2023-01-26 10:51:00 -03:00
Kristin Laemmert
e8b8a9e276 chore: move dashboard_acl models into dashboard service (#62151) 2023-01-26 08:46:30 -05:00
Eric Leijonmarck
c5cb5be3cc Auth: Fix catch both both ErrInvalidAPIKey for context with APIKey (#62193)
* fix: capture both ErrInvalidAPIKey

* rename of variable
2023-01-26 14:42:50 +01:00
lean.dev
7d8ec6199d Snapshots: Add snapshot enable config (#61587)
* Add config to remove Snapshot functionality (frontend is hidden and validation in the backend)
* Add test cases
* Remove unused mock on the test
* Moving Snapshot config from globar variables to settings.Cfg
* Removing warnings on code
2023-01-26 10:28:11 -03:00
renovate[bot]
928e2c9c9e Update dependency glob to v8.1.0 (#62186)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-01-26 13:24:35 +00:00
gotjosh
0bfe150928 Alerting: Fix Test Receivers when settings are non-strings (#62156)
* Alerting: Fix Test Receivers when settings are non-strings

As part of the Alerting extraction, we want to make sure we don't have circular depedencies. As such, I had to move `PostableGrafanaReceiver` to a new struct in `grafana/alerting` called `GrafanaReceiver`.

`PostableGrafanaReceiver` has an attribute called `Settings` that uses a Grafana-propietary struct called `RawMessage`, this struct shadows `json.RawMessage`.

When I created `GrafanaReceiver`, I turned settings into a `map[string]string` thinking all settings would end up as strings. This was a mistake, and this test proves that it doesn't work, and breaks the API.
2023-01-26 12:54:03 +00:00
Konrad Lalik
e8dd01df35 Alerting: Alert rules search improvements (#61398)
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2023-01-26 13:44:14 +01:00
Karl Persson
94dca85b30 Auth: Fix error check (#62192) 2023-01-26 12:35:08 +00:00
Virginia Cepeda
a20d1eec32 Alerting: validate alert condition on saving rule (#61958)
* Validate alert condition on saving rule

* Remove unused const
2023-01-26 09:27:08 -03:00
Ludovic Viaud
bfbc8c3c4f Transforms: Add join by fields (#61322) 2023-01-26 13:10:05 +01:00
Ashley Harrison
f7d92ab841 Navigation: only show the img for a section root if both img and icon are present (#62127)
only show an img for a section root if both img and icon are present
2023-01-26 12:07:43 +00:00
Ashley Harrison
a77c342764 Navigation: Add keyboard shortcut to search input (#62116)
* Show shortcut

* add icon to search bar, make same changes in search modal

* rename to modKey

Co-authored-by: joshhunt <josh@trtr.co>
2023-01-26 12:07:32 +00:00
Jack Westbrook
8f06784449 Chore: Bump d3-color to 3.1.0 (#61609)
* chore(d3-color): resolve all copies to 3.1.0 to fix vulnerability

* chore(yarn): fix resolution version

* chore(jest): compile d3-color from esm to cjs

* chore(d3): bump d3 to latest, set jest config to transpile es modules

* chore: bump visx packages to resolve d3-color to latest

* chore(jest): add missing es modules to config

* chore(storybook): prevent storybook config failure due to nested esm imports

* chore(storybook): use a direct path to avoid es modules breaking config build

* build(sass): use esbuild to generate sass theme vars for esm deps

* chore: clean up swc dependencies

* revert: remove debug console.log breaking tests
2023-01-26 13:02:22 +01:00
Ludovic Viaud
a3d93febd7 Transforms: Keep refId for labelsTopFields (#61916) 2023-01-26 12:55:13 +01:00
Andreas Christou
18465bc04f Bump code-coverage workflow version (#62182) 2023-01-26 11:04:00 +00:00
Josh Hunt
43828e829b Chore: Script to generate betterer issue summary (#61857)
* wip

* finish script

* limit by message

* fix filter message

* Add template

* improve template

* codeowners devdep
2023-01-26 10:48:33 +00:00
Ashley Harrison
64352e8d08 Chore: Move to node 18 again (#62079)
move to node 18 again
2023-01-26 10:19:39 +00:00
Torkel Ödegaard
9f7ddf1f0b QueryEditorRow: Fixes issue loading query editor when data source variable selected (#61927)
* QueryEditorRow: Fixes issue loading query editor when data source variable selected

* Fix func name

* Removed wait

* restore waiting for with better check

* restore waiting for with better check
2023-01-26 11:07:17 +01:00
Ashley Harrison
a3b396854a Navigation: Command palette topnav tweaks (#61991)
stylings tweaks to command palette
2023-01-26 10:03:16 +00:00
Joan López de la Franca Beltran
c4e067d49d Encryption: Cache new DEKs (only) after a caution period (#60664)
* Encryption: Cache new DEKs (only) after commit

* Fix typo

* Update secrets manager tests with new failing case

* Update secrets manager tests with new clarifications (comments)

* Correct broken method calls

* Unify methods

* Cache data keys only after a caution period

* Caution period for data keys caching only for encrypt ops
2023-01-26 10:54:31 +01:00
Dimitris Sotirakis
3a442610d2 Packages: Fix upload-packages case for Enterprise2 mode (#61772)
* Add corner case for Enterprise2

* Add versionMode corner case

* Fix lint

* Refactor

* Add tests

* Remove break

* Fix lint

* Return error instead of panicing

* Fix lint
2023-01-26 11:52:15 +02:00
Karl Persson
95ea4bad6f AuthN: Rebuild Authenticate so we only have to call it once in context handler (#61705)
* API: Add reqSignedIn to router groups

* AuthN: Add fall through in context handler

* AuthN: Add IsAnonymous field

* AuthN: add priority to context aware clients

* ContextHandler: Add comment

* AuthN: Add a simple priority queue

* AuthN: Add Name to client interface

* AuthN: register clients with function

* AuthN: update mock and fake to implement interface

* AuthN: rewrite test without reflection

* AuthN: add comment

* AuthN: fix queue insert

* AuthN: rewrite tests

* AuthN: make the queue generic so we can reuse it for hooks

* ContextHandler: Add fixme for auth headers

* AuthN: remove unused variable

* AuthN: use multierror

* AuthN: write proper tests for queue

* AuthN: Add queue item that can store the value and priority

Co-authored-by: Jo <joao.guerreiro@grafana.com>
2023-01-26 10:50:44 +01:00
Armand Grillet
95f052bbd1 Add handleGrafanaManagedAlerts jsonData (#61874)
* Add handleGrafanaManagedAlerts jsonData

* Update following feedback
2023-01-26 10:48:51 +01:00
Dominik Prokop
b9a1d8e5f9 Dashboard schema: Review and mature refresh property (#62104)
* Review and mature refresh property

* Update type

* Update report
2023-01-26 01:45:12 -08:00
Joey Tawadrous
1423f15b0d Tempo: Update column width for Loki search (#61924)
Update col widths
2023-01-26 09:35:44 +00:00
Victor Marin
ab7a4e5f28 Fix Barchart legend calcs when stacking is percent (#61449)
* Fix Barchart legend calcs when stacking is percent

* doc change

* Refactor + tests
2023-01-26 11:34:57 +02:00
George Robinson
a7eab8e46e Alerting: Support context.Context in Loki interface (#61979)
This commit adds support for canceleable contexts in the Loki
interface.
2023-01-26 09:31:20 +00:00
Ashley Harrison
e6e560e3ed Dropdown: Make escape close a dropdown (#62098)
* make escape close a dropdown

* make tab close the dropdown
2023-01-26 09:23:53 +00:00
Sofia Papagiannaki
cd27562c76 Access control: Modify dashboard/folder resolvers so that return also the inherited scopes (#62025)
* Access Control: Add folder service dependency to the dashboard/folder resolvers

* Expose the function fetching parents to folder interface

* Add generic prepend utility

* Modify dashboard resolvers to return inherited scopes
2023-01-26 10:21:10 +02:00
Torkel Ödegaard
8e3d22ca7a Chore: Fixes cleanNeedle regex to be more specific (#61967)
* Chore: Fixes code sec warning for frontend regex

* Update text.ts

* Update text.ts
2023-01-26 09:08:15 +01:00
Victor Marin
6a93c77082 Refactor state timeline/status history to cue model and refactor TimelineChart component (#61631)
* Adapt state timeline to scuemata

* Refactor status history to cue model

* Refactor

* Refactor TimelineChart as a core component

* wip

* Change as per CR

Co-authored-by: sam boyer <sdboyer@grafana.com>
2023-01-26 07:03:59 +00:00
Nathan Marrs
6c9174a766 Canvas: Fix connection anchors for svg elements (#61895) 2023-01-25 16:32:04 -08:00
Ryan McKinley
46c828c2d8 EntityAPI: Rename references from kind to family (#62044) 2023-01-25 23:42:04 +00:00
Oscar Kilhed
f3aa058886 XY Panel: Add and use schema for XY Panel configuration (#62148)
* Add schema for XYChart

* Minor cleanup

* remove unessecary fields from ScatterFieldConfigVeneer, and cleaning up more

* Fix counts

Co-authored-by: sam boyer <sdboyer@grafana.com>
2023-01-25 22:29:07 +00:00
Alexander Weaver
eb1293ebb1 Alerting: Re-generate swagger definitions (#62154)
Regenerate swagger, add body binding so parameters work
2023-01-25 15:01:42 -06:00
sam boyer
4a1d418157 Kindsys: Simpler PascalCase name handling (#62150) 2023-01-25 20:29:10 +00:00
Ryan McKinley
402345ac08 Chore: Fix dashboard service after refactor (#62153)
merge refactoring sequence
2023-01-25 19:52:01 +00:00
Ryan McKinley
4965cf2eda k8s: add feature toggle and stub to save dashboards k8s (#62053) 2023-01-25 11:10:16 -08:00
Ryan McKinley
a0405912a8 Preferences: Add preferences kind and remove unused navbar settings (#59621) 2023-01-25 11:00:32 -08:00
Nathan Marrs
8b574e22b5 SVG: Add dompurify preprocessor step (#62143)
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2023-01-25 10:37:29 -08:00
Kristin Laemmert
dd147a3c31 chore: move entity models into entity store service (#62145) 2023-01-25 12:43:22 -05:00
Alexander Weaver
046a9bb7c1 Alerting: Copy rule definitions into state history (#62032)
* Copy rules instead of accepting pointer

* Deep-copy the rule, for even more guarantees

* Create struct just for needed fields

* Move RuleMeta to historian/model package, iron out package dependencies

* Move tests for dash ID parsing to model package along with code
2023-01-25 11:29:57 -06:00
Hamas Shafiq
1f55a54543 Tempo: Create separate functions for querying the v1/v2 API for tag values (#61998) 2023-01-25 17:12:59 +00:00
Gabriel MABILLE
f99523048a Schema: Covering service accounts Core Kind (#62091)
* Adding service accounts schema

Co-authored-by: Eric Leijonmarck <eric.leijonmarck@gmail.com>

* Change metadata field

Co-authored-by: Eric Leijonmarck <eric.leijonmarck@gmail.com>

* Merging the two DTOs into one schema

Co-authored-by: Eric Leijonmarck <eric.leijonmarck@gmail.com>

* Eric dedup things

Co-authored-by: Eric Leijonmarck <eric.leijonmarck@gmail.com>

* Add optional to teams/created/updated

Co-authored-by: Eric Leijonmarck <eric.leijonmarck@gmail.com>

* Lower case the OrgId

Co-authored-by: Eric Leijonmarck <eric.leijonmarck@gmail.com>

Co-authored-by: Eric Leijonmarck <eric.leijonmarck@gmail.com>
2023-01-25 18:07:00 +01:00
Selene
3c073b00ec Schema: Fix interfaces with blank spaces (#62144)
Fixes interfaces with blank spaces
2023-01-25 17:03:46 +00:00
Taewoo K
069dc2d357 add export customHeadersSettings component (#62131) 2023-01-25 11:32:35 -05:00
Polina Boneva
08806924d8 [Chore] Add unit tests to PanelChrome component (#61695)
* PanelChrome: test loadingState and status

* add some tests

* fix error-related tests

* clean up

* fix tests

* pass aria-label from PanelChrome to ToolbarButton

* add prop comments and clean up
2023-01-25 18:29:53 +02:00
renovate[bot]
4dafdcbdc4 Update dependency fork-ts-checker-webpack-plugin to v7.3.0 (#62129)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-01-25 16:27:55 +00:00
Yuri Tseretyan
e2899dd6bd Docs: Update expression documentation to mention no data (#61934)
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-01-25 11:17:09 -05:00
Stephanie Hingtgen
0a1f31814a Plugins: add UI for more supported datasources with secure socks proxy feature toggle (#61962) 2023-01-25 08:39:17 -07:00
Dan Cech
0c8a2bbfd5 copy .github folder into golang build container since we rely on codeowners (#62122)
* copy .github folder into golang build container since we rely on codeowners

* remove .github for .dockerignore
2023-01-25 10:31:16 -05:00
Kristin Laemmert
7c27c866f6 chore: update folder model (json tags) to match previous model (#62117)
chore: update folder model to match previous model
2023-01-25 10:04:08 -05:00
ying-jeanne
b0b2b72290 [API Split] Move star api inside of packages (#61987)
move star api inside of packages
2023-01-25 14:58:54 +00:00
Isabella Siu
7c85db5bfa CloudWatch Logs: Set default logs query and disable button when empty (#61956) 2023-01-25 09:39:42 -05:00
juanicabanas
e46aa2e4e6 PublicDashboards: Footer alignment fix for Firefox browser (#62108)
footer x axis aligment fixed
2023-01-25 11:30:42 -03:00
Eric Leijonmarck
6bd11e0ebf Auth: Add skip_org_role_sync setting for github (#61673)
* add: skip_org_role_sync setting for github

* fix: frontend

* rearranged tests

* refactor: assignGrafanaAdmin skip also

* Add: tests for allowGrafanaAdmin

- both for the case when both settings are set and the setting for only
  allowGrafanaAdmin

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update pkg/login/social/github_oauth.go

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>

* added vairable inside scope

* Update docs/sources/setup-grafana/configure-security/configure-authentication/github/index.md

* Update docs/sources/setup-grafana/configure-security/configure-authentication/github/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
2023-01-25 15:16:08 +01:00
idafurjes
529e6c379f Chore: Remove Result field from dashboard snapshot mode (#62089)
Chore: Remove Result field from dashboard snapshot mode;
2023-01-25 15:09:44 +01:00
Kyle Brandt
13de1afcbe API: Change how Cache-Control and related headers are set (#62021)
- change Cache-Control from no-cache to no-store
- do not set (and remove if set) older Pragma/Expires
2023-01-25 09:09:27 -05:00
Timur Olzhabayev
0d7e303809 Chore: Keeping the list of plugin executable complete (#60840)
* Keeping the list of executable complete

* Update pkg/plugins/storage/fs.go

Co-authored-by: Will Browne <wbrowne@users.noreply.github.com>

Co-authored-by: Will Browne <wbrowne@users.noreply.github.com>
2023-01-25 14:07:59 +00:00
Alexa V
85bf098fdb Dashboard schema: Review and mature fiscalYearStartMonth property (#62105) 2023-01-25 13:28:13 +00:00
Ben Sully
bd4e3f0d16 API: Correctly use new grafana_com.api_url setting in /api/gnet proxy (#60893)
During the review of the initial PR adding this (#59506) I removed
a new global variable from the setting package, but forgot to update
the reference to the new setting, so the API URL wasn't actually
being used. This PR updates the proxy endpoint to use the API
URL correctly.

Aside: I'm not a huge fan of how the error is being ignored when parsing
the URL, but I think that should be addressed in a separate PR if anyone
has a suggestion for how we should handle it. (Should we check that the
URL is valid when parsing config?)
2023-01-25 15:23:18 +02:00
renovate[bot]
c3cc236b56 Update dependency eslint to v8.32.0 (#61894)
* Update dependency eslint to v8.32.0

* update sdk

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2023-01-25 12:55:00 +00:00
Eric Leijonmarck
143ee0c49f Auth: Add skip_org_role_sync to GitLab OAuth (#62055)
* Auth: Add skip_org_role_sync to GitLab OAuth

- add: tests
- docs added

* Update pkg/login/social/gitlab_oauth.go

Co-authored-by: Karl Persson <kalle.persson@grafana.com>

* fix: for import

Co-authored-by: Karl Persson <kalle.persson@grafana.com>
2023-01-25 13:39:54 +01:00
Dominik Prokop
5f6616ff3e Dashboard schema: Review and mature graphTooltip property (#62082)
* Review and mature graphTooltip property of Dashboard kind

* Review
2023-01-25 03:40:53 -08:00
renovate[bot]
a6f0b69d6f Update dependency eslint-plugin-jest to v27.2.1 (#61523)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-01-25 11:34:35 +00:00
Will Browne
eb1fed7929 Plugins: Add plugin resource tests (#62014)
* remove plugin context from response

* remove integration test indicator
2023-01-25 10:45:52 +00:00
gotjosh
bbf7c0a147 Update alerting to the latest main (#62003) 2023-01-25 10:06:36 +00:00
Dimitris Sotirakis
b2b48398d0 Chore: update latest.json to 9.3.4 (#62080) 2023-01-25 11:57:18 +02:00
Grot (@grafanabot)
e05fc9212a Changelog: Updated changelog for 8.5.20 (#62073) 2023-01-25 10:44:12 +01:00
Torkel Ödegaard
504fec46d2 CommandPalette: Design tweaks and design fixes (#61971)
* Command palette design tweaks start

* Fix some item styling issues

* Updated placeholder

* Style fixes

* Fix gradient border pos issue, and heading padding

* Fix header top margin

* Restore padding

* Update

* Change to md modal
2023-01-25 10:38:33 +01:00
idafurjes
b54b80f473 Chore: Remove Result from dashboard models (#61997)
* Chore: Remove Result from dashboard models

* Fix lint tests

* Fix dashboard service tests

* Fix API tests

* Remove commented out code

* Chore: Merge main - cleanup
2023-01-25 10:36:26 +01:00
Grot (@grafanabot)
8c3e4487ba Changelog: Updated changelog for 9.3.4 (#62067) 2023-01-25 11:30:59 +02:00
Grot (@grafanabot)
87023c85cb Changelog: Updated changelog for 9.2.10 (#62066)
* Changelog: Updated changelog for 9.2.10

* Update CHANGELOG.md

* Update CHANGELOG.md

Co-authored-by: Horst Gutmann <horst.gutmann@grafana.com>
2023-01-25 10:26:30 +01:00
Sonia Aguilar
dbdd135298 Alerting: Fix recording rules showing alert notification information. (#61988)
* Fix recording rules form steps not showing alert information

* Fix docs about creating cloud and recording rules

* Update docs with suggested changes
2023-01-25 08:26:51 +00:00
Shirley
cd86758a35 CloudWatch: Use grafana-aws-sdk v0.12.0 (#62007) 2023-01-25 09:22:33 +01:00
Esteban Beltran
cebd71cc36 Docs: Update publish a plugin FAQ to cover more common questions (#62001) 2023-01-25 08:19:32 +00:00
idafurjes
421976e919 Chore: Remove folders from models pkg (#61853) 2023-01-25 09:14:32 +01:00
Adela Almasan
6bf1d06dba Canvas: Update scene and panel when entering panel view mode (#62043) 2023-01-24 18:41:08 -06:00
owensmallwood
dd597c3a1e PublicDashboards: Adds middleware for email sharing (#61950)
adds Share field to PublicDashboard model
2023-01-24 18:23:39 -06:00
Aashish Illa
fbfb79afce Explore: Changed references to DataQuery and DataSourceRef (#62034) 2023-01-24 15:11:00 -06:00
Christopher Moyer
0f93548ac4 Docs: corrects broken link to v9.0 docs (#62035)
corrects broken link to v9.0 docs
2023-01-24 14:32:14 -06:00
sam boyer
af1a264f85 dashboards: Mark dashboards team as kind owner (#62013)
* dashboards: Mark dashboards team as kind owner

* Update .github/CODEOWNERS

Co-authored-by: Ivan Ortega Alba <ivanortegaalba@gmail.com>

Co-authored-by: Ivan Ortega Alba <ivanortegaalba@gmail.com>
2023-01-24 15:07:17 -05:00
Hamas Shafiq
76e1946bd7 Tempo: [TraceQL] Do not override the status tag name (#62030) 2023-01-24 19:21:48 +00:00
Ivana Huckova
a0921f2e88 Explore: Implement logs sample in Explore (#61864)
* Implement log samples

* Explore: Implement logs sample panel

* Log samples: Add documentation

* Update docs

* Add info for log sample

* Fix label

* Update

* Default to true

* Fix copy in test

* Update public/app/features/explore/LogsSamplePanel.tsx

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

* Use timeZone from grafana/schema

* Rename data props to queryResponse

* Unify name to logs sample

* Remove redundant optional parameters in LogsSamplePanel

* Make intervalMs parameter optional in dataFrameToLogsModel and remove undefined argument when not needed

* Fix incorrect position of copy log line button

* Update public/app/core/logsModel.ts

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

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
2023-01-24 19:10:27 +01:00
Santiago
e5920c211e Chore: Fix random indices for slices in test files (#61884)
* Fix random indices for slices in test files

* Empty commit
2023-01-24 15:07:37 -03:00
Kristina
6ab79c4fba Explore: Be sure time range key bindings are mounted after clear (#61892)
* Add list of bindings for updating on change

* Revert "Add list of bindings for updating on change"

This reverts commit 092707371d.

* Clear keybindings before component render
2023-01-24 11:12:09 -06:00
Tania
3324be6fda Docs: Fix schema attributes formatting in schema docs (#62016)
Docs: Fix schema attributes formatting
2023-01-24 17:53:22 +01:00
Alex Khomenko
8e94eab9ff Schema: Move known shared types into the common (#61875)
* Setup shared types

* Expand field types

* Fix array type

* Add QueryResultMeta

* Add QueryResultBase

* Add DataFrameJSON

* Add DataSourcePluginMeta

* Update QueryResultMetaStat

* Add plugin cue and veneers

* Rexport dupliate types to fix errors

* Fix export

* Update types

* Remove data frame/plugin types

* Cleanup types

* Remove redundant type

* Remove data frame related types
2023-01-24 16:45:28 +00:00
Chris Marchbanks
f85d072c17 Datasources: Fix Proxy by UID Failing for UIDs with a Hyphen (#61723)
Fix Proxy by UID Failing for UIDs with a Hyphen

Hyphens are allowed in short IDs but not picked up by the
proxyPathRegexp. This caused the end of the uid to be proxied as part of
the path to the backing datasource which would usually cause a 404.
2023-01-24 17:15:52 +01:00
George Robinson
239d94205a Alerting: Return chan <-error for #61811 (#61858) 2023-01-24 15:41:38 +00:00
Levente Balogh
cc502bbfbd Connections: update the style of the cards (#61989) 2023-01-24 16:22:46 +01:00
Will Browne
958eea2f78 Plugins: Add backend target to instrumentation (#61980)
* add target

* fix test
2023-01-24 16:18:34 +01:00
Joan López de la Franca Beltran
6e126596e0 Kindsys: Include CODEOWNERS to Kinds report (#61978)
* Kindsys: Include CODEOWNERS to Kinds report

* Sort CODEOWNERS for the sake of reproducibility

* Fix linter complains
2023-01-24 15:53:01 +01:00
Josh Hunt
32ff95bde3 CommandPalette: Fix feature flag (#62000) 2023-01-24 15:52:12 +01:00
Andres Martinez Gotor
3e73ba5460 Azure Monitor: Adapt Advanced component to multiple resources (#61981) 2023-01-24 15:44:48 +01:00
Christopher Moyer
12a4a83c77 Docs: prose and format updates (#61720)
* wording and format updates

* corrects typo
2023-01-24 08:15:09 -06:00
Isabella Siu
814e485dd3 CloudWatch: Prevent log groups from being removed on query change (#61891) 2023-01-24 09:05:41 -05:00
Andres Martinez Gotor
d54cda62a3 Add debug option for Golang tests in vscode (#61983) 2023-01-24 14:44:44 +01:00
Josh Hunt
88347caf5f Navigation: Open command palette from search box (#61667)
* Reduce size of topnav search 'input' to 1/5th of the width, min width 200px

* Open command palette on topnav search box click

* Rename component

* fix comment

* feature flag the change

* update feature flag description
2023-01-24 12:41:09 +00:00
ying-jeanne
ec171bcad5 [xorm] Clean up xorm dialect & cascade (#61969)
clean up xorm dialect
2023-01-24 19:57:33 +08:00
Alex Khomenko
18e0a060e6 AlertGroups: Generate models.gen.ts from models.cue (#61227)
* AlertGroups: Generate models.gen.ts from models.cue

* Update structure

* Update report

* Fix filenames

* Add missing file
2023-01-24 13:46:35 +02:00
Oscar Kilhed
6c9d9a2db5 Table panel: Use link elements instead of div elements with on click events to aid with keyboard accessibility (#59393)
* TablePanel: fix image of image cell overflowing table cell when a data link is added
2023-01-24 12:42:40 +01:00
Andre Pereira
81c35560a8 Chore: Update the tempo devenv with the latest Tempo config changes (#61622)
* Update the tempo devenv with the latest Tempo config changes

* Remove some settings to instead use the default values

* Pin the Tempo image to the current latest version

Co-authored-by: Hamas Shafiq <hamas.shafiq@grafana.com>
2023-01-24 11:08:40 +00:00
Zoltán Bedi
4167214e35 Panel edit: Add feature to drag & drop spreadsheet files to the grafana datasource (#60586)
Co-authored-by: Oscar Kilhed <oscar.kilhed@grafana.com>
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Adela Almasan <adela.almasan@grafana.com>
2023-01-24 10:43:44 +01:00
Ashley Harrison
92a750a732 Chore: convert last test to RTL and remove Enzyme references (#61918)
convert last test to RTL and remove enzyme references
2023-01-24 09:20:47 +00:00
Joan López de la Franca Beltran
479da46a9e Kindsys: Include @grafanamaturity counts to Kinds report (#61911)
* Kindsys: Include @grafanamaturity counts to Kinds report

* Replace reflect.DeepEqual with regular (in)equality op

* Move reference check to its use (inline)

* Fix linter complains
2023-01-24 09:37:32 +01:00
Torkel Ödegaard
7c786c11e3 Home: Fixes breadcrumb for custom home dashboard (#61499)
* Home: Fixes breadcrumb for custom home dashboard

* restore using home page cfg setting
2023-01-24 09:33:12 +01:00
Torkel Ödegaard
38d3d1c02b Profile: Rename profile page from preferences to profile (#61777)
* Rename preferences to Profile

* Fixed tests and ran i18 extract
2023-01-24 09:32:49 +01:00
Sofia Papagiannaki
e5e8bb4dea Chore: Use same JSON tag casing everywhere for parent UID (#61935)
Chore: Use same JSON tag casing everywhere for parent UID
2023-01-24 10:20:28 +02:00
Sonia Aguilar
3b73b16245 Alerting: Add maxdatapoints in alert rule form (#61904)
Add maxdatapoints in alert rule form
2023-01-24 09:16:21 +01:00
Timur Olzhabayev
7ebbd01688 Linking criteria and adding file and env variables access (#61830)
* Linking criteria and adding file and env variables access

* Formatting

* Update docs/sources/developers/plugins/publish-a-plugin.md

Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>

Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
2023-01-24 07:37:56 +00:00
Joan López de la Franca Beltran
c621693db0 Kindsys: Include generated-code links to Kinds report (#61910)
* Kindsys: Include generated-code links to Kinds report

* Apply feedback suggestions
2023-01-24 01:47:42 +00:00
Selene
6f26333e96 Chore: Add cuefix hook (#61941)
* Add cue

* Add fix-cue target

* Add pre-commit hook

* fixup! Add fix-cue target

* Update the cue version

* Add datasources and panels folders

* Update cue files

Co-authored-by: Tania B <yalyna.ts@gmail.com>
2023-01-23 20:36:46 -05:00
Adela Almasan
f5743ea9ac Canvas: Improve arrow positioning when border is present (#61961) 2023-01-23 18:38:04 -06:00
Brendan O'Handley
1181d06b1b Graphite: Have metric name type query variable use metric render endpoint (#61730)
* have metric name query var use metric render endpoint

* add documentation for new query types
2023-01-23 18:13:22 -05:00
Alex Khomenko
3006a457f2 Geomap panel: Generate types (#61636) 2023-01-23 15:12:56 -08:00
Alexander Weaver
7ccc845187 Alerting: Push state history entries to Loki (#61724)
* Implement push endpoint

* Drop duplicated struct

* Genericize auth/tenant headers and improve logging in error case

* Flesh out the data model

* Drop dead code

* Drop log line entirely

* Drop unused arg

* Rename a few type manipulation functions

* Extract label keys as constants

* Improve logs when loki responds with error

* Inline lokiRepresentation function
2023-01-23 16:31:03 -06:00
jeremybanzhaf
3146740d82 Docs: Update index.md to not escape dollar sign (#61694)
Update index.md to not escape dollar sign

the backslash is useful in json files, but not where most users will see it
2023-01-23 15:57:11 -06:00
juanicabanas
949857f3b1 PublicDashboards: Footer position fix (#61954) 2023-01-23 17:30:20 -03:00
juanicabanas
9b5e396be2 PublicDashboards: Checkboxes list refactor (#61947) 2023-01-23 17:23:23 -03:00
Kristin Laemmert
fe27acc3a9 chore: move validations model into the validations service (#61953) 2023-01-23 15:10:14 -05:00
sam boyer
17aaf9f0d3 panels: Remove redundant import package from cue defs (#61949) 2023-01-23 14:28:44 -05:00
sam boyer
856abe1281 Kindsys: Add Ptr func (#61948) 2023-01-23 14:27:33 -05:00
Kristin Laemmert
6e9eb0d931 chore: move plugins models into pluginsettings svc (#61944) 2023-01-23 13:56:20 -05:00
sam boyer
48b620231e Kindsys: Unique names for composable kind TS types (#61928)
* Kindsys: Unique names for composable kind TS types

* Update all TS imports
2023-01-23 18:03:44 +00:00
juanicabanas
7875fadd31 GrafanaUI: Checkbox description fix (#61929) 2023-01-23 14:50:19 -03:00
Ashley Harrison
6b53f927b2 Navigation: truncate landing page descriptions to 3 lines (#61925)
* truncate landing page descriptions to 3 lines

* use correct css prop names
2023-01-23 17:07:36 +00:00
Joe Elliott
3eb065339f Tempo Datasource: Correct TraceQL docs link (#61931)
* correct link

Signed-off-by: Joe Elliott <number101010@gmail.com>

* lint

Signed-off-by: Joe Elliott <number101010@gmail.com>

Signed-off-by: Joe Elliott <number101010@gmail.com>
2023-01-23 16:59:55 +00:00
Kristin Laemmert
857649e30b chore: move models/licensing into licensing service (#61878) 2023-01-23 11:53:43 -05:00
Adela Almasan
50faeba07e Canvas: Connection heads not rendering consistently (#61887) 2023-01-23 10:51:55 -06:00
Denis Limarev
812c90ec69 Perfomance: Add preallocation for some slices (#61632) 2023-01-23 17:44:27 +01:00
Jo
46cbf9d24c SAML: Update deps (#61906) 2023-01-23 16:24:59 +00:00
Jo
1037ef28a9 SupportBundles: Access control guards (#61914)
* rename routes and fix access control for support bundles

* AccessControl: Hide menu if not authorized

* AccessControl: Add AC guards for create and delete

* lint
2023-01-23 16:23:20 +00:00
Sven Grossmann
c5610450b2 Elasticsearch: Fix failing requests when using SigV4 (#61923)
fix setting of `es` servicename
2023-01-23 16:43:55 +01:00
Hamas Shafiq
5eca966f45 Tempo: [TraceQL] Integrate the new tag values API (#61637)
* Tempo: [TraceQL] Integrate the new tag values API

* Use the exact string entered in the spanset

* Update a test & add a new test

* Empty commit
2023-01-23 15:39:56 +00:00
Joan López de la Franca Beltran
afef0c926c Loki: Push support for multi-tenancy mode (#60866)
* Loki: Add multitenancy support for the HTTP client

* Loki: Support to push with multitenancy mode

* Apply feedback suggestions
2023-01-23 16:24:22 +01:00
Gareth Dawson
35c7bbef57 Loki: Add ingester to the devenv loki config (#61844)
feat: update loki config
2023-01-23 15:09:57 +00:00
Horst Gutmann
739fcf1796 CI: Remove grabpl integration-tests (#61920)
These tests can also be run without it.
2023-01-23 16:00:31 +01:00
sam boyer
8ddedf475b Kindsys: Remove reference to DecoderCompactor (#61922) 2023-01-23 14:44:24 +00:00
Selene
1e5eae5fca Chore: Remove DecoderCompactor() (#61706)
* Remove ApplyFunc and set NoOptionalPointers to true

* Update go mod
2023-01-23 09:00:34 -05:00
sam boyer
f62f3cb0e9 Kindsys: Generate plugin Go types under a kinds/ dir (#61899)
Kindsys: Generate plugin Go types under kinds/
2023-01-23 08:56:00 -05:00
Kristin Laemmert
40feee0d17 chore: move alert-related models (#61716)
* chore: move alert notification models into the alerting service (alerting/models)
2023-01-23 08:19:25 -05:00
Joan López de la Franca Beltran
2b0de82aa9 SQLStore: Add test for nested transactions events (#60500)
* SQLStore: Add test for nested transactions events

* Replace fmt.Print* with t.Log*

* Add different test cases
2023-01-23 14:17:56 +01:00
Levente Balogh
4def287e62 Connections: Show the Dashboards tab under DataSource settings (#61841)
* fix: use the correct URL for editing datasource dashboards

* feat: show the Datasource/Dashboards page under Connections as well

* refactor: remove unnecessary `useNavModel()` utility

* feat: add a utility for creating the nav-model for DS settings tabs

* refactor: use nav-model crating utility in Edit Datasource
2023-01-23 13:25:42 +01:00
Andreas Christou
590d1f8a7d AzureMonitor: Move DefaultSubscriptions field to separate component (#61633)
* Move DefaultSubscriptions field to separate component

- Add separate component
- Update CredentialsForm
- Update tests
- Remove redundant test

* Remove defaultSubscriptionId

- Update MonitorConfig to appropriately set subscriptionId
- Update DefaultSubscription component to make use of JsonData
- Remove references to defaultSubscriptionId
- Update tests
- Update mockInstanceSettings for flexibility

* Review

- Add DefaultSubscription test and remove component from AzureCredentialsForm test
- Remove onCredentialsChange from DefaultSubscription
- Set subscription as a part of onSubscriptionChange
2023-01-23 12:19:48 +00:00
Sofia Papagiannaki
c7a7ebd3e0 Chore: Drop search service dependency from folder service (#61789)
* Chore: Drop search service dependency from folder service
2023-01-23 14:09:09 +02:00
Gábor Farkas
bedd0b311a elastic: improve error-messages, first step, tests only (#61847) 2023-01-23 12:46:52 +01:00
Jack Westbrook
3a7623753b Build: Replace babel-loader with esbuild-loader (#57837)
* build(webpack): replace babel-loader with esbuild-loader

* build(webpack): add esbuild minifier to production builds

* Wip

* Removed ngInject and replaced with manual inject params

* chore: bump esbuild to 0.15.13

* Fixed angular issues

* build(frontend): update esbuild to 0.16.16

* chore(webpack): support browserslist for esbuild

* build(esbuild): unify versions of esbuild to 0.16.17 and esbuild-loader to 2.21.0

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2023-01-23 12:15:05 +01:00
Will Browne
59ef144e9e Plugins: Add file permission error check when attempting to verify plugin signature (#61860)
add permission err check
2023-01-23 12:01:10 +01:00
Karl Persson
50608db59a AuthN: Add interface and function to operate on clients that supports redirects (#61905) 2023-01-23 11:54:38 +01:00
Alexa V
db51e963de PanelChrome: Allow panel to be dragged if set as draggable from the outside (#61698) 2023-01-23 10:38:38 +00:00
Horst Gutmann
e32cd6d4ff CI: Add artifacts npm commands from grabpl (#61908) 2023-01-23 11:32:51 +01:00
gotjosh
0be920e61c Alerting: Remove unused code after importing from grafana/alerting (#61869)
* Alerting: Remove unused code after importing from grafana/alerting
2023-01-23 10:30:10 +00:00
Torkel Ödegaard
cd99bfec68 TopNav: Fixes breadcrumb issues and title for apps when topnav is disabled (#61835) 2023-01-23 11:03:28 +01:00
Torkel Ödegaard
97fc6c4eb4 Apps: Use plugin description as nav node subtitle (#61549) 2023-01-23 11:02:05 +01:00
Karl Persson
0942e0a815 RBAC: Rewrite data source api tests (#61783)
RBAC: Rewrite datasource rbac api tests
2023-01-23 10:54:29 +01:00
Ashley Harrison
253f9657cb Navigation: Change collapse icon + behaviour (#61496)
* adjust positioning and switch icon

* hide collapse button unless collapsed/focused

* use Button instead of IconButton
2023-01-23 09:30:28 +00:00
Ashley Harrison
a26bae45e1 Navigation: clean up colors in section nav (#61240)
* clean up colors in section nav

* just underline on hover/focus
2023-01-23 09:26:26 +00:00
Jack Westbrook
f0f3032edc Chore: Patch bump QS (#60508)
chore(yarn): patch bump qs to resolve dependabot alerts
2023-01-23 09:05:29 +00:00
Victor Marin
e6aaabed4d Docs: Update visualization and barchart panels (#61474)
* Update docs

* Regen cue model for barchart

* Fix docs

* models.cue renamed to composable_panelcfg.cue

* Rename 'Bar' to 'x-axis' in options UI

* run gen-cue
2023-01-23 10:49:41 +02:00
Jack Westbrook
1a97c79978 Chore: Bump Terser related dependencies (#60506)
chore(yarn): refresh lock file for all dependencies of terser
2023-01-23 08:47:48 +00:00
Ivan Ortega Alba
5bfe098b0a test: use deterministic timestamp to compare snapshots (#61670) 2023-01-23 09:44:10 +01:00
Tania
5f93e67419 Codegen: Generate docs for composable kinds (#61719)
* Generate docs for composable kinds

* Fix getting the kind schema

* Generate composable kinds docs

* Add disclaimer to the generated docs

* Change docs disclaimer
2023-01-22 18:58:49 -05:00
Nathan Marrs
65127d4913 Canvas: Update readme with link to docs (#61812) 2023-01-20 21:22:56 -08:00
Ryan McKinley
624e5dbed2 EntityAPI: Save nested summary info in the SQL database (#61732) 2023-01-21 00:00:17 +00:00
Adela Almasan
c4090c579d Canvas: Rectangle render error (#61883) 2023-01-20 15:29:37 -06:00
Adam Simpson
92936d3a72 Chore: update @grafana/experimental to 1.1.0 (#61820)
The main goal is to bring in changes that address a11y issue #56561.

This also fixes any ts errors.
2023-01-20 20:06:51 +00:00
Kristin Laemmert
cd08f2575a chore: move jwt models into auth/jwt (#61862)
* chore: move jwt models into auth/jwt
2023-01-20 13:11:06 -05:00
Matt Dodson
fb6df56464 Docs: rewrite data source intro (#61639)
* Docs: rewrite data source intro

- Include more than just "databases", which was overly narrow
- Try to make doc a "TL;DR" of the essential information

* docs, link data source to build plugin task

* Reduce jargon and sentence length

* Link out to different features

* Data source, docs turn examples into list

And trim language

* Better phrasing to introduce query editor

Old way implied that Grafana provides all query editors,
which isn't true of custom plugins.

* use relref for in-repo anchor

* remove double "in"

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* Simplify list

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* Restructure intro, clarify plugins and their URLs

* Add and configure

It's sometimes both.

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* makes prettier

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
2023-01-20 11:36:12 -06:00
Kyle Brandt
5bb38293d2 SSE/Prom: Undo empty frame change that triggers 500s in SSE (#61871)
added in https://github.com/grafana/grafana/pull/61643
2023-01-20 17:32:14 +00:00
Jo
7a9793ec0e SupportBundles: Fix collector typos and change defaults (#61850)
fix collector typos and change defaults
2023-01-20 16:33:29 +00:00
Adela Almasan
cef15873d6 Canvas: Add tooltip for data links (#61648) 2023-01-20 16:26:51 +00:00
Selene
c1251311d0 Chore: Fix cue imports when we don't use an alias (#61795)
Fix cue imports when we don't use an alias
2023-01-20 17:04:44 +01:00
Andres Martinez Gotor
b1efd911c1 AzureMonitor: Fix feature flag (#61863) 2023-01-20 15:29:23 +00:00
Matias Chomicki
87f8e7e223 Query Builder: Fix max width of input component to prevent overflows (#61798)
* fix(auto-size-input): return maxWidth when realWidth exceeds limit

* fix(query-builder): sex madWidth for simple editor component

* fix(auto-size-input): add unit test
2023-01-20 15:25:01 +00:00
Yuri Tseretyan
c0913ce718 SSE: Fix math expression to support NoData results (#61721)
* update perFloat to support NoData
* update union to correctly handle no-data
2023-01-20 09:53:03 -05:00
zsrv
d0cf7ff8e9 Docs: Use the correct name for the feedback_links_enabled option (#61825)
Also updates the description to be more in line with the style conventions.
2023-01-20 08:33:54 -06:00
idafurjes
68445a7c77 Chore: Remove dashboard ACL from models (#61749)
* Remove dashboard ACL from models

* Remove unused comment
2023-01-20 14:58:47 +01:00
Ivana Huckova
c106c7700b Explore: Create DataSourceWithSupplementaryQueriesSupport interface to support log volume and samples (#61298)
* Create DataSourceWithLogsSampleSupport check and move to 1 place

* Add new SupplementaryQueryType

* Add and change utility functions for loading, storing ancd checking supp queries

* Add logic to redux for processing of new type of supp query

* Implement queryLogsSample used to run samples queries

* Fix tests to include also Log samples

* Add tests

* Temporarily, default to false

* Change comment

* Fix lint error

* Refactor handling of supplementary queries in query.ts

* Fix looping over array

* Remove changes for any => unknowns as in utils.ts

* Fix logic

* Fix incorrect imports after function was moved to different file

* Migrate old log volume key

* Update public/app/features/explore/utils/supplementaryQueries.ts

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

* Refactor to use DataSourceWithSupplementaryQueriesSupport

* Refactor, improve tests,  change internal API

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

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

* Add deprecation for DataSourceWithLogsVolumeSupport, but still support it

* Update comment with correct new issue

Co-authored-by: Piotr Jamróz <pm.jamroz@gmail.com>
2023-01-20 14:20:49 +01:00
Joey Tawadrous
e517cc0cea Flame graph: Search with uFuzzy (#61748) 2023-01-20 12:57:31 +00:00
Torkel Ödegaard
ce879ac8e1 Explore: Keyboard shortcut to go to explore (#61837) 2023-01-20 13:54:58 +01:00
Armand Grillet
a960b55a99 Update link to provisioning docs (#61840)
Update links to provisioning docs
2023-01-20 12:55:27 +01:00
Andres Martinez Gotor
d4e0e75c0c Azure Monitor: Fix frame display name with multiple resources (#61750) 2023-01-20 12:20:01 +01:00
Ruud van der Weijde
b44df6c8d1 ElasticSearch: Improve ES error handling message (#61471)
Look for 'caused_by.reason' in ES error response

When the ES response does not contain `reason` or `root_cause[0].reason`
is empty, there is no information for the user to know what is going
wrong.

An example of the error message after this change:
```
Failed to evaluate queries and expressions: failed to execute query A: Trying to create too many buckets. Must be less than or equal to: [65536] but this number of buckets was exceeded. This limit can be set by changing the [search.max_buckets] cluster level setting.
```

Related to https://github.com/grafana/grafana/issues/61246
2023-01-20 11:46:31 +01:00
Andres Martinez Gotor
3e86a1b3d9 Azure Monitor: Implement logic to allow multiple selection (#61740) 2023-01-20 11:19:31 +01:00
Ivana Huckova
46722679b5 Elasticsearch: Fix creating of span link with no tags (#61753)
Elasticsearch: Fix create span link if no tags
2023-01-20 10:52:33 +01:00
sam boyer
3b3059c9ce Kindsys: Unify plugins, pfs with kind framework (#61192)
* New pfs impl

* Reached codegen parity with old system

* Update all models.cue inputs

* Rename all models.cue files

* Remove unused prefixfs

* Changes Queries->DataQuery schema interface

* Recodegen

* All tests passing, nearly good now

* Add SchemaInterface to kindsys props

* Add pascal name deriver

* Relocate plugin cue files again

* Clarify use of injected fields

* Remove unnecessary aliasing

* Move DataQuery into mudball

* Allow forcing ExpandReferences on go type generation

* Move DataQuery def into kindsys, add generator to copy it to common

* Fix copy generator to replace package name correctly

* Fix duplicate type, test failure

* Fix linting issues
2023-01-20 09:41:35 +00:00
Sven Grossmann
6a7cbeae6c Logs: Adjust documentation for new log details (#61311)
* update doc

* fix capitalisation and formatting of headings

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* fix capitalisation and formatting

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-01-20 10:16:50 +01:00
Jo
caae4fd034 SupportBundles: Add config enablement (#61776)
* wip

* implement role middleware drop

* remove not implement feature

* change grants based on config

* Update pkg/services/supportbundles/supportbundlesimpl/models.go

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
2023-01-20 08:59:15 +00:00
renovate[bot]
9faab75668 Update dependency eslint-plugin-jsx-a11y to v6.7.1 (#61525)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-01-20 09:13:24 +01:00
Levente Balogh
9d4e940097 Connections: Don't use gridSize directly in styling (#61684)
refactor: don't use gridSize directly
2023-01-20 09:01:51 +01:00
Usman Ahmad
6c6c0f5402 Update _index.md (#61662)
* Update _index.md

The troubleshooting page was missing how to send dashboard panels for debugging so added it here.

* Update docs/sources/troubleshooting/_index.md

* Update docs/sources/troubleshooting/_index.md

* removed empty lines

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
2023-01-20 04:10:28 +00:00
Julien Duchesne
efb98bcb99 Packaging: Use base64 key (#61802)
The tools in this repo need base64 but not in most other tools. I had to revert the change I made to the key
I created another key for base64 that we can use here
Follow-up to https://github.com/grafana/grafana/pull/61784
2023-01-19 15:03:19 -07:00
Isabel
9223fe5ca8 update adding new panel wording (#61817)
updated adding new panel wording
2023-01-19 13:45:07 -08:00
Ryan McKinley
c315946a91 SearchV2: Fix star query when no stars exist (#61726) 2023-01-19 21:37:06 +00:00
Gilles De Mey
845128dde9 Alerting: Swap templates and contact points places (#61808)
Alerting: swap templates and contact points places
2023-01-19 21:51:45 +01:00
gotjosh
511dab3b4b Update grafana/alerting to the latest main (#61810)
* Update `grafana/alerting` to the latest main

Also updates prometheus-alertmanager since we use that one directly for some structs.
2023-01-19 20:44:49 +00:00
Drew Slobodnjak
f1bb108ae5 Geomap: Update readme to include doc link (#61258) 2023-01-19 12:27:45 -08:00
Drew Slobodnjak
516bdddcb5 Canvas: Add server element (#61104)
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2023-01-19 12:03:17 -08:00
Erik Sundell
78184f37c4 Cloudwatch: Restructure languages in plugin root (#61490)
Co-authored-by: Isabella Siu <isabella.siu@grafana.com>
2023-01-19 14:04:28 -05:00
Adela Almasan
da7bf56c03 Canvas: Inconsistent border behavior (#61794) 2023-01-19 12:43:22 -06:00
Jo
e2ec219f6a SecretScan: Remove placeholder image and polish errors (#61785)
* remove placeholder image

* improve http client options

* add http clients options for webhook notifier

* ensure http is only used in dev mode

* cleanup errors
2023-01-19 18:33:27 +01:00
tonypowa
ed076adde5 ISSUE_TRIAGE.md: update (#60299)
* updated section #2

- added current bug issue template bullet points to # Bug reports subsection
- updated enhancement requests' subsection by adding info regarding GH discussions
- added link to WCAG criteria in Accessibility issues subsection
- linked Support requests' subsection  to section  # 3 Categorizing an issue/#support-requests subsection

* made changes as suggested

* updated sections 2, 3, 5

updating as discussed with Natalia
included feedback by Melori

* updated flowchart

* reupdated flowchart

* resolved pending comments

* run prettier command on triage doc
2023-01-19 18:21:36 +01:00
idafurjes
8cbcdf1c26 Remove live.go from models (#61742)
* Remove live.go from models

* Change Id to ID

* Add xorm tags
2023-01-19 18:10:40 +01:00
Sofia Papagiannaki
c104cc7020 Chore: Split folder store and dashboard store interfaces (#61655)
* update folder store mock

* Split folder store and dashboard store interfaces
2023-01-19 18:38:07 +02:00
Sonia Aguilar
a6102105af Alerting: Fix QueryAndExpressionStep not using the right query (#61738)
Fix QueryAndExpressionStep not using the right query
2023-01-19 17:33:32 +01:00
Stephanie Hingtgen
3b718a3e8f Plugins: enable the plugin sdk to get the json data for all datasources (#61729) 2023-01-19 08:49:45 -07:00
Julien Duchesne
be4c969337 Use new GPG key when publishing (#61784)
The old key is revoked: https://grafana.com/blog/2023/01/12/grafana-labs-update-regarding-circleci-security-updates/
But it's added as a manual Drone repo secret
This switches to the new gpg key that's also used to publish to apt.grafana.com
2023-01-19 15:30:05 +00:00
Andrej Ocenas
d8273eeb6b Parca: Use client dependency from buf.dev instead of generated sources (#60969) 2023-01-19 16:26:00 +01:00
Andreas Christou
d50f206677 AzureMonitor: Correctly select template variable values in E2E (#61780)
Correctly select values
2023-01-19 15:21:25 +00:00
linoman
56c2755b3b Fix JWT claims request (#61650)
* Fix JWT claims request

* Add test scenarios for missing config options
2023-01-19 16:03:09 +01:00
Hamas Shafiq
f28a437eb2 Chore: No longer refer to Node Graph as being in beta (#61775) 2023-01-19 14:56:39 +00:00
Alexander Zobnin
60ef88c918 SAML: Support auto login (#61685)
* SAML: Support auto login

* Add individual auto_login option for each OAuth provider

* Docs: Describe new auto_login option

* Minor refactor
2023-01-19 15:53:02 +01:00
Ieva
06350ed887 RBAC: remove the usage of access control mock from preference tests (#61709)
remove the usage of access control mock from preference tests
2023-01-19 14:43:00 +00:00
Torkel Ödegaard
70c17f212f DashList: Use blue link color on hover instead underline (#61282)
* Use blue on hover

* Updated

* Updated
2023-01-19 15:22:11 +01:00
Torkel Ödegaard
9b82e65b7a TablePanel: Refactor to functional component and move add ad hoc filter action to PanelContext (#61360)
* FieldOptions: Add filterable as registry added field item

* Refactor to functional component, move ad hoc filter to PanelStateWrapper

* review tweaks
2023-01-19 14:03:13 +01:00
Ivan Ortega Alba
29f8722c91 PanelChrome: Allow hovering on description when status error is visible (#61757) 2023-01-19 14:01:36 +01:00
Karl Persson
c5c34ed95e RBAC: Rewrite provisioning rbac tests (#61752)
* RBAC: Rewrite rbac provisioning api tests
2023-01-19 13:49:57 +01:00
Sven Grossmann
fd70f6034f Logs: Lines with long words do not break properly (#61707)
really break anywhere
2023-01-19 12:56:44 +01:00
Sven Grossmann
dd8f95a201 Elasticsearch: Fix toggle-settings are not shown correctly (#61751)
* changed `checked` propery to `value`

* revert changing the prop in the event
2023-01-19 12:32:02 +01:00
Alexa V
134ca6bb8f [Panel] Extract styling duplication in new TitleItem component (#61625) 2023-01-19 11:03:56 +00:00
Karl Persson
f38e2856d8 RBAC: Rewrite admin api test setup to not use mocked access control (#61741)
* RBAC: Rewrite admin api test setup to not use mocked access control
2023-01-19 11:36:44 +01:00
Artur Wierzbicki
c4ef47a70e Chore: update CODEOWNERS for edge & multitenancy squads (#61672)
update codeowners
2023-01-19 14:16:14 +04:00
Karl Persson
f5397a7c31 RBAC: Rewrite ldap rbac tests (#61743) 2023-01-19 11:09:26 +01:00
Alexander Weaver
c10713ea76 Alerting: Create query interface for state history along with annotation-based implementation (#61646) 2023-01-19 10:45:31 +01:00
idafurjes
cacc55ba06 Chore: Remove live from models (#61711) 2023-01-19 10:03:14 +01:00
Eric Leijonmarck
0d42edddbf Auth: Add skip_org_role_sync setting to OAuth integration Google (#61572)
* WIP

* Add: skip_org_role_sync for Google OAuth

- add setting for frontend
- add read of config
- add config to sample and default

* add: docs

* spelling

* Update pkg/login/social/social.go

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* removed unnessecary line

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-01-19 09:54:22 +01:00
yusuf-multhan
50df85189c Variables: Allow user to filter values in dropdown using white space (#60622)
Fix #60589
2023-01-19 09:53:14 +01:00
Andres Martinez Gotor
6d9e082f27 Azure Monitor: Adapt ResourceField to multiple resources (#61618) 2023-01-19 09:46:07 +01:00
Sven Grossmann
faf07716ee Loki: Use tsdb index in devenv (#61737)
update loki config to use new TSDB
2023-01-19 09:29:09 +01:00
ismail simsek
29c8ce12a0 Prometheus: Fix handling errors in streaming client (#61643)
* Return errors from data parsing

* Better error handling

* Fix the tests

* When there is no frame add empty frame to get metadata attached to it

* Fix tests

* Update testdata
2023-01-18 22:30:15 +01:00
Yuri Tseretyan
2c46f46d37 Alerting: Rule evaluator to get cached data source info (#61305)
do not skip cache when get data source info
2023-01-18 14:25:11 -05:00
Jean-Philippe Quéméner
44b11d3228 Alerting: support basic auth for the state history loki client (#61696) 2023-01-18 20:24:40 +01:00
Hamas Shafiq
7f4b2fcb9c Chore: Convert VirtualizedTraceView.test.tsx to RTL (#61589)
* Chore: Convert VirtualizedTraceView.test.tsx to RTL

* Don't need to change shared component

Co-authored-by: André Pereira <adrapereira@gmail.com>
2023-01-18 18:13:26 +00:00
Yuri Tseretyan
5e8866ed5a SSE: DSNode to parse only one response (#61644)
* do not iterate through responses
* log type of the response in all exit cases
2023-01-18 13:06:10 -05:00
owensmallwood
593e8ae17c PublicDashboards: Page to request access to protected pubdash (#61329)
Adds page to request pubdash access via email
2023-01-18 11:57:34 -06:00
sam boyer
492bdbd585 Kindsys: Rename mudball to common schemas, allow multiple input cue files (#61703)
* kindsys: Rename mudball to common schemas

* Update all core plugin imports

* Add missed table types

* Remove invalid JSON comment

* Remove coremodel dir from codeowners
2023-01-18 17:40:22 +00:00
Yuri Tseretyan
ef6d73e575 SSE: Resample command to support NoData (#61708)
* add test for nil value
2023-01-18 12:39:38 -05:00
George Robinson
d4256b352d Docs: Rename Message templates to Notification templates (#59477)
This commit renames "Message templates" to "Notification templates"
in the user interface as it suggests that these templates cannot
be used to template anything other than the message. However, message
templates are much more general and can be used to template other fields
too such as the subject of an email, or the title of a Slack message.
2023-01-18 17:26:34 +00:00
Will Browne
c54aa18cd8 Plugins: Add tailored interface for plugins licensing needs (#61045)
* tailored licensing service

* appease linter

* fix

* retrigger
2023-01-18 18:02:54 +01:00
sam boyer
61d8ab71a3 Dashboards: Promote dashboard kind to experimental maturity (#61693) 2023-01-18 11:36:35 -05:00
Ezequiel Victorero
5fb4a7f3b6 PublicDashboards: add timeSettingsEnabled on saving a public dashboard (#61701) 2023-01-18 16:03:41 +00:00
Sofia Papagiannaki
4b634fadcf Chore: Fix Swagger and OpenAPI specifications (#61669)
* Add go-swagger annotations for route

* Re-generate Swagger and OpenAPI specs
2023-01-18 17:49:07 +02:00
Sofia Papagiannaki
b80c9bb974 Chore: Drop dashboard service dependency from folder service (#61614)
* Chore: Drop dashboard dependency from folder service
2023-01-18 17:47:59 +02:00
Christian Simon
a1f2d0e205 Prometheus: Reduce allocations parsing exemplars (#58959)
* Prometheus: Reduce allocations parsing exemplars

This reduces allocations for parsing exemplars.

name            old time/op    new time/op    delta
ExemplarJson-8    24.7ms ±15%    17.6ms ± 2%  -28.72%  (p=0.008 n=5+5)

name            old alloc/op   new alloc/op   delta
ExemplarJson-8    4.70MB ± 0%    3.58MB ± 0%  -23.79%  (p=0.008 n=5+5)

name            old allocs/op  new allocs/op  delta
ExemplarJson-8     72.6k ± 0%     69.1k ± 0%   -4.81%  (p=0.008 n=5+5)

* Ensure pairs is reset
2023-01-18 16:42:22 +01:00
Alexander Zobnin
1fdd3767f1 RBAC: Add permission to get usage report preview (#61570)
* AccessControl: Protect usage report preview endpoint

* Fix role display name

* Change action name

* Fix imports
2023-01-18 16:07:36 +01:00
Josh Hunt
959c89793f Chore: eslint rule for preventing e2e selectors in aria-label (#59731)
* Create eslint plugin/rule for catching e2e selectors in aria-label

* Add no-aria-label-e2e-selectors to betterer

* chore: skip levitate for the `grafana-eslint-rules` package

* Fix rule

* Add readme

* Add Apache 2 license

* Typecheck using @typescript-eslint/utils

* actually export the rule

Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>
2023-01-18 15:02:35 +00:00
Eric Leijonmarck
bedd2304d1 Auth: Fix disable/remove duplicate user entries metrics for performance reasons (#61675)
* fix: remove metrics from duplicate user entries

* fix: disable metrics collection for authinfo

* fix: initifine goroutine loop that happened

* removed: metrics
2023-01-18 16:01:47 +01:00
Serge Zaitsev
fa36591380 Chore: Remove mockstore and use dbtest instead (#61629)
* remove mockstore and use dbtest instead

* fix wire

* remove unused expected fields

* fix more tests in alerting

* fix api tests
2023-01-18 16:01:25 +01:00
Matias Chomicki
89e77d072f Loki Query Builder: Fix bug parsing range params (#61678)
feat(loki-query-builder): fix bug parsing range params
2023-01-18 15:54:18 +01:00
Leonard Gram
d042c0b30b Docs: Renderer token (#59560)
* Docs: renderer token

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/image-rendering/_index.md

* Update docs/sources/setup-grafana/configure-grafana/_index.md

* makes prettier

Co-authored-by: Joan López de la Franca Beltran <joanjan14@gmail.com>
Co-authored-by: Joan López de la Franca Beltran <5459617+joanlopez@users.noreply.github.com>
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
2023-01-18 15:38:16 +01:00
Levente Balogh
4ef82dc73f Connections: Show a "No access" modal if the user has no permissions (#61397)
* feat: add a new modal for displaying no-access info

* feat(CardGrid): add an onClick handler for items

* feat: open a no-access modal when clicking on a connection in the catlog

* feat: update permissions

Open a "No access" modal when the user clicks a connection type but has no permissions creating a datasource out of it

* test: add tests for opening the No Access modal

* test: fix the user permissions in tests

* Wip

* Revert "Wip"

This reverts commit 7f080c7f77.
2023-01-18 15:34:23 +01:00
Hamas Shafiq
58a86133af Chore: Convert ListView/index.test.tsx to RTL (#61590)
* Chore: Convert ListView/index.test.tsx to RTL

* Update .better.results

Co-authored-by: André Pereira <adrapereira@gmail.com>
2023-01-18 14:10:31 +00:00
juanicabanas
18e8d1e28d PublicDashboards: Time range settings (#61585) 2023-01-18 10:54:19 -03:00
Karl Persson
1454b1b40a Reqcontext: Add methods to write responses bases on errutil.Error (#60889)
* ReqContext: Add methods to reqcontext used to handle errutil.Error

* ReqContext: Pass all public field in response from errutil.Error
2023-01-18 14:29:23 +01:00
linoman
4d095547f8 Auth: Implement skip org role sync for jwt (#61647)
* Add new config option

* Add frontend control

* Condition new auth broker with config option

* Condition old auth broker with config option

Co-authored-by: Jo <joao.guerreiro@grafana.com>
Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
2023-01-18 13:59:50 +01:00
Niklas
3debfd0ca7 Transformations: Extract JSON Paths (#59400)
* Added new extractJSONPath transformer
Co-authored-by: Galen <galen.kistler@grafana.com>
2023-01-18 06:59:20 -06:00
idafurjes
b573b19ca3 Chore: Remove dashboards from models pkg (#61578)
* Copy dashboard models to dashboard pkg

* Use some models from current pkg instead of models

* Adjust api pkg

* Adjust pkg services

* Fix lint

* Chore: Remove dashboards models

* Remove dashboards from models pkg

* Fix lint in tests

* Fix lint in tests 2

* Fix for import in auth

* Remove newline

* Revert unused fix
2023-01-18 13:52:41 +01:00
Karl Persson
db0be6bc95 RBAC: fix wildcard check (#61666)
RBAC: break correct loop
2023-01-18 13:19:09 +01:00
Konrad Lalik
9256ca371d Alerting: Landing page v2 (#61600) 2023-01-18 12:40:09 +01:00
Jo
ecafb4dd15 Auth forwarding: Pass tokens without refresh (#61634)
* return only tokens from oauth

* feedback
2023-01-18 10:50:35 +00:00
Sofia Papagiannaki
f25d5199c5 Chore: Fix folder service tests (#61659)
* Chore: Fix folder service tests
2023-01-18 12:22:23 +02:00
Karl Persson
412d80b498 AuthN: Add post auth hook for oauth token refresh (#61608)
* AuthN: rename package to sync

* AuthN: rename sync files

* Ouath: Add mock for OauthTokenService

* AuthN: Implement access token refresh hook

* AuthN: remove feature check from hook

* AuthN: register post auth hook for oauth token refresh
2023-01-18 10:47:09 +01:00
Levente Balogh
29119a7d08 UI/Alert: Infer the role property based on the severity (#61242)
* feat(UI/Alert): add two new optional properties: 'ariaLabel' and 'role'

* docs(UI/Alert): add some docs to the props

* feat: infer the role based on the severity

* fix: stop overriding props

* fix: fix a test depending on the wrong alert role
2023-01-18 10:16:41 +01:00
Sven Grossmann
6c566a391d Loki: Use queries maxLines if configured, even if it is zero (#61652)
* user `query.maxLines` even if it is zero

* remove unnecessary comment
2023-01-18 10:14:42 +01:00
Sven Grossmann
a5d577eca1 Logs: Make no logs found text more visible in Explore (#61651)
* move scan buttons up

* update test
2023-01-18 09:52:18 +01:00
Brendan O'Handley
872df59de5 Prometheus: Kickstart your query, formerly query patterns (#60718)
* add query pattern prom types

* rebase main

* update docs

replace query patterns with kick start your query

* update docs, remove raw query from prom docs

Raw query toggle was removed from the code

* add binary query pattern to query patterns

* add aria labels for accessibility

* fix tests

* apply/create a query pattern behavior if anything exists in the query editor

* fix tests

* rebase main
2023-01-17 20:04:50 -05:00
Santiago
b5fa9e3501 Chore: Fix "manger" typo (#61649)
fix mangers -> managers
2023-01-17 23:13:27 +00:00
Leon Sorokin
7e7daf48f4 Transforms: make partitionByValues create field labels by default (#61255) 2023-01-17 14:56:23 -06:00
Karl Persson
05a683d462 SupportBundles: Fix list response when we don't have any bundles yet (#61619)
* SupportBundles: Return empty slice instead of nil when there are no
support bundles
2023-01-17 21:04:12 +01:00
Alexander Weaver
1ac89ea040 Alerting: Add client configuration for remote Loki historian backend and test connection (#61114)
* Create loki client type and ping method

* Expose TestConnection on client

* Configure and ping Loki URL

* Close response body reader if present

* Add 30 second timeout

* Remove duplicate close
2023-01-17 13:58:52 -06:00
Kristin Laemmert
f6e3252c00 chore: move notifications models into notifications service (#61638) 2023-01-17 14:47:31 -05:00
Erik Sundell
8c826cd785 Cloudwatch: Cleanup resource api (#61465)
Co-authored-by: Isabella Siu <isabella.siu@grafana.com>
2023-01-17 14:27:53 -05:00
Matthew Jacobson
23e05373a7 Alerting: Fix flaky TestIntegrationUpdateAlertRules (#61641)
Prevents random OrgID=0 in test alert generation causing invalid alert rule.
2023-01-17 19:09:46 +00:00
owensmallwood
3fe81b3c3f PublicDashboards: Add share column to public dashboards table (#61102)
Adds share column to public dashboards table
2023-01-17 12:18:12 -06:00
Kristina
6ed7c77516 Explore: Add correlation variables for interpolation (#61008)
* Add correlation variables for interpolation

* Change to only look at relevant field

* Add links ignoring correlation check, add tests

* Add variables for all fields in dataframe, add tests for it, simplify URL expect
2023-01-17 11:12:37 -06:00
Torkel Ödegaard
70f2b01525 Scenes: Cleanups and simplify (#61579)
* Remove use of Scene / Embedded scene

* Use DashboardScene

* Update scenes package

* Updated scenes

* Updated DashboardScene

* Updates

* Updates
2023-01-17 18:02:46 +01:00
Alexander Zobnin
354342ab26 Support Bundles: Improve creating bundle UX (#61611)
* Support Bundles: Improve creating bundle UX

* Refactor create bundle page

* Fix typo

* Don't show loading indicaror after deleting bundle
2023-01-17 17:50:14 +01:00
Alexander Weaver
4f1bdc0607 Alerting: Skip flaky test in TestIntegrationUpdateAlertRules (#61627)
* Skip flaky test

* Add comment
2023-01-17 10:39:16 -06:00
Josh Hunt
daf171820c CommandPalette: Improve section header styling (#61584)
* Add border between command palette sections

* make breadcrumbs secondary text color

* Improve comments
2023-01-17 17:34:40 +01:00
Torkel Ödegaard
8620909006 Table: Fixes broken link styles after recent cell options PR (#61582)
* Table: Fixes broken link styles after recent cell options PR

* Share migration and fix bar gauge as well

* Remove unused import

* Review fixes

* Fixed test

Co-authored-by: Kyle Cunningham <kyle@codeincarnate.com>
2023-01-17 17:08:23 +01:00
Laura Fernández
bb7410aa09 Search: Fix empty folder message showing when by starred dashboards (#61610) 2023-01-17 16:35:54 +01:00
Joey Tawadrous
4076933e66 Traces: extra feature tracking (#61348)
* grafana_traces_service_graph_size

* grafana_traces_trace_view_find_next_prev_clicked

* grafana_traces_trace_view_scroll_to_top_clicked

* grafana_traces_cheatsheet_clicked
2023-01-17 14:43:28 +00:00
ismail simsek
6dcc94ecb2 Prometheus: Add default editor configuration (#61510)
* Add default editor option in Prometheus configuration

* Small readability improvement
2023-01-17 15:39:15 +01:00
Ana Ivanov
24ef778f4d Connect Data: Make search bar sticky (#61529) 2023-01-17 16:13:05 +02:00
ismail simsek
67c02f660a Influxdb: Remove backend migration feature toggle (#61308)
* Remove influxdbBackendMigration feature toggle

* Remove code blocks related to influxdbBackendMigration feature toggle

* Fix annotations

* Remove commented lines

* Fix unit tests
2023-01-17 15:11:26 +01:00
Serge Zaitsev
efed0151f8 Chore: Remove pkg/models/stats.go (#61613)
* remove pkg/models/stats.go

* rename models package in tests
2023-01-17 14:17:54 +01:00
Andres Martinez Gotor
1b86a49622 AzureMonitor: Adapt ResourcePicker and Advanced components to multiple resources (#61605) 2023-01-17 14:11:11 +01:00
Oscar Kilhed
004705a10b Table Panel: Fix image of image cell overflowing table cell when a data link is added. (#59392)
* TablePanel: fix image of image cell overflowing table cell when a data link is added

* Fix image cell and gauge panel in respective places instead
2023-01-17 14:05:58 +01:00
Karl Persson
766fa4e7d5 AuthN: Add last seen sync hooks for user and api keys (#61571)
* AUthN: Add last seen sync hooks for user / service account and move api
key last seen to own hook

* ContextHandler: only run sync for last seen if auth.Service is not
enabled
2023-01-17 13:50:58 +01:00
Hamas Shafiq
ac25913f53 Chore: Convert TimelineViewingLayer.test.tsx to RTL (#61056) 2023-01-17 12:35:36 +00:00
Denis Limarev
e6dee8a723 Perfomance: Preallocate slices (#61580) 2023-01-17 11:50:17 +00:00
Andre Pereira
d2a5b9b289 Tempo: Trace View - Search bar to absolute position instead of sticky (#61324)
* Trace View: Search bar to absolute position instead of sticky

* Fix search bar position to the inside of the trace view panel
2023-01-17 11:42:56 +00:00
Vicky Lee
e7271ee3f1 chore: update CODEOWNERS for Cloud Provider Plugins to Partner Plugins renaming (#61575)
* chore: update CODEOWNERS for Cloud Provider Plugins to Partner Plugins renaming

* chore: update CODEOWNERS for Cloud Provider Plugins to Partner Plugins renaming

* trigger build
2023-01-17 11:16:18 +00:00
Selene
68f1bfa471 Chore: Update ast to dst (#61469)
* Update ast to dst

* Sort imports

* Update thema

* Update pkg/codegen/util_go.go

Co-authored-by: sam boyer <sdboyer@grafana.com>

* Move DecoderCompactor into ApplyFuncs

* Remove unnecessary file

* Use dst decorator

* Downgrade parca-dev library

Co-authored-by: sam boyer <sdboyer@grafana.com>
2023-01-17 11:58:08 +01:00
Jo
9e097c531d SupportBundles: Build tars in memory (#61581)
* build tar in memory

* match tag
2023-01-17 11:39:59 +01:00
Alex Moreno
be72e570cf Fix documentation for notification policy object_matchers (#61602)
* Fix documentation

* Fix grammar

* Update docs/sources/alerting/set-up/provision-alerting-resources/file-provisioning/index.md

Co-authored-by: George Robinson <george.robinson@grafana.com>

Co-authored-by: George Robinson <george.robinson@grafana.com>
2023-01-17 11:37:56 +01:00
Ieva
cd363cb037 RBAC: remove access control mock from org quota tests (#61574)
* remove ac mock from org quota tests

* fix incorrect expected status code and swap tests to make setup easier

* remove empty line
2023-01-17 10:33:01 +00:00
Sonia Aguilar
04b5e6ed9e Alerting: Fix group select not being filled by selected folder when creating alert from panel (#61577)
Add fetchRulerRulesIfNotFetchedYet fetching when results are an empty object
2023-01-17 11:16:54 +01:00
Ieva
9a8c798bae Docs: add missing plugin roles, actions and scope (#61182)
* add missing plugin roles, actions and scope

* Update docs/sources/administration/roles-and-permissions/access-control/custom-role-actions-scopes/index.md

Co-authored-by: Alyssa Wada <101596687+alyssawada@users.noreply.github.com>

* Update docs/sources/administration/roles-and-permissions/access-control/custom-role-actions-scopes/index.md

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>

Co-authored-by: Alyssa Wada <101596687+alyssawada@users.noreply.github.com>
Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
2023-01-17 10:03:31 +00:00
Ieva
f44bc0dd6b RBAC: use scope reduction for user permission listing (#61583)
use scope reduction for user permission listing
2023-01-17 09:58:40 +00:00
Victor Marin
b5383b7d05 Barchart: Fix erroneous tooltip value (#61455)
Fix Barchart tooltip value issue
2023-01-17 11:30:30 +02:00
Karl Persson
b44b6fc5c6 AuthN: Add auth proxy client (#61555)
* AuthN: set up boilerplate for proxy client

* AuthN: Implement Test for proxy client

* AuthN: parse accept list in constructor

* AuthN: add proxy client interface

* AuthN: handle error

* AuthN: Implement the proxy client interface for ldap

* AuthN: change reciever name

* AuthN: add grafana as a proxy client

* AuthN: for error returned

* AuthN: add tests for grafana proxy auth

* AuthN: swap order of grafan and ldap auth

* AuthN: Parse additional proxy headers in proxy client and pass down
2023-01-17 10:07:46 +01:00
Torkel Ödegaard
c1d3b59643 PanelChrome: Simplify props and code a bit (#61595)
* PanelChrome: Simplify props and code a bit

* Don't set a default empty array for leftItems so we can know user has set it

* fix 'this' is undefined

* add storybook examples of statusMessage; remove SB examples of loadingState === Error; simplify loadingState checks in PanelChrome;

Co-authored-by: polinaboneva <polina.boneva@grafana.com>
2023-01-17 09:52:14 +01:00
Gareth Dawson
54fd1b634f Loki: Show configured log line limit (#61291)
* feat: show configured line limit

* test: correct failing test

* refactor: update variable names

* fix: ui renders the wrong value given a falsy value

* refactor: use nullish coalescing operator
2023-01-17 08:45:23 +00:00
Karl Persson
2324597d8d AuthN: Perform login with authn.Service (#61466)
* AuthN: Create password client wrapper and use that on in basic auth
client

* AuthN: fix basic auth client test

* AuthN: Add tests for form authentication

* API: Inject authn service

* Login: If authnService feature flag is enabled use authn login

* Login: Handle token creation errors
2023-01-17 09:11:45 +01:00
Selene
0d70eb18ac Dashboards: Add org_id in dashboards query (#61542)
* Add org_id in dashboards query

* Update OrgID

* Remove unused orgid
2023-01-16 21:59:43 +01:00
Josh Hunt
665f85cd7e CommandPalette: Minor usability improvements (#61567) 2023-01-16 18:33:46 +00:00
Andreas Christou
f135c6cbf1 Cloudmonitor: Refactor query builder (#61410)
* Reset filters when service is changed

* Update to reset any query props

* Reset query properties on metric change

* Update tests

* Refresh labels on panel time update

* Review

* Refactor VisualMetricsQueryEditor

- Move any Metrics functionality to VisualMetricsQueryEditor
- Update tests
- Expose timeSrv from datasource
- Update getLabels to make use of provided timeRange

* Review
2023-01-16 17:57:12 +00:00
Torkel Ödegaard
021eda7aad Scenes: Skip instance of check as it it does not work for apps (#61576)
* Scenes: Skip instance of check as it it does not work for apps

* remove logging
2023-01-16 18:01:31 +01:00
Andres Martinez Gotor
7a026d90e9 AzureMonitor: Set multiple resources for Logs (#61545) 2023-01-16 17:47:27 +01:00
Jo
6fec8fda39 AuthN: Clean errors in user/org sync (#61560)
* clean errors in user/org sync

* lower logging level for non 5xx errors
2023-01-16 16:37:04 +00:00
Sven Grossmann
82d8b2036f Logs: Add possibility to download logs in JSON format (#61394)
* add implementation of `logRowsToReadableJson`

* add test for logRowsToReadableJson

* add json, txt download buttons

* changed downloadmenu to `Menu`

* set closed state when menu closes

* removed unused css

* removed unused imports

* remove isOpen state

* remove unused import

* add tests

* remove untouched file
2023-01-16 17:20:19 +01:00
Alexa V
0eeeeef08b PanelChrome: Refactor and refine items next to title (#60514)
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
Co-authored-by: Polina Boneva <13227501+polibb@users.noreply.github.com>
Co-authored-by: polinaboneva <polina.boneva@grafana.com>
2023-01-16 15:56:39 +00:00
Gareth Dawson
8ae4b9060b Elastic: Change elastic version 8.0+ to be more accurate (#61379)
fix: change elastic version 8.0+ to be more accurate
2023-01-16 15:54:40 +00:00
Esteban Beltran
4454d5eb49 Build: Fix eslint in file (#61568) 2023-01-16 15:42:02 +00:00
idafurjes
7c2522c477 Chore: Move dashboard models to dashboard pkg (#61458)
* Copy dashboard models to dashboard pkg

* Use some models from current pkg instead of models

* Adjust api pkg

* Adjust pkg services

* Fix lint
2023-01-16 16:33:55 +01:00
Eric Leijonmarck
07bbc0716c Auth: Fix correct error for updateapikey in context handler (#61544)
* fix: correct error for updateapikey

* refactor: send the correct err forward

* update: based on review
2023-01-16 15:16:06 +01:00
Alexander Zobnin
997105c20d Config: Support JSON list syntax (#61288)
* Config: Separate lists either by spaces or by commas.

* Simplify space separation

* use separate function for the config strings

* Change behavior only if string contains quotes

* add test for invalid string

* Use JSON list syntax

* ignore leading spaces when process list

* Add notes about using JSON lists into the docs

* Fix typo

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-01-16 16:03:20 +03:00
Tania
045a12047f Codegen: Generate per-kind reference docs (#60416)
* Add docs generator

* Add json-to-md conversion

* Fix lint issues

* Remove check for kind type

* Disable prettier for generated docs

* Use schema ref names as identifiers for links & headers

* Display the default value (if so) in the description

* Undo 'draft:false' introduced by mistake

* Update pkg/codegen/jenny_docs.go

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>

* Undraft and unlist kinds documentation  (#61476)

* Support running containers without root daemon

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Use section shortcode to automatically list child pages

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Undraft and unlist kinds documentation

This page and child pages are directly accessible but are not listed
in the table of contents.

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Add docs-preview to browse drafted pages

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Replace end of line and pipe characters in table codegen

* Remove draft status from generated docs

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
Co-authored-by: Joan López de la Franca Beltran <joanjan14@gmail.com>
Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
Co-authored-by: Robert Horvath <robert.horvath@grafana.com>
2023-01-16 13:55:40 +01:00
bobemoe
59df361087 Public Dashboards: Docs: add ENV method to enable (#60412)
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-01-16 09:26:05 -03:00
Eric Leijonmarck
c5e74ee607 Auth: Add skip_org_role_sync for AzureAD OAuth (#60322)
* [WIP] Auth: add backend skipOrgRoleSync to AzureAD OAuth

- add: skipOrgRoleSync
- rename: skipOrgRoleSync to skipOrgRoleSyncBase (to make it clear that
  it is the base version of SocialBase)
- add: tests for skipOrgRoleSync in AzureAD

TODO:
- [ ] frontend changes

* add: docs

* refactor: remove role from basicinfo

* add: settings for grafanacom

* add: settigns for frontend

* add: logic for azureAD user skip org role

* add: docs for skip_org_role_sync

* refactor: docs a bit

* add: tests for userinfo

* refactor: to only extract if skiporgrolesync false

* refactor: based on review comments

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-01-16 13:16:01 +01:00
Matias Chomicki
7e505ea49c Loki Autocomplete: Suggest only possible labels for unwrap (#61411)
* feat(loki-autocomplete): filter valid labels for unwrap autocomplete suggestions

* refactor(unwrap): reuse new function in builder
2023-01-16 13:07:02 +01:00
Serge Zaitsev
7e51eac740 Chore: Remove unused models (#61533)
* Chore: Remove unused models

* put AuthModuleConversion back
2023-01-16 12:52:55 +01:00
renovate[bot]
0d513224af Update dependency @lezer/lr to v1.3.1 (#61341)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-01-16 12:46:42 +01:00
Jo
be3b81fecd AuthN: Readd user protection service to user sync (#61534)
* add user protection service to user sync

* fix tests
2023-01-16 11:15:14 +00:00
Jo
dcfeab2c73 AuthN: User Quota (#61540)
* remove reqContext from quota checks in login

* add guards for nil ScopeParams
2023-01-16 11:54:15 +01:00
Andres Martinez Gotor
a4c2237d16 AzureMonitor: Add region to the resource info (#61504) 2023-01-16 11:26:56 +01:00
Hamas Shafiq
1b6c0d9752 Chore: Convert ViewingLayer.test.tsx to RTL (#61358) 2023-01-16 10:25:47 +00:00
Victor Marin
43ca4e0bc7 Fix Barchart legend aligning right when orientation is horizontal (#61451) 2023-01-16 12:09:20 +02:00
Misi
b8b08ea292 Auth: Add sub claim check to JWT Auth pre-checks (#61417)
* Auth: Add sub claim check to JWT Auth pre-checks

* Add #nosec annotation to the test tokens
2023-01-16 10:50:34 +01:00
Andres Martinez Gotor
e481673b77 AzureMonitor: Use list of resources for metrics (#61485) 2023-01-16 09:49:35 +01:00
Torkel Ödegaard
8f37295b02 Scenes: Panel repeater change (#61302)
* Update scene panel repeater by change in scenes package

* Use latest scenes package

* Fix package.json

* lock update

* Fix lock

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
2023-01-14 09:30:43 +01:00
Yuri Tseretyan
9d57b1c72e Alerting: Do not persist noop transition from Normal state. (#61201)
* add feature flag `alertingNoNormalState`
* update instance database to support exclusion of state in list operation
* do not save normal state and delete transitions to normal
* update get methods to filter out normal state
2023-01-13 18:29:29 -05:00
Yuri Tseretyan
12d27edb52 Alerting: Update alerting package rerefence to the last commit (#61515) 2023-01-13 17:28:44 -06:00
Ghazanfar
d553a016cc Alerting: UI changes required to support v3 and Auth in Kafka Contact Point (#61123) 2023-01-13 17:45:43 -05:00
Alexander Weaver
b289b8ac6e Alerting: Set error annotation on EvaluationError regardless of underlying error type (#61506)
Set error annotation regardless of underlying error type
2023-01-13 13:58:02 -06:00
Erik Sundell
432cdbade4 Cloudwatch: Add support for template variables in new log group picker (#61243) 2023-01-13 14:03:08 -05:00
Timur Olzhabayev
b34377a0ef Chore: Making community support owners of issue triage doc (#61323)
Making community support owners of issue triage doc
2023-01-13 19:29:09 +01:00
Joey Tawadrous
483ca71621 Docs: Update trace to logs docs (#61099)
* Extend trace to logs docs

* Update docs text

* Update trace to logs tag types format

* adjusts formatting of unorderedlist

* adjusts formatting, adds intro to table

* Update docs/sources/datasources/zipkin/_index.md

Co-authored-by: Joey Tawadrous <90795735+joey-grafana@users.noreply.github.com>

* added table intros

Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-01-13 11:22:34 -06:00
Brendan O'Handley
6be341d505 Prometheus: Add query tracking (#61004)
* merge fix

* remove comments from debugging
2023-01-13 12:13:52 -05:00
gotjosh
e7cd6eb13c Alerting: Use alerting.GrafanaAlertmanager instead of initialising Alertmanager components directly (#61230)
* Alerting: Use `alerting.GrafanaAlertmanager` instead of initialising Alertmanager components directly
2023-01-13 12:54:38 -04:00
Joey Tawadrous
58c4c95e92 Tempo: dashboard feature tracking (#61210)
* grafana_tempo_dashboard_loaded

* Update version

* Updates

* Added more tracking stats + updates
2023-01-13 16:31:44 +00:00
Robby Milo
98cadb3aa0 update docs docker image reference (#61269)
* update docs docker image
* remove command
2023-01-13 17:19:23 +01:00
Sven Grossmann
5fe23b4964 Loki: Track obfuscated query (#61325)
* obfuscate query

* also conver numbers and comments

* query obfuscation: simplify obfuscation and keep some identifiers

* Query obfuscation: replace placeholder string with node name

Co-authored-by: Matias Chomicki <matyax@gmail.com>
2023-01-13 16:16:47 +00:00
Ryan McKinley
ce3a96abec Search: Auto focus input elements (#61443) 2023-01-13 16:01:47 +00:00
Brendan O'Handley
370272e57e Documentation: Update prometheus getting started doc (#60803)
* update prom getting started doc

* fix md

* Update docs/sources/getting-started/get-started-grafana-prometheus.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/getting-started/get-started-grafana-prometheus.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/getting-started/get-started-grafana-prometheus.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/getting-started/get-started-grafana-prometheus.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/getting-started/get-started-grafana-prometheus.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/getting-started/get-started-grafana-prometheus.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/getting-started/get-started-grafana-prometheus.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* update doc with image

* use multiple tasks template structure from writers toolkit

* fix image title

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-01-13 10:38:20 -05:00
Alex Khomenko
3569045dfc Admin: Update the order of nav items (#61497)
* Admin: Change order of the nav items

* Admin: Update order
2023-01-13 17:27:26 +02:00
Michael Mandrus
9dc081e629 SMTP: Update SMTP TemplatesPatterns to do an 'or' filter instead of 'and' (#61421)
update template path parsing to use 'or' logic instead of 'and'
2023-01-13 10:24:22 -05:00
renovate[bot]
2cadcd5aeb Update dependency eslint-config-prettier to v8.6.0 (#61413)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-01-13 14:55:08 +00:00
TaitChan
a1d33c63c8 Internationalization: Translate page headers and Search dashboard actions (#60727)
* Fix: PageHeader & PageHeaderTabs & NavBarItem & DashboardActions & PanelMenu is displayed in default_language (#60719)

* I18N: update strings (#60719)

Co-authored-by: TaitChan <1441645821@qq.coom>
2023-01-13 14:33:42 +00:00
Gábor Farkas
ed88401a58 logs: json/logfmt-detection, simplify code (#61492)
* logs: json/logfmt: simplify code

* remove obsolete comment

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

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
2023-01-13 14:33:18 +00:00
Josh Hunt
9b10f6c7dd CommandPalette: Fix long dashboard names freezing the browser (#61278)
* CommandPalette: Use custom useMatches to avoid perf issues with long names

* wip start to multi search

* use search permutations, and do substring match if search is over 25 chars

* update ufuzzy

* don't permute query if greater than 5 words
2023-01-13 14:16:16 +00:00
gotjosh
8f72893076 Alerting: Document not supporting inhibition rules (#61313)
* Alerting: Document not supporting inhibition rules

* Update docs/sources/alerting/manage-notifications/create-silence.md

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>

* Update docs/sources/alerting/manage-notifications/alertmanager.md

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
2023-01-13 15:06:06 +01:00
Joey Tawadrous
2b6a5e2b3d Tracing: Span link feature tracking (#61022)
* Span link feature tracking

* Update interaction name
2023-01-13 14:02:25 +00:00
Jan Garaj
28dbbe9f5f CloudWatch: Add CloudWatchSynthetics dimension (#60832) 2023-01-13 14:56:29 +01:00
Sven Grossmann
b3f28dea71 Logs: Change detected to selected label (#61487)
change `detected` to `selected`
2023-01-13 13:36:45 +00:00
Sven Grossmann
b816538e09 Loki: Fix misaligned derived fields settings (#61475)
* fix loki datasource settings

* remove unnecessary spacing

* remove unused import
2023-01-13 14:25:03 +01:00
Gábor Farkas
117874176d logs: removed unused code (#61484) 2023-01-13 14:11:57 +01:00
Sonia Aguilar
fb5a033282 Alerting: use SupportedPlugin.OnCall detecting OnCall types as a single source of truth (#61473)
Use SupportedPlugin.OnCall detecting OnCall types as a single source of truth
2023-01-13 13:34:39 +01:00
Ashley Harrison
da969e7d48 Command Palette: don't register dashboards as actions in the command palette (#61271)
* don't register dashboards as actions in the command palette

* create ActionImpls in RenderResults, memoize some array creation

* extract dashboard results out into separate hook

* remove unnecessary memoization from useActions

* move useDashboardResults into dashboardActions
2023-01-13 11:41:23 +00:00
Jack Baldry
017d4f2cbb Pin doc-validator image version to allow repository to opt in to breaking changes (#61456)
Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2023-01-13 11:40:30 +00:00
Ryan Cole
37a0afe136 Docs: Fix links to default_template.go in alert template reference file (#61340)
Docs: Fix links to `default_template.go` alert template reference file
2023-01-13 11:32:45 +00:00
Andres Martinez Gotor
f6e735cd29 AzureMonitor: Keep resource in the URL for single requests (#61414) 2023-01-13 12:30:45 +01:00
renovate[bot]
55ec0c1c49 Update dependency chrome-remote-interface to v0.32.0 (#61448)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-01-13 11:05:26 +00:00
renovate[bot]
be04096366 Update dependency core-js to v3.27.1 (#61342)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-01-13 12:03:24 +01:00
Joao Silva
cdd0a2d228 Navigation: Add close button to dashboard settings (#61366) 2023-01-13 11:50:35 +01:00
Andriy
2baf967ff1 fix: Fix flattening queries with null values (#61380) 2023-01-13 10:37:29 +01:00
Torkel Ödegaard
a5eb858d53 PanelChrome: Slight design improvements to menu button (#61399)
* PanelChrome: Slight design improvements to menu button

* Switch to narrow ToolbarButton

* Updated test

* removed unused import
2023-01-13 10:35:02 +01:00
Ieva
e543c10e25 RBAC: Remove RBAC mock from plugin installation tests (#61416)
remove ac mock from plugin installation tests
2023-01-13 09:34:20 +00:00
Karl Persson
0d572ff2ce AuthN: Add check for disabled identities (#61382)
* AuthN: return error if identity is disabled

* AuthN: Remove isDisabled check in client

* AuthN: Format imports
2023-01-13 10:28:50 +01:00
Karl Persson
b5255ebfdf RBAC: Update org rbac tests to not use mocked access control (#61211)
* API: Rewrite legacy access control and rbac tests for current org
endpoint

* API: Rewrite legacy and rbac endpoint tests for update current and
target org

* API: rewrite access control tests for create org

* API: Rewrite delete org api access control tests

* API: rewrite search org access control tests to not use mocked access
control

* API: Rewrite get org and get org by name access control tests to not use
mocked access control


Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
2023-01-13 10:22:32 +01:00
Armand Grillet
331fa686e0 Preferences: Changed 'Edit profile' to 'Profile' (#61376)
* Changed 'Edit profile' to 'Profile'

The profile is not always editable, e.g. when it is synec via OAuth,
and all the other sections of the preferences are titled without a
verb.

* Fix frontend test
2023-01-13 09:59:11 +01:00
idafurjes
490a787d9d Chore: Move tem member models to team pkg (#61294)
* Chore: Move tem member models to team pkg

* Fix test lint
2023-01-13 09:43:38 +01:00
Levente Balogh
b8aaf85fdc Levitate: Only run against the main branch (#61401)
chore: only run Levitate against the main branch
2023-01-13 09:43:09 +01:00
renovate[bot]
db894ac383 Update dependency eslint to v8.31.0 (#61412)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-01-13 09:04:53 +01:00
KonH
4421b31b66 Loki/Prometheus: Change signature - return non-reference from ReadPrometheusStyleResult (#57209)
* Change signature - return non-reference from ReadPrometheusStyleResult

Related to https://github.com/grafana/grafana/issues/52430

* Fix invalid reference usage

* Potential fix for test data

* Remove additional ref usage

* Revert "Potential fix for test data"

This reverts commit 94ed588ab3.

* Commit changed test data

* Revert unwanted conflict resolution

* Add additional condition to track empty responses

* Setup valid empty response

* Re-introduce changes reverted by merge
2023-01-13 09:00:39 +01:00
Alex Khomenko
078f2d4481 Admin: Remove navigation subheaders (#61344)
* Admin: Remove navigation subheaders

* Admin: Fix tests
2023-01-13 08:32:09 +02:00
Yuri Tseretyan
8e4922f02f Chore: Update alerting to the head of the main (#61437) 2023-01-12 22:35:19 -05:00
Nathan Marrs
b1a24232e4 Canvas: Add support for basic arrows (#57561)
Co-authored-by: Ryan McKinley <ryan.mckinley@grafana.com>
Co-authored-by: Adela Almasan <adela.almasan@grafana.com>
Co-authored-by: Drew Slobodnjak <drew.slobodnjak@grafana.com>
2023-01-13 02:38:00 +00:00
Ryan McKinley
0c20fe0ac9 EntityAPI: Include folder support and watch API stubs (#61338) 2023-01-13 00:39:36 +00:00
Ryan McKinley
da3f02d81b Schema: Add TimeZone to mudball (#61003) 2023-01-12 14:54:02 -08:00
Brendan O'Handley
245a589336 Angular: Remove ngInject from influxdb and graphite (#61251)
remove ngInject from datasources
2023-01-12 17:14:18 -05:00
Giordano Ricci
1e33e56dbd Explore: Unsync time ranges when a pane is closed (#61369)
* Explore: Unsync time ranges when a pane is closed

* remove unintentional import
2023-01-12 20:59:35 +00:00
Piotr Jamróz
e8ef0395b1 Glue: Hide run queries button in Correlations Page (#61039)
* Hide run queries button in Correlations Page when showing Loki and Prometheus editors

* Use more semantic selectors

Co-authored-by: Giordano Ricci <me@giordanoricci.com>

* Use more semantic selectors

Co-authored-by: Giordano Ricci <me@giordanoricci.com>

* Post-merge fix (remove duplicate)

Co-authored-by: Giordano Ricci <me@giordanoricci.com>
2023-01-12 21:14:55 +01:00
gotjosh
49ae1bbe63 Introduce AlertingConfiguration that implements alerting.Configuration (#61427)
* Introduce `AlertingConfiguration` that implements `alerting.Configuration`
2023-01-12 16:03:07 -04:00
gotjosh
fd6f107ded Alerting Unification: Use the errors from grafana/alerting in Alerts (#61425) 2023-01-12 15:23:34 -04:00
Sonia Aguilar
24c3c3a0ef Alerting: Use pluginBridge to check if plugin is installed (#61356)
* Use getPluginSettings (/api/plugins//settings) to check if plugin is installed

* Use usePluginBridge hook instead of getPluginSettings to check if plugin is installed
2023-01-12 19:52:36 +01:00
gotjosh
ddb85ad6ad Use the ClusterPeer interface from grafana/alerting (#61409)
* Use the Cluster interface from grafana/alerting
2023-01-12 14:47:22 -04:00
Artur Wierzbicki
23dbc916e8 Live: Fix Subscription to the channel already exists live streaming error (#61406)
#60570: Fix `subscription to the channel already exists`
2023-01-12 21:55:01 +04:00
Gilles De Mey
6b620c79e0 Alerting: Fix flakey silence test (#61395) 2023-01-12 14:32:25 -03:00
chrisharbro
447e56b557 Fix typos (#61318)
Redis was called Rediss twice, this was the source of some confusion.
2023-01-12 10:31:55 -06:00
gotjosh
2d1faae0b5 Alerting Unification: Use alerting.MaintenanceOptions to configure silences and nflog (#61384) 2023-01-12 12:31:38 -04:00
Andres Martinez Gotor
9055e1993d AzureMonitor: API support for multiple resources (#61315) 2023-01-12 17:25:13 +01:00
gotjosh
6822298953 Update grafana/alerting to the latest main (#61407) 2023-01-12 11:56:32 -04:00
Gábor Farkas
57425234c9 elastic: backend: removed unused time-field (#61362)
* elastic: backend: removed unused time-field

* improve comment formatting

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

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2023-01-12 15:52:32 +00:00
Eric Leijonmarck
91322bebb5 Auth: Add skip_org_role_sync setting for GrafanaCom (#60553)
* add frontend settings and setting for grafanacom

* removed println

* add skip-org-role-sync on login

* add deprecation notice for this field

* remove println

* remove newline

* change and renamed variables

* fix for reconfiguring the settings for grafanacom

* add documentationf or grafanacom setup

* WIP tests

* added tests

* Update docs/sources/setup-grafana/configure-security/configure-authentication/grafana-com/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-security/configure-authentication/grafana-com/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-security/configure-authentication/grafana-com/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-security/configure-authentication/grafana-com/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-security/configure-authentication/grafana-com/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-security/configure-authentication/grafana-com/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-security/configure-authentication/grafana-com/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-security/configure-authentication/grafana-com/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* updated steps

* Update docs/sources/setup-grafana/configure-security/configure-authentication/grafana-com/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-security/configure-authentication/grafana-com/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* doc: updated the docs to reflect what happens to grafana.com users

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Jo <joao.guerreiro@grafana.com>

* Update docs/sources/setup-grafana/configure-security/configure-authentication/grafana-com/index.md

Co-authored-by: Jo <joao.guerreiro@grafana.com>

* Update docs/sources/setup-grafana/configure-security/configure-authentication/grafana-com/index.md

Co-authored-by: Jo <joao.guerreiro@grafana.com>

* add blankline

* rephrase of doc improvements for explaing of the settings

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Jo <joao.guerreiro@grafana.com>

* add frontend setting for grafanacom.

* WIP tests

* refactor docs

* frontend to adhere to skipping org role sync for GrafanaCom users

* update docs to reflect desired behavior

* tests: added test for skip and nonskip

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Jo <joao.guerreiro@grafana.com>
Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
2023-01-12 16:44:08 +01:00
Ron D
e7b8b82c14 Correct invalid groups_attribute_path option + added details for nested groups (#61202)
* Correct invalid groups_attribute_path option + added details for nested groups

* Update docs/sources/setup-grafana/configure-security/configure-authentication/keycloak/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* linting

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: IevaVasiljeva <ieva.vasiljeva@grafana.com>
2023-01-12 14:41:30 +00:00
Ieva
bc75ee1392 Docs: OnCall role and action definitions (#61175)
* OnCall role and action definitions

* change verbs from write to update or edit

* Update docs/sources/administration/roles-and-permissions/access-control/rbac-fixed-basic-role-definitions/index.md

Co-authored-by: Joey Orlando <joseph.t.orlando@gmail.com>
2023-01-12 08:40:19 -06:00
malcolmholmes
3a1cf11055 Schema: Fix iterator for MajorsOrX (#61363) 2023-01-12 09:39:23 -05:00
Jack Westbrook
46228813e4 Chore: Refresh yarn lock file (#61385)
chore(yarn): refresh lock file
2023-01-12 14:37:43 +00:00
Ieva
37859668e6 Chore: update lockfile (#61381)
update lockfile
2023-01-12 14:31:59 +00:00
Gilles De Mey
11a8628381 Alerting: Improve incident button (#61372) 2023-01-12 15:30:31 +01:00
gotjosh
39e429a14b Alerting Unification: Use the errors from grafana/alerting in Silences (#61334) 2023-01-12 10:03:49 -04:00
Karl Persson
3e8857acb8 AuthN: Post login hooks (#61287)
* AuthN: add the ability to register post login hooks

* AuthN: add a guard for the user id

* AuthN: Add helper to create external user info from identity

* AuthN: Pass auth request to password clients

* AuthN: set auth module and username in metadata
2023-01-12 15:02:04 +01:00
Jack Westbrook
4b13a5a9ab Chore: Bump loader-utils to 2.0.4 and 3.2.1 (#60505)
chore: patch bump loader-utils to 2.0.4 and 3.2.1
2023-01-12 14:42:37 +01:00
Gareth Dawson
51c30ba22d Elastic: Remove experimental tag from v8.0+ (#61359)
* docs: remove experimental tag from v8.0+

* feat: remove experimental description from es version config
2023-01-12 12:23:31 +00:00
Andre Pereira
62633ba4a7 Tempo - Replace slate with monaco editor in search tags field (#61168)
* Recreate the tempo search tags field with monaco editor instead of slate

* Remove test file no longer needed
2023-01-12 12:06:28 +00:00
Kyle Cunningham
80e7f54166 Table Panel: Refactor Cell Options to Allow for Options per Cell Type (#59363)
* Update table data structure schema.

* Update table panel configuration options for new structure

* Fix TS errors from refactor

* Separate background and gauge display modes

* Remove the now used Bar Gauge display from the mud

* Fix types up

* Reorganize data structures

* Fix type issues.

* Start stubbing necessary code.

* Continue implementing option refactor

* Change category for cell type selection.

* Consolidate cell options

* Fix various typing issues

* Clean up dead code

* Stub handling display mode changes

* Make subOption editor dynamic

* Setup interface for sub-option editor props

* Remove unused imports

* Remove console.log call

* Persist display mode changes, stub sub options change, update comments.

* Make sure updates from cells are persisted

* Persist sub-option changes

* Update BarGaugeCell to take into account new settings.

* Add deprecated field back

* Remove unecessary options in configuration

* Update default cell to accept new settings

* Make sure color text display works

* Add deprecated property notice

* Use constant as opposed to string

* Make sure we name globally namespaced things uniquely

* Update to use unique name

* Use union type with discriminator.

* Simplify types and operation

* Update type definitons

* Update types

* Update property names in cells

* Remove React.FC usage

* Update option editor signature

* Update options structure

* Change variable name

* Fix "Color Text" display

* Remove debug statement

* Make sure we remain backwards compatible with display mode.

* Add migration for configuration.

* Export BarGaugeDisplayMode from grafana-ui

* Update import

* Fix bar gauge and dashboard migrator tests

* Fix potential undefined references causing test failures

* Fix another potential reference error in DefaultCell

* Try to fix breaking change detection.

* Cache setting changes

* Make sure we return with onChange invocation

* Fixed migrating overrides

* Fix a number of review comments

* Simplify option editors

* Fix unused imports

* Fill out comments for types

* Actually use defaultPanelConfig for editor default

* Move TableCellEditorProps alongside TableCellOptionEditor

* Update docs for table panel

* Also make sure we remove TableCellEditorProps from model file

* Stub migration tests

* Add tests for default config migration

* Add basic overrides test

* Flesh out tests a bit more

* Add inspect to same category as cell editor

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2023-01-12 18:42:57 +07:00
Jan Garaj
d5da42bbbc CloudWatch: Add RDS dimension (#61027) 2023-01-12 11:47:12 +01:00
Sonia Aguilar
f2d4e24710 Alerting: improve FolderPicker and Evaluation Group Select for Huge lists (#61221)
* Add AsyncVirtualizedSelect component in grafana-ui

* Slice FolderPicker results to 1k and virtualize list using AsyncVirtualizedSelect

* Group list in alert form: Use AsyncSelect and slice results to 1000

* Virtualize and slice always in FolderPicker: set default sliceResults value and let consumers change this value

* Always slice results in FolderPicker

* Limit folder results setting the limit in the api call instead slicing in the FE

* Remove warning about the limit in the Select label
2023-01-12 11:45:03 +01:00
Laura Benz
9400ccf478 Glue: Validate target query in correlations page (#57245)
* feat: add draft version of validate button

* feat: add some styling and basics

* temp: intermediate result

* refactor: solve TODOs

* refactor: replace string in state

* refactor: replace error message style

* refactor: set validate state on change in ds

* refactor: add QueryRunner

* refactor: add QueryRunner

* temp: temporary status

* Emit PanelData to check if the query is valid

* refactor: clean up

* refactor: improve a11y of error message and adjust test

* Remove deprecated property call, change equality

* refactor: add changes from code review

* refactor: remove memory leak

* refactor: replace query runner

* refactor: adjust error handling

* refactor: move testing to related unit test

* refactor: clean up test for QueryEditorField

* refactor: clean up test for CorrelationsPage

* refactor: repair test

* refactor: clean up

* refactor: add refId in order avoid errors when running Loki queries

* refactor: replace buildQueryTransaction + set query to invalid if query is empty

* refactor: add empty query value to test cases

* refactor: end handleValidation after setIsValidQuery()

* refactor: refactor test

* refactor: fix last two tests

* refactor: modify validation

* refactor: add happy path

* refactor: clean up

* refactor: clean up tests (not final)

* refactor: further clean up

* refactor: add condition for failing

* refactor: finish clean up

* refactor: changes from code review

* refactor: add response state to condition

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

* refactor: fix prettier issue

* refactor: remove unused return

* refactor: replace change in queryAnalytics.ts

* refactor: remove correlations from query analytics

* refactor: remove unnecessary test preparation

* refactor: revert changes from commit 4997327

Co-authored-by: Piotr Jamróz <pm.jamroz@gmail.com>
Co-authored-by: Kristina Durivage <kristina.durivage@grafana.com>
2023-01-12 11:43:40 +01:00
ismail simsek
321acca59f Prometheus: Send separate queries when the query type both selected (#60928)
Send separate queries when the query type both selected
2023-01-12 11:23:29 +01:00
Jan Garaj
056d5df285 CloudWatch: Add MaxProvisionedTableReadCapacityUtilization AWS/DynamoDB metric name (#60829) 2023-01-12 11:07:25 +01:00
Matias Chomicki
c506df3809 Log Row Context: disable false a11y postive (#61312)
Chore: disable false a11y postive
2023-01-12 10:06:54 +00:00
Sven Grossmann
9fa98dbbca Logs: Fix alginment of meta items (#61349)
fix items to be center
2023-01-12 10:42:28 +01:00
linoman
8ba5f59fb7 Promote openldap-mac (#61332)
* Replace `openldap` with `openldap-mac`

* Rename all references for `openldap-mac`

* Rename prepopulated users with first names
2023-01-12 10:20:01 +01:00
ying-jeanne
7339dbc090 Chore: Refectory of shorturl service, move models into service (#61295)
Chore: refectory of shorturl service, move models into service
2023-01-12 17:13:47 +08:00
Polina Boneva
84eb275c8d PanelChrome: Menu is wrapped in a render prop for full outside control (#60537)
* setup menu as a render prop sent down from PanelStateWrapper to PanelChrome

* let the Dropdown take care of opening the menu in PanelChrome

* menu and leftItems are on the right side of the header together

* add storybook examples with menu

* menu does not need to be a callback because it's opened in a Dropdown anyway

* pass down to getPanelMenu whether or not data is streaming atm

* stop loading data as well as streaming from menu

* override menu's style where needed

* reduce snapshot matching in tests
2023-01-12 11:10:09 +02:00
gotjosh
f85a948214 Alerting Unification: Use the State interface from the alerting package (#61333) 2023-01-11 19:50:45 -04:00
Torkel Ödegaard
7eaa95729c PluginsList: Improve layout for smaller screens (#61234)
* PluginsList: Improve layout for smaller screens

* fix test

* not sure if this will fix it

* fix
2023-01-11 23:14:57 +01:00
Ezequiel Victorero
34a865ebf0 PublicDashboards: remove publicDashboardUID from insights event request (#60649) 2023-01-11 18:25:18 -03:00
Christopher Moyer
b3272fe62c Docs: clarifies table view (#61320)
* clarifies table view

* Update docs/sources/panels-visualizations/panel-editor-overview/index.md

Co-authored-by: Sarah Zinger <sarah.zinger@grafana.com>

Co-authored-by: Sarah Zinger <sarah.zinger@grafana.com>
2023-01-11 14:32:23 -06:00
Sven Grossmann
5b2184c485 Logs: Unify detected fields and labels in Log Details (#60448)
* removed js-fields

* added buttons

* rename detectedField to field

* removed unused things from `logParser.ts`

* improve comment

* wip

* better way for statistics

* better hide-stats button

* update tests

* updated tests and var names

* made props optional again

* fix padding

* fix unused import

* removed test

* close elements

* renamed `LogRowMessageDetectedFields` to `LogRowMessageDisplayedFields`

* add active style to menu button

* changed comment in logParser

* updated ToolbarButton colors

* rename `Data Links` to `Links`

* fix stats button being wrongly highlighted
2023-01-11 19:20:11 +01:00
MeanMina
8bab6d3658 Change token for parent project action (#61314) 2023-01-11 17:03:59 +00:00
Denis Limarev
90badc8729 Performance: Add preallocation for some slices (#59593) 2023-01-11 18:03:37 +01:00
Ivana Huckova
8bda8b8272 Log volume: Fix functionality if query has multiple comments (#61306)
* Log volume: Fix functionality if query has comments

* Add additional test
2023-01-11 16:21:02 +00:00
Yuri Tseretyan
b4e1e1871f Alerting: Fix evaluation timeout (#61303) 2023-01-11 10:52:54 -05:00
Guilherme Caulada
1a9b6873e6 Store: Add mock for system users to be used in tests (#61245)
Add mock for system users to be used in tests
2023-01-11 11:50:22 -03:00
Sonia Aguilar
f7ae909324 Alerting: Fix General folder being added in alerting FolderPicker (#61277)
Fix General folder being added in alerting FolderPicker
2023-01-11 15:35:47 +01:00
ying-jeanne
6c6a970f56 [Chore] Remove health check that is not used (#61283) 2023-01-11 22:07:28 +08:00
Todd Treece
19ca93d5ce Prometheus: Fix concurrency issue with exemplar sampler initialization (#61281) 2023-01-11 08:27:47 -05:00
idafurjes
f2ffce4351 Chore: Move team models to models pkg (#61262)
* Chore: Move team models to models pkg

* Fix ACL tests

* More ACL tests

* Change Id to ID in conflict user command test

* Remove team from models

* Fix ac test lint
2023-01-11 14:20:09 +01:00
Carl Bergquist
672b1711b0 Instrumentation: measure time until plugin request (#61279)
Signed-off-by: bergquist <carl.bergquist@gmail.com>
2023-01-11 13:19:06 +00:00
Marcus Andersson
b633d5395d Bugfix: Prevent previous query editor to set default values when changing data source (#60218)
* Fixed issue where the query editor of the previous ds sets default values on query passed to the query editor of the next ds.

* Fixed issue with changing data source for query in Alerting.

* Will apply default values from DS if available.

* Fix failing tests.

* fixed spell error.

* reverted getDefaultQuery call so it can be added in a separate PR.
2023-01-11 14:06:33 +01:00
Ludovic Viaud
67cad49570 Prometheus: Grafana global variables in PromQL should not raise errors (#60461) 2023-01-11 13:12:03 +01:00
Gilles De Mey
909ec67c56 Alerting: Declare incident from a firing alert (#61178) 2023-01-11 11:52:20 +00:00
Gilles De Mey
db6d0464e9 Alerting: revert #60728 (#61222) 2023-01-11 12:37:11 +01:00
Jack Baldry
87ccf10ffe Update publishing workflows to use PATs with fine-grained access control (#61098)
Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2023-01-11 10:53:26 +00:00
Levente Balogh
8b290bba55 Connections: Update redirect alert message (#61152)
* fix(Alert): don't add padding to content when there is no title

* Feat(Connections): update the style and wording of the redirect alert

* fix(UI/Alert): more resilient check for has title
2023-01-11 11:41:19 +01:00
Levente Balogh
6b2394eff1 Connections: Make "Connect data" a section title (#61144)
* Wip

* Fix: change tests to cater for the new scenario

* feat(Connections): redirect to "Your connections / Datasources" if cannot admin plugins
2023-01-11 11:40:21 +01:00
Emil Tullstedt
fc47e0d35e Docs: Update curl example to use --user for basic auth (#61226) 2023-01-11 11:18:26 +01:00
Emil Tullstedt
649b50055c Chore: Move all backend contribution documents to a single directory (#61140) 2023-01-11 11:16:52 +01:00
Sean Dague
4de0149bd9 OAuth: Support pagination for GitHub orgs (#58648)
* Support pagination for github orgs

* fix unused variable

* Increase initial page to 100 per the way teams work
2023-01-11 09:52:17 +01:00
George Robinson
fa9f1c3a52 Docs: Re-order nav for Manage your alert notifications (#60897) 2023-01-11 08:44:01 +00:00
Alex Moreno
3db08d4e36 Add object_matchers example (#61235)
* Add object_matchers example

* Use better terminology
2023-01-11 09:43:42 +01:00
Alexander Weaver
499fdf1ae4 Docs: Unified Alerting is now compatible with AWS Aurora (#61001)
Remove line that aurora is incompatible
2023-01-11 08:43:18 +00:00
Victor Marin
2cf628e37a BarChart: Highlight bars option for easier interaction (#60530)
* Add bar highlighter plugin to BarChart

* refactor feature

* Horizontal bars can also be hovered

* Tooltip mode UI reflects settings when stacked and bar highlight toggled

* rename variables

* override tooltip option + zIndex on hover box

* change option desc and simplify condition
2023-01-11 10:30:01 +02:00
ying-jeanne
f9daf61e96 [Bug] Fix xorm dependency on yaml v2 2.2.3 (#61183)
fix xorm dependency on yaml v2 2.2.3
2023-01-11 08:08:28 +00:00
Erik Sundell
c72ab21096 Cloudwatch: Refactor log group fields request (#60909)
* cloudwatch/log-group-fields-refactor

* remove not used code

* remove empty line

* fix broken test

* add tests

* Update pkg/tsdb/cloudwatch/routes/log_group_fields_test.go

Co-authored-by: Isabella Siu <Isabella.siu@grafana.com>

* pr feedback

Co-authored-by: Isabella Siu <Isabella.siu@grafana.com>
2023-01-11 08:12:58 +01:00
Matthew Jacobson
63ba3ccb58 Alerting: Improve legacy migration to include send reminder & frequency (#60275)
* Alerting: Improve legacy migration to include send reminder & frequency

Legacy channel frequency is migrated to the channel's migrated route's
repeat interval if send reminder is true. If send reminder is false, we
pseudo-disable the repeat interval by setting it to a large value (1y).

If there were no default channels, the root notification policy is still
created with the default 4h repeat interval.
2023-01-10 23:01:43 -05:00
Leon Sorokin
be1c5e13d5 DataFrame: Add explicit histogram frame type (panel & transforms) (#61195) 2023-01-10 17:42:45 -06:00
Yuri Tseretyan
86b5fbbf60 Alerting: Introduce state manager config structure (#61249) 2023-01-10 16:26:15 -05:00
Hamas Shafiq
bc3ce5760b Chore: Convert TimelineColumnResizer.test.tsx to RTL (#61156) 2023-01-10 21:24:51 +00:00
George Robinson
2a291afbae Alerting: Use consts from alerting package (#61241) 2023-01-10 19:59:13 +00:00
juanicabanas
2505f112f5 PublicDashboards: A unique page for public dashboards (#60744)
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2023-01-10 14:50:37 -03:00
George Robinson
d19d8c6625 Alerting: Update Alerting and Alertmanager to v0.25.1 (#61233)
Update Alerting and Alertmanager to v0.25.1
2023-01-10 16:17:07 +00:00
Emil Tullstedt
67661c2535 Fix: Use an existing Dockerfile for the Go image (#61158) 2023-01-10 17:11:43 +01:00
Jo
5f6f1a7d07 Devenv: Update to keycloak 20 (#61174)
update to keycloak 20
2023-01-10 16:50:53 +01:00
Christopher Moyer
205457ae5e Docs: removed unsupported versions; reordered (#61112)
removed unsupported versions; reordered
2023-01-10 09:29:32 -06:00
Adela Almasan
a2bd85963c Canvas: Update element(s) selection after action (#61204) 2023-01-10 09:26:53 -06:00
Virginia Cepeda
3b2ec752fb Alerting: change context parameter type (#61197)
Change boolean value to string as the Faro API doesn't accept boolean types for the entries of the context object
2023-01-10 12:17:11 -03:00
Ludovic Viaud
220ee3d1d4 Prometheus: Disabled inputs when settings are read-only (#60354) 2023-01-10 16:13:42 +01:00
Josh Hunt
5d725d22ad CommandPalette: Search for dashboards using API (#61090)
* CommandPalette: Search for dashboards using API

* Fix ordering of dashboards

* Put recent + search dashboards in root list, refactor actions into hook

* limit recent dashboards to 5

* search debounce to 200ms

* update priorities

* extract i18n
2023-01-10 14:59:32 +00:00
Kat Yang
9a14a7db03 Chore: Remove star model duplicates (#61191) 2023-01-10 09:56:33 -05:00
Timur Olzhabayev
320266ae63 Chore: Introduce codeowners validator (#60818) 2023-01-10 15:40:00 +01:00
Gareth Dawson
4bfcc14c18 Docs: Update loki query editor documentation (#61223)
* feat: update list of toolbar features

* fix: update image to display new label browser
2023-01-10 14:31:22 +00:00
Hamas Shafiq
2af79535bc Chore: Fix flaky test in SpanGraph/index.test.tsx (#61009) 2023-01-10 14:23:00 +00:00
Cyril Tovena
ad1813da27 Phlare: Update client code to use v0.1.2 API. (#60941)
* Depends on Phlare API instead of copying the code

* Rollback the breaking change from the API version
2023-01-10 14:16:45 +00:00
Jo
0c8ad80575 Authn: JWT client (#61157)
* add jwt client

* alias JWT verifier

* debug implementation

* add tests for jwt client

* add constant for JWT module

* Feedback

Co-authored-by: Kalle Persson <kalle.persson@grafana.com>
Co-authored-by: Mihály Gyöngyösi <mgyongyosi@users.noreply.github.com>

Co-authored-by: Kalle Persson <kalle.persson@grafana.com>
Co-authored-by: Mihály Gyöngyösi <mgyongyosi@users.noreply.github.com>
2023-01-10 15:08:52 +01:00
Karl Persson
2de72c1c39 AuthN: Login (#61225)
* AuthN: Add function to login auth request
2023-01-10 14:55:27 +01:00
Matias Chomicki
ef9a71f483 Loki Autocomplete: Improve handling of trailing spaces in queries (#61184)
* Loki Autocomplete: improve handling of trailing spaces in the query

* Monaco Field: rename resizing handler function

* Fix typo

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

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2023-01-10 14:38:22 +01:00
Karl Persson
c5f77b6a46 AuthN: Set LookupTokenErr and fall through in case of error (#61217)
ContextHandler: Set LookupTokenErr and fall through in case of error
during authentication
2023-01-10 14:36:02 +01:00
Grafana I18n Bot
e88687cfa2 I18n: Crowdin sync (#61119)
* New translations grafana.json (Spanish)

* New translations grafana.json (Spanish)

* New translations grafana.json (German)

* New translations grafana.json (French)
2023-01-10 12:37:37 +00:00
Gareth Dawson
bbd7cb42a1 Docs: Remove redundant text about raw query toggle (#61161)
docs: remove redundant text about raw query toggle
2023-01-10 12:36:37 +00:00
Gareth Dawson
114c8b64aa Loki: Rename "explain" toggle to "explain query" (#61150)
* feat: rename explain toggle to explain query

* test: correct failing test for explain toggle

* docs: update documentation on explain query toggle

* fix: update capitalization
2023-01-10 12:35:12 +00:00
Andre Pereira
bda13a1b5d Explore: Expand table height to show sub-tables (#60359)
* Expand table height to show sub-tables when there isn't enough space

* Fix after merge
2023-01-10 11:58:49 +00:00
Dominik Prokop
5dbbaab3f1 Scenes: Use @grafana/scenes (#60972)
* Use @grafana/scenes WIP

* Use @grafana/scenes package

* Use released @grafana/scenes

* Fix template_srv test
2023-01-10 03:30:53 -08:00
George Robinson
35ad9e23ce Docs: Update weights for Customize notifications without changing the order of pages (#60898) 2023-01-10 11:07:00 +00:00
Joao Silva
86e2eb744c Navigation: Add Cancel button to New folder page (#61188) 2023-01-10 11:44:24 +01:00
Ashley Harrison
4e00fbbd7f Navigation: Allow overriding icons in nav settings (#61160)
expose k6 icon, allow overriding icon in nav settings, override connections + k6
2023-01-10 10:29:07 +00:00
Joao Silva
84ebee026c Navigation: Add Cancel button to Import dashboard page (#61187) 2023-01-10 11:25:27 +01:00
Ivana Huckova
256f640e19 Elasticsearch: Refactor processQuery to make it more readable (#61145)
* WIP: Simplify process query logic

* WIP: Simplify process query logic

* Simplify

* fix lint
2023-01-10 10:49:43 +01:00
Misi
b3a44649ce RolePicker: Align groupHeader to the list items horizontally (#61060)
RolePicker: align groupHeader to the list items horizontally
2023-01-10 10:43:02 +01:00
Torkel Ödegaard
b5b13975d6 Dashlist: Design tweak to dashlist items (#60140) 2023-01-10 10:41:29 +01:00
Torkel Ödegaard
a277d504a2 Table: Improve data link text style (#60811)
Table: Change data link text style
2023-01-10 07:48:53 +01:00
Leon Sorokin
a1609230f8 TimeSeries: Fix y-axis Yes/No and On/Off boolean units (#61207) 2023-01-09 23:04:50 -07:00
Yuri Tseretyan
da18c89e91 Alerting: Scheduler to call DeleteAlertRule once when it stops deleted rules (#61189)
scheduler to call DeleteAlertRule once when it stops deleted rules
2023-01-09 14:39:32 -05:00
Zoltán Bedi
6e41e898eb Candlestick: Fix showing hidden legend values (#60971)
Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
2023-01-09 13:28:10 -06:00
Torkel Ödegaard
9cdcbab2fc Explore: Remove unnessary scroll on split pane (#61064)
* Explore: Remove unnessary scroll on split pane

* set overflow to auto

Co-authored-by: Giordano Ricci <me@giordanoricci.com>
2023-01-09 19:55:38 +01:00
Virginia Cepeda
7604360622 Alerting: Add info to alert rule creation metric (#61105)
Add extra info to alert rule creation metrics
2023-01-09 15:27:02 -03:00
Virginia Cepeda
115218b1ff Alerting: only track events for survey if user is not new (#61005)
* Only track events data if user is not new

To know this we evaluate the creation date to be older than two weeks

* Address PR comments
2023-01-09 14:41:03 -03:00
Ivana Huckova
ddc8beda07 Logs volume: Refactor (#60998)
* Rename log volume in redux to supp query to make it more generic

* Change enabled query to queries

* Small spell fix StoreSuppQueryDataProviderAction -> storeSuppQueryDataProviderAction

* WIP

* Improve

* WIP

* Rename

* Move to 1

* Small updates

* Use enum

* Unify naming

* Use SUPP_QUERY_TYPES instead of Object.keys()

* Move SuppQueryType to types/explore

* Rename suppQuery to supportingQuery

* Rename SUPP_QUERY_TYPES to SUPPORTING_QUERY_TYPES

* Rename supporting to supplementary 🙈

* Remove suppQueryData && suppQueryData.data[0] check as it is redundant

* Update public/app/features/explore/state/query.ts

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

* Update public/app/features/explore/state/query.ts

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

* Fix naming of SupplementaryQuery interface

Co-authored-by: Piotr Jamróz <pm.jamroz@gmail.com>
2023-01-09 18:33:48 +01:00
Adela Almasan
26a3c864f3 Canvas: Min-width for inline editor (#61176) 2023-01-09 11:24:12 -06:00
George Robinson
402dc5e4d6 Alerting: Redo refactoring from reverted fix in #56812 (#61051)
This pull request re-applies the refactoring of ConditionsCmd from a
reverted fix #56812 for mathexp.noData. It does not add the fix, or
tests for the fix, because those were added in #56816. We use the
additional test coverage added in #56816 and #58650 to avoid the
reoccurrence of regressions that caused us to revert #56812 the
first time.
2023-01-09 17:01:19 +00:00
Sven Grossmann
b1a8e4f2b8 Logs: Add usage tracking to new download-logs button (#61177)
* add usage tracking to new download-logs buttom

* changed 'dimension' to 'area'
2023-01-09 17:25:19 +01:00
Taewoo K
7db284cfcb remove splunk plugin from legacyRunner check (#60979) 2023-01-09 16:52:14 +01:00
Karl Persson
a49892c9ac AuthN: Refactor basic auth client to support multiple password auth (#61153)
* AuthN: add interface for password clients

* AuthN: Extract grafana password client

* AuthN: Rewrite basic client tests

* AuthN: Add Ldap client and rename method of PasswordClient

* AuthN: Configure multiple password clients

* AuthN: create ldap service and add tests
2023-01-09 16:40:29 +01:00
Erik Sundell
c3378aff8b Cloudwatch: Use new log group picker also for non cross-account queries (#60913)
* use new log group picker also for non cross-account queries

* cleanup and add comment

* remove not used code

* remove not used test

* add error message when trying to set log groups before saving

* fix bugs from pr feedback

* add more tests

* fix broken test
2023-01-09 16:30:21 +01:00
Yuri Tseretyan
2b61fb6e4a Test Datasource: do not use global random (#61116) 2023-01-09 10:08:58 -05:00
Andres Martinez Gotor
9c46aca897 AzureMonitor: Fix dashboard json style (#61163) 2023-01-09 10:01:54 -05:00
Yuri Tseretyan
9f503a261a Traces: Create span when a new session is opened (#61115) 2023-01-09 09:41:15 -05:00
Yuri Tseretyan
e7b17cde47 Traces: Fix timestamp for database query traces (#61109) 2023-01-09 09:40:55 -05:00
idafurjes
7dcb502b33 Chore: Remove org model duplicates (#61025)
Remove org model duplicates
2023-01-09 14:39:53 +01:00
Karl Persson
68b43a24e2 RBAC: dashboard permission filter (#60582)
* PermissionFilter: Handle all search type and only check one action for dashboards

* PermissionFilter: Still handle multiple action but take short cut when
only one action is required
2023-01-09 14:38:57 +01:00
John Martins
a22672c496 AzureMonitor: Update app insights links in curated dashboards (#57306) 2023-01-09 12:59:37 +01:00
John Martins
ea3d204eea AzureMonitor: Alphabetically sorted variables (#56577) 2023-01-09 12:51:26 +01:00
Karl Persson
3b08946fd3 RBAC: Update org invite rbac tests to not used mocked access control (#61141) 2023-01-09 12:23:24 +01:00
ismail simsek
6a68fbb495 Influxdb: Improve filtering (#60994)
* Add createOptionPosition props to SelectBase

* Show create option in the beginning of the list

* Show only matched template variables

* Fix the test

* Remove redundant check
2023-01-09 11:37:25 +01:00
Karl Persson
e0c7ef3481 RBAC: Rewrite rbac annotations test (#61036)
* API: Rewrite annotation rbac tests to not use mocked access control

* API: rewrite mass deletion rbac tests
2023-01-09 09:59:14 +01:00
Sven Grossmann
5ad95a2952 Loki: Fix tracking of queries_with_changed_line_limit_count (#60091)
* change line limit tracking

* updated test
2023-01-09 09:54:57 +01:00
Alexander Zobnin
f1b5014efd Preferences: Add pagination to org configuration page (#60896)
* Add auth labels and access control metadata to org users search results

* Fix search result JSON model

* Org users: Use API for pagination

* Fix default page size

* Refactor: UsersListPage to functional component

* Refactor: update UsersTable component code style

* Add pagination to the /orgs/{org_id}/users endpoint

* Use pagination on the AdminEditOrgPage

* Add /orgs/{org_id}/users/search endpoint to prevent breaking API

* Use existing search store method

* Remove unnecessary error

* Remove unused

* Add query param to search endpoint

* Fix endpoint docs

* Minor refactor

* Fix number of pages calculation

* Use SearchOrgUsers for all org users methods

* Refactor: GetOrgUsers as a service method

* Minor refactor: rename orgId => orgID

* Fix integration tests

* Fix tests
2023-01-09 11:54:33 +03:00
Yuri Tseretyan
d44de7f20a Annotations: AddMany to not open session if nothing to save (#61117) 2023-01-06 21:23:46 -05:00
Yuri Tseretyan
48f1db63ff Alerting: Add support for tracing to alerting scheduler (#61057) 2023-01-06 21:21:43 -05:00
Ryan McKinley
a3e341f24b Inspect: Refactor InspectJSONTab to FC (#61106) 2023-01-06 18:14:20 -05:00
Adela Almasan
9799ac252b Canvas: Update context menu actions for multiple elements selected (#61108) 2023-01-06 15:59:41 -06:00
Alexander Weaver
eb960d9725 Alerting: Add un-documented toggle for changing state history backend, add shells for remote loki and sql (#61072)
* Add toggle for state history backend and shells

* Extract some shared logic and add tests
2023-01-06 12:06:01 -06:00
Daniel Lee
cd04f4e564 docs: update 9.0 upgrade instructions (#59223)
* docs: draft for 9.0 upgrade instructions

* docs: linting

* Add links and explanations for RBAC GA release

Co-authored-by: Vardan Torosyan <vardants@gmail.com>
2023-01-06 18:53:19 +01:00
sam boyer
4db3b2fd5c Kindsys: Remove defs, Slot->SchemaInterface (#61069)
* kindsys: Remove defs, Slot->SchemaInterface

* Remove excess file

* Fix up tests

* Regenerate kinds report

* Final bits of cleanup

* Stop complaining, linter

* Update pkg/kindsys/kindcat_composable.cue

Co-authored-by: Tania <yalyna.ts@gmail.com>

Co-authored-by: Tania <yalyna.ts@gmail.com>
2023-01-06 12:37:32 -05:00
Jo
c2ad447f8c AuthN: Document identity and add missing fields (#61094)
* add missing fields in identity

* add description of Identity fields
2023-01-06 15:58:02 +00:00
Giordano Ricci
19c8f45a4b QueryHistory: Add tracking for copy query button (#61042)
* QueryHistory: Add tracking for copy query button

* add datasources to payload
2023-01-06 14:24:53 +00:00
Giordano Ricci
fafae26068 GrafanaUI: Fix vercal slider handle positioning (#61088) 2023-01-06 14:24:35 +00:00
Torkel Ödegaard
f71bfd88c5 DataSourceList: Build a dashboard button to open new dashboard in panel edit with data source already set (#60532)
* New dashboard with preset data source

* Updates

* use replace instead

* Tests: fix failing tests

* Chore: add UID to the error message

Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>
2023-01-06 09:21:40 -05:00
Sofia Papagiannaki
e2ed42c2a3 Nested folders: Do not expose the sequential ID from the folder store (#60702)
* Nested folders: Do not expose the sequential ID from the folder store
2023-01-06 16:04:17 +02:00
Esteban Beltran
9c0d830e26 Docs: Add source code url field description in publish a plugin documentation (#61080) 2023-01-06 13:28:51 +01:00
Torkel Ödegaard
349b39c909 SupportBundles: Fixes sentance casing (#61055) 2023-01-06 10:53:08 +00:00
Kyle Cunningham
5cad1e924e Chore: Change TimePicker owner to User Essentials (#61084)
Change TimePicker owner to user essentials
2023-01-06 05:35:46 -05:00
Gareth Dawson
93fe3faed5 Loki: Fix code editor not correctly responding to window resize (#61061)
* fix: code editor not correctly responding to window resize

* trigger build
2023-01-06 10:17:20 +00:00
Sven Grossmann
ece0c121a5 Logs: Fix line not being selectable in Firefox (#61081)
fix log line not being selectable
2023-01-06 11:15:12 +01:00
Ivana Huckova
30424a8618 Elasticsearch: Return error if invalid query (#61044)
* Elasticsearch: Return error if invalid query

* Add test

* Fix query in test
2023-01-06 11:14:17 +01:00
Jack Baldry
410b23c3d9 Use preferred package header for generated code (#61059)
* Use preferred package header for generated code

> To convey to humans and machine tools that code is generated, generated source should have a line that matches the following regular expression (in Go syntax):
> `^// Code generated .* DO NOT EDIT\.$`

https://pkg.go.dev/cmd/go#hdr-Generate_Go_files_by_processing_source

Co-authored-by: sam boyer <sdboyer@grafana.com>
Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Regenerate files with updated header

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
Co-authored-by: sam boyer <sdboyer@grafana.com>
2023-01-06 04:57:45 -05:00
mikkancso
18f5f763a9 Connections: Align permissions for Connections page (#60725)
* protect /connection url paths with permissions

These permissions match the original ones at /datasources and /plugins

* add Connections section to navtree only if user has permissions

This commit works only when the easystart plugin is not present.
I'll see what I can do when it is present in the next commit(s).

* update datasources page permissions

The datasources page have Explore buttons on datasource entries,
therefore it makes sense to show this page for those, who can't edit or
create datasources but have explore permissions.
This applies for the traditional Editor role.

* DataSourcesList: link to edit page only if has right to write

If the user doesn't have rights to write datasources, then it's better
to not create a link from cards to the edit page. This way they won't
see the configuration of the data sources either, which is a desirable
outcome.

Also, I moved the query for DataSourcesExplore permission out from the
DataSourcesListView component in the DataSourcesList component, next to
the other permission queries - for the sake of consistency.

* fix permissions for connect data

This way it matches the permissions of the "Plugins" page.

* fix applinks test
2023-01-06 03:11:27 -05:00
idafurjes
d1c9b308bc Chore: Move tempuser model to tempuser package (#61024)
* Move tempuser model to tempuser package

* Add xorm tags for ID
2023-01-06 09:02:05 +01:00
mikkancso
8e8f498674 Connections: Add redirect notice for datasources and plugins pages (#61037)
* add redirect notice for datasources and plugins pages

* do not depend on the internal implementation of Alert

The deleted css piece was problematic because it relied on the internals
of Alert.
If we don't remove that padding, then the Alert looks a bit off, so I
added some title to the Alert to look better.

This way the Connections LinkButton is not vertically aligned to the
center, but this is the closest we can get to the designed alert without
doing hacks and reimplementing the Alert component.
2023-01-06 09:00:29 +01:00
Levente Balogh
fc0e3d6c14 Connections: use the "adjust-circle" icon as a logo (#61046)
* feat: add a new icon called 'adjust-circle'

* feat(Connetions): use the `adjust-circle` logo
2023-01-06 07:31:49 +01:00
Giordano Ricci
122be161f9 Datasource Onboarding: add tracking (#60918)
* Datasource Onboarding: add tracking

* remove unused var

* set ds logo alt text to empty screenn and remove presentation role

* run i18n:extract

* Revert "run i18n:extract"

This reverts commit 5313ac9661.
2023-01-05 22:27:43 +00:00
Giordano Ricci
dfed7e59a5 Explore: move items out of topnav & use canvas variant for toolbar buttons (#60630)
* Explore: remove topnav

* PageToolbar: fix left items margin when no title or page icon is set

* add missing key prop & fix tests

* use canvas variant in live logs

* avoid rendering empty space

* fix test

* avoid disabling split resize button when live tailing

* minor touchups

* Update packages/grafana-ui/src/components/PageLayout/PageToolbar.tsx

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

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2023-01-05 22:26:58 +00:00
Adela Almasan
97e25d70e7 Canvas: Improve placement when adding an element via context menu (#61071) 2023-01-05 16:09:04 -06:00
Joan López de la Franca Beltran
dc20b776bb Kindsys: New schema for Kinds report (#61034)
* New (desired) report output

* Kinds: New schema for kinds report

* Update report.json

* Sort dimension items
2023-01-05 22:48:13 +01:00
Karl Persson
cdd7392f68 AuthN: Make client params part of the identity (#61050)
* AuthN: Change client params to be a return value of authenticate

* AuthN: move client params to be part of the identity
2023-01-05 20:17:41 +01:00
Karl Persson
183397194a RBAC: rewrite team member api test to not use mock (#61040)
* RBAC: rewrite team member api test to not use mock
2023-01-05 20:08:07 +01:00
linoman
7582e77d25 Add reference to Google OAuth docs (#61048) 2023-01-05 20:04:04 +01:00
Selene
8f29450594 Kindsys: Remove Raw kind category (#60992)
* Remove Raw references

* Remove more raws

* Re-generate files

* Remove raw folder from veneer

* Fix import

* Fix lint

* Bring back raw folder in grafana-schema

* Another lint

* Remove use of "Structured" word in kinds

* Delete unused function and remove some structured words

* Bunch more removals of structured name

Co-authored-by: sam boyer <sdboyer@grafana.com>
2023-01-05 13:54:42 -05:00
Galen Kistler
db369fc5b2 Prometheus: instant results ux improvements rudderstack events (#60990)
* add rudderstack events for new interactive elements
2023-01-05 12:52:59 -06:00
Ryan McKinley
0f3b4e02a0 Dashboards: Support drag+drop to import dashboard (#61017) 2023-01-05 12:52:37 -06:00
Alexander Weaver
8c3a5f6da0 Alerting: Allow state history to be disabled through configuration (#61006)
* Add configuration option for if state history should be enabled

* Inject no-op when history is disabled
2023-01-05 12:21:07 -06:00
Ryan McKinley
48fbe51d37 Chore: Avoid FC in canvas elements and dimension editors (#61014) 2023-01-05 09:55:55 -08:00
Torkel Ödegaard
bd90a6e1be Transformations: Add context parameter to transformDataFrame and operators (#60694)
* Transformations: Add context parameter to transformDataFrame and operators

* Remove unused queries prop

* Fixed test

* Fixed test
2023-01-05 17:34:09 +01:00
Gabriel MABILLE
6da850a2f2 RBAC: Add function to reduce permissions (#58197)
* RBAC: Add function to reduce permissions

* Make names readable

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Remove copy pasted comment

* Nit.

Co-authored-by: Jguer <joao.guerreiro@grafana.com>
Co-authored-by: Mihaly Gyongyosi <mgyongyosi@users.noreply.github.com>
2023-01-05 16:32:13 +00:00
Jo
a460d50781 CodeOwners: Update authnz components (#60985)
update authnz codeowners
2023-01-05 17:23:36 +01:00
George Robinson
9af7adef76 Alerting: Support customizable timeout for screenshots (#60981)
This commit adds a customizable timeout for screenshots called
capture_timeout. The default value is 10 seconds, and the maximum
value is 30 seconds. This timeout should be less than the minimum
Interval of all Evaluation Groups to avoid back pressure on alert
rule evaluation.
2023-01-05 16:07:46 +00:00
Gareth Dawson
bd9cce2866 Loki: Add hints for query filters (#60293)
* add hint for label filter

* add hint for line filter

* add feature tracking for hints click

* fix failing tests

* add tests for new query builder hints

* update hint labels

* fix: hint continues to render after adding operation

* add missing title property to hints

* make use of isQueryWithParser and remove isQueryWithLogFmt

* refactor isQueryWithLabelFilter

* always render label operation, even if incomplete

* suggestion

* fix oversight in feature tracking name on hint click

* update query hint label

* improvements

* add missing test for ADD_NO_PIPELINE_ERROR
2023-01-05 13:56:31 +00:00
Jo
fc0926f8fb SupportBundles: Recover from Bundler panics gracefully (#60995)
bundler panics should not crash Grafana
2023-01-05 14:23:35 +01:00
Ashley Harrison
a9e39a108c RelativeTimeRangePicker: correctly trap focus in overlay (#60984)
* correctly trap focus in relativetimerangepicker overlay

* add underlay

Co-authored-by: Michael Mandrus <michael.mandrus@grafana.com>
2023-01-05 11:35:47 +00:00
Ivana Huckova
772e8cbf60 Elasticsearch: Use interval provided by data request in backend (#60480)
* Elasticsearch: Remove interval caulation and use interval provises by grafana

* Remove redundant code

* Adjust snapshot tests

* Update test

* Fix lint
2023-01-05 12:26:27 +01:00
Ryan McKinley
8b50c60342 TextPanel: Refactor to functional component (#60885) 2023-01-05 02:08:00 -08:00
Polina Boneva
3f1908464d PanelChrome: Implement Panel header with error, loading, and streaming data status (#60147)
* dashboards squad mob! 🔱

lastFile:packages/grafana-ui/src/components/LoadingBar/LoadingBar.tsx

* dashboards squad mob! 🔱

* dashboards squad mob! 🔱

lastFile:packages/grafana-ui/src/components/LoadingBar/LoadingBar.tsx

* user essentials mob! 🔱

* create grafana/ui LoadingBar and set it up in Storybook

* Remove test changes on PanelChrome

* Fix mdx page reference

* dashboards squad mob! 🔱

lastFile:public/api-merged.json

* dashboards squad mob! 🔱

* dashboards squad mob! 🔱

* dashboards squad mob! 🔱

* dashboards squad mob! 🔱

lastFile:public/app/features/dashboard/dashgrid/PanelHeader/PanelHeaderState.tsx

* Implemented basic draft of panel header states. Using ToolbarButton instead of IconButton.

* use 'warning' styled Button in ToolbarButton

* make LoadingBar a simple JSX Element; do not use containerWidth; have a wrapper around the loading bar itself;

* fix wrapper around LoadingBar: willChange css prop makes performance of rerendering better

* States: Render general panel query error states and render notices next
to the title

* add streaming to PanelChrome if data is streaming instead of loading

* PanelHeaderState with its own state 'mode'

* clean up useEffect

* notices have their own square space in the size of the panel header

* clean up

* minor fixes

* moving the LoadingBar to core

* LoadingBar is not in grafana/ui

* always have a place for the loading bar in the PanelChrome, otherwise it moves everything when appearing;

remove titleItemsNodes for now - in later development

make no changes to Notice component, not part of this PR

* Revert "moving the LoadingBar to core"

This reverts commit 11f0f4ff2f.

* do not use internal comment as it doesn't do anything

* integrate LoadingBar in PanelChrome from grafana/ui directly

* fix deprecated leftItems comment

* Modify annimation to 1 second

* remove comments

* remove streaming stopped UI because we cannot know when the streaming has stopped

* skip unnecessary test for now

* no point in removing hoverHeader now, even though it's not yet implemented

* small fixes

* error state of the data in a panel is positioned in PanelChrome itself, not in PanelHeaderState

* Fixed loading state jitter

* remove warning state as we have none of it

* streaming cannot be stopped from the icon

* explicit content container width and height

* explicit content container width and height

* edit deprecated comment

* fix LoadingBar to be relative to width of panel; remove explicit width and height on content strict

* no warning state of the data

* status of the panel data given directly to PanelChrome, not a node

* clean up

* clean up console log

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

* panel title design fits typography h6 styles; render error status only if error or error message are passed to PanelChrome

* add storybook examples; prepare PanelChrome for hoverHeader because this will be a breaking change and it will affect how the storybook example shows up

* show storybook example for streaming panel with title because that's the condition for having a header

* override margin-bottom: 0.45em of h6

Co-authored-by: Alexandra Vargas <alexa1866@gmail.com>
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
Co-authored-by: kay delaney <45561153+kaydelaney@users.noreply.github.com>
2023-01-05 11:48:11 +02:00
Adela Almasan
88a8cba6b0 Canvas: Save element placement (#61007) 2023-01-04 18:29:01 -05:00
Ieva
9334582022 RBAC: move RBAC + OnCall feature toggle to beta state (#60991)
* move RBAC + OnCall feature toggle to beta state

* move accessControlOnCall to the correct section in the docs
2023-01-04 17:52:08 +01:00
Galen Kistler
0e265245eb Prometheus: New instant query results view in Explore (#60479)
Add new default instant query UI option for prometheus users in Explore.

Co-authored-by: Beto Muniz <contato@betomuniz.com>
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
2023-01-04 10:46:03 -06:00
Alexander Weaver
0e7640475f Alerting: Store alertmanager configuration history in a separate table in the database (#60492)
* Update config store to split between active and history tables

* Migrations to fix up indexes

* Implement migration from old format to new

* Move add migrations call

* Delete duplicated rows

* Explicitly map fields

* Quote the column name because it's a reserved word

* Lift migrations to top

* Use XORM for nearly everything, avoid any non trivial raw SQL

* Touch up indexes and zero out IDs on move

* Drop TODO that's already completed

* Fix assignment of IDs
2023-01-04 10:43:26 -06:00
Jo
c74d86ca27 SupportBundles: Move support bundles to services (#60986)
* move support bundles to services

* update CODEOWNERS
2023-01-04 17:33:18 +01:00
Andre Pereira
298576c6a1 Tempo: Fix service graph when tempoApmTable is enabled (#60975)
Fix query variables breaking the generated query for the APM service graph
2023-01-04 16:18:41 +00:00
Alexander Weaver
1381fb6dfc Annotations: Fix EpochEnd being zero for Alert-generated annotations (#60931)
* Revert linter suggestion

* Re-add nolint

* Work in terms of pointer rather than copy

* Add tests covering validation

* Add comment
2023-01-04 10:16:54 -06:00
Josh Hunt
0aeee7f265 Chore: Automatically add crowdin PRs to User Essentials board (#60912)
* Chore: Automatically add crowdin PRs to User Essentials board

* ci
2023-01-04 15:47:45 +00:00
Josh Hunt
a26d4c90b2 I18N: Fail i18n:extract on warnings + update strings (#60949)
* I18N: Fail i18n:extract on warnings

* I18N: Fix onboarding page title

* extract all strings

* move t reassign outside of function
2023-01-04 15:28:07 +00:00
Karl Persson
d572ccdb2a AuthN: tune logging (#60917)
* AuthN: remove comment

* AuthN: Only start trace if valid authentication client is used
2023-01-04 16:25:42 +01:00
idafurjes
bb35f37b66 Chore: Delete org model duplicates (#60940)
* Delete org model duplicates

* Fix lint

* Move OrgDetailsDTO to org pkg
2023-01-04 16:20:26 +01:00
Stephanie Hingtgen
39b8d3a182 Plugins: add UI for secure socks proxy feature toggle (#60750) 2023-01-04 20:47:27 +05:30
Jo
9633b5c69c SupportBundles: Improve UX (#60964)
implement of easy frontend fixes for bundle list
2023-01-04 16:11:02 +01:00
Jo
a226903ec6 AuthN: Add session client (#60894)
* add basic session client

* populate UserToken in ReqContext

* token rotation as a post auth hook

* fixed in context handler

* add session token rotation

* add session token tests

* use namespacedID constructor
2023-01-04 16:10:43 +01:00
Ashley Harrison
ebb34560a4 Navigation: use "Home" instead of "Grafana" as the default Breadcrumb text (#60973)
* use Home instead of Grafana as the default Breadcrumb text

* use translated text
2023-01-04 15:02:30 +00:00
Ashley Harrison
7005b7bf8a Navigation: Update e2e tests to work with topnav (#60910)
* turn on topnav toggle in e2e tests

* fix variable e2e tests

* fix remaining tests + remove some hardcoded waits

* speculative fixes

* wait for error to disappear

* use new selector, turn toggle back off
2023-01-04 14:59:53 +00:00
Yuri Tseretyan
4d989860fb Alerting: Fix conversion of alert state from db state during manager warmup (#60933) 2023-01-04 09:40:04 -05:00
Ashley Harrison
8149efc729 Chore: group visx updates together (#60895)
group visx updates together
2023-01-04 14:32:57 +00:00
Gábor Farkas
12c4098bcd elastic: backend: handle naming bucket_scripts (#60460) 2023-01-04 15:26:57 +01:00
Domas
72d257ed4f PanelRenderer: fix error when variable replacement is used (#60968)
fix panel renderer when using replace
2023-01-04 16:20:44 +02:00
Sonia Aguilar
4ae0382415 Alerting: Add pagination in group modal alert table (#60868)
Add pagination in group modal alert table
2023-01-04 14:48:34 +01:00
Ivan Ortega Alba
d0f6a3a4ca Scene: Dashboard loader supports transformations & unit tests (#60855)
* Scene: use transformations for panel queries

* refactor: Clean up DashboardLoader class

* test: Add unit tests for creators

* test: Ensure the row herarchy is properly replicated

* test: Ensure the URLSync is initialized

* refactor: Use fixture to create panels
2023-01-04 08:29:22 -05:00
Galen Kistler
6ab6d661e2 Dashboard: .txt file extension is not supported in /dashboard/import file upload (#59760)
remove typo, allow txt file upload
2023-01-04 07:16:23 -06:00
Karl Persson
da24a9d74e AuthN: Add render auth client (#60914)
* AuthN: Add boilderplate for render auth client

* AuthN: Implement test function for render auth client

* AuthN: Implement Authenticate for render arender auth client

* ContextHandler: Perform render auth if flag is enabled
2023-01-04 13:48:00 +01:00
Joao Silva
220175cab9 A11y: Improve accessibility of ColorPickerInput (#60923) 2023-01-04 13:19:41 +01:00
Alex Khomenko
c68603a573 Teams: Use generated TS types (#60618)
* Teams: Use generated TS types

* Teams: Update types usage

* Teams: Update types import

* Teams: Move metadata to mock function

* Teams: Move TeamDTO to types

* Update kind
2023-01-04 14:08:03 +02:00
melGL
fc91baa2f8 Alerting Docs: Clarify feature flag for Grafana Cloud users (#57637)
Docs: Clarify feature flag for Grafana Cloud

Images in Alerts requires a feature flag for hosted Grafana instances. This change directs users to contact Support for access to this feature.
2023-01-04 10:57:58 +00:00
Andrej Ocenas
85d8d9c00b Phlare: Add devenv block (#60911)
Add Phlare devenv block
2023-01-04 11:29:45 +01:00
Jack Baldry
1516aa2762 Remove packages path from branch filter (#60128)
That directory is no longer used in published docs and causes this
workflow to fail when changes only affect the packages directory.

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2023-01-04 10:18:44 +00:00
mikkancso
0adcdae325 Connections: Show only data source plugins on Connect Data page (#60523)
show only data source plugins on connect data page

We intended to show only data source plugins on this page, but this
filter was missing until now.
2023-01-04 10:45:50 +01:00
Erik Sundell
bd09e88e50 Cloudwatch: Refactor log group model (#60873)
* refactor log group query model

* update deprecated comment

* refactor test
2023-01-04 10:07:03 +01:00
Alexander Weaver
b88b8bc291 Alerting: Fix missing dashboard/panelID links in annotations (#60926)
Assign thru ref
2023-01-03 14:12:27 -06:00
owensmallwood
f0ee3ac80a PublicDashboards: Enterprise email sharing feature flag (#60644)
adds feature flag for pubdash email sharing
2023-01-03 13:45:15 -06:00
Galen Kistler
4ed0cc7d18 Prometheus: Code editor - upgrade /series API endpoints to use label/values and /labels for supported prometheus clients (#59576)
* Allow prometheus code editor API to use new prometheus API calls for supported data source clients.
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2023-01-03 12:38:11 -06:00
Hamas Shafiq
0dffbcbca7 Chore: Refactor the root of the TraceTimelineViewer folder to TS (#59748) 2023-01-03 15:45:28 +00:00
Grafana I18n Bot
9d767b78d4 I18n: Crowdin sync (#59571)
* Update source file grafana.json

* New translations grafana.json (French)

* New translations grafana.json (Spanish)

* New translations grafana.json (German)

* New translations grafana.json (Chinese Simplified)
2023-01-03 14:45:10 +00:00
idafurjes
325f7a789e Chore: Delete duplicate models for user (#60906)
* Delete duplicate models for user

* Use new models in some tests

* Add auth model conversion back
2023-01-03 15:25:35 +01:00
Hamas Shafiq
355f513718 Chore: Refactor the TraceTimelineViewer/TimelineHeaderRow folder to TypeScript (#60351) 2023-01-03 13:36:50 +00:00
Will Browne
9aed364898 Plugins: Fix plugin query help markdown (#60485)
* refactor(pluginhelp): rewrite as functional component with useAsync

* mimic old behaviour

* feat(pluginhelp): display message if backend returned an empty string

Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
2023-01-03 14:20:27 +01:00
Hamas Shafiq
eb2a9d132a Chore: Convert SpanGraph/index.test.tsx to RTL (#60200) 2023-01-03 13:01:02 +00:00
mikkancso
899b035087 Connections: Update datasource details url (#60521)
update datasource details url

My ultimate goal is to make the cloud-onboarding plugin link to
datasource details page inside Connections.
I tried to do that, so that it linked to
`/connections/connect-data/datasources/:id`, but it didn't work. Details
below:

We have a problem with the datasources details page url:
If the plugin is not present, then the
`/connections/connect-data/datasources/:id` url is finely served by Grafana.
However, when the plugin is present, we register a Route entry like this:
`<Route exact=false path='/connections/connect-data' component={AppPlugin} />`
And this entry will be higher in the routes list than the datasources Route.
This means that every path under `/connections/connect-data` will be served
by the plugin. That's why exact is false. Otherwise the plugin couldn't
serve integrations details at `connect-data/infrastructure/:id`.
So `exact=false` is needed.

What can we do?
1. Put Grafana's Connection routes higher in the list of routes.
2. Find a different URL for datasources details page

Unfortunately, we can't do 1., because:
Routes roughly look like this (in this order):
- exact: false, path: connections/connect-data, component: AppPlugin
- exact: false, path: connections/your-connections/infrastructure,
    component: AppPlugin
- exact: false, path: connections, component: Connections
So if a request comes for `/connections` or `/connections/your-connections`
or `/connections/your-connections/datasources`, it will be served by
Connections.

Therefore, we can't really put the route for Connections higher in the list
of routes, because then it will match all routes beginning with
`/connections`, and the plugin's routes will have no effect.

So the only alternative left is to find another path :/

Since we set the DataSourceDetailsPage's navId explicitly to
`connections-connect-data`, the breadcrumbs will continue to show the
data source page as a child item of the Connect Data page :)
2023-01-03 13:57:16 +01:00
Alex Khomenko
b1573104d4 Schema: Use the latest cuetsy version (#60696)
* Schema: Use the latest cuetsy version

* Schema: Update Permission

* Use latest cuetsy
2023-01-03 14:10:32 +02:00
Sonia Aguilar
f22286df3f Alerting: Fix missing edit/delete/copy link in alert view (#60874)
Fix missing edit/delete/copy link in alert view
2023-01-03 13:08:14 +01:00
Andre Pereira
44afad2ce4 Tempo: TraceQL autocomplete feature tracking (#60876)
* Track usages of completion items in TraceQL query editor

* Change back traceID reportInteraction() name to avoid breaking dashboards

* Filter out TAG_VALUE labels from feature tracking to avoid exposing sensitive data
2023-01-03 10:43:11 +00:00
Joao Silva
993ab2587e A11y: Fix accessibility in menu icon on small screens (#60844) 2023-01-03 11:40:25 +01:00
Joey Tawadrous
b8618723d0 Phlare: Transition from LogQL/PromQL to Phlare should keep the query (#60217)
* Transition from LogQL/PromQL to Phlare keeps the query

* Tests
2023-01-03 10:25:16 +00:00
Erik Sundell
5bceff971d CloudWatch: Decrease log group picker viewport size (#60891)
decreasing viewport height
2023-01-03 11:22:55 +01:00
renovate[bot]
5576a4488d Update dependency @visx/event to v2.17.0 (#60717)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-01-03 10:22:33 +00:00
renovate[bot]
978d49ea51 Update dependency @babel/plugin-proposal-optional-chaining to v7.20.7 (#60716)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-01-03 10:10:44 +00:00
Jo
ba9decfd04 Devenv: Add SAML authentik devenv (#60881)
* add SAML support to authentik devenv

* update authentik image

* mark SAML as done
2023-01-03 10:06:24 +00:00
Karl Persson
9fbb29c588 AuthN: Add client to perform basic authentication (#60877)
* AuthN: Add basic auth client boilerplate

* AuthN: Implement test function for basic auth client

* AuthN: Implement the authentication method for basic auth

* AuthN: Add tests for basic auth authentication

* ContextHandler: perform basic auth authentication through authn service
if feature toggle is enabled

* AuthN: Add providers for sync services and pass required dependencies
2023-01-03 10:23:38 +01:00
Erik Sundell
b3540b5f46 Cloudwatch: Add feedback labels to log groups selector (#60619)
* add max item text

* add tests

* add selected log groups counter label

* cleanup

* fix styling in selector fields

* remove unused imports

* move selected log groups to a new component

* add confirm dialog

* remove not used import

* set max logs groups to 6

* add margin bottom
2023-01-03 09:56:01 +01:00
Jo
e1ea5490b3 Devenv: Remove abandoned environment (#60882)
chore: remove abandoned environment
2023-01-03 09:30:59 +01:00
sam boyer
7fd1d5cef0 Codegen: Add support for optional maps (#60883) 2023-01-03 09:12:48 +02:00
Timur Olzhabayev
3ceb3edcb9 Docs: Updating plugin publishing docs (#60853)
* Updating pluign publishing docs

* Update docs/sources/developers/plugins/publish-a-plugin.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/developers/plugins/publish-a-plugin.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2023-01-02 17:09:36 +01:00
Karl Persson
5b4e1ee6fc Oauth: Remove extra decoding of redirect url (#60875)
Oauth: remove extra decoding of redirect cookie url
2023-01-02 16:45:45 +01:00
Andre Pereira
950f357175 Tempo: TraceQL editor bug fixes (#60414)
* Set width of common columns between trace and span rows

* Better syntax highlighting for non string constants

* Apply variables to traceql query

* Fix test
2023-01-02 14:23:50 +00:00
Timur Olzhabayev
b179ac91a2 Docs: Removing outdated plugin_dev doc (#60849)
* Removing outdated plugin dev doc

* Update docs/sources/developers/plugins/legacy/_index.md

Co-authored-by: Karen Germond <110922559+karengermond@users.noreply.github.com>

Co-authored-by: Karen Germond <110922559+karengermond@users.noreply.github.com>
2023-01-02 15:20:13 +01:00
Dominik Prokop
4446d500a4 grafana/data: Deprecate kbn.regexEscape and move to grafana/data (#60869)
grafana/data: Deprecate kbn.regexEscape and move escapeRegex to grafana/data
2023-01-02 05:57:55 -08:00
Dominik Prokop
831e7697ae grafana/data: Move useFieldOverrides from core (#60817)
* grafana/data: Move useFieldOverrides from core

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

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

* Review

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2023-01-02 02:27:48 -08:00
Erik Sundell
6e89421544 CloudWatch: Add macro for resolving period in SEARCH expressions (#60435)
* interpolate macro in the backend

* refactor logger in cloudwatch query

* revert added metrics

* add docs

* apply pr feedback

* fix broken test

* fix spelling
2023-01-02 09:08:31 +01:00
Michael Mandrus
09c759b36c Graphite: Fix bug in wildcard queries to Graphite plugin (#60549)
* commit something that works, need to figure out scoping issues

* clean up now that I know about addressable values
2022-12-30 13:53:42 -05:00
Todd Treece
73d5aa4878 Prometheus: Refactor exemplar sampler (#60278) 2022-12-30 13:04:35 -05:00
ying-jeanne
ce8512ace7 [xorm] Change interface to become an interface (#60838)
[xorm] change interface to become an interface
2022-12-30 13:58:10 +00:00
MeanMina
dcb106aec0 CODEOWNERS: to rename Observability Experience (#60820)
Update CODEOWNERS to rename Observability Experience
2022-12-30 09:23:02 +00:00
Matthew Jacobson
570b62091c Alerting: Prevent uid collision in migration when db is case-insensitive (#60494)
* Alerting: Prevent short uid collision in legacy migration when db is case-insensitive

Two factors come into play that cause sporadic uid conflicts during legacy alert migration:
- MySQL and MySQL-compatible backends use case-insensitive collation.
- Our short uid generator is not a uniform RNG and generates uids in such a way that generations in quick succession have a higher probability of creating similar uids.

Normally we would be guaranteed unique short uid generation, however if the source alphabet contains
duplicate characters (for example, if we use case-insensitive comparison) this guarantee is void.

Generating even ~1000 uids in quick succession is nearly guaranteed to create a case-insensitive
duplicate.
2022-12-29 15:15:29 -05:00
Giordano Ricci
9ff3bf4849 Explore: Use Datasource Onboarding page when visiting without any datasource set up (#60399)
* allow DatasourceOnboarding title and cta text customization

* Explore: use Datasource Onboarding page when visiting without any datasource set up

* move & rename DatasourceOnboarding

* Rename component
2022-12-29 15:38:40 +00:00
ismail simsek
15d32546ea Prometheus: Fix Instant query time calculation (#60815)
* Use single point in time instead of doing time range calculation

* Comment update
2022-12-29 16:32:08 +01:00
Sandro
ab1777e7a6 Remove accidential code block (#60712) 2022-12-29 08:19:59 -06:00
Dominik Prokop
c3c4a57c79 grafana/data: Move getPanelOptionsWithDefaults from core (#60813)
* grafana/data: Move getPanelOptionsWithDefaults from core

* Add internal comments
2022-12-29 05:48:22 -08:00
Dominik Prokop
168afa99d1 Scenes / DashboardsLoader: Add variables migration (#60226)
* VizPanel - add variables dependencies definition

* Migrate variables to scene variables

* Constant variable migration

* Update test

* Lint fix
2022-12-29 05:34:22 -08:00
Karen Germond
53d3a810dd Fix https://github.com/grafana/grafana/issues/60772 -- typo in alerting-rules-edit-mimir-loki-namespace-group (#60796)
Fix https://github.com/grafana/grafana/issues/60772
2022-12-29 07:03:58 -06:00
Emil Tullstedt
bf574e98c8 Chore: Upgrade Go to 1.19.4 (#60794) 2022-12-29 13:03:56 +01:00
Joan López de la Franca Beltran
329fedb55d Codegen: Fix mudball gen (#60812)
* Codegen: Fix mudball gen

* Fix Go build tags annotations
2022-12-29 12:48:27 +01:00
Dominik Prokop
370aa9f6ea Runtime: Expose panel plugin import utils (#60799)
* Runtime: Expose plugin import utils

* Review

* Fix
2022-12-29 00:45:50 -08:00
Ivan Ortega Alba
7de81ca673 test: Fix Jest reporter (#60810) 2022-12-29 03:14:09 -05:00
ying-jeanne
a3a0c01301 [xorm] Remove some unused functions && mssql related logics (#60788)
* remove some unused functions

* more

* put back the pakcage replace
2022-12-28 22:23:25 -05:00
Torkel Ödegaard
497ce81867 Table: Refactoring state handling for expanded rows (#60791)
* Table: Refactoring state handling for expanded rows

* Simplify row expander

* remove console.log

* review fixes

* Simplify hook name

* fixed test
2022-12-28 19:37:17 +01:00
Torkel Ödegaard
14c2209b33 TopNav: Fixes the invite user page navId / missing section nav and design of user list page (#60701) 2022-12-28 19:29:42 +01:00
Dominik Prokop
78d7f11b8e grafana/data: Move data frames processing functions from core (#60795) 2022-12-28 07:59:45 -08:00
Dominik Prokop
aa0936127d Runtime: Expose runRequest function (#60793) 2022-12-28 06:28:12 -08:00
Kristin Laemmert
b356526ebe chore(dashboard version service): remove user table join from store implementations (#60779)
chore (dashboardversion service): remove (one) join from store implementations

We return the userID from the dashboardservice store; the service (or api) layer can use that to get the user's login when needed.
2022-12-28 07:59:10 -05:00
Kristin Laemmert
6e9419ea80 chore(dashboard version service): make method sigs more consistent (#60736)
The DashboardVersion struct is the database object; the DashboardVersionDTO is the object that should be sent to the API layer.

In the future I'd like to move DashboardVersion to dashverimpl and un-export it, but there are a few places that Insert directly into that table, not all of which are test fixtures, so that should wait until we clean up at least the DashboardService's use of it.
2022-12-27 11:17:24 -05:00
ying-jeanne
29276581d2 [xorm] Remove cache from xorm (#60770)
[xorm] remove cache from xorm
2022-12-27 10:48:49 -05:00
Emil Tullstedt
88323a30b7 Logging: Fix running tests multiple times (#60559)
- Create new ctxLogProviders for each scenario to support
go test -count=n for n>1. Currently, it just kept adding providers for
every new run, which would make it add way more key-value pairs to
the provider than necessary.

- Adding a helper method to the scenario to make it easier to set up tests
for logging and easier to read the tests. I also flattened the test file, to
reduce the complexity of each test function.
2022-12-27 16:42:03 +01:00
Dominik Prokop
9b7418ec17 Revert "Chore: Update typescript to 4.9.3 (#60538)" (#60774)
This reverts commit 51f5334748.
2022-12-27 06:30:52 -08:00
Ivan Ortega Alba
0d65063d0b Jest: Add logger to print test results in Loki friendly format (#59672) 2022-12-27 12:06:06 +01:00
Torkel Ödegaard
591c86e31d Scene: Consolidate layout props on a layout prop (formerly named size) (#60437)
* Initial prop rename changes

* Updates

* Rename layout to placement

* Fix

* Fixed test

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
2022-12-27 09:05:06 +01:00
ying-jeanne
12c292fd44 [Bug] Fix annotations update/patch (#60385)
* fix annotations update/patch

* verify that when update doesn't contain data, we will not update data
2022-12-26 09:53:52 -05:00
ying-jeanne
746c7839dc [xorm] Remove some unused functionalities from engine (#60763)
remove some unused functionalities from engine
2022-12-26 22:39:21 +08:00
ying-jeanne
77b3520b47 [xorm] remove mssql as driver (#60760)
* Remove mssql driver

* reput the go.mod

* add back xorm and remove mssql
2022-12-26 06:01:51 -05:00
ying-jeanne
33dbbbad6b [xorm] Rmove engine group (#60761) 2022-12-26 05:32:51 -05:00
ying-jeanne
572e5a76ef [xorm] add xorm as package into grafana (#60678)
* add xorm and xorm/core as package

* remove mssql and oracle as driver

* fix some typo

* remove unittest

* remove some cache

* restore the removed part

* remove logfile
2022-12-26 17:45:21 +08:00
Dan Cech
9c4051bfa1 Switch grafana server command to use urfave/cli/v2 (#60684)
* switch grafana server to use urfave/cli/v2

* autocomplete support

* lint fix
2022-12-24 22:33:18 -05:00
Victor Marin
9bd6e471e4 BarChart: Clear tooltip when cursor exits bar (#60617) 2022-12-23 13:00:52 -06:00
Leon Sorokin
b439fd56d8 Heatmap: Fix bottom bucket range in tooltip (#60562)
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2022-12-23 12:56:07 -06:00
Nathan Marrs
8b200d74b9 Geomap: Fix datalink UX regression (#60739) 2022-12-23 10:48:01 -08:00
Nathan Marrs
283cdc184e Barchart: Fix tooltip erroneous header (#60741) 2022-12-23 13:42:53 -05:00
Andres Martinez Gotor
7a679db08b Azure Monitor: Add current value to editor options (#60726) 2022-12-23 18:43:43 +01:00
yusuf-multhan
bb5ac924ae Folder: Folder name update redirects to desired location, for grafana served with subpath (#60721) 2022-12-23 17:29:41 +01:00
Gilles De Mey
f72cbc16ad Alerting: Warn about missing contact-point in notification policy (#60728)
* initial simplistic version
still need to figure out what to do with child policies

* adds test
2022-12-23 14:54:57 +01:00
Serge Zaitsev
1d12dda7db Chore: Update CODEOWNERS (#60724)
* Chore: Update CODEOWNERS

* remove comment
2022-12-23 08:46:17 -05:00
Andreas Christou
f319a5f740 CloudMonitor: Add adoption metrics (#60706)
* Add adoption metrics for Cloud Monitoring

- Add metrics to track each query type (MQL/Time Series Query, Builder/Time Series Filter, SLO, Annotation)

* Remove hidden fields and account for pre 9.4 queries

* Simplify object
2022-12-23 07:01:29 -05:00
ismail simsek
76e822af39 Prometheus: Fix exemplar popover overflow (#60189)
Add popover modifiers to fix overflow issue
2022-12-23 10:14:46 +01:00
Yuri Tseretyan
33e4a93e36 Revert "Chore: Add static UID to test datasource to devenv provisioning file" (#60714)
Revert "Chore: Add static UID to test datasource to devenv provisioning file (#60707)"

This reverts commit 4e2bd63572.
2022-12-23 07:58:47 +01:00
Santiago
05c9af5110 Extract custom template functions (#60695)
extract custom template functions and export the FuncMap
2022-12-22 17:31:40 -03:00
Yuri Tseretyan
4e2bd63572 Chore: Add static UID to test datasource to devenv provisioning file (#60707) 2022-12-22 14:57:01 -05:00
Andres Martinez Gotor
eb757ee15e Azure Monitor: Fix behavior for nested template variables (#60697) 2022-12-22 17:31:05 +01:00
Andreas Christou
c34aa05548 grafana/e2e: Add ability to customise scenario config (#60646)
* Add ability to retry e2e test scenarios

* Add wait and remove retries

* Revert retry logic and elaborate on 15s wait time

* No need to update datasource name now
2022-12-22 11:07:49 -05:00
juanicabanas
9c3ddda99b PublicDashboards: Revert Time range setting added (#60698)
Revert "PublicDashboards: Time range setting added (#60487)"

This reverts commit 6f609dbced.
2022-12-22 12:31:54 -03:00
Gilles De Mey
e9fe9baf66 Alerting: Improve threshold displays (#60046) 2022-12-22 16:28:17 +01:00
Kristina
58716de073 Fix Explore URL generator (#60653) 2022-12-22 16:23:30 +01:00
Ivana Huckova
c289cd136c Elasticsearch: Fix adding of adhoc filters when jumping to explore (#60691)
* Elasticsearch: Fix adding of adhoc filters when jumping to explore

* Change NOT operator to - as it is preffered solution
2022-12-22 16:06:30 +01:00
Sven Grossmann
9f9bf4650d Loki: Fix missing parameters on Query Builder operations (#60677)
* add missing mandatory params

* improve naming

* change let to const
2022-12-22 15:31:41 +01:00
Yuri Tseretyan
f990be58cb Alerting: Use all notifiers from alerting repository (#60655) 2022-12-22 09:27:18 -05:00
Kristin Laemmert
542cccaecc flapflapflapflap - "organization not found" is really annoying (#60628)
flapflapflapflap
2022-12-22 09:14:09 -05:00
Ivana Huckova
a1ef3d77f2 Elasticsearch: Use constants for default values and types (#60673) 2022-12-22 15:08:15 +01:00
Dimitris Sotirakis
658414a025 CI: Update grabpl to v3.0.20 (#60670)
Update grabpl to v3.0.20
2022-12-22 14:51:43 +01:00
Sven Grossmann
01c4783c0b Logs: Fix height of logs component when used with topnav (#60669)
fix height for topNav
2022-12-22 14:43:02 +01:00
Sonia Aguilar
22ad487c4b Use queryFn instead of query to be able to catch errors in onCall req… (#60685)
Use queryFn instead of query to be able to catch errors in onCall request
2022-12-22 14:30:27 +01:00
Elthariel
9ce1cd9ddf Docs: Add implementation key in data source table (#59494)
* Add `implementation` key in data source table

The implementation field that seems to be used by the alertmanager data source config wasn't documentated

* Align | of table

Co-authored-by: Armand Grillet <2117580+armandgrillet@users.noreply.github.com>
2022-12-22 07:41:32 -05:00
Andres Martinez Gotor
f8cc45f5bd Azure Monitor: Fix metric metadata retrieval based on template variables (#60674) 2022-12-22 13:33:54 +01:00
sam boyer
b8253ac3b9 deps: Update thema, use CUE fork (#60496)
* deps: Update thema, use CUE fork

* Remove superfluous openapi-codegen output

* Update thema again to catch cuetsy changes

* Rerun codegen with latest

* Latest thema, removes cuetsy update

* Latest of cuetsy

* Update type usage

* One last cuetsy rollback

* Update playlist summary tests

* More lint fixes

* Remove TS veneer changes for VariableHide

Co-authored-by: Clarity-89 <homes89@ukr.net>
2022-12-22 07:20:02 -05:00
Andres Martinez Gotor
9d64e7cedc Docs: Update Azure Monitor config parameters (#60577) 2022-12-22 11:56:14 +01:00
Dimitris Sotirakis
21a017e185 Lint: Fix lint-frontend step error (#60671)
yarn run prettier:write
2022-12-22 10:50:20 +00:00
Giedrius Statkevičius
0485cf34cd Plugins: Pass through dashboard/contextual HTTP headers to plugins/datasources (#60301)
`X-Dashboard-Uid`, `X-Datasource-Uid`, `X-Grafana-Org-Id`, `X-Panel-Id` are very useful headers set
by Grafana front-end that we would like to see on the data source as
well. This is so that it would be possible to pinpoint from where slow
queries are coming in Mimir/Thanos/Cortex/etc., for example. Relevant
Mimir code lines:
0a94f26203/pkg/frontend/transport/handler.go (L182-L184)

Tested manually that with these changes the headers are visible.
2022-12-22 11:15:00 +01:00
sam boyer
b28a208926 kindsys: Move code ownership of CustomStructured to apps platform team (#60497)
kindsys: Separate code ownership of CustomStructured
2022-12-22 10:20:25 +02:00
Torkel Ödegaard
c6db57c7d0 Scene: Exploring typed scene panels (#58168)
* Scene: Exploring typed scene panels

* Updated

* minor rename
2022-12-22 08:19:43 +01:00
Eve Meelan
c7671b6d1d Add copyright notice (#60658)
* Create copyright

* add copyright notice
2022-12-21 14:21:13 -08:00
Yuri Tseretyan
03cd7f0295 Chore: Add mysqld exporter to devenv (#55773)
Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
2022-12-21 16:10:55 -05:00
Kevin Minehart
dc00f6dbe3 CI: add log for branch deletion (#60647)
* add log for branch deletion
* return an err when branch deletion fails
2022-12-21 19:27:49 +00:00
Ashley Harrison
a16ca209fb Segment: Individual segments are now keyboard accessible (#60555)
use <button> for keyboard accessibility
2022-12-21 17:26:18 +00:00
Andreas Christou
0367036108 AzureMonitor: E2E update (#60624)
* Wait for locations call to complete

* Update drone to run cloud suite on tests update
2022-12-21 16:42:24 +00:00
Andreas Christou
2e4bc200f5 AzureMonitor: Correctly set filter values in portal URL (#60627)
* Correctly set filter values in portal URL

* Refactor to include dimensions as a part of AzureMonitor query

* Correctly set splitting value in URL

- Add type for dimension filters object

* Update tests

* Don't test dimensions
2022-12-21 16:30:17 +00:00
Gilles De Mey
cb1ca92419 Alerting: re-enable recording rule editor test (#60639) 2022-12-21 13:12:44 -03:00
Andreas Christou
f3f043e097 AzureMonitor: Set Logs portal URL from resource URI (#60583)
Set URL based off of resource URI
2022-12-21 15:46:31 +00:00
Gilles De Mey
16c6f223ba TimeSeriesPanel: Allow threshold indicators without change handler (#60575) 2022-12-21 16:18:35 +01:00
Ashley Harrison
44232569a8 ToolbarButtonRow: Overflow button now toggles visibility correctly (#60635)
* only close the overlay if we're interacting with something other than the overflow button/the overlay itself

* use a ref instead of a test id
2022-12-21 15:01:39 +00:00
Giordano Ricci
e723021e13 Explore: Re-initialize graph when number of series to show changes (#60499) 2022-12-21 15:01:26 +01:00
Giordano Ricci
838cbf22da Chore: remove various type assertions in Explore (#60501) 2022-12-21 15:01:03 +01:00
Sonia Aguilar
e219e2a834 Alerting: Recognise & change UI for OnCall notification policy + contact point (#60259)
* Identify and show onCall contact points with a badge in case the plugin is installed

* Add onCall logo for onCall contact points Badge

* Refactor and make Grafana App Receiver type more generic, not only for onCall type

* Show onCall notification policy in the specific routing table with special onCall badge

* Fix tests

* Move onCall badge to the type column in contact points view table

* Fix typos and remove onCallIntegrations from tagTypes in alertingApi

* Fetch only local plugins instead of all (external are not needed) and don't fetch plugin details

* Use directly useGetOnCallIntegrationsQuery and more PR review suggestions

* Move onCall contact point to the top in the drop-down,  in the notification policy view

* Add PR review requested changes
2022-12-21 14:46:55 +01:00
Matias Chomicki
c537d3699c Logs A11y: Support keyboard interactions with log lines (#60561)
* Logs A11y: Support keyboard interactions with log lines

* LogRowMessage: specify text align

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

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
2022-12-21 13:45:47 +00:00
Kristin Laemmert
c90756eef5 feat(grafana-cli): allow configuring admin ID for reset-admin-password (#60603)
* feat(grafana-cli): add a flag to control the admin user's ID for reset-admin-password

Since this is now more permissive, I've also added validation that the requested user is an admin.

* slight refactor to support testing
2022-12-21 08:24:33 -05:00
Joao Silva
bf541ee3d1 DatasourceList: Fixes using sub path on datasources URL (#59597) 2022-12-21 14:21:04 +01:00
Dominik Prokop
70dd5b42ce DataLinks: Allow providing a dynamic data link builder (#60452) 2022-12-21 05:09:31 -08:00
Kristina
0adb00b692 Explore: Use new icons for split pane resizing (#60391)
* Add icons, use them for split pane resizing

* Change icons

* Apply scale to child div

* Use fancier logic for displaying icon

* Remove color fill on icon

* Change icons, remove scale

* Change icons and logic
2022-12-21 07:07:05 -06:00
Ashley Harrison
78e12b140e TimePicker accessibility: remove stopPropagation from everywhere (#60404)
* remove stopPropagation from everywhere

* improve keyboard a11y in DateTimePicker
2022-12-21 13:04:47 +00:00
Sergey Kostrukov
96b7fb15de Plugins: Fix parsing of Azure settings for plugins (#60611)
Fix parsing of Azure settings for plugins
2022-12-21 13:37:33 +01:00
Marcus Efraimsson
c35c689a96 Plugins: Automatically forward plugin request HTTP headers in outgoing HTTP requests (#60417)
Automatically forward core plugin request HTTP headers in outgoing HTTP requests. 
Core datasource plugin authors don't have to specifically handle forwarding of HTTP 
headers, e.g. do not have to "hardcode" the header-names in the datasource plugin, 
if not having custom needs.

Fixes #57065
2022-12-21 13:25:58 +01:00
Armand Grillet
aaab477594 Use new link for templating docs (#60615) 2022-12-21 13:10:08 +01:00
Andres Martinez Gotor
733dbe0163 Azure Monitor: Remove references to Germany cloud (#60588) 2022-12-21 11:51:57 +01:00
renovate[bot]
2533b44cb6 Update dependency eslint to v8.30.0 (#60606)
* Update dependency eslint to v8.30.0

* update eslint sdk

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-12-21 10:51:38 +00:00
George Robinson
1a442de094 Docs: Rephrase opening sentence for Customize notifications (#60560) 2022-12-21 10:51:02 +00:00
Ashley Harrison
793a3f8d32 Accessibility: clean up VisualizationSuggestions (#60557)
clean up VisualizationSuggestions
2022-12-21 10:40:25 +00:00
Josh Hunt
51f5334748 Chore: Update typescript to 4.9.3 (#60538)
* Update typescript to 4.9.3

* Update from typescript changes
2022-12-21 10:25:29 +00:00
renovate[bot]
0e1700bcd3 Update dependency @cypress/webpack-preprocessor to v5.16.0 (#60605)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-21 10:22:10 +00:00
Jo
c6263ccabb SupportBundles: Add runtime information to basic info (#60616)
add extra basic info
2022-12-21 10:40:40 +01:00
Jo
d3031202b6 SupportBundles: Do not allow multiple collectors with the same UID (#60581)
* unexport service methods

* fix typos

* make constants

* do not allow double register of support bundle collectors

* fix get collectors response
2022-12-21 10:15:01 +01:00
Alexander Zobnin
5ef545d290 Role picker: Refactor menu components (#60584)
* Simplify underlying components

* Move state management deeper to RoleMenuGroupsSection component

* Get rid of some unnecessary props passing

* Reduce number of unnecessary re-renders

* Simplify state
2022-12-21 11:59:12 +03:00
Christopher Moyer
3d8890453f docs: corrects broken links (#60594)
correct broken links
2022-12-21 08:44:23 +00:00
Yuri Tseretyan
dc2ca80f4d Alerting: Refactor email notifier (#60602)
* refactor email to not use simplejson

* add tests

* split integration test and unit test + more unit-tests

* Remove outdated comment

Co-authored-by: Armand Grillet <2117580+armandgrillet@users.noreply.github.com>
2022-12-21 02:03:15 -05:00
Santiago
d070032065 Alerting: Fix incorrect links/aliases to template docs (#60597) 2022-12-20 22:38:01 +01:00
hugofqt
8adb16b662 Transformations: Grouping to matrix empty value option (#55591)
* feat: grouping matrix transformer empty value

Allow grouping matrix data transformer to define the value used when the matrix entry is not defined

* fix: grouping to matrix empty value test

* remove balel width for empty value text

Co-authored-by: bohandley <brendan.ohandley@gmail.com>
2022-12-20 15:25:55 -05:00
Karl Persson
c4b4baea2a AuthN: set org id for authentication request in service (#60528)
* AuthN: Replicate functionallity to get org id for request

* Authn: parse org id for the request and populate the auth request with
it

* AuthN: add simple mock for client to use in test

* AuthN: add tests to verify that authentication is called with correct
org id

* AuthN: Add ClientParams to mock

* AuthN: Fix flaky org id selection
2022-12-20 21:18:48 +01:00
Nicholas Auger
17696f8dec Removing hardcoded Cloud CTA in favor of a programmatic from website (#60179)
* Removing hardcoded Cloud CTA in favor of a programmatic from website

* makes prettier

Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
2022-12-20 13:58:59 -06:00
Yuri Tseretyan
4a3097f52a Alerting: Update Discord receiver to use encoding/json to build a webhook message + truncate long message (#60592)
* replace simplejson with models
* truncate too long messages

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>
2022-12-20 14:20:42 -05:00
Yuri Tseretyan
aaa55b4252 Alerting: Update Kafka receiver to use encoding/json to build messages (#60593)
Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>
2022-12-20 14:20:09 -05:00
Ivan Ortega Alba
3e52d5e72b Fix: Report E2E result stack trace (#60596) 2022-12-20 20:36:18 +02:00
brendamuir
620cc52863 Fixes Alertmanager links (#60591) 2022-12-20 17:09:34 +00:00
Yuri Tseretyan
a0bf62cc9e Alerting: Update receivers to use app version from factory config (#60585) 2022-12-20 11:23:10 -05:00
Sofia Papagiannaki
4df78cebc2 Nested Folders: Unify folder services (#60390)
* Nested Folders: Unify folder services
2022-12-20 17:38:09 +02:00
Konrad Lalik
53d1f4e50b Alerting: Add landing page (#59050)
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2022-12-20 16:21:56 +01:00
Andres Martinez Gotor
10cfc27397 AzureMonitor: Update SDK version (#60372) 2022-12-20 16:20:31 +01:00
Yuri Tseretyan
ec45c9c990 Alerting: update dingding, discord, googlechat, kafka, line notifiers to use encoding/json to parse settings (#60542)
also, rename Content to Message to match JSON name for Discord and GoogleChat
2022-12-20 09:46:13 -05:00
Andres Martinez Gotor
76e23a9fef Azure Monitor: Fix config editor style (#60563) 2022-12-20 15:44:02 +01:00
Andres Martinez Gotor
7db8d031d3 Azure Monitor: Fix health check for empty default subscription (#60569) 2022-12-20 15:32:22 +01:00
Christopher Moyer
b5834fd6d3 docs: fixes links (#60541)
fixes links
2022-12-20 08:18:56 -06:00
Kristin Laemmert
06ec8ad185 chore(docs): remove warning about (resolved) bug (#60539)
chore: remove warning about now-resolved bug
2022-12-20 09:05:15 -05:00
sam boyer
f86abf096d schema: Use generated dashboard model in frontend (#55769)
Co-authored-by: Ivan Ortega <ivanortegaalba@gmail.com>
Co-authored-by: Josh Hunt <joshhunt@users.noreply.github.com>
Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
Co-authored-by: polinaboneva <polina.boneva@grafana.com>
2022-12-20 15:04:14 +01:00
Jo
a553040441 Authn: Refactor user sync and org sync as post auth hooks (#60504)
* add user sync

* add org user sync

* add client params

* merge remaining conflicts

* remove change to report.go

* update comments

* add basic tests for user ID population

* add tests for auth ID find

* add tests for user sync create and update

* add tests for orgsync

* satisfy lint

* add userID guards
2022-12-20 08:59:05 -05:00
Karl Persson
1b1a14b6f6 ContextHandler: Get token from req context when performing rotation (#60533)
ContextHandler: get token from req context when performing end of
request rotation
2022-12-20 14:41:26 +01:00
Christian Segundo
707198227c Auth: Log a more useful msg if no OAuth provider configured (#56722)
Log a useful msg if no oauth provider configured

When a user doesn't configure an OAuth provider and uses auto login, Grafana logs a misleading message indicating that he has multiple providers configured.
2022-12-20 14:35:43 +01:00
Ashley Harrison
ba6d2f2a82 Chore: improve some more types (#60476)
* improve some more types

* fixes

Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
2022-12-20 13:07:57 +00:00
Sofia Papagiannaki
55b014974d Nested folders: Refactor folder update (#60323)
* Nested folders: Refactor folder update

* Apply suggestions from code review
2022-12-20 15:00:33 +02:00
George Robinson
5d4e35c3d5 Docs: Fix links in Using Go's templating language (#60564) 2022-12-20 12:30:43 +00:00
Andres Martinez Gotor
4d693863c0 GoogleCloudMonitoring: Adapt frontend to the new API format (#60173)
* GoogleCloudMonitoring: Migrate queries to the new format

* Refactor Aligment and AligmentFunction components (#60235)

* Adapt CloudMonitoringDatasource and CloudMonitoringAnnotationSupport (#60177)

* Fix: avoid migration for new queries (#60375)

* Move preprocessor handling to the backend (#60383)

* Other fixes and new function (#60411)

* Adapt components to the new API (#60451)

* Split metrics query type in time series list and query (#60475)

* Clean up metricQuery references (#60478)

* More bug fixes (#60525)
2022-12-20 12:47:49 +01:00
Alexander Zobnin
f6f140c412 Role picker: Fix handling groups with the same name (#60535)
* Role picker: split components into separate files

* Role picker: fix selection groups with the same name
2022-12-20 13:43:48 +03:00
Jo
2c7410c87d Admin: Add support bundles (#60536)
* Add support bundles

Co-authored-by: ievaVasiljeva <ieva.vasiljeva@grafana.com>
Co-authored-by: Kalle Persson <kalle.persson@grafana.com>

* tweak code owners

* rename and lint frontend

* lint

* fix backend lint

* register feature flag

* add feature toggle. fix small backend issues

Co-authored-by: ievaVasiljeva <ieva.vasiljeva@grafana.com>
Co-authored-by: Kalle Persson <kalle.persson@grafana.com>
2022-12-20 11:13:37 +01:00
Alexander Zobnin
6e2b148745 Role picker: Split components into separate files (#60519) 2022-12-20 13:05:37 +03:00
Yuri Tseretyan
35090c376c Alerting: Replace VictorOps receiver with the one from alerting repository (#60543)
* replace victorops with one from alerting

* update other usages
2022-12-20 10:55:41 +01:00
George Robinson
d7b555c405 Docs: Remove old message templates documentation (#60548) 2022-12-20 08:23:42 +00:00
juanicabanas
11a2a28ef5 PublicDashboards: Remove unnecessary css style in Audit Table (#60546)
unncessary global style filter-table removed
2022-12-20 02:31:18 +03:00
Alexander Weaver
ca3f8ba6f4 Alerting: Refactor alertmanager notifier to use encoding/json to parse settings instead of simplejson (#55507)
* replace basic auth header with method call

Co-authored-by: Yuri Tseretyan <yuriy.tseretyan@grafana.com>
2022-12-19 15:12:49 -05:00
Gareth Dawson
90185bea00 Loki: Change format of query builder hints (#60228)
* change format of query builder hints

* fix tests

* add hint property on query actions

* revert changes to prometheus hints

* respond to feedback

* fix failing tests

* trigger drone

Co-authored-by: Matias Chomicki <matyax@gmail.com>
2022-12-19 16:28:46 +00:00
Dimitris Sotirakis
158502572e CI: Add aws-marketplace pipeline (#60484)
* Add aws marketplace automation

# Conflicts:
#	.drone.yml

* Fix secret paths

# Conflicts:
#	.drone.yml

* Add docker socket

# Conflicts:
#	.drone.yml

# Conflicts:
#	.drone.yml

* s/enterprise2/enterprise

* Add dependency on the enterprise docker publish

# Conflicts:
#	.drone.yml

* Replace testing args with prod args

# Conflicts:
#	.drone.yml

* Fix path

# Conflicts:
#	.drone.yml
2022-12-19 11:25:48 -05:00
Zoltán Bedi
c25fe34ac0 SQL Datasources: Use health check for config test (#59867)
* SQL Datasources: Use health check for config test

* Remove unnecessary test

* Fix test errors

* Revert mysql go driver update

* Use transform query error

* Use TransformQueryError from sql_engine
2022-12-19 17:17:52 +01:00
Jo
77786f236a RBAC: Fix DeleteUserPermissions not being called on Upsert org sync (#60531)
* fix DeleteUserPermissions not being called on RemoveOrgUser

* do not error out of auth flow

* fix test missing service
2022-12-19 11:10:31 -05:00
Matias Chomicki
dbff9b4b97 CI: Enable coverage report for Elasticsearch (#60513) 2022-12-19 17:04:05 +01:00
Yuri Tseretyan
f0cabe14d5 Alerting: import Grafana alerting package and update usages (#60490)
* update remaining notifiers to use alerting package
2022-12-19 10:53:58 -05:00
Ashley Harrison
9b21375d78 Chore: remove @storybook/addon-knobs package (#60524)
remove @storybook/addon-knobs package
2022-12-19 15:35:32 +00:00
Dimitris Sotirakis
a1c2093b53 CI: Remove enterprise2 bits from enterprise pipelines (#60459)
Remove enterprise2 bits from enterprise pipelines
2022-12-19 17:30:49 +02:00
George Robinson
f6aea16894 Docs: Templating notifications (#60109)
* Docs: Templating notifications

* Feedback

* More feedback

* Edit template notifications

* More edits

* Fix typo

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
Co-authored-by: Armand Grillet <2117580+armandgrillet@users.noreply.github.com>
2022-12-19 15:01:18 +00:00
Ludovic Viaud
f67b8fe0dc Prometheus: Create feature flag to disable exemplar sampling (#60105)
:Fix rebase
2022-12-19 16:00:15 +01:00
Andriy
bce33eeb85 Add plugin spellcheck docs (#60512) 2022-12-19 15:59:34 +01:00
renovate[bot]
4f7920da06 Update dependency @testing-library/dom to v8.19.0 (#51151)
* Update dependency @testing-library/dom to v8.19.0

* refresh lockfile

* fix unit tests

* Revert "fix unit tests"

This reverts commit eb40f3207a.

* Revert "refresh lockfile"

This reverts commit c0cd5822da.

* ensure a consistent version of @testing-library/dom

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-12-19 14:44:46 +00:00
juanicabanas
6f609dbced PublicDashboards: Time range setting added (#60487)
Time range added for public dashboard: 

- Enable/Disable switch added in public dashboard configuration.
- Time range picker shown in public dashboard for viewer user
2022-12-19 17:38:37 +03:00
Gareth Dawson
65f7b93e6b Loki: Add format explanation to regex operations (#60518)
* change explain messages for regex operations

* update explain messages to use the more accurate RE2
2022-12-19 14:32:51 +00:00
KristianGrafana
da6f4067f7 Docs: add Grafana security hardening (#58973)
* Docs: add Grafana security hardening

* Apply suggestions from code review

Changed grammar and typos based on feedback.

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Move configure-security-hardening.md file to new directory to comply with Hugo.

* Linting with Prettier

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2022-12-19 08:31:07 -06:00
Sonia Aguilar
a812818457 Alerting: Show unknown badge instead of Error in group rule modal in case of Mimir unknown interval (#60515)
* Show unknown badge instead of Error in group rule modal in case of  Mimir unknown interval

* Use red Badge with xclamation-circle icon in case of Error in ForBadge

* Fix typo
2022-12-19 15:22:08 +01:00
Giordano Ricci
785c857ec7 QueryHistory: prevent query history tests from failing if the suite is rerun (#60462)
remove all queries from query history after running suite
2022-12-19 14:21:00 +00:00
Ludovic Viaud
645262d4a2 Prometheus: Remove promQueryBuilder feature flag (#60153) 2022-12-19 14:52:06 +01:00
Erik Sundell
e6b5c2655a Cloudwatch: Improve log group selector styling (#60370)
* add space between search field and result table

* add margin between checkbox and log group

* add space between result table and bottom buttons

* revert modal always open

* use secondary variant for cancel button

* fix spacing between selected log groups
2022-12-19 13:48:36 +01:00
Ludovic Viaud
4346a91dee Prometheus: Remove timeSeriesQuery query type (#60466) 2022-12-19 13:16:30 +01:00
Gilles De Mey
1f41dd5df2 Docs: Remove beta mention for expression queries (#60251) 2022-12-19 13:09:08 +01:00
Gilles De Mey
68b044fb7c RelativeTimeRangePicker: Don't respond to submit event when nested in a form element (#60495) 2022-12-19 13:08:33 +01:00
Will Browne
48b33ab521 Plugins: Unsigned chromium file should not invalidate signature for Renderer plugin (#59104)
* Plugins: Unsigned chromium file should not invalidate signature for Renderer plugin

* fix test

* re-work solution
2022-12-19 12:46:27 +01:00
Dimitris Sotirakis
02fbb1cd8f Chore: Remove unused config fields (#60393)
Remove unused config fields
2022-12-19 13:08:43 +02:00
Ashley Harrison
bc3d1fdd2a Command Palette: Correctly clear button styles when changing theme (#60511)
add topnav feature toggle to new theme created when using 'c t'
2022-12-19 10:59:28 +00:00
Armand Grillet
9941dfc2b6 Update the Alerting HA docs (#60292)
* Update the Alerting HA docs

* Update docs/sources/alerting/set-up/configure-high-availability/_index.md

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>

* Update docs/sources/alerting/set-up/configure-high-availability/_index.md

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>

* Update docs/sources/alerting/set-up/configure-high-availability/_index.md

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>

* Update docs/sources/alerting/set-up/configure-high-availability/_index.md

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>

* Update docs/sources/alerting/set-up/configure-high-availability/_index.md

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>

* Update HA introduction paragraph

* Apply prettier

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
2022-12-19 11:49:42 +01:00
renovate[bot]
1b860a4074 Update dependency rc-cascader to v3.8.0 (#60489)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-19 10:09:57 +00:00
renovate[bot]
76ce83be52 Update dependency prettier to v2.8.1 (#60483)
* Update dependency prettier to v2.8.1

* update prettier sdk

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-12-19 04:57:34 -05:00
Jack Baldry
97f01c0d1a Apply linting advice from doc-validator tool (#59606)
* Apply linting advice from doc-validator tool

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Prettier

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2022-12-19 09:49:44 +00:00
Jack Westbrook
f3f9697914 Storybook: Bump dark-mode addon to 2.0.4 and remove patch (#60384)
chore(storybook): bump dark-mode addon to 2.0.4 and remove patch
2022-12-19 10:43:21 +01:00
renovate[bot]
271dbbb552 Update dependency msw to v0.49.2 (#60482)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-19 09:42:43 +00:00
Ashley Harrison
3c399ed943 Accessibility: Render gauge as a button when onClick is provided (#60396)
render gauge as a button when onClick is provided
2022-12-19 09:40:45 +00:00
Sofia Papagiannaki
b1ef5ab320 Nested Folders: Support listing nested folder children (#58566)
* Nested Folders: Support listing nested folder children

* Filter out subfolders with no permissions

* Apply suggestion from code review
2022-12-19 10:52:04 +02:00
Karl Persson
0743c4eb87 ServiceAccount: Rewrite the api test to use fakes (#60441)
* RBAC: Add fake for permissions service

* ServiceAccount: Rewrite create api tests

* ServiceAccount: Rewrite api delete tests

* ServiceAccount: Rewrite api test for RetriveServiceAccount

* ServiceAccount: Refactor UpdateServiceAccount api test

* ServiceAccount: Refactor CreateToken api test

* ServiceAccount: refactor delete token api tests

* ServiceAccount: rewrite list tokens api test

* Remove test helper that is not used any more

* ServiceAccount: remove unused test helpers
2022-12-19 09:27:52 +01:00
Karl Persson
2e53a58bc3 Authn: Add client for api keys (#60339)
* AuthN: Add functionallity to test if auth client should be used

* AuthN: Add bolierplate client for api keys and register it

* AuthN: Add tests for api key client

* Inject service

* AuthN: Update client names

* ContextHandler: Set authn service

* AuthN: Implement authentication for api key client

* ContextHandler: Use authn service for api keys if flag is enabled

* AuthN: refactor authentication method to return additional value to
indicate if client could perform authentication

* update prefixes

* Add namespaced id to identity

* AuthN: Expand the Identity struct to include required fields from signed
in user

* Add error for disabled service account

* Add function to write error response based on errutil.Error

* Add error to log

* Return errors based on errutil.Error

* pass error

* update log message

* Fix namespaced ids

* Add tests

* Lint
2022-12-19 09:22:11 +01:00
sam boyer
cc4d18f626 kindsys: Include composable kinds and planned maturity in report (#60477)
kindsys: Include composable kinds + planned maturity
2022-12-19 09:14:51 +01:00
Yuri Tseretyan
92d12fdefa Alerting: Remove fake secret service in tests (#60488) 2022-12-16 15:01:41 -05:00
Yuri Tseretyan
9ad45aedcf Alerting: replace usage of simplejson to json.RawMessage in NotificationChannelConfig (#60423)
* introduce alias for json.RawMessage with name RawMessage. This is needed to keep raw JSON and implement a marshaler for YAML, which does not seem to be used but there are tests that fail.
* replace usage of simplejson with RawMessage in NotificationChannelConfig
* remove usage of simplejson in tests
* change migration code to convert simplejson to raw message
2022-12-16 13:01:06 -05:00
Ivana Huckova
09bb4423d2 Elasticsearch: Fix pipeline aggregation queries in backend to pass frontend tests (#60337)
* Elasticsearch: Fix pipeline aggregation queries in backend

* Update

* Update lint

* Update pkg/tsdb/elasticsearch/time_series_query.go

* Fix lint

* Fix merge
2022-12-16 17:45:43 +01:00
Kristin Laemmert
cc007e9727 chore: sqlstore cleanup (#60415)
* chore: remove unused test helper from sqlstore

TimeNow() is no longer used in any tests in this package.

* chore: move sqlstore.SQLBuilder to the infra/db package

This required some minor refactoring; we need to be a little more explicit about passing around the dialect and engine. On the other hand, that's a few fewer uses of the `dialect` global constant!

* chore: move UserDeletions into the only package using it

* cleanup around moving sqlbuilder

* remove dialect and sqlog global vars

* rename userDeletions to serviceAccountDeletions
2022-12-16 11:09:06 -05:00
Ivana Huckova
d332dab3ec Elasticsearch: Refactor parse query (#60440)
* Refactor parse query to functions

* Move parsing to new file

* Create empty result variable and use it when returning early

* Fix linting

* Revert "Create empty result variable and use it when returning early"

This reverts commit 36a503f66e.
2022-12-16 16:30:36 +01:00
Kristin Laemmert
e4a877b123 chore: attempt to fix flapping "organization not found" tests (#60418)
we live in hope!
2022-12-16 10:10:59 -05:00
Alexander Weaver
91bd1cdb41 Revert "Alerting: Store alertmanager configuration history in a separate table in the database" (#60470)
Revert "Alerting: Store alertmanager configuration history in a separate table in the database (#60197)"

This reverts commit ec80f38c34.
2022-12-16 10:07:44 -05:00
Ludovic Viaud
63df11b729 Prometheus: Hide query section when empty (#60304) 2022-12-16 15:09:47 +01:00
linoman
25d7c591cf Auth: Add plugin roles to RolePicker (#59667)
* Add `RoleMenuGroupsSection` component

* Add plugin roles data structures

* Use `RoleMenuGroupsSection` for rendering roles

Co-authored-by: Alexander Zobnin <alexanderzobnin@gmail.com>
2022-12-16 14:41:09 +01:00
Gilles De Mey
1da7bf7f60 Alerting: Increase test timeout (#60445) 2022-12-16 12:41:38 +01:00
Alex Moreno
174c61b949 Alerting: Set Dashboard and Panel IDs on rule group replacement (#60374)
* Set Dashboard and Panel IDs on rule group replacement

* fix comments and abbreviate test variable name

* Update pkg/services/ngalert/provisioning/alert_rules.go

Co-authored-by: Jean-Philippe Quéméner <JohnnyQQQQ@users.noreply.github.com>

Co-authored-by: Jean-Philippe Quéméner <JohnnyQQQQ@users.noreply.github.com>
2022-12-16 11:47:25 +01:00
Levente Balogh
689f30623a Levitate: Fix typo in CI workflow scripts (#60438)
Fix: Typo in a Levitate CI script
2022-12-16 05:21:46 -05:00
Fionera
055c3b7332 Prometheus: Add POST support to client (#60243)
* Prometheus: Add POST support to client

* Prometheus: Revert client test change from 1c503908
2022-12-16 11:15:19 +01:00
renovate[bot]
fe0d34c408 Update dependency mini-css-extract-plugin to v2.7.2 (#60421)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-16 10:03:09 +00:00
mikkancso
e4d4eacd36 Connections: Render a landing page for pages without actual content (#60369)
* render a landing page for pages without actual content

To be consistent with other pages in Grafana

* update tests
2022-12-16 11:00:35 +01:00
Ashley Harrison
9bbc2c4cbb Chore: fix some typings in @grafana/data (#60009)
fix some typings in @grafana/data
2022-12-16 09:59:00 +00:00
renovate[bot]
2e3c4a7626 Update dependency mocha to v10.2.0 (#60422)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-16 09:58:27 +00:00
renovate[bot]
4d16cf05ec Update dependency esbuild to v0.16.7 (#60326)
* Update dependency esbuild to v0.16.7

* chore(packages): bump rollup-esbuild-plugin to 5.0.0

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
2022-12-16 04:48:59 -05:00
Alexander Weaver
ec80f38c34 Alerting: Store alertmanager configuration history in a separate table in the database (#60197)
* Update config store to split between active and history tables

* Migrations to fix up indexes

* Implement migration from old format to new

* Move add migrations call

* Delete duplicated rows

* Explicitly map fields

* Quote the column name because it's a reserved word

* Lift migrations to top
2022-12-15 17:35:00 -06:00
Grot (@grafanabot)
dcd30f9b5d Changelog: Updated changelog for 9.3.2 (#60428) 2022-12-15 22:48:45 +00:00
Galen Kistler
f7bd85d7f4 Prometheus: Updating editor value on Monaco's onDidChangeContent performance issues (#60191)
debounce slow function that is running on each keystroke
2022-12-15 14:15:57 -06:00
Andreas Christou
5fd8d515be Bump code coverage versions (#60419) 2022-12-15 14:32:19 -05:00
Matias Chomicki
c7c7cad4ba Workflows: include Loki to OX code coverage workflow (#60341) 2022-12-15 20:15:31 +01:00
Drew Slobodnjak
5c7f77e402 Geomap: Add color gradients to route layer (#59062)
* Geomap: Add color gradients to route layer

* Add support for all color schemes

* Address PR feedback: remove ! from verified object

* Add arrow support and simplify color functions

* Simplify and clean-up code

* Remove line width slider and drive width by size

* Drive arrow size based on size

* Allow arrows for fixed color

* Add gdev dashboard

* Use square line caps only when arrows are active

* Apply size to width for fixed color and size

* Handle arrows when size and color are fixed

* Add tags to gdev dashboard

* Fix null error in backend test for gdev dashboard

Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2022-12-15 09:54:08 -08:00
Hamas Shafiq
3dc74bd74b Chore: Refactor TickLabels.test.js to TypeScript (#59956) 2022-12-15 17:11:17 +00:00
Sonia Aguilar
1f871d1dff Alerting: Add refactoring todo for getting rid of '+ Add new' option in drop-downs (#60405) 2022-12-15 11:24:58 -05:00
Giuseppe Guerra
92c01e416e Prometheus: Fix X-Id-Token and X-ID-Token sent to Prometheus in query requests (#60342)
* Prometheus: Use Set rather than map assignment in sdkHeaderToHttpHeader
Fixes #59940

* Prometheus: Add TestPrometheusCanonicalHeaders
2022-12-15 17:18:38 +01:00
Yuri Tseretyan
6637333748 Alerting: refactor notifiers to use package specific Logger interface (#60361)
* introduce Logger interface local to channles + implementaton that wraps the Grafana logger
* make NewFactoryConfig accept LoggerFactory
* add logger field to FactoryConfig
* update usages of log.Logger to internal interface
2022-12-15 11:10:31 -05:00
Torkel Ödegaard
0fb9987d12 TablePanel: Improve and align table styles with the rest of Grafana (#60365)
* TablePanel: Improve and align table styles with rest of Grafana

* Fixing footer styles
2022-12-15 16:45:00 +01:00
renovate[bot]
8b5ad5824a Update dependency eslint to v8.29.0 (#60328)
* Update dependency eslint to v8.29.0

* update sdk version

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-12-15 10:02:55 -05:00
renovate[bot]
da0054ae07 Update dependency lint-staged to v13.1.0 (#60381)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-15 14:50:31 +00:00
Dominik Prokop
44ce67aef5 SceneDataTransformer: Update data state regardless of loading state (#60394)
SceneDataTransformer: useconsumed data when loading state is different than Done
2022-12-15 06:45:46 -08:00
Sofia Papagiannaki
11d8bcbea9 Guardian: Introduce additional constructors (#59577)
* Guardian: Use dashboard UID instead of ID

* Apply suggestions from code review

Introduce several guardian constructors and each time use
the most appropriate one.
2022-12-15 16:34:17 +02:00
Marcus Efraimsson
6478d0a5ef Plugins: Forward user header (X-Grafana-User) in backend plugin requests (#58646)
Grafana would forward the X-Grafana-User header to backend plugin request when 
dataproxy.send_user_header is enabled. In addition, X-Grafana-User will be automatically
forwarded in outgoing HTTP requests for core/builtin HTTP datasources. 
Use grafana-plugin-sdk-go v0.147.0.

Fixes #47734

Co-authored-by: Will Browne <wbrowne@users.noreply.github.com>
2022-12-15 15:28:25 +01:00
Josh Hunt
ecf83a6df9 Search: Fix report search usage from throwing in console (#60382) 2022-12-15 13:58:20 +00:00
Ezequiel Victorero
8d5b19bc61 PublicDashboards: support time range selection on the backend (#60203) 2022-12-15 10:44:33 -03:00
Erik Sundell
6928ad2949 Cloudwatch: Add run query button (#60089)
* refactor header

* split left and right header actions

* cleanup

* fix broken tests

* move MetricsQueryEditor tests to QueryEditor tests

* fix mock imports

* remove no longer used onRunQuery func

* move run queries button

* apply defaults also when changing query type

* remove not used prop
2022-12-15 14:29:57 +01:00
Dominik Prokop
66c076f24e Scenes: Add support for transformations (#60329)
* Add support for transformations

* Add tests for data transformers

* Provide replace function to transformations

* Unsubscribe from existing transformations stream if new data comes in
2022-12-15 04:56:29 -08:00
Ashley Harrison
b2da0d22af Navigation: show section toggle if there are any react children (#60336)
show section toggle if there are children
2022-12-15 12:41:46 +00:00
Gábor Farkas
3cfeac9c5a elastic: enabled more tests (#60331) 2022-12-15 07:40:41 -05:00
Konrad Lalik
384322dc14 Alerting: Access query details of provisioned alerts (#59626)
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2022-12-15 13:33:41 +01:00
Emil Tullstedt
b7fc837c35 Chore: Upgrade golangci-lint to v1.50.1 (#60379) 2022-12-15 12:58:48 +01:00
Sofia Papagiannaki
efd827fd65 Chore: Trigger backend lint on bingo updates (#60380)
Chore: Trigger backend lind on bingo updates
2022-12-15 06:48:00 -05:00
Shirley
06a2943cb6 Cloudwatch: Refactor logs query field (#59503)
* Refactor LogsQueryField to function component (#59503)
2022-12-15 10:54:05 +01:00
Ida Štambuk
3ef440b30a Cloudwatch: Increase label width in Config Editor (#60333)
* Increase cloudwatch config label width
2022-12-15 10:51:23 +01:00
Neil Fordyce
b0874d8059 DataProxy: Populate X-Grafana-Referer header (#60040)
* ProxyUtil: Populate X-Grafana-Referer header

* ProxyUtil: Move Referer/Origin header removal

So that the removal and setting X-Grafana-Referer logic applies to all
proxied requests and not just datasource proxy.

* ProxyUtil: Test to guard against multiline headers

* ProxyUtil: Explicitly check injected header isn't parsed
2022-12-15 10:08:10 +01:00
Matias Chomicki
5dfa59884e Loki Query Editor: Update history items with successive queries (#60327)
feat(loki-monaco-autocomplete): add support to update history with successive queries
2022-12-15 10:03:05 +01:00
Sven Grossmann
ae05c6180c Loki/ES: Add further items to query tracking (#60347)
* add more tracking to queries from ES and Loki

* improve tracking elasticsearch

* update type assertion

* remove unused import
2022-12-15 09:59:50 +01:00
Marcus Andersson
d0a68b266c Bugfix: Attach correct link to "levitate detect breaking changes"-message included in PR (#60220)
* Fixed so we link to the proper job and step.

* Fixed according to feedback.

* Added check_suite to the job link
2022-12-15 09:56:23 +01:00
Dimitris Sotirakis
f73cdc5e80 Metadata: Move and rename genversions.go and genversions_test.go (#60315)
* Move and rename genversions.go and tests

* Fix lint - bring back cli.Exit

* Move package.json and fix tests

* Add necessary env vars for promote event
2022-12-15 03:51:11 -05:00
mikkancso
edb86d4bf3 DataSources: fix DataSourceAddButton component (#60176)
* fix DataSourceAddButton component

This component implicitly returned `false` when `canCreateDataSource`
was false, and that way it didn't qualify as a function component.
We fixed it to explicitly return null in this case.

* DataSourceAddButton: update function signature

This is more consistent with other code in this codebase.
2022-12-15 09:25:03 +01:00
Sonia Aguilar
171cd60480 Alerting: Enable editing evaluation interval in alert form when creating a new group (#60083)
* Enable editing evaluation interval in alert form when creating a new group

* Disable group when no folder selected and focus on group when clicking add new

* Improve group selector showing interval as a description for each option

* Fix evaluate every input and label aligment

* Fix columns width in EditRuleGroupModal rules table

* Reduce amount of space in the evaluation behaviour section
2022-12-15 08:28:47 +01:00
Torkel Ödegaard
79ffb699ee Revert "TablePanel: Improve and align table styles with rest of Grafana"
This reverts commit 1e28ee41cc.
2022-12-15 07:15:35 +01:00
Torkel Ödegaard
1e28ee41cc TablePanel: Improve and align table styles with rest of Grafana 2022-12-15 07:14:17 +01:00
Yuri Tseretyan
0e7c95a4d2 Alerting: Remove reference to global models package in channels package (#60358)
* remove intermediate struct to create Base struct
* fix alertmanager
2022-12-14 16:21:55 -05:00
George Robinson
342b0f3668 Alerting: Rename contact point type to receiver in the user interface (#59589)
This commit renames contact point type to integration in the user interface
as "New contact point type" suggests that you are creating a new type,
when instead you are just creating a new integration of a pre-determined type,
such as email or Slack. You can also have two or more integrations of the same
type, something which is not apparent from the current text.

This change will also make it easier to explain the difference between
a contact point integration, and how to configure an integration of a certain type,
such as email.
2022-12-14 20:50:36 +00:00
renovate[bot]
9d3c1f0cbd Update dependency @leeoniya/ufuzzy to v0.9.0 (#60302)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-14 14:03:23 -06:00
Sven Grossmann
386faf5958 OpenSearch: Use aoss servicename if OpenSearch is configured as serverless (#60344)
* Use `aoss` if opensearch is configured as `serverless`
2022-12-14 20:22:26 +01:00
Kristina
5a7f38053b Remove explore compact URLs (#59686)
* Remove explore compact URLs

* Remove two explore link builders that create compact URLs

* Fix merge conflict
2022-12-14 12:57:53 -06:00
Kim Nylander
d3afe9e85c [DOC] Add link to access policies (#60352)
* Add link to access policies

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2022-12-14 10:45:44 -08:00
Yuri Tseretyan
de008005ce Alerting: isolate ImageStore in notify package (#60353) 2022-12-14 13:20:20 -05:00
Brendan O'Handley
286af5a53b Transformations: Fix bug in convert fields boolean to number (#60277)
* fix bug in convert fields boolean to number

* check for string outside of loop
2022-12-14 13:00:10 -05:00
Brendan O'Handley
d5d07894b1 Graphite: bug fix, strip white space from queries before comparing them (#60133)
strip white space from queries before comparing them
2022-12-14 11:39:29 -05:00
Matias Chomicki
4be99c56f6 Loki Query Editor: Autocompletion and suggestions improvements (unwrap, parser, extracted labels) (#59103)
* Chore: refactor test to improve internal categorization of scenarios

* feat(loki-monaco-unwrap): add unwrap situation support

* Chore: remove redundant path from aggregation situation

* feat(loki-monaco-unwrap): add unwrap suggestions

* feat(loki-monaco-autocomplete): rename IN_DURATION and add missing tests

* feat(loki-monaco-autocomplete): detect parser and line filter

* feat(loki-monaco-autocomplete): optionally suggest line filters and parsers

* feat(loki-monaco-autocomplete): improve suggestions and update completions tests

* feat(loki-monaco-autocomplete): allow for multiple line filters suggestions

* Chore: update situations test

* Chore: add test case for AFTER_UNWRAP completion

* feat(loki-monaco-autocomplete): use logs query instead of labels for data sample

* Chore: improve getParser function name and add tests

* Chore: update test mock data

* Update public/app/plugins/datasource/loki/components/monaco-query-field/monaco-completion-provider/situation.test.ts

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

* feat(loki-monaco-autocomplete): improve after unwrap detection

* feat(loki-monaco-autocomplete): remove leftover parser detection

* Chore: completely remove parser suggestion exclusion implementation

It was correct to have more than one parser, so we don't need to exclude parsers if one is present.

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2022-12-14 11:37:08 -05:00
MeanMina
3605103e28 Chore: New workflow to add and update epic issue into parent project (#59909)
* Create issue-add-to-parent-project.yml

Tested in https://github.com/grafana/github-actions-testrepo/blob/main/.github/workflows/issue-add-to-parent-project.yml

* Rename issue-add-to-parent-project

Rename issue-add-to-parent-project and update to make it clear it's Platform UX specific for now.

* Add action trigger on closed epics

Update epic-add-to-platform-ux-parent-project.yml to add action trigger on closed alongside the others and fix typo.
2022-12-14 11:27:59 -05:00
ying-jeanne
b059296cb0 [nested folder]Add circular reference detection in create nested folder (#60163)
* add circulic reference detection in create neste folder

* redeclare mock

* add log for getHeight when depassing limit
2022-12-14 11:07:55 -05:00
Yuri Tseretyan
7c3ab4a715 Alerting: Remove dependency on Grafana notifications package in alerting notifiers (#60271)
* create sender service interface and bridge to grafana notifier service
* update notifiers to use local sender interface
2022-12-14 10:59:37 -05:00
Yuri Tseretyan
07b5043222 Alerting: Add support for settings parse_mode and disable_notifications to Telegram reciever (#60198) 2022-12-14 10:44:39 -05:00
Andreas Christou
c81df0dec0 AzureMonitor: Add custom header support to Azure Monitor (#60269)
* Add integration test for Azure Monitor

- Add Azure Monitor to datasource types
- Update instance creation to correctly set HTTP client options
- Combine custom azure headers and custom grafana headers on HTTP client creation
- Update HTTP client tests

* Test custom azure headers
2022-12-14 15:09:11 +00:00
Virginia Cepeda
e3805e1309 Alerting: Track events for rule creation/abortion (#59912)
* Track events for rule creation/abortion

These events will be sent to Rudderstack using the EchoSrv in order to be consumed from Intercom

* Change method names and send user_id

* Track validation errors

* Only track errors for rule creation
2022-12-14 11:50:15 -03:00
Yuri Tseretyan
ad09feed83 Alerting: rule backtesting API (#57318)
* Implement backtesting engine that can process regular rule specification (with queries to datasource) as well as special kind of rules that have data frame instead of query.
* declare a new API endpoint and model
* add feature toggle `alertingBacktesting`
2022-12-14 09:44:14 -05:00
Josh Hunt
258696409d Dashboards: Fix 'Make Editable' button not working in Dashboard Settings (#60306)
* Dashboards: Fix 'Make Editable' button not working in Dashboard Settings

* comment
2022-12-14 14:24:09 +00:00
renovate[bot]
ac93c5321b Update dependency centrifuge to v3.1.0 (#60303)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-14 14:10:19 +00:00
Josh Hunt
af719888d6 Chore: Remove any type assertion in PanelQueryRunner (#60096) 2022-12-14 14:07:22 +00:00
Sven Grossmann
6f64dd533f Devenv: Add back loki-promtail (#60282)
* add back loki-promtail

* update README

* add MacOS note
2022-12-14 15:02:12 +01:00
Ida Štambuk
30e2de89ec Chore: Update code-coverage version to 0.1.13 (#59545)
Update code-coverage version to 0.1.13
2022-12-14 14:44:51 +01:00
Josh Hunt
495fceeeef Dashboards: Wrap MakeEditable in the new Page layout (#60311)
Wrap MakeEditable in the new Page layout
2022-12-14 13:32:29 +00:00
Leo
c75ed8fa69 Accessibility: Improved keyboard accessibility in BigValue (#59830)
use appropriate elements when rendering BigValue
2022-12-14 14:28:44 +01:00
Ashley Harrison
3a5c3b517c Navigation: conditionally use actions in DataSourceListPage (#60300)
* conditionally use actions in DataSourceListPage

* fix unit tests
2022-12-14 13:19:29 +00:00
Ivana Huckova
70e34e7f32 Elasticsearch: Fix defaulting to time field if no field is specified in aggregation (#60238)
* Elasticsearch: Add test for using timeField from datasource when not specified in query

* Add default to timefield

* Merge fix
2022-12-14 14:19:03 +01:00
Ivana Huckova
d3ef86bd90 Elasticsearch: Add query building for log queries (#60182)
* Elasticsearch: Fix ordering in raw_document and add logic for raw_data

* Add comments

* Fix raw data request to use correct timefield

* Fix linting

* Add raw data as metric type

* Fix linting

* Elasticsearch: Add defaults for log query

* Add higlight

* Fix lint

* Add snapshot test

* Implement correct query for logs

* Update

* Adjust naming and comments

* Fix lint

* Remove ifs
2022-12-14 13:56:09 +01:00
Emil Tullstedt
3188a8288e Settings: Update reference to go-kit/log (#60309)
Introduced after last update to #59732.
2022-12-14 12:48:09 +00:00
Matias Chomicki
2c1b65021d feat(loki-query-autocomplete): suggest unique history items (#60262) 2022-12-14 07:43:06 -05:00
Josh Hunt
9a41277ecd Dashboards: Show error when data source is missing (#60099)
Return caught exceptions to panel as error state
2022-12-14 12:37:31 +00:00
juanicabanas
666f69ca14 PublicDashboards: Add react-hook-form for Public Dashboard modal (#60249) 2022-12-14 09:12:09 -03:00
Kyle Brandt
55d2d872ec Chore: Missed deprecations due to overly broad lint exclusion (#59732) 2022-12-14 12:32:45 +01:00
Ida Štambuk
cea5e6589d Cloudwatch: Define and use getDefaultquery instead of calling onChange on mount (#60221)
* Implement getDefaultQuery for cloudwatch logs and metrics

* Fix bug with query reference in queryMigrations and replace tests

* Move migrate functions to /migrations, remove onChange from LogsQueryField

* [EMPTY] Retry CI

* Fix naming
2022-12-14 12:21:36 +01:00
renovate[bot]
6fcea37638 Update dependency @react-types/shared to v3.16.0 (#60265)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-14 11:03:54 +00:00
Ieva
6aa5a79cad Access control: endpoint for searching single user permissions (#59669)
* initial commit

* clean up

* fix a bug and add tests

* more tests

* undo some unintended changes

* undo some unintended changes

* linting

* PR feedback - add user ID to search options

* simplify the query

* Apply suggestions from code review

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>

* remove unneeded formatting changes

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
2022-12-14 10:53:25 +00:00
Esteban Beltran
d9d94ebc56 Toolkit: Deprecate all plugin related commands (#60290) 2022-12-14 11:10:05 +01:00
renovate[bot]
a75829a5f7 Update dependency @wojtekmaj/enzyme-adapter-react-17 to v0.8.0 (#60270)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-14 10:05:07 +00:00
Joey Tawadrous
bf8814749e Traces: Fix for multiple $__tags in trace to metrics (#59641)
* Fix interpolation of multiple  in query

* Add another  to test case
2022-12-14 09:51:43 +00:00
Ashley Harrison
bb2ecb1468 Influx: Query segment menus now position correctly near the bottom of the screen (#60087)
* only open the menu once options are loaded for better positioning

* use !loadState.loading instead of Boolean(loadState.value)
2022-12-14 09:51:04 +00:00
ms-hujia
5010765115 Azure Monitor: Propagate the error when failed to get datasource instance (#60210)
Propagate the error when failed to get instance
2022-12-14 10:36:41 +01:00
Andres Martinez Gotor
b4e76e75b1 AzureMonitor: Fix filter query for empty queryType (#60252) 2022-12-14 09:54:19 +01:00
Misi
6d8bf5ac01 LDAP: Disable user in case it has been removed from LDAP directory (#60231)
* Fix login flow

* Align test

* Fix comments

* Improve test
2022-12-14 03:41:51 -05:00
renovate[bot]
ed28324233 Update dependency @types/react-calendar to v3.9.0 (#60266)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-14 09:12:22 +01:00
Leon Sorokin
e0eacf1b04 StateTimeline: Fix negative infinity legend/tooltip from thresholds (#60279) 2022-12-13 21:56:59 -08:00
Ryan McKinley
4064fa51c6 Export: move export page to a full page (not view on storage) (#60263)
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2022-12-13 19:40:20 -08:00
Alexander Weaver
821614fb43 Alerting: Align notifier truncation and logging with prometheus/alertmanager (#59339)
* Move truncation code to util to mirror upstream

* Resolve merge conflicts

* Align logging of alert key

* Update tests and fix field passing bug

* Remove superfluous newline in test now that we trim whitespace

* Uptake minor log changes from upstream
2022-12-13 19:50:24 -06:00
Isabella Siu
d6bb2a7493 Cloudwatch: Fix deeplink with default region (#60260)
Cloudwatch: fix deeplink with default region
2022-12-13 15:24:28 -05:00
Misi
7bb5200cc2 Devenv: OpenLDAP-Mac improvements (#60229)
* Use groupOfUniqueNames and uniqueMember

* Update README.md
2022-12-13 18:20:37 +01:00
Matias Chomicki
58a41af3f3 Loki Query Editor: Add support to display query parsing errors to users (#59427)
* feat(loki-query-validation): validation proof of concept

* feat(loki-query-validation): refactor and properly display the error portion

* feat(loki-query-validation): add support for multi-line queries

* feat(loki-query-validation): improve display of linting errors to users

* feat(loki-query-validation): add unit tests

* Chore: remove unused import

* wip

* Revert "wip"

This reverts commit 44896f7fa2d33251033f8c37776f4d6f2f43787d.

* Revert "Revert "wip""

This reverts commit f7889f49a6b0bdc5a4b677e9bbb8c62ea3cccb74.

* feat(loki-query-validation): parse original and interpolated query for better validation feedback

* feat(loki-query-validation): refactor interpolated query validation support

* feat(loki-query-validation): improve validation for interpolated queries
2022-12-13 12:07:59 -05:00
renovate[bot]
c2dcf78fac Update dependency @react-types/button to v3.7.0 (#60241)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-13 16:04:03 +00:00
Ryan McKinley
cf055ab4ec k8s: Add a dev only feature flag and simple service to get a client (#60204) 2022-12-13 07:41:16 -08:00
Sven Grossmann
ebd728a99a Logs: Fix Logs Pagination Button styling (#60219)
use css class rather css strings
2022-12-13 16:23:16 +01:00
Laura Fernández
5f4435b693 GLDS: Update icons in Storybook (#60183) 2022-12-13 16:17:55 +01:00
renovate[bot]
d08d1e6f0f Update dependency @opentelemetry/semantic-conventions to v1.8.0 (#60230)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-13 14:59:26 +00:00
Ashley Harrison
535c4576f7 Command Palette: Fix not being able to type if triggered whilst another modal is open (#59728)
handle command palette in the same way as other modals
2022-12-13 14:44:32 +00:00
Ashley Harrison
c801f030fb Navigation: use the branding menu logo in topnav (#60227)
use the branding menu logo in topnav
2022-12-13 14:44:18 +00:00
Domas
c2cea076ee Chore: Add deprecation warnings for Sentry (#60165) 2022-12-13 16:41:42 +02:00
Dan Cech
fe3ae49cce Backend: Consistently use context RemoteAddr function to determine remote address. (#60201)
consistently use context RemoteAddr function to determine remote address
2022-12-13 09:33:05 -05:00
Ashley Harrison
4e7a316903 TimePicker: Fix time picker selection (#60104)
fix time picker selection
2022-12-13 14:11:15 +00:00
Gabriel MABILLE
109df85cae RBAC: Add benchmarks to search all users given a specific permission (#59980)
* RBAC: Add benchmarks to search all users given a specific permission

* Add missing time

* Inline benchmarks

* Make bench setup memory efficient

* fix user id

* comment

* Ran 10K_10k and got a better time this time

* change comment to pass linting

* change comment to pass linting

* Update pkg/services/accesscontrol/acimpl/service_bench_test.go

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
2022-12-13 09:07:15 -05:00
Dimitris Sotirakis
be0e4ab179 Enterprise checks: Update pull request check regexp for enterprise (#60234)
Update pull request check regexp for enterprise
2022-12-13 08:01:20 -06:00
Eric Leijonmarck
371d7850a5 Auth: Service account store refactor (#58961)
* refactor: renaming of files from database to store

* refactor: make service account store private

- moves store interface to manager package
- adds an interface to the ProvideAPI constructor
- refactors tests to use the store when necessary
- adds mocks for the new interface implementations in the tests package

* wip

* refactor: make fakestore in service

* wip

* wip

* wip

* working tests

* trailing whitespaces

* Update pkg/services/serviceaccounts/api/api.go

* Update pkg/services/serviceaccounts/tests/common.go

* Update pkg/services/serviceaccounts/tests/common.go

* refactor: doc string for retriever

* fix import unused

* remove: serviceaccount from featuretoggle

* added: back legacy serviceaccounts feature toggle

* added: docs

* refactor: make query for the SearchQuery

* add: validation of service input fields

* add validation
2022-12-13 14:56:10 +01:00
renovate[bot]
13adaddfaa Update babel monorepo (#60208)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-13 13:52:47 +00:00
Shirley
db145774d3 CloudWatch: Fix logs insights deeplink (#59906)
* CloudWatch: Add arns to log insights button

* start test

* convert to function component

* add tests

Co-authored-by: Erik Sundell <erik.sundell87@gmail.com>
2022-12-13 14:50:39 +01:00
Dominik Prokop
239888f229 Snapshots: Build snapshot originalUrl on the backend (#60232)
* Snapshots: Fix originalUrl spoof security issue

* Store relative URL only & validate UID

* use existing modal management tools

* Dummy commit to nudge CI

* Remove unused hooks file

* Fix import after backport

* Backport fixes

Co-authored-by: kay delaney <kay@grafana.com>
2022-12-13 05:48:54 -08:00
Emil Tullstedt
f864be5024 Chore: Deny gopkg.in/yaml.v2 (#60187) 2022-12-13 14:31:04 +01:00
Andre Pereira
209b1848b8 Tempo: Merge Trace ID and TraceQL tabs (#60180)
* Remove TraceID tab when TraceQL is enabled. Use TraceQL editor to query for trace IDs by checking whether the content is an hex only string

* Highlight valid trace IDs in traceql editor

* Update trace and span links to use TraceQL tab when feature flag is enabled

* Remove traceqlEditor feature flag.

* Remove traceId query type from Tempo and replace it with traceQl
2022-12-13 08:27:45 -05:00
Ashley Harrison
75a11e92b2 Dropdown: Menu now closes correctly when selecting options on touch devices (#60181)
update the version of react-popper-tooltip in @grafana/ui
2022-12-13 13:23:46 +00:00
Gábor Farkas
5633843f76 Elasticsearch: backend: do not set name for time-fields (#60169)
elastic: backend: improve field-naming
2022-12-13 13:19:03 +01:00
Ivana Huckova
0973501233 Elasticsearch: Add query building for raw data and raw document queries to backend (#59741)
* Elasticsearch: Fix ordering in raw_document and add logic for raw_data

* Add comments

* Fix raw data request to use correct timefield

* Fix linting

* Add raw data as metric type

* Fix linting

* Hopefully fix lint
2022-12-13 13:11:44 +01:00
renovate[bot]
d571376e8f Update dependency @kusto/monaco-kusto to v5.3.6 (#60151)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-13 13:04:34 +01:00
Torkel Ödegaard
58feee0b53 TopNav: Align profile button with search bar toggle (#60212) 2022-12-13 12:50:57 +01:00
Gareth Dawson
1b1f2475c2 Loki: Set custom width for modals in the loki query editor (#59714)
* set custom width for modals in the loki query editor

* convert unit from px to vw

* add media query for smaller devices

* use theme breakpoints instead of @media
2022-12-13 11:09:30 +00:00
Dimitris Sotirakis
6d339d94dc Chore: Remove %w and err from print line (#60215)
Remove %w and err
2022-12-13 05:56:34 -05:00
Alexander Weaver
e97b43cd58 Alerting: Add provisioning endpoint to fetch all rules (#59989)
* Domain layer api for fetching all rules

* Add endpoint for getting all rules
2022-12-13 11:54:08 +01:00
Hamas Shafiq
d6bd3c4fb6 Chore: Refactor trace-generators.js to TypeScript (#59431) 2022-12-13 10:38:00 +00:00
Hamas Shafiq
eaf96081d2 Chore: Refactor scroll-page.test.js to TypeScript (#59617) 2022-12-13 10:17:28 +00:00
Serge Zaitsev
af7d293eaf Chore: Remove Store interface and use db.DB instead (#60160)
* Chore: Remove Store interface and use db.DB instead

* use old-style session exec
2022-12-13 11:03:36 +01:00
Joey Tawadrous
4c4bc3bd32 Phlare: Reset flame graph after query is run (#59609)
Reset flame graph after query is run
2022-12-13 09:40:38 +00:00
Zoltán Bedi
d65899de7b SQL Datasources: Move database setting to jsonData (#58649)
* Datasource settings: Add deprecation notice for database field

* SQL Datasources: Migrate from settings.database to settings.jsonData.database

* Check jsonData first

* Remove comment from docs
2022-12-13 09:56:52 +01:00
Torkel Ödegaard
ac19b920f1 Explore: Fixes explore page height and margin issues (#59865) 2022-12-13 08:22:33 +01:00
Torkel Ödegaard
ef46761b9a Scene: Variables and All value support (#59635)
* Working on the all value

* Support for custom allValue

* Fixes

* More progress

* Progress

* Updated

* Fixed issue with multi and All value

* Clarified tests
2022-12-13 08:20:09 +01:00
owensmallwood
d2f9d7f39b Public Dashboards: Dont make annotations request when access token is falsey (#60202)
dont make annotations request when access token is falsey
2022-12-12 15:52:49 -06:00
Yuri Tseretyan
46e86300cb Alerting: add support for placeholder to text area generated for contact points (#60193) 2022-12-12 13:42:30 -05:00
renovate[bot]
47551c742b Update Moveable (#60021)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2022-12-12 10:07:44 -08:00
Alexander Weaver
595e623c28 Alerting: Additional tests for the config store (#60130)
Additional tests for the config store
2022-12-12 11:11:18 -06:00
Hamas Shafiq
dfed68feed Chore: Refactor packages/jaeger-ui-components/src/TraceTimelineViewer/SpanDetail to TS (#59850) 2022-12-12 17:08:01 +00:00
ismail simsek
5424ec4157 Prometheus: Remove buffered client and feature toggle related to it (#59898)
* Remove prometheus buffered client and feature toggle related to it

* Remove redundant pieces

* Clean the integration test
2022-12-12 18:05:55 +01:00
Sven Grossmann
8356df081d Loki/Prometheus: Fix wrong queries executed in split view (#60172)
* add context to monaco editors
2022-12-12 17:50:00 +01:00
Gilles De Mey
88e988f8b5 Alerting: Adds TODO list (#60166) 2022-12-12 17:49:23 +01:00
Yuri Tseretyan
df7f636759 Alerting: Fix slack receiver to close file descriptors when they're not needed anymore (#60178) 2022-12-12 11:19:02 -05:00
Gareth Dawson
22736cc93b Loki: Update feature tracking for label browser (#59295)
* update feature tracking names

* track when label browser is opened

* remove old feature tracking

* report interaction on modal close

* update

* fix type error

* revert changes to modal

* revert changes to modal

* remove close method from report interaction

* remove close type for grafana_loki_log_browser_closed

* nit pick

* add closeType to grafana_loki_label_browser_closed
2022-12-12 15:35:29 +00:00
Ashley Harrison
39a4ba4396 Navigation: Fix some missing pages in admin section (#60143)
* add stats and licensing under admin -> general when topnav is enabled

* add ldap to users and access

* use ID instead of Id

* add enterprise licensing node
2022-12-12 15:23:49 +00:00
Polina Boneva
be57419540 Grafana/ui: Create new LoadingBar component (#59508)
* dashboards squad mob! 🔱

lastFile:packages/grafana-ui/src/components/LoadingBar/LoadingBar.tsx

* dashboards squad mob! 🔱

* dashboards squad mob! 🔱

lastFile:packages/grafana-ui/src/components/LoadingBar/LoadingBar.tsx

* user essentials mob! 🔱

* create grafana/ui LoadingBar and set it up in Storybook

* Remove test changes on PanelChrome

* Fix mdx page reference

* make LoadingBar a simple JSX Element; do not use containerWidth; have a wrapper around the loading bar itself;

* fix wrapper around LoadingBar: willChange css prop makes performance of rerendering better

* moving the LoadingBar to core

* Revert "moving the LoadingBar to core"

This reverts commit 11f0f4ff2f.

* do not use internal comment as it doesn't do anything

* Modify annimation to 1 second

Co-authored-by: Alexandra Vargas <alexa1866@gmail.com>
2022-12-12 17:16:03 +02:00
Yuri Tseretyan
4374966987 Alerting: Replace hardcoded <no value> to [no value] in label expansion (#60129)
* replace hardcoded <no value> to [no value] in label expansion
2022-12-12 10:12:30 -05:00
Gábor Farkas
3172d8dd9b elastic: response parser: simplify code (#59782)
elastic: simplify code
2022-12-12 16:00:15 +01:00
renovate[bot]
0ab5ea0843 Update dependency @opentelemetry/api to v1.3.0 (#60152)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-12 14:59:22 +00:00
Josh Hunt
45d1cfa172 Datasources Fix formatting for SQL data sources permissions disclaimer (#60155)
Chore: Fix formatting for sql datasources permissions disclaimer
2022-12-12 14:56:30 +00:00
Dimitris Sotirakis
e9cf8fa751 CI: Add automation for github assets publishing (#59491)
* Add github.star

# Conflicts:
#	.drone.star
#	.drone.yml

* Make step depend on fetch images

# Conflicts:
#	.drone.yml

* artifacts -> path

# Conflicts:
#	.drone.yml

* Add github token

# Conflicts:
#	.drone.yml

* Fix custom path

# Conflicts:
#	.drone.yml

* Add case where path is absent

# Conflicts:
#	.drone.yml

* Add GH_REGISTRY secret

# Conflicts:
#	.drone.yml
2022-12-12 09:51:27 -05:00
Hamas Shafiq
583aafbbd8 Tempo: Fix TraceQL autocomplete issues (#60058) (#60125) 2022-12-12 14:49:18 +00:00
Joan López de la Franca Beltran
61cd9eeb24 Kinds: Generate JSON report (#59742)
* Kinds: Generate JSON report

* Kinds: Add Validate/Write support for JSON report

* Kinds: Report format

* Kinds: Report new line

* Kinds: Use kindsys.SomeKindMeta to generate the report

* Move kinds report generation to the end

* Re-structure kinds report JSON output

* Make prettier to ignore kinds json report

* Minor on kinds report generation

* Fix toggles_gen test
2022-12-12 15:47:19 +01:00
Ashley Harrison
8e77a42741 Chore: run toggles_gen_test.go to fix backend test (#60164)
run toggles_gen_test.go
2022-12-12 14:33:46 +00:00
Hamas Shafiq
7c5555d67f Chore: Refactor DraggableManager.test.js to TypeScript (#59966) 2022-12-12 14:25:51 +00:00
Dominik Prokop
089ec1d94e Scenes: Use DataSourceRef only in the query variable type (#60157) 2022-12-12 09:19:28 -05:00
Ashley Harrison
a09d9d68a8 Chore: fix glob pattern in renovate config (#60146)
fix glob pattern
2022-12-12 14:19:14 +00:00
Connor Lindsey
8fe9969826 PanelRenderer: Interpolate variables in applyFieldOverrides (#59844)
Update PanelRenderer to interpolate variables in applyFieldOverrides
2022-12-12 07:18:47 -07:00
Galen Kistler
b0f8e803a1 Prometheus: Fix exception being thrown when toggling visibility in explore (#60159)
fix error being thrown when frameIndex is out of bounds of dataframe
2022-12-12 07:44:15 -06:00
Gilles De Mey
b71ae13b63 Alerting: Adds evaluation interval to group view (#59974) 2022-12-12 13:53:18 +01:00
Ashley Harrison
97fa63d14d TimeZonePicker: Scroll menu correctly when using keyboard controls (#60008)
pass innerRef to TimeZoneOption so the menu scrolls properly
2022-12-12 12:30:02 +00:00
Konrad Lalik
d7b4a017d2 Alerting: Fix RelativeTimeRangePicker (#60016) 2022-12-12 13:27:02 +01:00
Dominik Prokop
1758ddd457 Scenes: Add query variable support (#59553)
* WIP first attempt to query variable

* regex issue repro demo

* Refresh variable on time range change if refresh specified

* Instantiate variable runner when updating query variable options

* Simplify runners getTarget interface

* Fix issue with variable ot being updated correctly after other variable changed

* Add templateSrv.replace compatibility with query variable

* QueryVariable: use datasource variable as source

* use proper format

* Make sure variables set is correctly updated when query variable errors

* Do not destruct scopedVars when using sceneGraph.interpolate in templateSrv

* Add support for Legacy variables (metricFindQuery)

* Review

* Fix lint

* Test: Add unit for datasource by variable

* test: Add unit for datasource as var

* query: delegate interpolation to datasourceSrv

* Cleanup

Co-authored-by: Ivan Ortega <ivanortegaalba@gmail.com>
2022-12-12 04:01:27 -08:00
Hamas Shafiq
712e23ac50 Chore: Refactor packages/jaeger-ui-components/src/utils to TypeScript (#59979) 2022-12-12 11:31:53 +00:00
renovate[bot]
e24ff033ce Update dependency @grafana/eslint-config to v5.1.0 (#60116)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-12 11:23:49 +00:00
renovate[bot]
b365eb0022 Update babel monorepo (#60115)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-12 10:21:14 +00:00
Marcus Efraimsson
7bf7308ea5 Plugins: Remove connection/hop-by-hop request/response headers for call resource (#60077)
Removes request/response connection/hop headers for call resource in similar 
manner as Go's reverse proxy functions. Also removes Prometheus datasource 
custom call resource header manipulation in regards to hop-by-hop headers.

Fixes #60076
Ref #58646

Co-authored-by: Will Browne <wbrowne@users.noreply.github.com>
2022-12-12 10:27:53 +01:00
Dominik Prokop
b58cecc788 Scenes: Basics for rendering scenes as an embedded page (#60098)
* Basics for rendering scenes as an embedded page

* Render submenu in embedded scene

* EmbeddedScene alternative for embedding within Grafana page
2022-12-12 01:25:28 -08:00
Joe Blubaugh
1a8d0e2736 Alerting: Speed up unit and integration tests. (#60067)
This change marks tests in the `sender` package that use an external
process as integration tests instead of unit tests. This speeds up the
package's unit tests by about 20 seconds.

This change also reduces the number of alert instances in the `store`
package's bulk write integration test from 20_000 to 10_000. This is
still enough to exercise the bulk-write code but speeds up the package
tests from about 250s to 130s.

Put together, integration tests go to about 160s while also speeding up
unit tests by 20s.
2022-12-12 14:21:06 +08:00
Torkel Ödegaard
50c4430661 PanelEditor: Fixes issue where panel edit would show the panel plugin options of the previous edit panel (#59861)
* PanelEditor: Fixes issues with panel edit state cleanup

* Removed console log

* Fixed test
2022-12-11 09:57:49 +01:00
xdavidwu
5d6bdc60b1 HeatmapPanel: Fix typo in variable naming (#57326) 2022-12-09 21:07:12 -06:00
matt abrams
ca3c4bb50f Docs: Fix OSS typo (#60131)
fix OSS typo
2022-12-09 13:04:24 -10:00
Leon Sorokin
8317bf5def BarChart: Fix value mappings (#60066) 2022-12-09 12:52:34 -05:00
Jack Baldry
6f9ee7acf9 Fix branch filter for release workflows (#59963)
Ensures the workflow is run on every push to all version branches.

This was thought to be working because it was tested with a manual
dispatch, however, that trigger does not consider filters and was not
an accurate test.

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2022-12-09 13:52:06 -04:00
Alexander Weaver
3bdffc92cf Alerting: Create alertmanager config history table (#60103)
Create config history table
2022-12-09 11:42:40 -06:00
Leon Sorokin
435ada45c5 TimeSeries: Better y-axis ticks for IEC units (#59984) 2022-12-09 10:25:44 -07:00
Jack Baldry
c1c48dd610 Use relative aliases for all non-current Grafana aliases (#60062)
* Use relative aliases for all non-current Grafana aliases

Prevents non-latest documentation "stealing" the page away from latest
and through permanent redirects for latest pages that no longer exist.

The redirected pages are indexed by search engines but our robots.txt
forbids them crawling the non-latest page.

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Remove aliases from shared pages

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Rewrite all current latest aliases to be next

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Fix typo in latest alias

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Remove all current page aliases

find docs/sources -type f -name '*.md' -exec sed -z -i 's#\n *- /docs/grafana/next/[^\n]*\n#\n#' {} \;
find docs/sources -type f -name '*.md' -exec sed -Ez -i 's#\n((aliases:\n *-)|aliases:\n)#\n\2#' {} \;

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

* Prettier

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2022-12-09 12:36:04 -04:00
Ashley Harrison
1497ad4760 TimePicker: Prevent TimePicker overflowing viewport on small screens (#59808)
* render timepicker in a modal style on small screens

* remove top: -1

* apply styles

* prevent bug where selecting a relative range wouldn't apply if the absolute ranges were expanded

* Revert "prevent bug where selecting a relative range wouldn't apply if the absolute ranges were expanded"

This reverts commit 7090443c12.
2022-12-09 15:02:26 +00:00
renovate[bot]
90ece9d1f3 Update Yarn to v3.3.0 (#60022)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-12-09 14:14:32 +00:00
Ashley Harrison
a589929c92 Navigation: Prevent app crash when importing a dashboard with a uid of home (#59874)
* change home id to be more unique, refactor so that home circular reference is never created

* prefix starred dashboards

* update reducer
2022-12-09 12:54:00 +00:00
Andreas Christou
4730be8842 AzureMonitor: Add error indicating potential configuration issue on Resource Picker (#60041)
* Add error indicating potential configuration issue

- Update test

* Update error

- Lint update
2022-12-09 13:50:01 +01:00
Ludovic Viaud
07d6b632b5 Remove PromExploreQueryEditor and PromQueryEditor (#60020)
Remove Prom editor
2022-12-09 12:56:47 +01:00
Sonia Aguilar
cf342f1933 Alerting: Reduce number of scroll bars in rule group modal (#59725)
Reduce number of scroll bars in rule group modal
2022-12-09 12:31:42 +01:00
Sofia Papagiannaki
341d7b01ee Login: Fix failure to login a new user via an external provider if quota are enabled (#60015)
* Login: Fix failure to login a new user via an external provider if quota are enabled
2022-12-09 12:30:27 +01:00
Josh Hunt
6280780e0c TimeRangePicker: Fix recent ranges not showing all items (#59836)
* Fix not all recently used time ranges showing

* Refactor time picker history to store simpler json objects

* Don't store duplicate items

* update todo tests:

* Add tests for TimePickerWithHistory

* better fix for focus scope issues in test
2022-12-09 11:28:57 +00:00
Ashley Harrison
0c9aed905a Chore: normalize monaco colors to hex string (#59784)
normalize monaco colors to hex string
2022-12-09 10:07:32 +00:00
Manoj Vivek
10c2bdea3e Parca: Logo image fixed with theme agnostic colors (#59835) 2022-12-09 11:01:39 +01:00
Ashley Harrison
c91c828c46 Renovate: use rebaseWhen: conflicted to try to speed up renovate runs (#60028) 2022-12-09 09:45:38 +00:00
Esteban Beltran
a7a2c0f373 Linting: Speed up betterer by sharing eslint instances by groups (#60019) 2022-12-09 09:18:19 +01:00
Kim Nylander
a6e8f651ac [DOC] Change AWS to Google Cloud Monitoring (#60065)
Change AWS to GCP
2022-12-09 08:07:34 +00:00
Artur Wierzbicki
4893acaeb4 EntityAPI: disable integration tests (#60073)
disable entity api int tests
2022-12-09 02:50:13 -05:00
Marcus Efraimsson
2db8ed9441 Chore: All tests under pkg/tests should be integration tests (#59521)
* Chore: All tests under pkg/tests should be integrationtests

* run alerting integration tests only for sqlite
2022-12-09 08:11:56 +01:00
Victor Marin
896cb9ddce Fix index out of range in regenerateLinksSupplier (#60011) 2022-12-09 09:09:29 +02:00
Galen Kistler
e85763065c Prometheus: Exemplar optimization (#60055)
replace inefficient forEach
2022-12-08 15:20:27 -06:00
Galen Kistler
dfc15163da Prometheus: Fix exemplar fill color to match series color in time series. (#59908)
* Implementing new optional color property to ExemplarMarker component 
* Refactor some changes from #59743
2022-12-08 14:15:05 -06:00
George Robinson
76601f3ae7 Alerting: Better define how we set states (#59977)
This commit better defines how we set states in resultNormal,
resultAlerting, resultError and resultNoData. It changes the existing
code to call methods such as SetAlerting, SetPending, SetNormal,
SetError and NoData instead of assigning values to each individual field
whenever the state is changed. This should make it easier to understand
what fields should be set for which states and avoid cases where states are
missing, or have additional unexpected fields.
2022-12-08 20:12:13 +00:00
Ryan McKinley
b2c4af16d7 Git: Update experimental workflow POC (#60049) 2022-12-08 13:57:33 -05:00
ismail simsek
29d2f86955 Update heatmap exemplar popover styles (#59988)
* Put traceID on top

* Update exemplar popover styles

* Remove console.log

* Make exemplar header opt-in via optional prop

Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2022-12-08 19:55:39 +01:00
Yuri Tseretyan
a83268db7b Alerting: skip flaky test RuleEditor recording rules.can create a new cloud recording rule (#60044) 2022-12-08 13:09:45 -05:00
Galen Kistler
f37997aec0 Prometheus: Add traceID link to heatmap exemplar popover (#60039)
* Add traceID link to heatmap exemplar popover
* Render links for each field individually

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
2022-12-08 12:02:17 -06:00
ismail simsek
551a2ac9ec Prometheus: Tweak query builder select component (#59749)
* Have consistent color for operators

* Add more operators and reorder them to align with dashboard filters
2022-12-08 18:52:27 +01:00
Galen Kistler
22f828300d Prometheus: Fix exemplars not respecting corresponding series display status. (#59743)
* Exemplar filtering when series are toggled in legend UI
2022-12-08 11:46:00 -06:00
Dominik Prokop
6f930f4836 Panel Edit: Fix data links edit icons being off screen when provided title is too long (#59829)
* Fix data links edit icons being off screen

* Remove unused imports

* Review
2022-12-08 09:32:22 -08:00
renovate[bot]
dedf292228 Update dependency @reduxjs/toolkit to v1.9.0 (#58247)
* Update dependency @reduxjs/toolkit to v1.9.0

* fix types on mockToolkitActionCreator

* Fix external AM selector tests

* timeout added in shared public dashboard test

* Revert "timeout added in shared public dashboard test"

This reverts commit 205c295192.

* update to @reduxjs/toolkit@1.9.1

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
Co-authored-by: Konrad Lalik <konrad.lalik@grafana.com>
Co-authored-by: Juan Cabanas <juan.cabanas@grafana.com>
2022-12-08 17:27:38 +00:00
Yuri Tseretyan
316870c658 Alerting: PagerDuty receiver to let user configure fields Source, Client and Client URL (#59895)
* add support for source field
* add client_url
* use real host name for source placeholder
2022-12-08 11:49:27 -05:00
Armand Grillet
64ccbf0a98 Update docs regarding Grafana as an alert receiver (#59938)
* Update docs regarding Grafana as an alert receiver

* Add link to AM docs
2022-12-08 17:31:59 +01:00
Ashley Harrison
a3681a3353 Command Palette: Links now work when grafana is served under a subpath (#60033)
strip base when pushing urls to locationService
2022-12-08 15:00:07 +00:00
Joe Blubaugh
e6743a7e9a Alerting: Use the QuotaTargetSrv instead of the QuotaTarget in quota check (#60026)
Before this change, the alerting provisioning system incorrectly used
the QuotaTarget to check if alerting's request quota had been reached.
The quota service requires the QuotaTargetSrv, which is what's
registered with the service at startup time. This is leading to errors
in the provisioning system.
2022-12-08 22:34:46 +08:00
Sofia Papagiannaki
e7b25baf46 Chore: Fix failing feature toggle test (#60030) 2022-12-08 16:24:01 +02:00
Ludovic Viaud
694dc60724 Prometheus: Add traceID field on top of the exemplar popover (#59920)
Prioritize trace link
2022-12-08 14:53:07 +01:00
ying-jeanne
1131bac5da [Nested Folder] Block move operation that could introduce more than 8 level of depth,… (#59832)
* block move operation that could introduce more than 8 level of depth, forbid circular reference

* move getHeight to store, mock store in service

* fix linter
2022-12-08 08:49:17 -05:00
Jo
9094153b30 Fix feature toggle test main (#60024)
fix feature toggle test
2022-12-08 14:26:18 +01:00
Ivana Huckova
3c9ccd4512 Loki: Usage for queries not from dashboards (#60017)
Loki: Usage for queries not from dashboars
2022-12-08 13:04:05 +01:00
Ivana Huckova
e2077e9659 Dashboard: Run requests with correct app type (#60010)
Dashboard: Run quries with correct core app
2022-12-08 11:52:28 +01:00
Ivana Huckova
4b56493789 Elasticsearch: Add tracking for plugin adoption stats (#59954)
* Elasticsearch: Add tracking

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

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

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

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

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

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

* Refactor getLineLimit

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

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

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

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

* Update not tracking for volume queries

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
2022-12-08 11:28:40 +01:00
Yuri Tseretyan
c5ee4e4ae1 Alerting: Improve rule validation to check if rule uses backend datasources (#58986)
* validate if rule uses backend datasources

* add backend datasource to test

* fix tests

* another forgotten import

* remove unused var
2022-12-08 10:44:02 +01:00
Andriy
75cceec62c chore: update go version to 1.19.4 in plugin ci images (#59978) 2022-12-08 10:11:31 +01:00
Ivana Huckova
601df109af Loki: Remove annotation, context and volume tracking (#59962)
* Loki: Remove annotation and context tracking

* Implement log volume
2022-12-08 10:05:11 +01:00
kay delaney
955bf55c6a Datasource Onboarding: Create initial data source onboarding page (#58795) 2022-12-07 23:29:38 +00:00
Daniel Lee
74167b4d44 UsageInsights: Record events for Explore queries (#59931)
* usageinsights: record events for Explore queries

* usageinsights: make the source field optional

It is not logical to have it for an event like the dashboard-view

* usageinsights: add comment to Explore test

Explain why we are reversing a previous decision
2022-12-07 21:19:35 +01:00
Kevin Minehart
69ffce4c42 CI: add a quick test, set enterprise2 when the enterprise2 flag is added (#59967)
* add a quick test, set enterprise2 when the enterprise2 flag is added

Co-authored-by: Dave Henderson <dave.henderson@grafana.com>
2022-12-07 13:52:16 -05:00
Kristin Laemmert
ceb3d8d295 feature (user service): Add a validation check after the user record is created in the sqlstore. (#59968)
Add a validation check after the user record is created in the sqlstore.
2022-12-07 12:33:40 -05:00
Shirley
5c08f03512 CloudWatch: Fix deeplinks to still be able to pass log group names (#59809)
Co-authored-by: Erik Sundell <erik.sundell87@gmail.com>
2022-12-07 11:40:15 -05:00
Christopher Moyer
a4c884e808 Docs: corrects relref (#59970)
correct relref
2022-12-07 10:37:08 -06:00
Kristin Laemmert
70fbf47022 chore: remove CreateUser from sqlstore & replace with userService.CreateUserForTests (#59910) 2022-12-07 11:03:22 -05:00
Ryan McKinley
d036225f7b Chore: get user from appcontext rather than store utility (#59926)
user from appcontext
2022-12-07 07:38:23 -08:00
Shirley
e8ed79873a CloudWatch: return silently in case of missing log groups or incomplete query (#59701)
* Remove defaultLogGroups check in filterQuery
2022-12-07 16:37:35 +01:00
Andreas Christou
43afb85056 CloudMonitor: Improve detail of MQL series labels (#59747)
* Improve consistency between MQL and builder queries

* Review

* Review and fix test
2022-12-07 15:32:54 +00:00
Ivana Huckova
1aa94165d9 Loki: Do not track samples (#59960) 2022-12-07 16:24:22 +01:00
Sonia Aguilar
55055d0b9b Alerting: Fix RuleEditor flaky test for existing grafana managed alert (#59780)
* Fix RuleEditor flaky test for existing grafana managed alert

* Fix RuleEditor flaky test for creating a new grafana managed alert

* Fix tests for cloud rules

* Split tests for different rule types

* Move common clickSelectOption method to helpers

* Remove from RuleEditorCloudRules.test.tsx  a repeated cloud rule test

* Move existing grafana rule test case to a new file

* Split RuleEditorCloudRules test: move checking only allowed data sources test case to a new test file

* Re-use common ui const

* Re-use renderRuleEditor method

* Create getDiscoverFeaturesMock to reduce code
2022-12-07 16:15:33 +01:00
Jo
d833031726 ServiceAccounts: Do not display warnings about secret scanner when scanner is disabled (#59952)
ServiceAccounts: Fix warnings about secret scanner when scanner is disabled
2022-12-07 14:49:28 +01:00
Carl Bergquist
a5ace56be8 Plugins: Add username to datasource plugin logging (#59893)
Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
Signed-off-by: bergquist <carl.bergquist@gmail.com>
2022-12-07 13:15:42 +01:00
Carl Bergquist
1b676d0d49 Contexthandler: Add uname as response header (#59930)
Signed-off-by: bergquist <carl.bergquist@gmail.com>
2022-12-07 13:14:53 +01:00
Torkel Ödegaard
7b58fb3a20 Scenes: Fix flaky scenes time range test (#59900)
* Scenes: Fix flaky scenes time range test

* Update public/app/features/scenes/core/SceneTimeRange.test.tsx
2022-12-07 11:52:35 +01:00
Polina Boneva
db1e19fe86 Dashboard: Making a dashboard editable does not allow resizing of panels (#59255)
* DashboardGrid should rerender ReactGridLayout when mutable dashboard updates

* add missing prop to test
2022-12-07 12:46:10 +02:00
George Robinson
6359dab040 Alerting: Change resultError in preparation for supporting ForError duration (#59894) 2022-12-07 10:45:56 +00:00
Ashley Harrison
5d0029c647 Navigation: handle case where navIndex is undefined (#59826)
handle case where navIndex is undefined
2022-12-07 10:16:55 +00:00
Ashley Harrison
2b3c86d201 Chore: Remove unused/deprecated @types definitions (#59888)
* remove @types/rc-tree, @types/classnames

* remove @types/rc-time-picker

* remove @types/reselect

* remove @types/testing-library__react-hooks

* only include known package.json's
2022-12-07 10:10:59 +00:00
Hamas Shafiq
dd406e887b Chore: Refactor packages/jaeger-ui-components/src/TraceTimelineViewer/ListView to TS (#59873) 2022-12-07 10:01:20 +00:00
Jo
df4f0343e5 Auth: Session cache [main] (#59935)
* Auth: Session cache [v9.2.x] (#59907)

* add cache wrapper

only cache token if not to rotate

Co-authored-by: Kalle Persson <kalle.persson@grafana.com>

anticipate next rotation

Co-authored-by: ievaVasiljeva <ieva.vasiljeva@grafana.com>
Co-authored-by: Kalle Persson <kalle.persson@grafana.com>
Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
(cherry picked from commit 07a4b2343d59cb593ad128355e1d9217ba493700)

* FeatureToggle: for storing sessions in a Remote Cache

Co-authored-by: ievaVasiljeva <ieva.vasiljeva@grafana.com>
(cherry picked from commit b8a8c15148)

* use feature flag for session cache

* ensure ttl is minimum 1 second

Co-authored-by: ievaVasiljeva <ieva.vasiljeva@grafana.com>
Co-authored-by: Kalle Persson <kalle.persson@grafana.com>
Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>

* ensure 2 ttl window to prevent caching of tokens near rotation

Co-authored-by: Kalle Persson <kalle.persson@grafana.com>

* fix description of toggle

Co-authored-by: gamab <gabi.mabs@gmail.com>
Co-authored-by: ievaVasiljeva <ieva.vasiljeva@grafana.com>
Co-authored-by: Kalle Persson <kalle.persson@grafana.com>
Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
(cherry picked from commit 2919588a82)

* fix broken quota test
2022-12-07 10:55:48 +01:00
Ivana Huckova
13acddd605 Elasticsearch: Fix adding correct min_doc_count to all aggregation types in backend implementation (#59713)
* Elasticsearch: Fix adding correct min_doc_count to all aggregation types in backend implementation

* Update snapshot tests

* Fix linting
2022-12-07 09:47:31 +01:00
Conor Evans
dce7f50d59 CloudWatch: Fix - make sure dimensions are propagated to alert query editor (#58281)
* fix(unified-alerting/cloudwatch): propagate dimensions to alert

Signed-off-by: Conor Evans <coevans@tcd.ie>

* add unit test

Signed-off-by: Conor Evans <coevans@tcd.ie>
Co-authored-by: Erik Sundell <erik.sundell87@gmail.com>
2022-12-07 09:42:04 +01:00
Dimitris Sotirakis
0801fce23c CI: Move verify-storybook command from grabpl (#59928)
* Move verify-storybook from grabpl

* Remove zerolog
2022-12-07 09:56:15 +02:00
Dan Cech
440d8a3d88 Build: Drone starlark file cleanup (#59919)
* format drone starlark files with black

* clean up unused params

* more simplification

* more cleanup

* more cleanup
2022-12-07 09:13:57 +02:00
Sven Grossmann
d0eeff2fa0 Loki: Add tracking of executed queries (#59887)
* add query tracking

* add app

* add comment

* use `reportInteraction` not `console.log`

* add test to `queryUtils`

* organize imports

* add datasource tests

* change `metrics` to `metric`

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

* change `parseToArray` to `parseToNodeNamesArray`

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2022-12-06 15:54:20 -05:00
Serge Zaitsev
43f40e6c7c Chore: Replace yaml.v2 with yaml.v3 (#59897)
* replace yaml.v2 with yaml.v3

* fix a few tests due to the yaml.v3 api changes

* and another goconvey mistake in tests
2022-12-06 21:17:17 +01:00
Ivana Huckova
fdc3adb2c9 Loki: Add tracking for on dashboard load (#59914)
Loki: Add on dashboard load tracking
2022-12-06 21:15:55 +01:00
Artur Wierzbicki
9e349bf9b0 EntityStore: support filtering by labels (#59905)
* label filtering

* filtering in sql

* filtering in sql group by

* label is unique - no need for distinct

* capitalize

* fix capitalization
2022-12-06 23:21:12 +04:00
George Robinson
3c249e1b99 Fix incorrect start time for DatasourceError alerts (#59903) 2022-12-06 18:44:06 +00:00
Matias Chomicki
7e339decfe JavaScript Unit Tests: Enable shouldFailOnLog only for CI environments (#59901)
Tests: enable shouldFailOnLog only for CI environments
2022-12-06 19:38:55 +01:00
Yuri Tseretyan
abb49d96b5 Alerting: update state manager to return StateTransition instead of State (#58867)
* improve test for stale states
* update state manager return StateTransition
* update scheduler to accept state transitions
2022-12-06 13:07:39 -05:00
Yuri Tseretyan
a85adeed96 Alerting: Update state history service to filter states transitions (#58863)
* rename the method to better reflect its behavior
* make historian filter transition on itself
* call historian with all changes
2022-12-06 12:33:15 -05:00
Torkel Ödegaard
18d09cd3fe PanelEdit: Fixes broken panel edit splitter logic (#59859)
* Alt panel edit fix

* fix fix
2022-12-06 18:21:03 +01:00
Dimitris Sotirakis
bc5badbcd8 CI: Add enterprise2 flag to unblock enterprise2 image deployments (#59904)
Add hacky flag to unblock enterprise2
2022-12-06 18:42:11 +02:00
Dan Cech
1dbc22d18b Build: don't remove grafana-server and grafana-cli binaries from deb and rpm packages (#59890)
* don't remove grafana-server and grafana-cli binaries from /usr/share/grafana/bin in deb and rpm packages

* don't add config overrides in /usr/sbin/grafana-server
2022-12-06 10:36:43 -05:00
Serge Zaitsev
f1fb202284 Chore: Add encryption codec to the remote cache (#59871)
* add encryption codec to the remote cache

* change config files too

* fix test constructor

* pass codec into the test cache
2022-12-06 15:12:27 +01:00
Hamas Shafiq
2ff6ae65df Chore: Refactor the packages/jaeger-ui-components/src/TracePageHeader folder to TS (#59722) 2022-12-06 13:13:15 +00:00
Hamas Shafiq
982005152a Chore: Refactor ScrollManager.test.js to TypeScript (#58661) 2022-12-06 13:03:37 +00:00
Sofia Papagiannaki
4259b6bf58 API: Fix delete user failure due to quota not enabled (#59875) 2022-12-06 15:02:01 +02:00
Serge Zaitsev
3978502d83 Chore: Remote cache key prefix (#59838)
* attempt to implement a remote cache key prefix

* add a test for the prefix store

* oh, linter
2022-12-06 13:20:49 +01:00
Sven Grossmann
932349b5ab Loki: Fix wrongly escaped label values when using LabelFilter (#59812)
* change backticks to quotes

* add unescaping to `addFilterAsLabelFilter`

* fix removal of wrong quotes

* change unescape order
2022-12-06 12:30:03 +01:00
Dimitris Sotirakis
78ef55eb06 CI: Add enterprise2 mode in versions.go (#59851)
Add enterprise2 mode
2022-12-05 15:03:47 -06:00
sam boyer
46143b0764 kindsys: Change "Meta" to "Properties" (#59852) 2022-12-05 14:48:47 -05:00
Kyle Brandt
4e0f95dc31 Chore: Update SDK to v0.145.0 with TimeSeriesMulti Constant (#59729) 2022-12-05 12:48:10 -05:00
Yuri Tseretyan
eeb57cd520 Alerting: Refactor PagerDuty and OpsGenie notifiers to use encoding/json to parse settings (#58925)
* update pagerduty and opsgenie to deserialize settings using standard JSON library
* update pagerduty truncation to use a function from Alertamanger package
* update opsgenie to use payload model (same as in Alertmanager)
2022-12-05 11:38:50 -05:00
Ashley Harrison
46adfb596d Command Palette: Maintain page state when changing theme (#59787)
* use same function as the change theme keybindings

* rename toggleTheme service to just theme
2022-12-05 16:12:56 +00:00
Andrej Ocenas
c6840cfdec Tempo: Fix traceQL suggestions for tag names with dots (#59736) 2022-12-05 17:05:22 +01:00
Yuri Tseretyan
866aea0db2 Alerting: fix UI element for PagerDuty's severity field configuration (#58927)
* make severity a regular text field
* add logs + fallback to critical if empty
2022-12-05 11:02:20 -05:00
Christopher Moyer
5240905f05 docs: fixes broken link and spelling error (#59828)
fixes broken link and spelling error
2022-12-05 10:00:20 -06:00
Ivana Huckova
e356a56741 Elasticsearch: Fix removing of empty settings from query in backend implementation (#59704)
* Elasticsearch: Fix removing of empty settings from query in backend implementation

* Update

* Update

* Update pkg/tsdb/elasticsearch/time_series_query.go

Co-authored-by: Gábor Farkas <gabor.farkas@gmail.com>

Co-authored-by: Gábor Farkas <gabor.farkas@gmail.com>
2022-12-05 16:06:55 +01:00
Ida Štambuk
3544250baf Accessibility: Make QueryEditorHelp examples keyboard interactive (#59355)
* Cloudwatch: A11y - Make example log keyboard interactive

* Change all cheat sheets to buttons

* Make suggestions block
2022-12-05 16:03:24 +01:00
Dimitris Sotirakis
7deaeb0f9e CI: Add identify-runner step for publish images (#59827)
Add missing identify-runner step
2022-12-05 09:49:33 -05:00
Erik Sundell
32309a8373 Datasource: Fix - apply default query also to queries in new panels (#59625)
* apply default query also to new panels

* add comment

* add tests
2022-12-05 15:44:04 +01:00
Andreas Christou
b4cf711a74 Package: @grafana/e2e updates (#59723)
E2E package updates

- Update addDashboard flow to work with latest grafana
- Update viewport configuration to ensure components aren't hidden
2022-12-05 13:49:25 +00:00
Garrett Guillotte
0bdee8757b Docs: Document Prometheus-Alertmanager integration settings (#57043)
* Docs: Document Prometheus AM integration settings

* Update docs/sources/datasources/alertmanager/_index.md

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>

Co-authored-by: Armand Grillet <2117580+armandgrillet@users.noreply.github.com>
Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
2022-12-05 14:01:12 +01:00
brendamuir
5c9d1a4706 Delete broken links in notifications doc (#59785)
* Delete broken links in notifications doc

* changes descendents to children

* deletes broken alertmanager link
2022-12-05 12:53:14 +01:00
Gábor Farkas
b8b2de1ac4 elastic: remove unused debug-code (#59712)
* elastic: remove unused debug-code

* removed unused structs
2022-12-05 04:21:15 -05:00
Galdin Raphael
bf85bf9b7a Docs: Fix typo in docs for the mssql datasource (#59253)
Fix typo
2022-12-04 15:23:23 +01:00
Alexander Weaver
9977c7ea43 Alerting: Simplify scheduler configuration and remove dependency on Grafana-wide settings (#59735)
* Make scheduler not depend directly on grafana-wide settings

* Re-add missing interval
2022-12-02 16:02:07 -06:00
Jack Baldry
e7bdcb4ba8 Restrict workflow to grafana/grafana repository (#59740)
Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2022-12-02 15:29:57 -05:00
ismail simsek
ba2e226ba9 Prometheus: Send time range params when requesting labels (#59648)
* Send time range params when requesting labels

* Update public/app/plugins/datasource/prometheus/datasource.tsx

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

* Send params when calling values too

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2022-12-02 19:11:34 +01:00
Christopher Moyer
ece8609e7c Docs: removes email templating (#59745)
removes email templating
2022-12-02 12:01:01 -06:00
Christopher Moyer
cc575d2341 Docs: updates based on customer feedbak (#59720)
updates based on customer feedbak
2022-12-02 11:43:55 -06:00
Jo
6762aaba56 SAML: Add teamsync details and example (#59624)
doc: saml fixes
2022-12-02 17:04:59 +01:00
Karl Persson
22be025284 Auth: Add anonymous authn client (#59637)
* Authn: Add Client interface and Reqeust and Identity structures

* Authn: Implement Authenticate method in service

* Authn: Add tracing

* Authn: Add logger

* AuthN: Implement Anonymous client
2022-12-02 15:10:03 +01:00
Andreas Christou
c52d4e2a64 AzureMonitor: Automate location retrieval (#59602)
* Automate location retrieval

- Add function to retrieve provider information
- Add function to retrieve subscription locations
- Add parsers for each function
- Add types
- Update resourcePickerData with new functions
- Remove old location metadata file

* Improve types

- Add types for responses
- Use correct name parameter
- Update response parser (parseProvider unnecessary)

* Fix tests

- Add necessary mocks

* Fix logic and ensure maps are consistent

* Add tests

* Review

* Lint issue
2022-12-02 13:23:15 +00:00
Sonia Aguilar
020b9960c8 Alerting: Move modal buttons before the rules table (#59703)
Move modal buttons before the rules table
2022-12-02 13:51:01 +01:00
Will Browne
76233f9997 Plugins: Unexport PluginDir field from PluginDTO (#59190)
* unexport pluginDir from dto

* more err checks

* tidy

* fix tests

* fix dboard file tests

* fix import

* fix tests

* apply PR feedback

* combine interfaces

* fix logs and clean up test

* filepath clean

* use fs.File

* rm explicit type
2022-12-02 13:46:55 +01:00
Karl Persson
6d1bcd9f40 DataSourcePermissions: Handle licensing properly for ds permissions (#59694)
* RBAC: add viewer grand if dspermissions enforcement is not enabled

* RBAC: Change permissions based on role prefix

* RBAC: Add option to for permission service to add a license middleware

* RBAC: Remove actions from query struct
2022-12-02 13:19:14 +01:00
Andres Martinez Gotor
a7d4bbf024 AzureMonitor: Fix bad request when setting dimensions (#59700) 2022-12-02 13:17:11 +01:00
Andres Martinez Gotor
231b5b587c AzureMonitor: Fix panic from empty response in ARG (#59691)
AzureMonitor: Avoid panic from empty response in ARG
2022-12-02 13:14:48 +01:00
Joao Silva
7b47021d19 A11y: Remove unnecessary onClick from LegendSeriesItem (#59671) 2022-12-02 12:10:21 +01:00
Torkel Ödegaard
069c99fba3 Themes: Re-init graph on theme change (#59690)
Re-init graph on theme change
2022-12-02 11:55:18 +01:00
Zoltán Bedi
5712b05330 Datasource settings: Add deprecation notice for database field (#58647)
* Datasource settings: Add deprecation notice for database field

* Revert store.go change
2022-12-02 11:40:33 +01:00
Shirley
1c5a3a7d2c CloudWatch: Create deeplinks from log group ARNs (#59646) 2022-12-02 11:25:34 +01:00
Torkel Ödegaard
37c118b7dd Table: Fixes row border style not showing and colored rows blending together (#59660)
* Table: Fixex row border style not showing and colored rows blending together

* Updated
2022-12-02 10:54:06 +01:00
George Robinson
ec1d93c8ab Alerting: Upload images to Slack via files.upload (#59163)
This commit makes a number of changes to how images work in Slack
notifications.

It adds support for uploading images to Slack via the files.upload
API when the contact point has a token. Images are no longer linked
via a URL if a token is present.

Each image uploaded to Slack is posted as a reply to the original
notification. Up to maxImagesPerThreadTs images can be posted as
replies before a final message is sent with:

  There are no images than can be shown here. To see the panels for
  all firing and resolved alerts please check Grafana

Incoming Webhooks cannot upload files via files.upload and so webhooks
require the image to be uploaded to cloud storage and linked via URL.
2022-12-02 09:41:24 +00:00
George Robinson
311e1e56f2 Docs: Reference Alertmanagers in Notifications docs and move Alertmanager docs (#59673) 2022-12-02 09:41:01 +00:00
George Robinson
4073d044c1 Docs: Consolidate Templating labels and annotations docs into a single page (#59685) 2022-12-02 09:40:48 +00:00
Ashley Harrison
2ac235eaff Chore: remove preloading roboto font (#59664)
remove preloading roboto font
2022-12-02 09:30:47 +00:00
Ashley Harrison
11a32bddbb Accessibility: Add the correct role to the modal backdrop (#59572)
add the correct role to the modal backdrop
2022-12-02 09:30:30 +00:00
Erik Sundell
fde9a5d112 Cloudwatch: Backend cleanup (#59663)
* cleanup cloudwatch.go

* streamline interface naming

* use utility func

* rename test utils file

* move util function to where they are used

* move dtos to models

* split integration tests from the rest

* Update pkg/tsdb/cloudwatch/cloudwatch.go

Co-authored-by: Isabella Siu <Isabella.siu@grafana.com>

* refactor error codes aggregation

* move error messages to models

Co-authored-by: Isabella Siu <Isabella.siu@grafana.com>
2022-12-02 10:21:46 +01:00
Shirley
ada0c771ef CloudWatch: Return with error message for empty logs query string (#59584) 2022-12-02 10:01:01 +01:00
Michael Mandrus
8152b0e1ef Pubdash: Verify affected rows count in database 'create' call (#59591)
* make create call consistent with update and delete

* use appropriate error type

* update log statements

* update error log for 0 affected rows
2022-12-02 02:46:35 -05:00
Marcus Andersson
7f92f1df00 Schema: Refactor plugin code generation (#58901)
* wip

* wip

* almost there..

* wip - change so it can run.

* treelist is working.

* support CODEGEN_VERIFY env variable

* use log.fatal

* comment out old PluginTreeList code generation

* cleanup

* rename corelist package files

* fix makefile

* move pkg/codegen/pluggen.go to pkg/plugins/codegen

* copy and refactor files to pkg/plugins/codegen

* use pkg/plugins/codegen instead of pkg/codegen for core plugins code gen

* remove unneeded files

* remove unused code to resolve linting errors

* adapters first hack

* added flattener

* add back ignore build tags to go generate file

* cleaned up the code a bit.

* seems to work, needs to do some refactoring of the GoTypesJenns and TSTypesJenny.

* one more step, going to get upstream changes in this branch.

* working but need to run import tmpl in jenny_schemapath to have the proper imports.

* added header to generated files.

* added missing jenny.

* preventing plugins with multiple decls/schemas to insert multiple lines in corelist.

* fixed so we use Slot type from kindsys to detect if its group.

* adding a go jenny that only runs if the plugin has a backend.

* added version object to generated ts.

* generating the ts types with the same output as prior to this refactoring.

* removed code that is replaced by the jenny pattern.

* removed the go code that isn't used anymore.

* removed some more unused code and renamed pluggen to util_ts

* fixed linting issue.

* removed unused vars.

* use a jenny list postprocessor for header injection

* moved decl and decl_parser to pfs.

* removed the pre-pended header in the gotypes jenny since it is done in the postprocess.

* moved decl to pfs.

* removed unused template.

Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
2022-12-02 08:22:28 +01:00
Michael Mandrus
0c560b8b0d Graphite: Process multiple queries to Graphite plugin (#59608)
* make create call consistent with update and delete

* send multiple targets to graphite and correlate the responses with the requests

* make create call consistent with update and delete

* send multiple targets to graphite and correlate the responses with the requests

* Revert "make create call consistent with update and delete"

This reverts commit 26b6463bd6.

* refactor query -> target parsing and fix unit tests

* add additional validations and more unit tests

* change error statement to warn
2022-12-01 18:05:44 -05:00
Leon Sorokin
e1e858323a TimeSeries: Fix rendering when zooming to time ranges between datapoints (#59444) 2022-12-01 16:01:35 -07:00
malcolmholmes
7d043e1930 Chore: update latest.json to 9.3.1 (#59682) 2022-12-01 21:19:47 +00:00
Grot (@grafanabot)
9c742fd0c7 Changelog: Updated changelog for 9.3.1 (#59677) 2022-12-01 21:01:13 +00:00
Brendan O'Handley
f9ef0eb414 Dataplane: Deprecate timeseries-many in favor of timeseries-multi (#59070)
* deprecate timeseries-many in favor of timeseries-multi

* deprecate timeseries-many, do not just remove it

* undo changes to jsonc files

* update deprecation message

* return TimeSeriesMulti for prepareTimeSeries transformer
2022-12-01 15:27:31 -05:00
Sasha Melentyev
f0adc69ada Chore: Change fmt.Errorf to errors.New when there is no formatting required (#58600)
Signed-off-by: Sasha Melentyev <sasha@melentyev.io>
2022-12-01 20:51:12 +01:00
Ryan McKinley
fb98a97efa EntityStore: Move slug+folder to summary metadata (#59620) 2022-12-01 14:45:08 -05:00
Marcus Efraimsson
6dbe3b555f Plugins: Refactor forward of cookies, OAuth token and header modifications by introducing client middlewares (#58132)
Adding support for backend plugin client middlewares. This allows headers in outgoing 
backend plugin and HTTP requests to be modified using client middlewares.

The following client middlewares added:
Forward cookies: Will forward incoming HTTP request Cookies to outgoing plugins.Client 
and HTTP requests if the datasource has enabled forwarding of cookies (keepCookies).
Forward OAuth token: Will set OAuth token headers on outgoing plugins.Client and HTTP 
requests if the datasource has enabled Forward OAuth Identity (oauthPassThru).
Clear auth headers: Will clear any outgoing HTTP headers that was part of the incoming 
HTTP request and used when authenticating to Grafana.
The current suggested way to register client middlewares is to have a separate package, 
pluginsintegration, responsible for bootstrap/instantiate the backend plugin client with 
middlewares and/or longer term bootstrap/instantiate plugin management. 

Fixes #54135
Related to #47734
Related to #57870
Related to #41623
Related to #57065
2022-12-01 19:08:36 +01:00
Ben Sully
632ca67e3f Add a separate grafana.com API URL setting (#59506)
The GrafanaComURL setting is currently used in two places:

- the /api/gnet endpoint, which proxies all requests to the URL
  configured in GrafanaComURL
- OAuth logins using grafana.com, where the auth URL, token URL and
  redirect URL are all configured to use the GrafanaComURL.

This has worked fine until now because almost all Grafana instances have
just used the default value, https://grafana.com. However, we now have a
few different grafana.com's, some of which are behind IAP. The IAP
causes the /api/gnet proxy to fail because the required cookies are not
present in the request (how could they be?). Setting the
[grafana_net.url] setting to an internal-only URL improves the situation
slightly - the proxy works again just fine - but breaks any OAuth logins
using grafana.com, because the user must be redirected to a publicly
accessible URL.

This commit adds an additional setting, `[grafana_com.api_url]`,
which can be used to tell Grafana to use the new API URL when proxying
requests to the grafana.com API, while still using the existing
`GrafanaComURL` setting for other things.

The setting will fall back to the GrafanaComURL setting + "/api" if unset.
2022-12-01 18:06:12 +01:00
Ryan McKinley
b537acab49 FeatureFlags: enable i18n flag in the registry (#59662) 2022-12-01 08:27:52 -08:00
Tania
16fec64690 Schema: Add Team structured core kind (#59242)
* Add Team kind

* Minor changes

* Use ToMedatata annotation

Co-authored-by: sam boyer <sdboyer@grafana.com>

* Use ToMedatata annotation

Co-authored-by: sam boyer <sdboyer@grafana.com>

* Use ToMedatata annotation

Co-authored-by: sam boyer <sdboyer@grafana.com>

* Use ToMedatata annotation

Co-authored-by: sam boyer <sdboyer@grafana.com>

* Update comments

* Add created and updated fields

* Make orgId required

* Use int64 for datetime

Co-authored-by: sam boyer <sdboyer@grafana.com>
2022-12-01 17:08:54 +01:00
Dan Cech
c4bb9d637e Build: Unify custom dockerfiles, fix missing semicolon (#59615)
* unify custom dockerfiles, fix missing semicolon

* tweak verbiage

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* update example description

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2022-12-01 11:08:31 -05:00
Gilles De Mey
c3a8590fe5 Alerting: Reduce number of buildinfo calls (#59319) 2022-12-01 11:05:28 -05:00
Ashley Harrison
94c5be8dfb Navigation: Remember expanded sections in megamenu (#59661)
use local storage to remember which sections of megamenu are expanded
2022-12-01 16:04:36 +00:00
owensmallwood
97e81ecbde PublicDashboards: Modal warns when using unsupported datasources (#58926)
Adds warning to pubdash modal when dashboard uses datasources not supported by pubdash
2022-12-01 10:02:10 -06:00
Konrad Lalik
d2c129fbac Alerting: Add alert rule cloning action (#59200)
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2022-12-01 16:21:54 +01:00
Serge Zaitsev
b3284a8330 Chore: Make getUserOrgList private to sqlstore (#59654)
* make getUserOrgList private in sqlstore

* make other identifiers private
2022-12-01 15:46:42 +01:00
Ezequiel Victorero
c6cf774ac5 PublicDashboards: add time picker enabled column (#59324) 2022-12-01 11:37:08 -03:00
Christopher Moyer
3a9d4cc688 Docs: removes dashboard images (#59619)
* removes dashboard images

* removes explore and developer docs screenshots
2022-12-01 08:32:25 -06:00
Leo
d9f697b41e Accessibility: Improved keyboard accessibility in BarGauge (#59382)
* Accessibility: Improved keyboard accessibility in BarGauge

* use appropriate elements when rendering bargauge

* added space for focus-visible outline border

* Revert "added space for focus-visible outline border"

This reverts commit 9b83fa3a0b.
2022-12-01 14:45:56 +01:00
Joao Silva
379cde3a72 FolderPicker: Fixes issue with typing to search for folder (#59434) 2022-12-01 13:34:07 +01:00
Ashley Harrison
dab83c6855 Theme: Use Inter font by default (#59544)
* Switch to using Inter font by default

* run toggles_gen_test
2022-12-01 11:59:37 +00:00
Joey Tawadrous
0209cde7e0 Tracing: Add keyboard accessibility to SpanDetailRow (#59412)
SpanDetailRow keyboard accessibility
2022-12-01 11:23:33 +00:00
Andres Martinez Gotor
0d4fd305c4 GoogleCloudMonitoring: Refactor parseResponse (#59595)
* GoogleCloudMonitoring: Remove duplicated code from buildDeepLink (#59600)
2022-12-01 12:09:30 +01:00
Ivana Huckova
a2ed586576 Elasticsearch: Migrate frontend query builder tests to backend (#59578)
* WIP: Migrated first batch of tests

* Migrate more tests

* Migrate rest of the tests

* Update comments

* Update

* Update

* Remove newline
2022-12-01 12:09:12 +01:00
Esteban Beltran
0a9b238d39 Build: Adds a fallback script to fix package.json main and types fields before packaging (#59628) 2022-12-01 11:34:52 +01:00
Sofia Papagiannaki
798a8ceb9c Nested folders: Fix delete (#59627)
* Fix deleting subfolder

It used to fail with beause of missing signed in user

* Add logging

* fixup

* Fail request if deleting nested folder has failed

Before we only used to log the error

* Fix failing test

During failed nested folder creation
call the dashboard store deletion instead of the service one.
2022-12-01 05:27:40 -05:00
George Robinson
8ed2426e8e Docs: Improve documentation for notifications (#59504) 2022-12-01 09:57:45 +00:00
Ashley Harrison
a958b0be44 Accessibility: Use button instead of div in ColorPicker story (#59581)
use button instead of div in colorpicker story
2022-12-01 09:26:58 +00:00
Gábor Farkas
51d7231595 elastic: added more backend tests, copied from the frontend code (#59423) 2022-12-01 04:06:39 -05:00
Torkel Ödegaard
5281cff94d Variables: Url sync for MultiValueVariable (#59371)
* Initial take on variable url sync

* Url sync is working

* Fixing test
2022-12-01 09:48:26 +01:00
Gabriel MABILLE
8e929163a8 RBAC: Add config option to reset basic roles on start up (#59598)
* RBAC: add config option to reset basic roles on start up

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Update docs

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Add to sample.ini as well

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

Co-authored-by: Jguer <joao.guerreiro@grafana.com>
2022-12-01 09:41:40 +01:00
Artur Wierzbicki
009d65b794 Add query library behind dev-mode-only feature flag (#55947)
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
Co-authored-by: Adela Almasan <adela.almasan@grafana.com>
Co-authored-by: drew08t <drew08@gmail.com>
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-11-30 15:33:40 -08:00
Ryan McKinley
14a080ec12 EntityStore: Rename ObjectStore to EntityStore (part 2) (#59616) 2022-11-30 17:52:15 -05:00
Christopher Moyer
ab40f8b8a3 Docs: removes screenshots (#59514)
removes screenshots
2022-11-30 16:04:15 -06:00
Mitch Seaman
240c77bb42 Add feature toggles to docs (#59483) 2022-11-30 16:50:20 -05:00
Ryan McKinley
5dc7b01f9d EntityStore: Rename ObjectStore to EntityStore (part 1) (#59613) 2022-11-30 13:42:42 -08:00
Ryan McKinley
b0b74337f1 Chore: fix go.mod and slugify after merge (#59611) 2022-11-30 16:16:57 -05:00
Ryan McKinley
b4b843be66 ObjectStore: Replace path model with folder, uid, and slug model (#59452) 2022-11-30 12:10:35 -08:00
Serge Zaitsev
5f3291be03 Chore: remove GetTeamByUser (#59604)
here goes some unused code
2022-11-30 20:02:31 +01:00
Hamas Shafiq
5073839f8f Chore: Refactor span.js, trace.js & trace.fixture.js to TypeScript (#58006) 2022-11-30 18:09:08 +00:00
Leo
ce630b2dc5 Folder: Fix top folder creation (#59422)
fix top folder creation
2022-11-30 18:51:14 +01:00
Josh Hunt
93eb8cb51d CommandPalette: Add actions for entire Nav tree (#58138)
* wip for exposing full nav tree in command palatte

* Expose whole nav tree in command palette

* give search an icon

* comments

* remove unused index variable

* navigate to parents

* include image icons

* comment
2022-11-30 12:34:25 -05:00
Joey Tawadrous
b12b5ed92f Remove fire text in Phlare ds (#59484)
* Renames

* Rename to phlareql

* Go renames
2022-11-30 17:22:47 +00:00
João Calisto
bba42b113c Middleware: Add Custom Headers to HTTP responses (#59018)
* Middleware: Add Custom Headers to HTTP responses

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update conf/defaults.ini

Co-authored-by: Dave Henderson <dave.henderson@grafana.com>

* Update conf/sample.ini

Co-authored-by: Dave Henderson <dave.henderson@grafana.com>

* Update _index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Dave Henderson <dave.henderson@grafana.com>
2022-11-30 17:12:34 +00:00
Serge Zaitsev
9cdb6b07c7 Chore: Move stats service into a standalone packge from sqlstore (#59574)
* move original stats service into a separate package

* add stats service to wire

* move GetAdminStats

* switch to using stats.Service

* add missing package

* fix api tests
2022-11-30 18:11:07 +01:00
Jack Baldry
a343defe64 Fix release_branch_regexp (#59590)
Apparently the non-capturing group was incorrect.

I verified the logic in a branch in grafana-github-actions:
https://github.com/grafana/grafana-github-actions/compare/jdb/2022-11-prove-grafana-regexp-behaves-correctly?expand=1

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2022-11-30 12:37:03 -04:00
Andres Martinez Gotor
2e64ea652e GoogleCloudMonitoring: Refactor SLO queries (#59421)
* GoogleCloudMonitoring: Refactor metricType input

* Remove preprocessor in favor of secondary inputs

* GoogleCloudMonitoring: Refactor SLO queries

* GoogleCloudMonitoring: Refactor util functions (#59482)

* GoogleCloudMonitoring: Remove unnecessary util functions

* GoogleCloudMonitoring: Refactor run function (#59505)
2022-11-30 17:23:05 +01:00
idafurjes
4ec08c4317 Chore: Delete DeleteUserInSession from sqlstore (#59275)
* Remove DeleteUser from sqlstore

* Use Delete instead of DeleteUser

* Remove unused method

* Remove DeleteUserSession from sqlstore

* Add fake for DeleteUseraccessControl

* Use user service, add fakes to tests

* Add comments to sqlstore

* Correct typo

* Add quota service initialisation

* Add config to acimpl initialisation

* Add routing to initialisation

* Making user provideStore private

* Use InTransaction instead of session

* Add cfg to userimpl

* Fix lint

* Make ProvideStore public again - enterprise tests

* Fix back ProvideStore to public

* Wrap merge user in transaction

* Delete DeleteUserAccessControl use DeleteUSerPermissions instead

* Add feature mgmt into acimpl

* DeleteUserAccessControl from ac database

* Remove case insensitive clause
2022-11-30 17:19:28 +01:00
Ryan McKinley
5b71a16acf Slugify: Replace gosimple/slug with a simple function (#59517) 2022-11-30 11:12:56 -05:00
Ashley Harrison
000de83eb4 Accessibility: Improve a11y in DataLinkSuggestions (#59569)
DataLinkSuggestions: Add role + ignore keyboard lint rule
2022-11-30 15:58:10 +00:00
Kevin Minehart
76a586195a Packaging: Use rpm-digest sha256 when creating rpm packages (#59510)
* Use rpm-digest sha256 when creating rpm packages

* only append this argument with rpm builds
2022-11-30 09:35:02 -06:00
Joey Tawadrous
3b53fdb53a Trace View: Disallow a span colour that is the same or looks similar to previous colour (#58146)
* Disallow sequential spans with the same color

* Disallow same prev color and similar color

* Tests

* Remove assignemnt
2022-11-30 15:14:58 +00:00
Jack Baldry
6d6cb0a478 Remove dependency on test job (#59575)
Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2022-11-30 11:13:46 -04:00
Torkel Ödegaard
6625147e74 PanelEdit: Fixes alignment issue with collapse button (#59414)
* PanelEdit: Fixes alignment issue with collapse button

* Fix
2022-11-30 15:06:32 +00:00
Robby Milo
d4d4e05bcb remove _build param from whatsnew (#59236)
* remove `_build` param from whatsnew

* Update whats-new-in-v9-3.md
2022-11-30 09:06:11 -06:00
Gabriel MABILLE
bf49c20050 RBAC: Add an endpoint to list all user permissions (#57644)
* RBAC: Add an endpoint to see all user permissions

Co-authored-by: Joey Orlando <joey.orlando@grafana.com>

* Fix mock

* Add feature flag

* Fix merging

* Return normal permissions instead of simplified ones

* Fix test

* Fix tests

* Fix tests

* Create benchtests

* Split function to get basic roles

* Comments

* Reorg

* Add two more tests to the bench

* bench comment

* Re-ran the test

* Rename GetUsersPermissions to SearchUsersPermissions and prepare search options

* Remove from model unused struct

* Start adding option to get permissions by Action+Scope

* Wrong import

* Action and Scope

* slightly tweak users permissions actionPrefix query param validation logic

* Fix xor check

* Lint

* Account for suggeston

Co-authored-by: ievaVasiljeva <ieva.vasiljeva@grafana.com>

* Add search

* Remove comment on global scope

* use union all and update test to make it run on all dbs

* Fix MySQL needs a space

* Account for suggestion.

Co-authored-by: ievaVasiljeva <ieva.vasiljeva@grafana.com>

Co-authored-by: Joey Orlando <joey.orlando@grafana.com>
Co-authored-by: Joey Orlando <joseph.t.orlando@gmail.com>
Co-authored-by: ievaVasiljeva <ieva.vasiljeva@grafana.com>
2022-11-30 15:38:49 +01:00
Jo
fee50be1bb Sessions: Remove invalid session cookie if it's invalid/expired/missing (#59556)
only remove invalid session cookie if it's invalid/expired/missing
2022-11-30 15:33:19 +01:00
Jack Baldry
10a83714c8 Automate docs publishing steps (#59550)
Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2022-11-30 10:04:23 -04:00
idafurjes
d6275c58dd Remove GetSignedInUserWithCacheCtx and GetSignedInUser from sqlstore (#59551)
* Remove GetSignedInUserWithCacheCtx and GetSignedInUser from sqlstore

* Delete removed method from test
2022-11-30 14:28:51 +01:00
Will Browne
0fca3cf9dd Datasources: Use context logger in cache service (#59547) 2022-11-30 14:25:04 +01:00
Alex Khomenko
c3d13a0e2f Admin: Combine org and admin user pages (#59365)
* Admin: Add unified users page

* Admin: Combine admin and org components

* Admin: Add combined route

* Admin: Show combined page in nav

* Admin: Update translation

* Admin: Update description

* Admin: Update description on backend

* Admin: Update translations

* Admin: Use dynamic imports
2022-11-30 15:24:53 +02:00
Gabriel MABILLE
32a498e04f RBAC: Validate plugin app access permission targets the plugin (#59468)
* RBAC: Validate plugin app access permission targets the plugin

* Fix service test
2022-11-30 13:55:07 +01:00
Laura Fernández
ddc3706f19 Accessibility: Increase badge constrast to be WCAG AA compliant (#59531) 2022-11-30 13:20:59 +01:00
Hamas Shafiq
0b42b2f790 Chore: Refactor TracePageHeader.test.js to TypeScript (#59256) 2022-11-30 07:08:02 -05:00
Dimitris Sotirakis
ba0b2dfa1a Security: Fix XSS in runbook URL (#59540)
Fix XSS in runbook URL

Co-authored-by: George Robinson <george.robinson@grafana.com>
2022-11-30 12:37:16 +02:00
renovate[bot]
701d1b135e Update dependency rc-drawer to v6 (#58237)
* Update dependency rc-drawer to v6

* updates for rc-drawer v6

* move aria-label to an inner child to fix e2e tests

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-11-30 10:30:06 +00:00
Ashley Harrison
eaa4d19ed0 Navigation: Move k6 to top-level, rename to "Performance testing" (#59481)
Move k6 to top-level, rename to "Performance testing"
2022-11-30 10:27:41 +00:00
sam boyer
695cb06c77 deps: Remove effectless go.mod replace statements (#58882) 2022-11-30 11:24:51 +01:00
Hamas Shafiq
749eb9ed19 Chore: Delete UiFindInput.test.js (#59228) 2022-11-30 10:12:36 +00:00
Dimitris Sotirakis
d11c1ee646 Chore: Update latest.json to 9.3.0 (#59538)
Chore: update latest.json to 9.3.0
2022-11-30 04:52:36 -05:00
Grot (@grafanabot)
005d0f852f Changelog: Updated changelog for 9.3.0 (#59533) 2022-11-30 11:30:06 +02:00
Karl Persson
6aaf36776b RBAC: Handle edge case where there is duplicated acl entries for a role on a single dashboard (#58079)
* RBAC: Handle edge case where there is duplicated acl entries for a role
on a single dashboard
2022-11-30 10:29:21 +01:00
Gabriel MABILLE
5bb99775bb Fix: Unlocking the UI for AuthProxy users (#59507)
Unlocking the UI for AuthProxy users

Co-authored-by: Eric Leijonmarck <eric.leijonmarck@gmail.com>

Co-authored-by: Eric Leijonmarck <eric.leijonmarck@gmail.com>
2022-11-30 09:53:00 +01:00
Jack Westbrook
207b2993b2 Plugins Catalog: Only allow admins to access plugins catalog (#57101)
* feat(plugins-catalog): only allow admins to access plugins catalog routes

* add backend check

* fix(plugins-catalog): update route role access to include server admins

Co-authored-by: Will Browne <will.browne@grafana.com>
2022-11-30 09:41:28 +01:00
mikkancso
c72322874d Connections: Update "Your connections/Data sources" page (#58589)
* navtree.go: update Data sources title and subtitle

* DataSourceList: move add button to header

* DataSourcesList: add buttons to items

The action buttons are added inside `<Card.Tags>` so that they end up at
the right end of the card, as it was designed.

The "Build a Dashboard" button's functionality is not defined yet.

* DataSourcesListHeader: add sort picker

* fix css

* tests: look for the updated "Add new data source" text

* tests: use an async test method to verify component updates are wrapped in an act()

* update e2e selector for add data source button

* fix DataSourceList{,Page} tests

* add comment for en dash character

* simplify sorting

* add link to Build a Dashboard button

* fix test

* test build a dashboard and explore buttons

* test sorting data source elements

* DataSourceAddButton: hide button when user has no permission

* PageActionBar: remove unneeded '?'

* DataSourcesList: hide explore button if user has no permission

* DataSourcesListPage.test: make setup prop explicit

* DataSourcesList: use theme.spacing

* datasources: assure explore url includes appSubUrl

* fix tests and add test case for missing permissions

Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>
2022-11-30 09:41:01 +01:00
Grot (@grafanabot)
312dbc979e Changelog: Updated changelog for 9.2.7 (#59525) 2022-11-30 10:36:11 +02:00
Stephanie Hingtgen
6805c951e9 Plugins: add option to proxy ds connections through a secure socks proxy (#59254)
* Plugins: add feature to proxy data source connections
2022-11-29 23:50:59 -06:00
Leon Sorokin
122f0d947e BarChart: when horiz, allow rotation and skipping of y tick labels (#59354) 2022-11-29 21:46:39 -05:00
sam boyer
ce0bdb2cd9 kindsys: Fix loading on windows (#59519) 2022-11-29 19:01:45 -05:00
Christopher Moyer
823a40bc85 Docs: What's New content for v9.3 (#57991)
* initial content for What's New 9.3

* Update docs/sources/whatsnew/whats-new-in-v9-3.md

* Update docs/sources/whatsnew/whats-new-in-v9-3.md

* makes prettier

* docs: add conflict cli tool

* remoed the conflict users tool in favor of not having it completely out yet

* Adds note about pubdash annotations support in 9.3-beta notes

* puts audit table photo back in right section

* Docs: Add OAuth improvements to what's new in 9.3 (#58756)

* Add OAuth improvements to what's new in v9.3

* Update docs/sources/whatsnew/whats-new-in-v9-3.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/whatsnew/whats-new-in-v9-3.md

* Update docs/sources/whatsnew/whats-new-in-v9-3.md

Co-authored-by: Mitch Seaman <mjseaman@users.noreply.github.com>
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Docs: Add conflict cli tool (#58827)

docs: add conflict cli tool

* docs: add Terraform updates for What's New in Grafana 9.3 (#58858)

* Terraform updates for Grafana 9.3

* Remove empty line

* linting

* Docs: Update OAuth improvements section of what's new in 9.3  (#59045)

Update OAuth improvement docs for 9.3

* fix incorrect version number

* Adds Alerting whats new entries

* Add edge squad 9.3 whats new information

* Docs: Update whats-new 9.3 with auth related news (#59093)

* LDAP role mapping improvements

* RBAC list token's permissions

* Azure force_use_graph_api

* Reorder

* LDAP uniformize

* Update docs/sources/whatsnew/whats-new-in-v9-3.md

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>

* Update docs/sources/whatsnew/whats-new-in-v9-3.md

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>

* Update docs/sources/whatsnew/whats-new-in-v9-3.md

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>

* adds new nav and new language to what's new

* Add report zoom to What's New in 9.3 (#59345)

* Add report zoom to What's New in 9.3

Still needs a link to docs, a double-check on the name of the feature toggle, and a screenshot.

* Update whats-new-in-v9-3.md

* Apply suggestions from code review

* makes prettier

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Chris Moyer <chris.moyer@grafana.com>

* add report zoom image

* fix typo

* fix link to upload images in template description

* Copy edits

* copy and format updates

* Apply suggestions from code review

* Update docs/sources/whatsnew/whats-new-in-v9-3.md

* Update docs/sources/whatsnew/whats-new-in-v9-3.md

* Update docs/sources/whatsnew/whats-new-in-v9-3.md

* Update docs/sources/whatsnew/whats-new-in-v9-3.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/whatsnew/whats-new-in-v9-3.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/whatsnew/whats-new-in-v9-3.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/whatsnew/whats-new-in-v9-3.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/whatsnew/whats-new-in-v9-3.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Fix prettier

* Update whats-new-in-v9-3.md

* update nav wording

* Screenshots for navigation and internazionalization

* adds alerting images

* fixes path to new nav and localization screenshots

Co-authored-by: eleijonmarck <eric.leijonmarck@gmail.com>
Co-authored-by: Owen Smallwood <owen.smallwood@grafana.com>
Co-authored-by: Misi <mgyongyosi@users.noreply.github.com>
Co-authored-by: Mitch Seaman <mjseaman@users.noreply.github.com>
Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
Co-authored-by: Mitchel Seaman <mitchel.seaman@gmail.com>
Co-authored-by: Zsofia <97596715+zsofiakomaromigrafana@users.noreply.github.com>
2022-11-29 17:06:55 -06:00
Andrej Ocenas
038c97f31c TestDatasource: Add scenario for generating trace data (#59299) 2022-11-29 22:50:01 +01:00
Alexander Weaver
1481ace528 Alerting: Fix swallowing of errors when attaching images to notifications (#59432)
* Break out image logic and add logging

* Attach alert log context to image attachment

* Fix capitalization
2022-11-29 13:18:47 -06:00
Kevin Minehart
a77d95807c Store: skip flaky test in the store service (#59443)
skip flaky test
2022-11-29 17:54:20 +00:00
Josh Hunt
b2fdf46820 Docs: Minor improvements to Preferences documentation (#59498)
Small improvements to Preferences documentation
2022-11-29 17:21:07 +00:00
Sonia Aguilar
1020e33409 Add discord as a possible receiver in cloud rules (#59366) 2022-11-29 17:23:21 +01:00
Giordano Ricci
dc918f7e91 Grafana UI: Add experimental InteractiveTable component (#58223)
* wip

* move table

* refine example

* move to experimental

* add row expansion example

* add expanded row to kitchen sink

* add column prop docs

* add props docs

* remove useless example

* WIP

* use unique id per row & proper aria attrs for expander

* add custom cell rendering example

* Remove multisort

* rename shrink to disableGrow

* move isTruthy type guard to @grafana/data

* add missing prop from TableData interface

* make column id required

* fix correlations table

* expand on docs

* remove leftover comment

* rename to InteractiveTable

* add some tests

* add expansion tests

* fix tests

* revert unneeded changes

* remove extra header rule
2022-11-29 16:18:55 +00:00
Ashley Harrison
191ca1df86 Chore: some type fixes (#59030)
some type fixes
2022-11-29 15:52:08 +00:00
Emil Tullstedt
f485f8a8f8 Chore: Upgrade Go dependencies (#59501) 2022-11-29 16:37:45 +01:00
linoman
6cc56311d9 Auth: Display id Provider label in orgs/users view (#58033)
* Add frontend test

* Add frontend label component

* Adjust backend tests

* Retrieve auth IDP labels for users at org/users.

Co-authored-by: Misi <mgyongyosi@users.noreply.github.com>
Co-authored-by: Kalle <kalleep@users.noreply.github.com>
Co-authored-by: Jo <Jguer@users.noreply.github.com>
2022-11-29 15:20:28 +01:00
Galen Kistler
5b7ef92399 Prometheus: Remove raw query toggle (#59069)
* remove the raw query option toggle from the prometheus query builder
2022-11-29 08:12:46 -06:00
Gareth Dawson
6b5ebf2b4b Loki: Add improvements to loki label browser (#59387)
* improvements

* refactor label browser modal

* feat(label-browser-modal): fetch labels on modal open

* apply suggestions

* check for log labels after languageProvider start

Co-authored-by: Matias Chomicki <matyax@gmail.com>
2022-11-29 14:07:34 +00:00
Josh Hunt
37c14bd6bd Internationalization: Preferences documentation (#59203)
* I18n: Preferences documentation

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/administration/organization-preferences/index.md

Co-authored-by: Ursula Kallio <ursula.kallio@grafana.com>

* remove api spec

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Ursula Kallio <ursula.kallio@grafana.com>
2022-11-29 14:02:11 +00:00
Torkel Ödegaard
1395436dce Scenes: Url sync (#59154)
* Scene url sync

* muu

* Progress

* Time range stuff

* Progress

* Progress

* Adding tests

* Rennamed interface

* broken test

* handling of unique url keys

* Fixing isuse with unique key mapping and depth

* Testing grid row expand sync

* Updates

* Switched from Map to Object

* Now arrays work

* Update public/app/features/scenes/core/types.ts

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

* Update public/app/features/scenes/core/SceneTimeRange.tsx

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

* Update public/app/features/scenes/core/SceneObjectBase.tsx

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

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
2022-11-29 14:49:26 +01:00
George Robinson
c8c1499cd0 Docs: Add docs for labels with dots (#59352) 2022-11-29 13:15:48 +00:00
Levente Balogh
778fb07464 Plugins: Make the Plugin Details page reusable (#58741)
* refactor(PluginDetails): use react-router hooks instead of props

* Wip

* refactor: remove unnecessary constant

* feat: use the original plugin details page under connections

* chore: use better wording in the not-found warning

Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>

* chore: use the renderer utility everywhere in the test

* chore: don't show a title while loading a plugin

Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
2022-11-29 13:45:03 +01:00
Ashley Harrison
5e53582bb1 Navigation: change apps icon to differentiate from dashboards (#59476)
change apps icon to differentiate from dashboards
2022-11-29 12:02:58 +00:00
Andres Martinez Gotor
6127409ab3 GoogleCloudMonitoring: Refactor metricType input (#59369)
* GoogleCloudMonitoring: Refactor metricType input

* Remove preprocessor in favor of secondary inputs (#59384)
2022-11-29 12:39:45 +01:00
Ashley Harrison
5011b259c7 Chore: ignore eslint rules in Dropdown/TopNavBarMenu (#59385)
ignore eslint rules in dropdown/topnavbarmenu
2022-11-29 11:13:21 +00:00
Torkel Ödegaard
fd39417db5 VizPanel: Fixes sizing issues (#59456) 2022-11-29 11:02:47 +01:00
Ivan Ortega Alba
3417125553 Reporter: add logger E2E results to be queried by Loki (#58839)
Co-authored-by: dsotirakis <dimitrios.sotirakis@grafana.com>
2022-11-29 10:59:12 +01:00
Karl Persson
17ec4089dc Features: Add aplha feature toggle for authn service (#59469)
* Features: Add aplha feature toggle for authn service

* AuthN: Add service boilerplate

* Set authnz-team as codeowners of authn service
2022-11-29 10:57:47 +01:00
Eric Leijonmarck
8a0e0584ba Auth: Add caseinsensitive check for ingestion command (#59129)
add: check for caseinsensitive configuration and have that on during ingestion
2022-11-29 09:56:51 +00:00
Karl Persson
a4a5307722 Login: Remove CreateUser from LoginService (#59464)
* LoginService: remove create user and use user.Service instead

* Fix tests
2022-11-29 10:20:44 +01:00
Piotr Jamróz
454c8841a4 Glue: Show data links only for fully interpolated correlations (#59052)
* Create data link filters for Explore

* Add comments and make the code more explicit
2022-11-29 10:09:38 +01:00
Serge Zaitsev
57fbe264ea Chore: Remove CreateOrg from alerting and use orgStore instead (#59440) 2022-11-29 09:59:03 +01:00
Sofia Papagiannaki
933879a347 Chore: Delete accidentally committed test database (#59238) 2022-11-29 10:33:43 +02:00
Gabriel MABILLE
d279b6d7b0 Fix: Allow creating snapshot with no dashboard id (#58669) 2022-11-29 09:29:27 +01:00
Kyle Cunningham
839465ae44 Various Panels: Remove beta label from Bar Chart, Candlestick, Histogram, State Timeline, & Status History Panels (#58557)
* Remove beta label from numerous panels.

* Update backend snapshot to fix test

Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2022-11-29 14:26:05 +07:00
Zoltán Bedi
71e4a8261d SQL Datasources: Fix annotation migration (#59438) 2022-11-29 07:56:59 +01:00
George Robinson
110fdf4da9 Alerting: Fix ConditionsCmd behavior when last is No Data (#58953) 2022-11-28 21:56:22 +00:00
Dan Cech
7436872dab Build: Unified dockerfile for all builds (#59173)
* unified dockerfile for all builds

* update builder

* include docker commands and output in logs

* quiet docker build

* quiet gsutil
2022-11-28 16:18:53 -05:00
Dan Cech
3377575788 fix pr-commands.json by removing trailing comma (#59437) 2022-11-28 15:19:01 -05:00
Kevin Minehart
5995824f0c CI: Use the git event payload rather than github context to populate the source SHA in the enterprise downstream test (#59435)
* test

* I guess the pull_request event doesn't include the 'sha' item
2022-11-28 20:49:20 +01:00
Dan Cech
9fec54df2d Build: Streamline and sync dockerfiles (#58101)
* streamline and sync dockerfiles

* improve go dependency cacheability

* unify alpine and ubuntu Dockerfiles

* include glibc support in locally-built alpine images
2022-11-28 14:43:42 -05:00
Brendan O'Handley
84ec35a4ad Transformations: Convert fields transform fix, convert strings with commas to numbers (#59074)
convert strings with commas to numbers
2022-11-28 13:16:02 -05:00
Kevin Minehart
560b595ef2 CI: change regex to accomodate new branching stategy in enterprise (#59429)
change regex to accomodate new branching stategy in enterprise
2022-11-28 13:09:10 -05:00
Ivana Huckova
d6dd86d273 Elasticsearch: Run explore queries trough backend if feature toggle enabled (#59394) 2022-11-28 17:26:45 +01:00
Andre Pereira
8dbde1b921 Tempo: TraceQL table and editor (#59313)
* Tempo: Add the ability to show/hide the Span column in the table when using TraceQL

* Add optional chaining

* Update tests

* Show subcols in a subtable

* Add more space for the subtable

* Remove unused import

* Better expander icon. Improved the subtable styling. Integrated with real data

* Fix expanding the wrong index when table already has an expanded row

* ⚠️ Hack ⚠️ - Fix table links

* Link to spans

* Tempo: [TraceQL] Don't wrap the autocomplete vals for the status tag in quotes

* TraceQL result table improvements and fixes

* Include span name in the subtable

* Loop through data only if it is not nullish

* Integrate traceql with sub-tables

* Added booleans as keywords. Make query editor multiline

* Make date format consistent between trace and span

* Reset expanded indexes when data or subdata change

* Dynamic attributes by trace

* Fix test. Cleanup and refactor

* Tiny refactor

Co-authored-by: Hamas Shafiq <hamas.shafiq@grafana.com>
Co-authored-by: Andrej Ocenas <mr.ocenas@gmail.com>
2022-11-28 16:13:03 +00:00
Sonia Aguilar
a5c58e46f2 Fix Silence table grid layout (#59415) 2022-11-28 17:10:39 +01:00
Sofia Papagiannaki
8ab7ca45cd Nested folder: Fix for PostgreSQL (#59405)
* Nested Folders: Fix PostgreSQL LastInsertId failure

* Fix children sorting

* Fix store tests
2022-11-28 17:48:44 +02:00
Kevin Minehart
b3b7cba0fe CI: add source_sha option to enterprise-pr-check action (#59314)
* add source_sha option to enterprise-pr-check action

* Add git hash to enterprise check branch
2022-11-28 09:44:23 -06:00
Michael Mandrus
40d87d9d40 Datasources: Refactor mixed datasource support to improve concurrency and error handling (#58163)
* recover from panic inside mixed ds query loop

* remove accidental commit

* add messages from panics and errors to the query response

* refactor based on PR comments

* quick update to unit test to verify mixed errors and successes

* reduce concurrency limit
2022-11-28 10:21:54 -05:00
Victor Marin
958aadd54a Table docs (#59395)
* Table docs

* Update docs/sources/panels-visualizations/visualizations/table/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2022-11-28 10:10:54 -05:00
George Robinson
0af3515e95 Docs: Improve docs for images in notifications (#59033) 2022-11-28 14:11:00 +00:00
George Robinson
e7316ff13f Docs: Improve Labels and annotations docs (#59325)
This commit makes a number of changes to the docs for Labels and
annotations.

 1. It changes the order in which Labels and annotations are mentioned
    from Annotations and labels to Labels and annotations as this is
    the order shown in the UI when creating and editing alert rules.
    It is also the order in the Prometheus documentation.

 2. It changes most of the documentation explaining what labels and
    annotations are and the differences between them. It also adds
    some paragraphs on Custom Labels.
2022-11-28 14:09:02 +00:00
Andrej Ocenas
e033775264 NodeGraph: Allow usage with single dataframe (#58448) 2022-11-28 15:03:00 +01:00
Gábor Farkas
f1dfaa784a elastic: add more backend tests (#59312)
* elastic: added backend snapshot tests

* linter fixes
2022-11-28 14:59:57 +01:00
idafurjes
a7b2943dd1 Chore: Delete SetUsingOrg from sqlstore (#59276)
* Chore: Delete SetUsingOrg drom sqlstore

* Adjust test

* Move test to dashboards

* Move test
2022-11-28 14:59:40 +01:00
Joey Tawadrous
ae8acf178b Add flame graph, Phlare and Parca to code owners file (#58328)
Update codeowners file for flame graph, Phlare and Parca
2022-11-28 12:52:00 +00:00
Will Browne
8a09fd3257 Plugins: Fix app child config func typo (#59386)
fix func typo
2022-11-28 13:43:14 +01:00
Kyle Brandt
5623b5afaf SSE: Make sure to forward headers, user and cookies/OAuth token (#58897)
Fixes #58793 and Fixes https://github.com/grafana/azure-data-explorer-datasource/issues/513

Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
2022-11-28 07:40:06 -05:00
Joey Tawadrous
ba37516690 Add Phlare and Parca to commands file (#58330)
Update github commands file
2022-11-28 12:29:28 +00:00
Leon Sorokin
13d5ad2ce2 BarChart: fix hover overlay for hz stacked (#59359) 2022-11-28 06:29:00 -06:00
Josh Hunt
b0e886840d Internationalization: Add language preference analytics (#59230)
* Report change languange

* clean defaults.ini

* Add language to rudderstand user identify call

* undo changes not intended
2022-11-28 07:11:55 -05:00
Denis Limarev
b814c66c1d Perfomance: add preallocation for some slices (#59263)
add preallocation for some slices
2022-11-28 13:10:24 +01:00
Erik Sundell
254577ba56 CloudWatch: Cross-account querying support (#59362)
* Lattice: Point to private prerelease of aws-sdk-go (#515)

* point to private prerelease of aws-sdk-go

* fix build issue

* Lattice: Adding a feature toggle (#549)

* Adding a feature toggle for lattice

* Change name of feature toggle

* Lattice: List accounts (#543)

* Separate layers

* Introduce testify/mock library

Co-authored-by: Shirley Leu <4163034+fridgepoet@users.noreply.github.com>

* point to version that includes metric api changes (#574)

* add accounts component (#575)

* Test refactor: remove unneeded clientFactoryMock (#581)

* Lattice: Add monitoring badge (#576)

* add monitoring badge

* fix tests

* solve conflict

* Lattice: Add dynamic label for account display name (#579)

* Build: Automatically sync lattice-main with OSS

* Lattice: Point to private prerelease of aws-sdk-go (#515)

* point to private prerelease of aws-sdk-go

* fix build issue

* Lattice: Adding a feature toggle (#549)

* Adding a feature toggle for lattice

* Change name of feature toggle

* Lattice: List accounts (#543)

* Separate layers

* Introduce testify/mock library

Co-authored-by: Shirley Leu <4163034+fridgepoet@users.noreply.github.com>

* point to version that includes metric api changes (#574)

* add accounts component (#575)

* Test refactor: remove unneeded clientFactoryMock (#581)

* Lattice: Add monitoring badge (#576)

* add monitoring badge

* fix tests

* solve conflict

* add account label

Co-authored-by: Shirley Leu <4163034+fridgepoet@users.noreply.github.com>
Co-authored-by: Sarah Zinger <sarah.zinger@grafana.com>

* fix import

* solve merge related problem

* add account info (#608)

* add back namespaces handler

* Lattice: Parse account id and return it to frontend (#609)

* parse account id and return to frontend

* fix route test

* only show badge when feature toggle is enabled (#615)

* Lattice: Refactor resource response type and return account (#613)

* refactor resource response type

* remove not used file.

* go lint

* fix tests

* remove commented code

* Lattice: Use account as input when listing metric names and dimensions (#611)

* use account in resource requests

* add account to response

* revert accountInfo to accountId

* PR feedback

* unit test account in list metrics response

* remove not used asserts

* don't assert on response that is not relevant to the test

* removed dupe test

* pr feedback

* rename request package (#626)

* Lattice: Move account component and add tooltip (#630)

* move accounts component to the top of metric stat editor

* add tooltip

* CloudWatch: add account to GetMetricData queries (#627)

* Add AccountId to metric stat query

* Lattice: Account variable support  (#625)

* add variable support in accounts component

* add account variable query type

* update variables

* interpolate variable before its sent to backend

* handle variable change in hooks

* remove not used import

* Update public/app/plugins/datasource/cloudwatch/components/Account.tsx

Co-authored-by: Sarah Zinger <sarah.zinger@grafana.com>

* Update public/app/plugins/datasource/cloudwatch/hooks.ts

Co-authored-by: Sarah Zinger <sarah.zinger@grafana.com>

* add one more unit test

Co-authored-by: Sarah Zinger <sarah.zinger@grafana.com>

* cleanup (#629)

* Set account Id according to crossAccountQuerying feature flag in backend (#632)

* CloudWatch: Change spelling of feature-toggle (#634)

* Lattice Logs (#631)

* Lattice Logs

* Fixes after CR

* Lattice: Bug: fix dimension keys request (#644)

* fix dimension keys

* fix lint

* more lint

* CloudWatch: Add tests for QueryData with AccountId (#637)

* Update from breaking change (#645)

* Update from breaking change

* Remove extra interface and methods

Co-authored-by: Shirley Leu <4163034+fridgepoet@users.noreply.github.com>

* CloudWatch: Add business logic layer for getting log groups (#642)



Co-authored-by: Sarah Zinger <sarah.zinger@grafana.com>

* Lattice: Fix - unset account id in region change handler (#646)

* move reset of account to region change handler

* fix broken test

* Lattice: Add account id to metric stat query deep link (#656)

add account id to metric stat link

* CloudWatch: Add new log groups handler for cross-account querying (#643)

* Lattice: Add feature tracking (#660)

* add tracking for account id prescense in metrics query

* also check feature toggle

* fix broken test

* CloudWatch: Add route for DescribeLogGroups for cross-account querying (#647)

Co-authored-by: Erik Sundell <erik.sundell87@gmail.com>

* Lattice: Handle account id default value (#662)

* make sure right type is returned

* set right default values

* Suggestions to lattice changes (#663)

* Change ListMetricsWithPageLimit response to slice of non-pointers

* Change GetAccountsForCurrentUserOrRole response to be not pointer

* Clean test Cleanup calls in test

* Remove CloudWatchAPI as part of mock

* Resolve conflicts

* Add Latest SDK (#672)

* add tooltip (#674)

* Docs: Add documentation for CloudWatch cross account querying (#676)

* wip docs

* change wordings

* add sections about metrics and logs

* change from monitoring to observability

* Update docs/sources/datasources/aws-cloudwatch/_index.md

Co-authored-by: Sarah Zinger <sarah.zinger@grafana.com>

* Update docs/sources/datasources/aws-cloudwatch/query-editor/index.md

Co-authored-by: Fiona Artiaga <89225282+GrafanaWriter@users.noreply.github.com>

* Update docs/sources/datasources/aws-cloudwatch/query-editor/index.md

Co-authored-by: Fiona Artiaga <89225282+GrafanaWriter@users.noreply.github.com>

* Update docs/sources/datasources/aws-cloudwatch/query-editor/index.md

Co-authored-by: Sarah Zinger <sarah.zinger@grafana.com>

* Update docs/sources/datasources/aws-cloudwatch/query-editor/index.md

Co-authored-by: Fiona Artiaga <89225282+GrafanaWriter@users.noreply.github.com>

* apply pr feedback

* fix file name

* more pr feedback

* pr feedback

Co-authored-by: Sarah Zinger <sarah.zinger@grafana.com>
Co-authored-by: Fiona Artiaga <89225282+GrafanaWriter@users.noreply.github.com>

* use latest version of the aws-sdk-go

* Fix tests' mock response type

* Remove change in Azure Monitor

Co-authored-by: Sarah Zinger <sarah.zinger@grafana.com>
Co-authored-by: Shirley Leu <4163034+fridgepoet@users.noreply.github.com>
Co-authored-by: Fiona Artiaga <89225282+GrafanaWriter@users.noreply.github.com>
2022-11-28 12:39:12 +01:00
Serge Zaitsev
5b861faec3 Chore: Reduce the usage of sqlstore.createorg and use orgservice instead (#59356)
* remove legacy createorg from org service

* remove another createorg from orgimpl

* remove createorg from api pref tests

* remove createorg from api org tests

* fix tests

* remove createorg from annotations test

* remove createorg from team tests

* remove createorg from service accounts

* remove createorg from accesscontrol tests

* remove createorg from provisioning

* Use quotaservice from sc.hs
2022-11-28 12:05:46 +01:00
Selene
92e3ee7d89 StatsColelctor: Check if result is nil before set the metrics (#59372)
Check if result is nil before set the metrics
2022-11-28 05:40:49 -05:00
Andres Martinez Gotor
64143ea7d0 GoogleCloudMonitoring: Refactor types (#58644) 2022-11-28 09:17:01 +01:00
Victor Marin
16af756d50 TablePanel: Add support for Count calculation per column or per entire dataset (#58134)
* WIP

* TablePanel: Add support for Count calculation per column or per entire dataset

* refactor

* refactor

* refactor + fixes

* refactor + tests

* Docs and cue model fix
2022-11-28 10:16:35 +02:00
Gábor Farkas
7ba86dc1dc Elastic: always return DataFrames from the datasource's query method (#58636)
* elastic: response parsing: convert TableModel to DataFrame

* elastic: response parsing: convert JSONDocumentData to DataFrame

* elastic: response parsing: convert TimeSeries to DataFrame

* elastic: unit tests: type fixes

* elastic: fixed unit test
2022-11-28 08:57:56 +01:00
Torkel Ödegaard
f3f1c5aa32 Scene: Fixes infinite update loop (#59306)
* Scene: Fixes infinite update loop

* fixed lint issue
2022-11-25 14:20:56 +01:00
Ivana Huckova
28c390bc90 Loki: Fix adhoc parsing if multiple stream selectors and some empty (#58658) 2022-11-25 14:00:48 +01:00
Gilles De Mey
49f91721ec Alerting: fix "no permissions" alert flashing (#59300) 2022-11-24 19:58:02 +01:00
Sofia Papagiannaki
f5c41ea497 Nested Folders: More API fixes (#59316)
* Nested Folder: Fix create, use camel case for JSON properties

* Fix get parents if the folder does not exist

* Add store test for get parents
2022-11-24 13:28:53 -05:00
Timur Olzhabayev
5a3f0e8696 Docs: Updating sign plugin docs (#59322)
Updating sign plugin docs
2022-11-24 19:00:33 +01:00
Laura Fernández
45d3125919 OptionsUI: SliderValueEditor does not get auto focused on slider change (#59209) 2022-11-24 18:21:33 +01:00
Zoltán Bedi
220295d26f SQL: Return no data response when no rows returned (#59121) 2022-11-24 18:01:05 +01:00
Matias Chomicki
ff87a2641f Loki Variable Query Editor: Improve stream selector tooltip text (#59311)
* feat(loki-variable-query-editor): improve stream selector tooltip text

* Chore: improve sample stream selector

* Chore: update sample stream selector in tooltip

* Chore: add example of interpolated stream selector
2022-11-24 11:41:02 -05:00
Zoltán Bedi
58fd0a8b44 Calcs: Fix difference percent in legend (#59243) 2022-11-24 16:23:13 +01:00
Torkel Ödegaard
d76638338d PanelEdit: Fixes bug with not remembering panel options pane collapse/expand state (#59265) 2022-11-24 16:03:26 +01:00
Ieva
a8bae3f0b0 Access Control: Clear user's permission cache after resource creation (#59101)
* refresh user's permission cache after resource creation

* clear the cache instead of reloading the permissions

* don't error if can't clear cache

* fix tests

* fix tests again
2022-11-24 14:38:55 +00:00
Karl Persson
a53f57cc43 Navigation: Support rbac for new dashboard, import dashboard and new folder (#59303)
RBAC: Support rbac for new dashboard, import dashboard and new folder
page
2022-11-24 15:25:51 +01:00
Kevin Minehart
45c759eb59 CI: Make the downstream enterprise test a check instead of comments (#59071) 2022-11-24 08:17:12 -06:00
Tania
76372a240c Storage: Add system users service (#57767)
* Storage: Add access for reporting

* reporting upload user per org

* add some basic comments

* Move reporting storage to enterprise

* add comments

Co-authored-by: Artur Wierzbicki <artur.wierzbicki@grafana.com>
2022-11-24 15:15:32 +01:00
renovate[bot]
e84a01e870 Update jest monorepo to v29 (#58261)
* Update jest monorepo to v29

* update snapshots + wrap test in act

* fix linting errors: jest.mocked now defaults to deep mocking

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-11-24 14:00:41 +00:00
Sofia Papagiannaki
8e6d343981 Nested Folders: Some API fixes (#59298)
* Nested Folders: Fix API responses

* Fix panic during deletions

* Add test
2022-11-24 08:59:47 -05:00
Ivan Ortega Alba
1a6b46e98d Scenes: Add support for Datasource variables (#59147) 2022-11-24 13:53:31 +01:00
Victor Marin
0da77201bf TimeseriesPanel: Preserve string fields for data link interpolation (#58424)
* TimeseriesPanel: Preserve string fields for data link interpolation

* clean code

* Modify tests so that string fields are allowed only when a valid time/number dataframe exists

* performance mods

* fix wrong length

* remove console.log

* Check if aligned dataframe has links
2022-11-24 14:44:32 +02:00
Uladzimir Dzmitračkoŭ
1ee52e14d2 GrafanaUI: Add disabled option for menu items (#58980) 2022-11-24 13:39:42 +01:00
Sven Grossmann
400ada1ad0 Logs: Fix misalignment of LogRows (#59279)
* add default display flex

* changed to `text-align: left`
2022-11-24 13:21:55 +01:00
Dimitris Sotirakis
2d7fcea8fa CI: Remove npm steps from enterprise pipelines (#59108)
Remove npm steps from enterprise pipelines
2022-11-24 14:12:07 +02:00
Oscar Kilhed
be73418d00 PostgreSQL: Fix missing CA field from configuration (#59280)
* PostgreSQL: Fix missing CA field from configuration
2022-11-24 12:52:10 +01:00
Polina Boneva
314c22bc5b PanelChrome: Implementing the new layout on PanelChrome @ grafana/ui (#57203)
* Use newPanelChromeUI feature flag in DashboardPanel panel rendering

* just render the PanelChromeUI instead of the PanelChrome

* add new props to PanelChrome; have ChromePanel from grafana/ui in DashboardPanel for testing (will remove before finished);

* put icons next to the title of PanelChrome header space

* arrange PanelChrome's title icons into view/edit/status sections

* icons next to title in PanelChrome are surrounded by square focusable space

* items to be render in Header in PanelChrome come in as props

* PanelChrome accepts items next to title from the outside; currently them being ordered in the left side is okay, right side not so much

* revert local changes to DashboardPanel

* cleanup unused imports

* simple PanelChrome render without any header props

* CSS function

* add test PanelChrome prop padding

* add icons next to title if they are passed to PanelChrome

* fixed PanelChrome header: hoverHeader, having a menu prop;

* only show icons with correct icon names; show menu icon only on hover over panel container; minor other fixes

* attempt to resolve hovering in an RTL test for the menu icon to work as expected

* menu opens in a Dropdown if provided as prop

* fixing tooltips and aria-labels

* Fixed issue with light theme in storybook

* comment out props and tests that are not yet used

* Fixed issue where content was overflowing the boundaries

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-11-24 13:21:18 +02:00
Sofia Papagiannaki
f3da48bd50 SQLStore: Refactor query retries to use exponential backoff (#58559) 2022-11-24 13:12:50 +02:00
zdg-github
a2f1d2e102 TraceView: Fix broken rendering when scrolling in Dashboard panel in Firefox (#56642) 2022-11-24 11:49:55 +01:00
Andres Martinez Gotor
276b54fe9d Azure Monitor: Fix empty/errored responses for Logs variables (#59240) 2022-11-24 11:25:40 +01:00
Serge Zaitsev
cff36ea7d8 Chore: Remove unused method from sqlstore (#59156)
remove unused method
2022-11-24 05:21:06 -05:00
Hamas Shafiq
624e6037cf Chore: Refactor transform-trace-data.test.js to TS (#59214) 2022-11-24 05:16:00 -05:00
Hamas Shafiq
2105e52138 Chore: Refactor the packages/jaeger-ui-components/src/model folder to TS (#59233) 2022-11-24 09:56:09 +00:00
Timur Olzhabayev
24ce1a8a0b Feat: Adding an optional browser config option to e2e test runner (#59076)
Adding an optional browser config option to e2e test runner
2022-11-24 10:15:21 +01:00
Leon Sorokin
6f00bc5674 Heatmap: Fix blurry text & rendering (#59260) 2022-11-23 21:55:30 -06:00
matt abrams
f4574f098d DataLinks: Improve Data-Links AutoComplete Logic (#58934)
* refactor dollar-sign logic to consider cursor position

* refactor logic

* add inline comment for obscure collapse() function
2022-11-24 03:59:37 +01:00
Ryan McKinley
5888f53aab Angular: auto-migrate graph panel when angular is disabled (#59247) 2022-11-23 13:32:52 -08:00
Nathan Marrs
5fe35e4860 Canvas: Update docs for 9.3.0 (#59168) 2022-11-23 11:58:21 -08:00
Drew Slobodnjak
38b74d8bd6 Geomap: Update documentation for 9.3 (#59164)
* Geomap: Update documentation for 9.3

* Update docs/sources/panels-visualizations/visualizations/geomap/index.md

Co-authored-by: Nathan Marrs  <nathanielmarrs@gmail.com>
2022-11-23 11:46:04 -08:00
owensmallwood
4d8e681b96 Chore: update latest.json to 9.2.6 (#59246) 2022-11-23 13:44:46 -06:00
Dimitris Sotirakis
27bd50da52 Docs: Update merge-pull-request.md regarding backport policies (#59239)
* Update merge-pull-request.md

* yarn run prettier:write
2022-11-23 20:51:09 +02:00
Ryan McKinley
0a7a5b13fe Heatmap: Remove legacy angular based implementation (#59249)
remove angular heatmap
2022-11-23 10:46:21 -08:00
Andre Pereira
183b279274 Explore: Sub-tables support for Table component (#58682)
* First commit with working version of sub-tables using subData array

* Update TableContainer and query result to support a dataframe array for the table result

* Fix border issue by moving the subtable to above the cells in the DOM

* Allow header to be configurable using custom options.

* Update TablePanel to support sub-tables

* Fix main row links

* Added tests

* Fix TablePanel correctly splitting frames and sub-frames by using refId
2022-11-23 17:49:32 +00:00
Selene
b981a93f9a Chore: Add Quote function in DB (#58594)
Added Quote function
2022-11-23 18:40:58 +01:00
Selene
9dc82606db LoginService: Remove unused sqlstore (#58595)
Remove unused sqlstore
2022-11-23 17:58:52 +01:00
Ashley Harrison
d33b4918cd Chore: more any/type assertion improvements (#59229)
more any/type assertion improvements
2022-11-23 16:54:57 +00:00
Gareth Dawson
a098bdef58 Loki: Make label browser accessible in query builder (#58525)
* add label browser button to query editor header

* add dynamic button label text

* add LabelBrowserModal.tsx

* toggle label browser modal on click

* pass required props to LabelBrowserModal

* add placeholder to text input

* render label browser inside of the modal

* change button based on label status

* remove label browser button from code mode

* fix element overlap in label browser

* fix undefined app in feature tracking

* remove all any types

* add tests for label browser button

* update modal component width

* update label loading function

* add tests to LabelBrowserModal

* fix broken mock datasource

* update test names

* use stack component for button spacing

* revert modal width

* update label search placeholder

* remove unused import

* add test assertion for closed modal

* remove redundant if statement

* remove unnecessary code

* update error message and fix position

* fix input placeholder text
2022-11-23 16:48:41 +00:00
Dan Cech
ed72b02b27 Chore: update vscode "Run Server" config for single-binary (#59237)
update vscode "Run Server" config for single-binary
2022-11-23 11:32:42 -05:00
Shirley
7cec30f0e1 CloudWatch: Fix flaky test assertions (#59234) 2022-11-23 17:13:47 +01:00
Gareth Dawson
94372f5f23 Loki: Remove raw query toggle (#59125)
* set default query expression

* always show raw query

* remove raw query title

* remove test for raw query toggle

* remove raw query toggle

* remove default expression

* hide raw query preview if empty

* remove e2e test for raw query toggle

* update test name
2022-11-23 16:07:59 +00:00
Grot (@grafanabot)
ae508c12f3 Changelog: Updated changelog for 9.2.6 (#59232) 2022-11-23 10:05:17 -06:00
Karl Persson
83c101dc34 LoginAttempts: Reset attempts on successfull password reset (#59215)
* LoginAttempt: Add function to reset attemtps for username

* PasswordReset: Reset attempts on successful password reset
2022-11-23 16:57:18 +01:00
Andres Martinez Gotor
9d88e14f01 Azure Monitor Logs: Avoid warning when the response is empty (#59211) 2022-11-23 16:15:18 +01:00
Sofia Papagiannaki
ad96b240fc Nested Folder: Enforce maximum nested folder depth (#59213)
* Nested Folder: Enforce maximum nested folder depth

* Cleanup

* Fix logging
2022-11-23 09:44:45 -05:00
Sonia Aguilar
980a2cb949 Use Stack from experimental instead of css styles for flex containers (#59201) 2022-11-23 15:43:38 +01:00
George Robinson
c9286ff794 Alerting: Remove comments for fixed behavior (#58951) 2022-11-23 15:37:15 +01:00
Josh Hunt
2d8910d9de Chore: gitignore storage.json (#59225) 2022-11-23 09:31:40 -05:00
Josh Hunt
ba0ac08465 Internationalization: Enable internationalization by default (#59204)
* Enable internationalization feature flag by default

* Change i18n feature to beta

* Set i18n feature flag to stable

* update features
2022-11-23 14:23:26 +00:00
Hamas Shafiq
6d94fa6aa5 Tempo: Send the correct start time when making a TraceQL query (#59128) 2022-11-23 13:45:10 +00:00
Timur Olzhabayev
5af9a511c0 Chore: Reordering codeowners file (#59198)
Reordering codeowners file
2022-11-23 14:09:27 +01:00
Grafana I18n Bot
343f65fffb I18n: Crowdin sync (#59210)
* New translations grafana.json (French)

* New translations grafana.json (Spanish)

* New translations grafana.json (German)

* New translations grafana.json (Chinese Simplified)
2022-11-23 07:24:54 -05:00
Josh Hunt
f180bb46f8 I18n: Translate Dashboard Starred notification (#59138) 2022-11-23 13:12:33 +01:00
Leo
7d82a27835 Folder: Provide adhoc ui for nested folder creation (#59126)
chore: provide adhoc ui for nested folder creation
2022-11-23 13:08:36 +01:00
Hamas Shafiq
4e6b8f658e Chore: Refactor TreeNode.js & TreeNode.test.js to TypeScript (#58540) 2022-11-23 11:48:25 +00:00
Ashley Harrison
c2f31c2685 Navigation: always show GetStartedWithPlugin even if there's install control wa… (#59127)
always show `GetStartedWithPlugin` even if there's install control warnings
2022-11-23 11:34:00 +00:00
Sofia Papagiannaki
0af96936be Nested Folders: Do not refer to the configuration for checking for the flag (#59197)
* Nested Folders: Do not refer to the configuration for checking for the flag

Use always features.IsEnabled() instead

* Depend on the interface instead
2022-11-23 06:16:00 -05:00
Selene
a0334a92f5 Solo Panel: Configurable timezone (#59153)
* Allow to set timezone in query

* Use optional timestamp

* Update timeZone
2022-11-23 12:14:35 +01:00
Jo
d7a652ff7f User: Optimize signed in user cache management (#59090)
* only access the cache if a user ID is set

* ignore all negative values
2022-11-23 12:04:38 +01:00
Josh Hunt
c02f2321c1 I18n: Fix variables not interpolating with pseudo localisation (#59145)
* I18n: Don't pseudolocalise string variables

* clean up
2022-11-23 10:32:20 +00:00
Yann Vigara
f1ef63791a Fix #58598 X-ID-Token header missing on Loki Datasource (#58784)
* Fix #58598 X-ID-Token header missing on Loki Datasource

* Remove unecessary continue statements

* Add getAuthHeadersForCallResource unit tests

* Fix test and switch statement issues introduced during merge
2022-11-23 11:31:50 +01:00
idafurjes
054d87e52e Chore: Remove DeleteUser from sqlstore (#59180)
* Remove DeleteUser from sqlstore

* Use Delete instead of DeleteUser

* Remove unused method
2022-11-23 11:15:48 +01:00
Ashley Harrison
8761a71da2 Navigation: use correct id to find cloud access policies page (#59123)
use correct id to find cloud access policies page
2022-11-23 10:01:57 +00:00
Serge Zaitsev
c2e847d0b0 Chore: Remove createorgwithmember (#59161)
remove createorgwithmember
2022-11-23 10:37:04 +01:00
Zoltán Bedi
75097b99fb SQL: Fix code editor for SQL datasources (#58116)
* SQL: Fix code editor for sql datasources

* Fix: mysql completion with defaultdb
2022-11-23 10:36:07 +01:00
George Robinson
7376eee6ff Alerting: Support From and To when taking screenshots (#59166)
This commit adds support for the From and To parameters that set the
time range for the graph. The default is 6 hours, which can sometimes
be too large of a time range.
2022-11-23 09:28:24 +00:00
Konrad Lalik
cae5d89d0f Alerting: Add dashboard and panel picker to the rule form (#58304)
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2022-11-23 10:27:49 +01:00
Serge Zaitsev
245a59548c Chore: Remove DeleteOrg method from sqlstore (#59162)
remove DeleteOrg method from sqlstore
2022-11-23 10:22:52 +01:00
Sofia Papagiannaki
02b6b09121 Nested Folders: Set user in the API level (#59148) 2022-11-23 11:13:47 +02:00
Laura Fernández
4a628f18b0 Internationalization: Translate menu items (#59088) 2022-11-23 09:34:53 +01:00
Leon Sorokin
9512f1e1af StateTimeline: Prevent label text from overflowing state rects (#59169)
Co-authored-by: Vegard Vatn <vegard.vatn@avento.no>
2022-11-22 20:58:48 -07:00
Leon Sorokin
2a8706b025 Heatmap: Fix tooltip y range of top and bottom buckets in calculated heatmaps (#59172)
Co-authored-by: xdavidwu <xdavidwuph@gmail.com>
2022-11-22 20:54:54 -07:00
Nathan Marrs
e157ef1171 Canvas: Add icon value mapping (#59013) 2022-11-22 14:39:19 -08:00
Hamas Shafiq
51359fe90d Chore: Refactor Tween.test.js to TypeScript (#58655) 2022-11-22 22:19:35 +00:00
juanicabanas
a93b8a03cb PublicDashboards: Orphaned public dashboard deletion script added (#57917)
* Adds migration to remove orphaned public dashboards.

Co-authored-by: Jeff Levin <jeff@levinology.com>
2022-11-22 13:11:06 -09:00
Drew Slobodnjak
ee8f292c6a Geomap: Improve location editor (#58017)
* add custom component for location editor

* FC cleanup

* Apply filter to add location fields call

* Create custom editor for location mode

* Apply validation logic and render warning

* Improve alert styling

* Add help url button to location alert

* Add success alert for auto

* Remove completed TODOs

* Only use alert on error, not success

* Change location mode to dropdown

* Change alert severity to less severe, info

* Prevent auto field selection during manual

* Update location testing to be for auto mode

* Run geo transformer editor init once

* Fix breaking test

* Clean up some anys

* Update styling for alert

* Remove auto success styling

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2022-11-22 11:24:56 -08:00
Serge Zaitsev
b875ca08c6 SQLStore: Make addOrgUser private (#59142)
make addOrgUser private
2022-11-22 17:02:39 +00:00
Dan Cech
de99ce139c Server: Switch from separate server & cli to a unified grafana binary (#58286)
* avoid the need for a second bulky binary for grafana-cli

* look for grafana-server in $PATH as well as same directory

* implement unified "grafana" command

* update dockerfiles, fix grafana-cli -v

* update packaging to work with single binary

- add wrapper scripts for grafana and grafana-server
- update and sync package files
- implement --sign flag of build package command
- stop packaging scripts folder, they are not useful for end users
- add support for --configOverrides in server command
- remove unused nfpm.yaml config file

* windows support
2022-11-22 11:53:43 -05:00
Ashley Harrison
824a562b03 Navigation: share logic between buildBreadcrumbs and usePageTitle (#58819)
* simplify usePageTitle logic a bit

* use buildBreadcrumbs logic in usePageTitle

* always add home item to navTree, fix some tests

* fix remaining unit tests
2022-11-22 16:48:07 +00:00
Ashley Harrison
26a7423151 Chore: add some unique keys to prevent warnings (#59143)
add some unique keys to prevent warnings
2022-11-22 16:42:21 +00:00
Guilherme Caulada
414df842b8 Build: Add command to publish to AWS Marketplace through the pipeline (#59068)
* Remove generic variables from publish github action

* Create publish aws cmd to automate aws releases

* Add tests to publish aws cmd

* Replace fmt with log for prints

* Remove unnecessary type assertions

* Readd mistakenly removed go package

* Replace log with fmt for prints due to conflicts

* Update github tests to conform with casing
2022-11-22 13:04:14 -03:00
Jean-Philippe Quéméner
41b3398eb4 Alerting: Enable interpolation for notification policies in file provisioning (#58956) 2022-11-22 16:54:24 +01:00
Kristina
d5274dfdda Explore: Skip flaky query history test (#59135)
Skip flaky query history test
2022-11-22 10:52:50 -05:00
Joao Silva
f8dc333ee4 Preferences: Add confirmation modal when saving org preferences (#59119) 2022-11-22 16:47:42 +01:00
Andres Martinez Gotor
5b1ff83ee9 Azure Monitor: Fix resource picker selection for subresources (#56392) 2022-11-22 16:43:57 +01:00
Andres Martinez Gotor
3bea8f2462 Azure Monitor: Fix namespace selection for storageaccounts (#56449) 2022-11-22 16:43:35 +01:00
Ivan Ortega Alba
f98ec2c582 Scenes: Add custom variable support (#59057) 2022-11-22 16:30:16 +01:00
Shirley
c43e1a721f CloudWatch: fix custom namespace for listing dimension keys, refactor to non-pointer types, add test assertions, rename packages (#59106)
Co-authored-by: Erik Sundell <erik.sundell87@gmail.com>
2022-11-22 15:59:11 +01:00
Hamas Shafiq
f62e55f461 Chore: Refactor CopyIcon.test.js to TS (#59024) 2022-11-22 14:40:12 +00:00
Hamas Shafiq
2903e2dbf5 Chore: Refactor UiFindInput.test.js to TypeScript (#59063) 2022-11-22 14:38:43 +00:00
Serge Zaitsev
7ff41cde9a Chore: Fix status codes for nested folders (#59087)
* check for errutil errors first

* a better fix
2022-11-22 16:06:39 +02:00
Ashley Harrison
6f26668a9f Chore: Document theme toggle keybinding (#59031)
* make theme toggle keybinding dev only

* fix bug + add support for theme change keybinding
2022-11-22 14:01:51 +00:00
sam boyer
42baad837a codegen: Refactor core jennies for reusability, add version-picking metajennies (#58995)
* Add each-major jenny, refactor TS jenny for it

* Introduce LatestJenny, refactor GoTypesJenny for it
2022-11-22 15:00:29 +01:00
Andreas Christou
4eed56193f DataSourceWithBackend - Set postResource method to POST (#59114)
Set postResource method to POST
2022-11-22 13:31:47 +00:00
Sven Grossmann
08e87a217c Loki: Add gzip compression to resource calls (#59059)
* Loki: Add compression to `callResource`

* add missing tests

* fix formatting
2022-11-22 14:02:30 +01:00
Gábor Farkas
afeb21e300 yarn: commit files to make yarn-install reproducible (#55979) 2022-11-22 13:49:03 +01:00
Marcos de Oliveira
91582ba03d LDAP: Make LDAP attribute mapping case-insensitive (#58992)
* Make LDAP attribute mapping case-insensitive

* Add test case with attribute name different from schema's

* Add fix to getArrayAttribute also and add test with mismatched letter
case.

* Update pkg/services/ldap/helpers.go

Co-authored-by: Misi <mgyongyosi@users.noreply.github.com>
2022-11-22 13:47:53 +01:00
Denis Limarev
4d8287b319 Performance: add preallocation for some slice/map (#57860)
This change preallocates slices and maps where the size of the data is known before the object is created.

Co-authored-by: Joe Blubaugh <joe.blubaugh@grafana.com>
2022-11-22 20:24:36 +08:00
Josh Hunt
460be70261 Internationalization: Change locale preference to language (#58359)
* backend locale -> language

* frontend locale -> language

* sample.ini and tests

* fix few last locale -> language

* fix few last locale -> language
2022-11-22 12:18:34 +00:00
Sofia Papagiannaki
9926931d40 Nested Folder: Include URL into the GET response (#59099) 2022-11-22 07:04:09 -05:00
brendamuir
6c6103d573 Docs: adds workaround for editing provisioned rules using the HTTP API (#59094)
* Docs: adds workaround for editing provisioned rules using api

* updates text

* updates text take two
2022-11-22 11:46:48 +00:00
Sonia Aguilar
9c4b78ae4f Alerting: add group name validation in alert rule form (#59095)
Add group name validation in alert rule form
2022-11-22 12:26:07 +01:00
Ashley Harrison
19e97a1f31 Accessibility: Improve keyboard accessibility in Collapse (#59022)
fix keyboard accessibility in Collapse
2022-11-22 11:19:57 +00:00
Karl Persson
189bf102cf LoginAttempt: Move logic around login attempts into the service (#58962)
* LoginAttemps: Remove from sqlstore mock

* LoginAttemps: Move from models package to service package

* LoginAttemps: Implement functionallity from brute force login in service

* LoginAttemps: Call service

* LoginAttempts: Update name and remove internal functions

* LoginAttempts: Add tests

* LoginAttempt: Add service fake

* LoginAttempt: Register service as a background_services and remove job
from cleanup service

* LoginAttemps: Remove result from command struct

* LoginAttempt: No longer pass pointers
2022-11-22 11:37:18 +01:00
Sonia Aguilar
082c8ba7a0 Docs: Add step for custom labels in alert form (#59027) 2022-11-22 11:35:54 +01:00
kay delaney
850f5fa8d7 LibraryPanels: Fix issue where viewer with folder edit permissions could not update library panel (#58420)
* LibraryPanels: Fix issue where viewer with folder edit permissions could not update library panel
2022-11-22 10:05:55 +00:00
Karl Persson
062c5b805c Auth: Merge ActiveAuthTokenService into UserAuthTokenService (#59032)
* Auth: Merge UserTokenService and ActiveAuthTokenService

* Auth: Rename function
2022-11-22 10:58:59 +01:00
linoman
f8f61c1a69 Auth: Add expiry date for service accounts access tokens (#58885)
* Add new configuration option for SA tokens

* Add new expiry date option to frontend components

* Add backend validation


Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
2022-11-22 10:08:40 +01:00
jmatosgrafana
c1eabb893f Docs: Update RSS feed in security page (#56439)
* Update RSS security feed

* docs: update security.md to refer to blog

* Update SECURITY.md

Co-authored-by: Richard Hartmann <RichiH@users.noreply.github.com>

Co-authored-by: Daniel Lee <dan.limerick@gmail.com>
Co-authored-by: Richard Hartmann <RichiH@users.noreply.github.com>
2022-11-22 10:07:59 +01:00
Sasha Melentyev
c02003af3c Refactor time durations (#58484)
This change uses `time.Second` in place of `1000 * time.Millisecond` and `time.Minute` in place of `60*time.Second`.
2022-11-22 15:09:15 +08:00
sam boyer
6ac43c9cb4 kindsys: Return Decl from Kinds (#59075)
* kindsys: Return Decl from Kinds

* Add funcs to extract DeclForGen from kinds
2022-11-21 17:50:06 -05:00
Bart Peeters
57d6adbc7c Alerting: Support Prometheus durations in Provisioning API (#58293)
Provisioning API should support Prometheus durations
2022-11-21 18:58:25 +00:00
Zoltán Bedi
38f25a0bf5 MS/My/PostgresSQL: Migrate annotation query (#58847) 2022-11-21 19:46:04 +01:00
Dimitris Sotirakis
44402ff726 CI: Split enterprise2 pipelines (#57997)
* Add publishimages_enterprise2.go file

* Add push.go

* Modify build files

* Modify starlark files

* Remove promotion pipeline

* Remove unused args

* Handle tag for custom events
2022-11-21 20:06:00 +02:00
Leon Sorokin
1f4834a144 Prometheus: fix Heatmap y buckets when legendFormat: auto (#59053) 2022-11-21 10:29:37 -07:00
Sonia Aguilar
99725bf9d4 Alerting: Improve UI for making more clear that evaluation interval belongs to the group (#56397)
* In GrafanaEvaluationBehaviour component : Split evaluation interval from for duration and add button to edit to allow editing it and warning

* Move folder and group fields to the evaluation section in the alert form

* Include 'Group behaviour' info in a card and fix 'Edit group behaviour' button onClick.

* Create hook for  getting groups for a particular folder

* Use dropdown in group instead of input and fill it with groups that belong to the selected folder

* Add evaluation interval for each group in dropdown , and show warning in case user wants to update it

* Avoid saving evaluation interval when some rules in the same group would have invalid For with this change

* Clear group value when reseting the drop down

* Remove evaluationEvery from form values, show this as a label and add a button to edit the group

* Open EditRuleGroupModal for editing evaluation interval form the alert rule form

* Fix aligment in group behaviour card

* compact space in evaluation behaviour card and change group drop down label

* In EditgroupModal, in case of grafana managed group, show folder instead of namespcace label and disable the folder name input

* Add edge case in rulesInSameGroupHaveInvalidFor method when For value is zero

* Vertically align annotations input to the evaluation section in alert rule form

* Fix width when editing new group

* Add placeholder for group input

* Make folder and group in modal readonly from alert form and disable edit group button when new group

* Update texts

* Don't show evaluation behaviour section until folder and group are selected

* Update texts

* Fix merge conflits

* Fix wrong margin in evaluation label

* Remove non-used isRulerGrafanaRuleDTO method

* Remove negative margin to avoid overlaping on Firefox
2022-11-21 17:59:19 +01:00
Laura Fernández
8f567d57fa Internationalization: Translate ViewJSONmodal and ClipboardButton (#58807) 2022-11-21 17:37:53 +01:00
Sven Grossmann
a62e437eb3 DevEnv: Add default loki configuration (#59058)
add local default config
2022-11-21 17:12:27 +01:00
ying-jeanne
ba8124ef93 Chore: Fix SQLx failure when starting the server with newDBLibrary enabled (#58985)
change the weekstart to pointer

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>
2022-11-21 16:53:56 +02:00
Torkel Ödegaard
156ed4b56c VizPanel: Support panel migrations and state changes (#58501)
* VizPanel: Make it more real

* Updates

* Progress on query runner and max data points from width

* Updated

* Update

* Tests

* Fixed issue with migration

* Moving VizPanel

* Fixed migration issue due to pluginVersion not being set

* Update public/app/features/scenes/querying/SceneQueryRunner.test.ts

Co-authored-by: Ivan Ortega Alba <ivanortegaalba@gmail.com>

* Some minor review fixes

* Added expect

Co-authored-by: Ivan Ortega Alba <ivanortegaalba@gmail.com>
2022-11-21 15:31:01 +01:00
Sofia Papagiannaki
15561b83e4 Nested Folders: Make parent_uid column nullable (#59035)
Nested Folders: Make parent UID column nullable
2022-11-21 15:24:20 +01:00
Kristina
bdfa127ee5 Explore: Notify when compact URL is used (#58684)
* Add explore compact url notices

* Add error checking around data links urls

* Fix tests

* remove global flag, add test for warning in title

* Move feature tracking to initialization, add better error messaging

* Fix test

* Add compact url tests, fix styling bug, remove warning tooltip

* Fix broken check, move tests to util file
2022-11-21 08:03:50 -06:00
Josh Hunt
b1ffe18599 Chore: Fix some as HTMLElement type assertions (#58667) 2022-11-21 13:05:55 +00:00
Andres Martinez Gotor
448358ac66 @grafana/runtime: Avoid calling applyTemplateVariables for the wrong datasource (#57921) 2022-11-21 13:09:43 +01:00
Andreas Christou
f8656d269d AzureMonitor: Separate subscription health check API version (#58253)
Separate subscription health check API version
2022-11-21 13:03:16 +01:00
George Robinson
2f878acd9d Alerting: Add Troubleshooting to Images in notifications docs (#58955) 2022-11-21 11:21:59 +00:00
Karl Persson
4d1504d160 Change codeowner of login and login attempt packages (#59020)
Set grafana authnz team as CODEOWNERS for /pkg/services/loginattempt and /pkg/login
2022-11-21 05:32:47 -05:00
Sonia Aguilar
ee9057a5fa Alerting: Remove checkForPathSeparator validation in alert rule name (#59014)
Remove checkForPathSeparator validation in alert rule name
2022-11-21 11:15:00 +01:00
Mitch Seaman
b0fc736e7a Remove Annotations API version reference (#57057)
Remove minimum version reference in Annotations API docs, since docs are versioned and this feature has been released for years.
2022-11-21 10:07:59 +00:00
Ashley Harrison
8aa74fe9ee Accessibility: Improve keyboard accessibility of FilterPill (#58976)
fix keyboard a11y in FilterPill
2022-11-21 09:29:41 +00:00
Ashley Harrison
598935cb34 Accessibility: Improve keyboard accessibility in AnnoListPanel (#58971)
fix keyboard accessibility in AnnoListPanel
2022-11-21 09:25:56 +00:00
Yuri Tseretyan
b57689e07e Alerting: Add header X-Grafana-Org-Id to evaluation requests (#58972) 2022-11-21 10:13:44 +01:00
Leo
4aa5dea96b Navigation: Set navtree to an empty array instead of null (#58919)
set navtree to  an empty array instead of null
2022-11-21 09:43:21 +01:00
Leo
14fbd44ac0 Navigation: Prevent viewer role accessing dashboard creation, import and folder creation (#58842)
hide pages related dashboard import create and folder creation for viewer role
2022-11-21 09:42:58 +01:00
Sonia Aguilar
97bf3c1dca Alerting: Move alert rule name to the top left in alert form (#58579)
* Move alert rule name to the top left in alert form, and add a placeholder

* Update docs

* Fix lint error
2022-11-21 09:11:02 +01:00
Christopher Moyer
8ac197b11c Docs/removes admin screenshots (#58994)
* removes screenshots in the admin docs

* removes unneeded screenshot
2022-11-18 15:55:46 -06:00
Christopher Moyer
780efa5791 Docs: adds permission validation setting (#58970)
* adds permission validation setting

* Update docs/sources/administration/roles-and-permissions/access-control/configure-rbac/index.md

Co-authored-by: Misi <mgyongyosi@users.noreply.github.com>

* makes prettier

Co-authored-by: Misi <mgyongyosi@users.noreply.github.com>
2022-11-18 12:06:09 -06:00
Andreas Christou
19ff3645e8 Update verify-release script (#58812)
Update verify-release script with required arg
2022-11-18 16:47:13 +00:00
Christopher Moyer
e7b5bd34bd Docs: adjusts link to kms integration (#58981)
adjusts link to kms integration
2022-11-18 10:46:07 -06:00
George Robinson
4da97aef7d Alerting: Fix metric in Images in Notifications docs (#58954) 2022-11-18 16:28:00 +00:00
Ashley Harrison
e19957bbc8 Accessibility: Improve keyboard accessibility in GettingStarted panel (#58966)
fix keyboard a11y in `GettingStarted` panel
2022-11-18 15:29:50 +00:00
Dimitris Sotirakis
01afe9fbd4 CI: Move upload-packages subcmd from grabpl (#58960)
* Move upload-packages subcmd from grabpl

# Conflicts:
#	.drone.yml

# Conflicts:
#	.drone.yml

* Fix lint - add ActivateServiceAccount

* Fix lint
2022-11-18 17:22:14 +02:00
Josh Hunt
5978dc138e Nav: Split Admin into three sections for new IA (#58229)
* start to split admin into two sections

* most of new admin nav implemented

* landing pages

* hide admin for non-admins

* update admin redirects if not topnav

* clean up

* updated IA for admin (still WIP)

* move plugin pages into correct admin sections

* fix backend unit test

* move correlations into the correct section

* add translations for admin sections

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-11-18 15:11:59 +00:00
Yuri Tseretyan
8c72d19bcc Alerting: Refactor MS teams, Pushover and Webhook notifiers to use encoding/json to parse settings (#56834)
* update teams
* update sensugo
* update pushover
* update webhook to use json.Number
2022-11-18 09:24:12 -05:00
Ashley Harrison
5226a61f67 Navigation: Stop clearing search state when opening a result in a new tab (#58880)
search: only clear search state if not opening in a new tab
2022-11-18 14:17:59 +00:00
Dimitris Sotirakis
0bf3c98eec CI: Add environment variables for edition to all pipelines (#58964)
Add environment variables to pipelines
2022-11-18 16:15:04 +02:00
Ivan Ortega Alba
766867735d E2E: Fix flakiness for dashboard-search spec (#58950) 2022-11-18 14:55:34 +01:00
Giordano Ricci
27b5e5f781 Explore: Fix a11y issue with logs navigation buttons (#58944) 2022-11-18 14:54:56 +01:00
Giordano Ricci
b68fe6336a Chore: move keydown handler in rich history card (#58945)
Chore: move kedown handler in rich history card
2022-11-18 14:54:20 +01:00
Giordano Ricci
44e8fb628e Explore: Fix a11y issue with show all series button in Graph (#58943)
* Explore: Fix a11y issue with show all series button in Graph

* remove extra space

* add spacing
2022-11-18 14:52:54 +01:00
Karl Persson
b3406a8273 Auth: Remove userauth service (#58941)
* Auth: remove userauth service

* Use Revoke user tokens from UserAuthTokenService
* Add function to delete user auth info to UserAuthInfo service
2022-11-18 14:40:26 +01:00
Dimitris Sotirakis
e37fc888c0 CI: Move upload-cdn subcommand from grabpl (#58957)
Move upload-cdn from grabpl
2022-11-18 08:37:18 -05:00
sfranzis
e823a90b82 GaugePanel: Setting the neutral-point of a gauge (#53989) 2022-11-18 12:13:31 +01:00
Ryan McKinley
8e19a1618f QueryData: skip header validation (revert check) (#58871) 2022-11-18 05:46:50 -05:00
Alex Pakalniskis
0e4108f62f Documentation Update: Minor spelling change (#58933)
chore: minor grammar tweak
2022-11-18 11:34:25 +01:00
Torkel Ödegaard
38b980bd81 SceneObject: Prevent state mutation by using Object.freeze (#58936) 2022-11-18 10:35:27 +01:00
George Robinson
b77c3946a5 Alerting: Fix ConditionsCmd No Data for "has no value" (#58634)
This commit fixes a bug where ConditionsCmd returns No Data even when
the condition checks for "has no value". It should return 1 with a nil
match.
2022-11-18 09:28:21 +00:00
Misi
9c98314e9f OAuth: Refactor OAuth parameters handling to support obtaining refresh tokens for Google OAuth (#58782)
* Add ApprovalForce to AuthCodeOptions

* Extract access token validity check to a function

* Refactor

* Oauth: set options internally instead of exposing new function

* Align tests

* Remove unused function

Co-authored-by: Karl Persson <kalle.persson@grafana.com>
2022-11-18 10:12:17 +01:00
Ashley Harrison
d46e3916a1 Navigation: move connections + integrations to be a top level item (#58902)
* move connections + integrations to be a top level item

* add a test to check we can move apps to the root

* split out movePlugin logic into a separate function

* fix linting

* rename movePlugin -> addPluginToSection
2022-11-18 09:05:45 +00:00
George Robinson
48c34d310c Alerting: Add tests that check current No Data behaviour with two conditions (#58650) 2022-11-18 09:04:43 +00:00
Karl Persson
fef1e1d5bc Auth: Refactor auth package (#58920)
* Auth: move interface to its own file

* Auth: move to test package

* Auth: move quota consts to auth file

* Auth: move service to impl package

* Auth: move interfaces and related models to auth package

* Auth: Create sub package and type alias to avoid circular dependency
2022-11-18 09:56:06 +01:00
Gilles De Mey
ea27eca147 Email: Use MJML email templates (#57751)
Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>
2022-11-17 21:41:46 +01:00
Sofia Papagiannaki
18738cfd77 Quota: Fix failure in store due to missing scope parameters (#58874)
Quota: Fix failure in store
2022-11-17 18:08:25 +01:00
Kristina
5cad7089b3 Explore: Enable resize of split pane (#58683)
* Move layout to paneleditor, make SplitPaneWrapper more generic

* Read/write the size ratio in local storage

* Add min height to enable scrollbar

* Enable show/hide panel options

* Add new component to explore

* Add styles

* Bring in code from other branch

* Fix update size function, add min size to explore container

* Add window size, save width as a ratio

* Fix tests

* Allow for one child

* Remove children type definition

* Use library methods for min/max size instead of hooks
2022-11-17 09:27:07 -06:00
Torkel Ödegaard
0c4aa6d0d8 DashboardScene: First step to loading the current dashboard model and rendering it as a scene (#57012)
* Initial dashboard loading start

* loading dashboard works and shows something

* loading dashboard works and shows something

* Minor tweaks

* Add starred dashboards to scene list page

* Use new SceneGridLayout

* Allow switching directly from dashboard to a scene

* Migrate basic dashboard rows to scene based dashboard

* Review nit

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
2022-11-17 07:15:51 -08:00
Levente Balogh
c093a471e6 AppRootPage: Fix passing the queryParams (#58912)
* fix(AppRootPage): push the query params properly

* refactor: remove unnecessary changes in AppRootPage

* refactor(AppRootPage): use existing utility function
2022-11-17 10:09:06 -05:00
Torkel Ödegaard
c14cbfc65d Breadcrumbs: Remove semi-bold and change current/last breadcrumb text color (#58875) 2022-11-17 15:51:09 +01:00
Ashley Harrison
ac66e14054 Navigation: rename Grafana Machine Learning to just Machine Learning (#58893)
rename Grafana Machine Learning to just Machine Learning
2022-11-17 14:31:03 +00:00
Karl Persson
6e3cb2e3ed Oauth: Remove unused function for oauth implementations (#58887)
* Oauth: remove unused function

* Oauth: remove unused Oauth types
2022-11-17 15:03:15 +01:00
Jo
7e9d94cfda Chore: Extract server lock error so it can be used with errors.As (#58899)
chore: extract server lock Error so it can be used with error.As
2022-11-17 15:02:17 +01:00
Dimitris Sotirakis
5ea077c440 CI: Replace TAG with DRONE_TAG in CI (#58894)
* Replace TAG with DRONE_TAG

* Fix variable call

* Replace remaining bits

* Bump grabpl version
2022-11-17 08:30:09 -05:00
Dimitris Sotirakis
d0dcbe34b2 grafana.com: Make beta and test releases not stable (#58883)
If version is beta or test, don't mark it as stable
2022-11-17 12:44:53 +02:00
Eric Leijonmarck
2a6ed76e54 [Docs] Edit terraform example and doc for file generation (#58822)
* docs: update terraform example and doc for file generation

* docs: updated the documnettaion to include the help command with fields included

* Update pkg/cmd/grafana-cli/commands/commands.go

* docs: add help command
2022-11-17 05:24:07 -05:00
Ashley Harrison
b398e8640d Navigation: Change quick add styling (#58854)
Change quick add styling + allow for returning isOpen state to dropdown children
2022-11-17 09:03:12 +00:00
Leo
27b6b3b3bd Folder: Replace folderId with folderUid (#58393)
* support folderuid in FolderPicker

* support folderuid in unified alerting

* support folderuid when returning to view mode after editing a panel

* support folderuid when preselecting the folderpicker in dashboard general settings

* support folderuid when saving dashboard

* support folderuid when pre-selecting folderpicker in dashboard form

* support folderuid in routes when loading a dashboard

* support folderuid when saving dashboard json

* support folderuid when validating new dashboard name

* support folderuid when moving dashboard to another folder

* support folderuid on dashboard action buttons

* support folderuid when creating a new dashboard on an empty folder

* support folderuid when showing library panel modal

* support folderuid when saving library panel

* support folderuid when importing dashboard

* fixed broken tests

* use folderuid when importing dashboards

* remove commented line

* fix typo when comparing uid values
2022-11-17 09:22:57 +01:00
Sofia Papagiannaki
ab36252c86 Quota: Fix failure when checking session limits (#58865) 2022-11-17 00:30:27 +01:00
sam boyer
c4528f9bd8 codejen: Update to latest codejen (#58866) 2022-11-16 15:08:01 -05:00
lean.dev
88f5ed0faf Chore: update latest.json to 9.2.5 (#58860) 2022-11-16 13:42:38 -05:00
Marcus Efraimsson
79f1a7a4fd Database: Adds support for enable/disable SQLite Write-Ahead Logging (WAL) via configuration (#58268)
Adds support for enable/disable SQLite Write-Ahead Logging (WAL) via configuration.
Enables SQLite WAL for E2E tests.
2022-11-16 19:29:33 +01:00
Grot (@grafanabot)
df27164b8e Changelog: Updated changelog for 9.2.5 (#58856) 2022-11-16 15:25:14 -03:00
matt abrams
d9b8b761e9 Query Editor: Hide overflow for long query names (#58840)
hides overflow for long query names
2022-11-16 18:22:06 +01:00
João Calisto
f254a37d35 Middleware: Add CSP Report Only support (#58074)
* Middleware: Add CSP Report Only support

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update csp documentation wording

* Update conf/sample.ini

Co-authored-by: Dave Henderson <dave.henderson@grafana.com>

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Dave Henderson <dave.henderson@grafana.com>

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Dave Henderson <dave.henderson@grafana.com>

* Update docs/sources/setup-grafana/configure-grafana/_index.md

Co-authored-by: Dave Henderson <dave.henderson@grafana.com>

* Update pkg/middleware/csp.go

Co-authored-by: Dave Henderson <dave.henderson@grafana.com>

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Dave Henderson <dave.henderson@grafana.com>
2022-11-16 17:11:26 +00:00
matt abrams
aea860a3bd DataLinks: Fix double dollar-sign bug in data-links editor (#58096)
* fix template variable bug

* fix bug when adding vars before existing vars

* take 2--remove includeDollarSign logic

* take 3-add includeDollarSign logic for template vars
2022-11-16 17:46:12 +01:00
Gabriel MABILLE
8756c4d91f RBAC: Add tests on AddAppLinks (#58843)
* RBAC: Add tests on AddAppLinks
2022-11-16 17:44:33 +01:00
Ivan Ortega Alba
f4d238cdbd Build: Disable flaky RuleEditor frontend test (#58844) 2022-11-16 16:41:32 +01:00
Kyle Brandt
1953d473c0 SSE: Keep value name from numeric table (#58831)
fixes #48868
2022-11-16 10:39:28 -05:00
Kyle Brandt
f2066398f0 CodeOwners: (Chore) Add Server Side Expressions (SSE) (#58841)
CodeOwners: Add Server Side Expressions (SSE)
owned by observability-metrics
2022-11-16 10:38:53 -05:00
Artur Wierzbicki
7bf3e28e8f Chore: skip flaky tests (#58835)
skip flaky tests
2022-11-16 10:23:49 -05:00
Ryan McKinley
934fb2f0ee QueryData: fix header parsing to support expressions (#58826)
fixes #58821
2022-11-16 10:17:24 -05:00
Laura Benz
9a5a344304 Explore: A11y of range slider in query history (#58708)
refactor: remove temporary setting
2022-11-16 09:05:30 -06:00
Karl Persson
9283773c12 Teams: Support paginating and filtering more then 1000 teams (#58761)
* TeamList: break out rows to its own component

* TeamsState: Add total count

* TeamList: Remove teamsCount prop

* TeamList: Restructure code and use count from backend response

* TeamList: calculate total pages using totalCount

* TeamList: Rename to state to currentPage and the reducer to
setCurrentPage

* TeamList: remove wrapper functions

* TeamList: rewrite as a functional component

* TeamList: export components for test

* TeamList: pass limit, page and query to backend

* TeamList: Rename properties in state and create actions for page and
query change

* TeamList: Add flag to control if EmptyList banner should render
2022-11-16 15:55:10 +01:00
Gabriel MABILLE
a8c48b6801 RBAC: Cover plugin includes (#57582)
* RBAC: Add action to plugin includes

* Adding the feature toggle check

* Cue update

* Extract include access control to method

* Suggestion to prevent log when RBAC is disabled

Co-authored-by: ievaVasiljeva <ieva.vasiljeva@grafana.com>

* Rename IsRBACReady to RequireRBACAction

Co-authored-by: ievaVasiljeva <ieva.vasiljeva@grafana.com>
2022-11-16 15:54:04 +01:00
Torkel Ödegaard
bce83485a9 Scenes: Share factory function for test data query runner (#58816) 2022-11-16 15:47:44 +01:00
Yuri Tseretyan
332630c2e0 kindsys: Make kind generators run in Windows (#58794) 2022-11-16 09:21:11 -05:00
Dimitris Sotirakis
5d73f7f8e8 CI: Cleanup e2e tests dependencies (#58829)
Cleanup end to end tests dependencies
2022-11-16 09:07:53 -05:00
Torkel Ödegaard
20133ec6fb Variables: Use new format registry from templateSrv (#58813)
* Variables: Use new format registry from templateSrv

* Updated comment

* Fixed e2e
2022-11-16 14:55:31 +01:00
matt abrams
74010fd05d Admin: Fix broken links to image assets in email templates (#58729)
fix broken links to image assets
2022-11-16 14:17:39 +01:00
Laura Fernández
f2cb248d93 Internationalization: Translate 'Hide / show legend' of PanelHeaderMenuItem (#58800) 2022-11-16 13:06:04 +01:00
Laura Fernández
515440979b Internationalization: Translate ShareSnapshot label (#58802) 2022-11-16 13:04:51 +01:00
Laura Fernández
3f63ca06c3 Internationalization: Translate NavBar - 'Search dashboard' menu item (#58815) 2022-11-16 13:02:29 +01:00
Levente Balogh
4ee83a5f2b AppRootPage: Render app plugins without pages (#58776)
fix: render app plugins that don't have a page in includes
2022-11-16 11:49:34 +01:00
Torkel Ödegaard
8c585a4ebf Scene: Variables interpolation formats and multi value handling (#58591)
* Component that can cache and extract variable dependencies

* Component that can cache and extract variable dependencies

* Updates

* Refactoring

* Lots of refactoring and iterations of supporting both re-rendering and query re-execution

* Updated SceneCanvasText

* Updated name of file

* Updated

* Refactoring a bit

* Added back getName

* Added comment

* minor fix

* Minor fix

* Merge fixes

* Scene variable interpolation progress

* Merge fixes

* Added all format registeries

* Progress on multi value support

* Progress on multi value support

* Updates

* Progress on scoped vars

* Fixed circular dependency

* Updates

* Some review fixes

* Updated comment

* Added forceRender function

* Add back fail on console log

* Update public/app/features/scenes/variables/interpolation/sceneInterpolator.test.ts

* Moving functions from SceneObjectBase

* fixing tests

* Fixed e2e

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
2022-11-16 11:36:30 +01:00
Giordano Ricci
2a9381e998 Explore: Refactor ExploreGraph (#58660)
* WIP

* revert collapse changes

* use HorizontalGroup instead of custom styles

* fix tests

* use import aliases
2022-11-16 11:16:27 +01:00
Timur Olzhabayev
174a039ee1 Fix: Bump-version action regex pattern to work with beta1 (#58805)
Fixing bump version regex
2022-11-16 09:26:38 +00:00
Marcus Andersson
5bd15026ff Docs: How to add plugin interaction tracking (#58652)
* docs for plugin interaction tracking.

* Update docs/sources/developers/plugins/add-anonymous-usage-reporting.md

Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>

* Adding query type

* Fixed spelling issue

Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
2022-11-16 10:06:42 +01:00
Dimitris Sotirakis
3d016d67a2 latest.json: Update latest.json to 9.3.0-beta1 (#58788)
Update latest.json
2022-11-15 18:32:34 -03:00
Grot (@grafanabot)
d5318f02c6 Changelog: Updated changelog for 9.3.0-beta1 (#58785) 2022-11-15 17:01:22 -03:00
Laura Fernández
3cedcdedbd Internationalization: Translate VariableInput and VariableOptions components (#58748) 2022-11-15 17:30:33 +01:00
Kristina
2055d922f3 Refactor SplitPaneWrapper to be more centralized component, refactor PanelEditor to use it (#58380)
* Move layout to paneleditor, make SplitPaneWrapper more generic

* Read/write the size ratio in local storage

* Add min height to enable scrollbar

* Enable show/hide panel options

* Change back variable name
2022-11-15 09:10:05 -06:00
sam boyer
78f0340031 plugindef: Move pluginmeta out of coremodels as standalone thema lineage (#56765)
* Get pluginmeta mostly moved over to pkg/plugins/plugindef

* Remove dead func

* Fix up pfs, use sync.Once in plugindef

* Update to latest thema

* Chase Endec->Codec conversion in Thema

* Comments on slash header gen; use ToSlash

* Also generate JSON schema for plugindef

* Generate JSON Schema as well

* Fix slot loading from kindsys cue decls

* Remove unused vars

* skip generating plugin.schema.json for now

Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
2022-11-15 14:48:31 +01:00
Ashley Harrison
ff1afbb699 Revert "Chore: move to node 18 (#58570)" (#58754)
This reverts commit 0a9129cf90.
2022-11-15 13:47:14 +00:00
lean.dev
83bd57244d Chore: Update version (#58750) 2022-11-15 10:03:05 -03:00
Joao Silva
20e6ac397e Search: Fixes issue with Recent/Starred section always displaying "General" folder (#58746) 2022-11-15 13:16:03 +01:00
Ashley Harrison
028751a18a Navigation: Add quick actions button (#58707)
* initial implementation for quick add

* add new isCreateAction prop on NavModel

* adjust separator margin

* switch to primary button

* undo changes to plugin.json

* remove unused props from interface

* use a consistent dropdown overlay type

* memoize findCreateActions

* add prop description

* use a function so that menus are only rendered when the dropdown is open
2022-11-15 12:08:15 +00:00
Torkel Ödegaard
84a69135a7 Scene: Variables and support for declaring variable dependencies and getting notified or re-rendered when they change (#58299)
* Component that can cache and extract variable dependencies

* Component that can cache and extract variable dependencies

* Updates

* Refactoring

* Lots of refactoring and iterations of supporting both re-rendering and query re-execution

* Updated SceneCanvasText

* Updated name of file

* Updated

* Refactoring a bit

* Added back getName

* Added comment

* minor fix

* Minor fix

* Merge fixes

* Merge fixes

* Some review fixes

* Updated comment

* Added forceRender function

* Add back fail on console log
2022-11-15 12:54:24 +01:00
Sofia Papagiannaki
93b4b9154e Chore: Restore folder properties (#58743)
* Chore: Fix folder URL

* Restore more folder properties

* Fixup
2022-11-15 12:58:12 +02:00
Karl Persson
98dbc637cc Auth: Always include oauth and saml settings for frontend (#58705)
* Auth: Always include oauth and saml settings
2022-11-15 10:50:37 +01:00
Gabriel MABILLE
d999b5bda0 RBAC: remove redundant role name field from plugin role registrations (#58166)
* RBAC: Remove name from role registration

* Inline accesscontrol service

* test fix

* use fmt

Co-Authored-By: marefr <marcus.efraimsson@gmail.com>

Co-authored-by: marefr <marcus.efraimsson@gmail.com>
2022-11-15 09:51:40 +01:00
Dominik Prokop
80e80221b9 Scenes: Grid layout (#56737)
* WIP: First approach to scene grid layout

* Flex layout

* Grid layout rows

* Allow passing custom props to scene object renderers

* Allow nesting grid layouts

* Re-layout nested grid's enclosing grids

* Update public/app/features/scenes/components/layout/SceneGridLayout.tsx

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

* Review comments

* Got rid of flex & grid child layout objects

* WIP: Recreating rows behaviour (almost working)

* Major progress on rows

* remove nested grid example (not supported)

* Remove removal damn

* Trying to use children directly

* Ts fixes

* chore: Fix TS

* Fix issue when row bboxes when not updated on layout change

* Now the tricky part

* working

* Removing some code

* needs more work

* Getting some thing working

* Getting some thing working

* fix toggle row

* Starting to work

* Fix

* Yay it's working

* Updates

* Updates

* Added some sorting of children

* Updated comment

* Simplify sorting

* removed commented code

* Updated

* Pushed a fix so we can move a panel out from a row and into the parent grid

* simplify move logic

* Minor simplification

* Removed some unnesary code

* fixed comment

* Removed unnessary condition in findGridSceneParent

* remove unnessary if

* Simplify toGridCell

* removed duplicate if

* removed unused code

* Adds grid demo with different data scenarios

* Make it green

* Demo grid with multiple time ranges

* Move child atomically

* Add tests

* Cleanup

* Fix unused import

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
Co-authored-by: Ivan Ortega <ivanortegaalba@gmail.com>
2022-11-15 00:49:39 -08:00
matt abrams
16aa4376ac Transformations: Make Card Descriptions Clickable (#58717)
replace Card Meta w Card Description
2022-11-15 09:37:37 +01:00
Artur Wierzbicki
eff5450ff1 Search: Revert "load dashboard performance improvements" (#58730)
Revert "Search: load dashboard performance improvements (#57509)"

This reverts commit 1df8a85a42.
2022-11-15 02:25:13 -05:00
Ryan McKinley
d33939da55 DataSourceWithBackend: Add plugin id to the request headers (#58082) 2022-11-14 19:35:50 -05:00
Jack Baldry
b9d8bcb59b Use relref resolved from nearest section (#58718)
As image-rendering is a branch bundle, it is considered a section by
Hugo and relrefs should be resolved from there even for child pages.

The behavior that worked in `next` but not `latest` could be explained
by the lenient but potentially ambiguous relref resolution algorithm
Hugo uses. However, I have not determined the exact difference between
the two sets of content that causes `next` to work but `latest` not to.

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>

Signed-off-by: Jack Baldry <jack.baldry@grafana.com>
2022-11-14 17:00:28 -04:00
kay delaney
59d2cf2ff7 Snapshots: Allow user with viewer permissions to delete own snapshots (#58572)
Also allows deletion of snapshots whose original dashboard is
in a folder which the viewer has explicit edit permissions for
2022-11-14 19:13:33 +00:00
Sofia Papagiannaki
9855e74b92 Chore: Refactor quota service (#58643)
Chore: Refactor quota service (#57586)

* Chore: refactore quota service

* Apply suggestions from code review
2022-11-14 21:08:10 +02:00
Laura Fernández
dd0d034796 Internationalization: Translate RefreshPicker component (#58530) 2022-11-14 17:47:15 +01:00
Laura Fernández
67bd0d5537 Internationalization: Translate TimeRangePicker component (#58470) 2022-11-14 17:16:34 +01:00
Yuri Tseretyan
28d39d35fd Alerting: Update state manager to save state transitions in one batch (#58358)
* change stale results handler to not update database but return transitions
* save all transitions in one call
2022-11-14 10:57:51 -05:00
Misi
4915d21c25 OAuth: Feature toggle for access token expiration check and docs (#58179)
* Add feature toggle for access token expiration check

* Add docs for configuring refresh tokens

* Update docs

* Update docs based on review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Improve documentation

* Change access_type default to Offline

* Update docs/sources/setup-grafana/configure-security/configure-authentication/gitlab/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-security/configure-authentication/google/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Update pkg/services/featuremgmt/registry.go

Co-authored-by: Eric Leijonmarck <eric.leijonmarck@gmail.com>

* Regenerate toggles

* Update Generic OAuth docs

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Eric Leijonmarck <eric.leijonmarck@gmail.com>
2022-11-14 16:47:46 +01:00
Christopher Moyer
a9458c8c00 Docs: corrects relrefs (#58706)
corrects relrefs
2022-11-14 09:24:39 -06:00
Jo
121631daae Fix: Email and username trimming and invitation validation (#58442)
* fix: email and username trimming and invitation validation

* Trim leading and trailing whitespaces from email and username on signup

* Check whether the provided email address is the same as where the invitation sent

* Align tests

Co-authored-by: Mihaly Gyongyosi <mgyongyosi@users.noreply.github.com>
2022-11-14 13:11:26 +01:00
David Beitey
1fddd9aed1 Docs: Update install guides link in README (#56116)
This updates the link to the installation guides in the README to the docs for the latest Grafana version, whereas the previous redirect was going to v9.0. This also improves the security of the link, which was previously insecure http://.
2022-11-14 11:42:23 +01:00
Dimitris Sotirakis
09c3ead945 CI: Make build and store storybook trigger in the release process (#58686)
Make storybook trigger conditional
2022-11-14 10:14:50 +00:00
Garrett Guillotte
b0c197b966 Docs: Comment out broken images (#57482)
* Docs: Comment out broken images

* Docs: Hide the correct images

Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
Co-authored-by: Daniel Lee <dan.limerick@gmail.com>
2022-11-14 10:49:04 +01:00
Labesse Kévin
c3fef96ee0 docs: code format (#58216) 2022-11-14 10:35:44 +01:00
Leo
a71f74220a Navigation: Remove monitoring texts for items under Monitoring section (#58522)
* rename Synthetic monitoring with Synthetics

* improved text override
2022-11-14 10:01:23 +01:00
Karl Persson
f4531b4ee1 Omit error from http response (#58443) 2022-11-14 09:42:31 +01:00
Jack Westbrook
ce50400740 Toolkit: Fix compilation loop when watching plugins for changes (#58167)
* fix(toolkit): ignore node_modules and dist directories when watching for changes to plugin

* fix(toolkit): move watchOptions.ignored config to pluginDev watch call
2022-11-14 09:30:52 +01:00
Niklas Kaaf
75c9350a5a docs: fix heading level for env variable on configuration page (#58689)
fix syntax error in Heading
2022-11-13 13:43:23 +01:00
Ryan McKinley
5934407443 Storage: add an admin write flavor that can explicitly set the user/time (#58618) 2022-11-12 11:36:18 -08:00
ying-jeanne
69b5a9c752 Chore: [Nested Folder] Add db migration at service start time (#58590)
* add db migration at service start time

* make changes for the 3 db

* revert migrator

* fix feature toggle check

Co-authored-by: Serge Zaitsev <serge.zaitsev@grafana.com>
2022-11-12 09:51:46 -05:00
Oscar Kilhed
75e435fb00 SQL: Fix issue where testing the datasource would always be successful if the datasourceQueryMultiStatus feature was enabled (#58671)
SQL Datasources: fix issue where testing the datasource connection would show success even when there was an error.

Co-authored-by: Victor Marin <victor.marin@grafana.com>
2022-11-11 22:41:38 +01:00
Victor Marin
6e776d0fec MSSQL: Add connection timeout setting in configuration page (#58631)
* MSSQL add connection timeout

* add docs

* Update docs and add min value to the timeout setting
2022-11-11 14:04:08 -05:00
Alex Moreno
78bb8c10ce Alerting: Allow none provenance alert rule creation from provisioning API (#58410) 2022-11-11 19:58:45 +01:00
Victor Marin
79142340e0 StateTimelinePanel: Fix duration on merged values (#58561)
Fix stateTimeline duration
2022-11-11 20:19:40 +02:00
gotjosh
d748979048 Alerting: Implement the Webex notifier (#58480)
* Alerting: Implement the Webex notifier

Closes https://github.com/grafana/grafana/issues/11750

Signed-off-by: gotjosh <josue.abreu@gmail.com>
2022-11-11 17:27:13 +00:00
ismail simsek
1c5039085b Prometheus: Make Prometheus streaming parser as default client (#58365)
* Introduce a new feature flag for prometheus buffered client

* Use querydata client as default and put buffered client behind the feature flag

* Remove prometheusStreamingJSONParser feature flag as it is not needed anymore

* Update tests

* Fix unit tests

* Update feature flag description
2022-11-11 17:53:12 +01:00
Ashley Harrison
500cf16142 Chore: fix some types (#58662)
chore: fix some types
2022-11-11 16:29:49 +00:00
Leon Sorokin
860e25df3c BarChart: add gdev panel for random threshold from query (#58580) 2022-11-11 08:58:08 -07:00
ismail simsek
8edeb1aa22 Prometheus: Handle errors in buffered client (#58504)
* Handle prometheus errors in buffered client

* Handle prometheus warnings

* Fix tests

* Add unit test for warnings
2022-11-11 15:49:46 +01:00
Ashley Harrison
0bd120e01b Navigation: fix page title spacing when there is no subtitle (#58654)
* fix page title spacing when there is no subtitle

* apply margin to whole page header
2022-11-11 09:43:11 -05:00
Virginia Cepeda
e5cb1ceae0 Alerting: Suggest previously entered custom labels (#57783)
* [Alerting] - replace label inputs with dropdowns (#57019)

* Add AlertLabelDropdown component

It will be used to pick from or create new labels

* Adapt LabelsField component to use AlertLabelDropdown instead of inputs

* Add tests for LabelsField component

Plus a few other tests were adapted to work with the label dropdowns

* Use ref in component

* Fix showing placeholders in the label dropdowns

* Minor syntax change

* Remove unneeded import after rebase

* Display custom labels

When a label key is selected, its corresponding values are shown in the dropdown

* Add tooltip explaining where labels in the dropdowns come from

* Fix import of Stack component

* Avoid duplicated values

* Improvements based on review

* Display labels for currently selected datasource only

* Refactor AlertsField to allow to choose whether to suggest labels or not

* Suggest labels for NotificationStep and tests

* Don't suggest labels in TestContactPointModal

* [LabelsField] - refactor: get dataSourceName as a parameter

* [LabelsField] - extract common code into reusable components

* Display loading spinner while fetching rules

* LabelsField - refactor

Removing the suggest prop and the default dataSource 'grafana'. Instead, the component now relies on the dataSourceName param. If it's set it means we want to show suggestions so we fetch the labels, otherwise, if not set, we show the plain input texts without suggestions.

* Add test for LabelsField without suggestions

* Show custom labels for grafana managed alerts

When the dataSourceName in the NotificationsStep component has a null value, we can assume it's because we're dealing with grafana managed alerts. In that case we set the correct value.

* Fix tests after latest changes

Since we removed the combobox from the TestContactPoints modal, tests had to be adjusted

* Update texts

* initialize all new added inputs with empty data
2022-11-11 10:29:59 -03:00
idafurjes
080ea88af7 Nested Folders: Support getting of nested folder in folder service wh… (#58597)
* Nested Folders: Support getting of nested folder in folder service when feature flag is set

* Fix lint

* Fix some tests

* Fix ngalert test

* ngalert fix

* Fix API tests

* Fix some tests and lint

* Fix lint 2

* Fix library elements and panels

* Add access control to get folder

* Cleanup and minor test change
2022-11-11 14:28:24 +01:00
Sonia Aguilar
88a829e103 Fix: don't show an error when receiver status is not available (#58638) 2022-11-11 14:26:43 +01:00
Ashley Harrison
6625f6f0c8 Chore: Update .nvmrc (#58641)
Update .nvmrc
2022-11-11 07:21:38 -05:00
Ashley Harrison
0a9129cf90 Chore: move to node 18 (#58570)
* bump node version to 18

* update folder to 18.x

* update README for m1 instructions

* update drone

* update unit test

* update README
2022-11-11 11:34:00 +00:00
Daniel Lee
891ae91c70 docs: fix typo in provisioning docs (#58110)
Fix typo

Co-authored-by: Udlei Nati <udlei@nati.biz>
2022-11-11 12:30:26 +01:00
Hamas Shafiq
8e4fa4046b Chore: Refactor process.js & process.test.js to TypeScript (#58464) 2022-11-11 10:44:06 +00:00
Joey Tawadrous
c76183a961 Tempo: Fix search removing service name from query (#58630)
* Fix handleOnChange deps

* Remove eslint disable
2022-11-11 10:40:13 +00:00
Timur Olzhabayev
02137396bd Fix: Bumping msw and xmldom (#58627)
Bumping msw and xmldom to mitigate xmldom vulnerability
2022-11-11 11:18:38 +01:00
George Robinson
bd87b46b15 Alerting: Improve test coverage for ConditionsCmd (#58603) 2022-11-11 09:27:35 +00:00
Todd Treece
c090de9ed9 Chore: Move dev-dashboards jsonnet into separate directory (#58619) 2022-11-11 04:19:29 -05:00
Alexa V
5fac98bcfd Docs: Add feature flag example to override configuration with environment variables (#58613) 2022-11-10 15:39:27 -06:00
Nathan Marrs
fd6edbf8c5 Canvas: Improve disabled inline editing UX (#58610) 2022-11-10 13:04:42 -08:00
sam boyer
07e5f8117f Reconcile coremodels, entities, objects under new kind framework (#56492)
* Update thema to latest

* Deal with s/Library/*Runtime/

* Commit new, working results of codegen

* We like pointers now

* Always take runtime arg for NewBase()

* Sketchy handwavy pass at entity meta framework

* Little nibbles

* Update pkg/framework/coremodel/entityframework.cue

Co-authored-by: Artur Wierzbicki <wierzbicki.artur.94@gmail.com>

* Move file into new framework location

* Introduce loaders, Go code

* Complete rename to kind

* Flesh out framework, add svg/dashboard examples

* Cruft removal

* Remove generated kind go files from gitignore

* Refine maturity concept, add SlotKind

* Update embed and go deps

* Export PrefixWithGrafanaCUE

* Make the loader actually work, holy crap

* Many small tweaks to type.cue

* Add Apache 2 licensing exceptions for kinds

* Add new kinds dir, start of generator

* Roll back to earlier oapi-codegen

* Introduce new grafana-specific CUE loaders

* Introduce new tidy code generators framework

* Catch up kind framework with tinkering

* Add slices for the generators

* Add write/verify step to main generator

* Many renames

* Split up kind framework cue files

* Use kind.Decl within generated kinds

* Create kind.SomeDecl wrapper type to cache lineages

* Better names again

* Get one generated implemented, hopefully

* Copy dashboard schema into new kind.cue

* Small fixes to make the initial gen work

* Put svg kind in its new home

* Add generated Go dashboard type

* More renames and cleanups

* Add base kind registry and generator

* Stop blacklisting *_gen.go files

This is not the Go best practice, anyway. All we actually want to ignore
for enterprise is generated wire files.

* Change codegen output directories

pkg/kind -> pkg/kinds
pkg/registry/kindreg -> pkg/registry/corekind

* Rename pkg/framework/kind to pkg/kindsys

* Add core structured kind generator

* Add plural and machine names to kind spec

* Copy playlist over to kind system

* Consolidate kindsys files

* Add raw kind generator

* Update CODEOWNERS for kind framework

* Touch up comments a bit

* More docs tweaks

* Remove generated types to reduce noise for review

* Split each generator into its own file

* Rename Slot kind to Composable kind

* Add handwavy types for customkind loading

* Guard against init calls to framework loader

* First pass at doc on extending the kind system

* Improve attribute example in docs

* Fix wire imports

* Add basic TS types generator

* Fix composable kind category def

* No need for a separate file with generate directive

* Catch dashboard schema up

* Rename generator types to something saner and generic

* Make version configurable in ts/go generators

* Add CommonMeta to ease property access

* Add kindsys prop indicating whether lineage is group

* Put all kind categories back in a single file

* Finish with kindsys group props

* Refactor maturity progression per discussion

- Replace "committed" with "merged"
- All kindcats can use all maturity levels, at least for now

* Convert ts veneer index generator to modular system

* Move over to new jennywrites framework

* Strip down old coremodel generator

* Use public version of jennywrites

* Pull latest thema

* Commit generated Go types

* Add header injection postprocessor

* Move sdboyer/jennywrites to grafana/codejen

* Tweak header output

* Remove dashboard and playlist coremodels

* Fix up backend dashboards devenv test

* Fix TS import patterns to new gen filename

* Update internal imports, remove coremodel registry

* Fix compilation errors, wire generation

* Export and replace the prefix dropper

* More Go struct and field name changes

* Last name fixes, hopefully

* Fix lint errors

* Last lint error

Co-authored-by: Artur Wierzbicki <wierzbicki.artur.94@gmail.com>
2022-11-10 12:36:40 -08:00
Ryan McKinley
f92d978386 Export: support export in postgresql (#58553) 2022-11-10 14:16:31 -05:00
Nathan Marrs
47055561ec Canvas: Fix setting icon from field data #58499 2022-11-10 10:56:31 -08:00
Timur Olzhabayev
41c491e2db Cleaning up plugin developer docs (#58596) 2022-11-10 18:36:59 +01:00
Timur Olzhabayev
5bc7f693b5 Docs: Replacing toolkit with sign-plugin (#58593) 2022-11-10 18:31:42 +01:00
Ashley Harrison
9cbbe65243 Move cloud link app to the Administration section (#58578) 2022-11-10 17:02:41 +00:00
Ivana Huckova
261d620f1c Elasticsearch: Add feature toggle for backend migration (#58585)
* Elasticsearch: Add feature toggle for backend migration

* Update
2022-11-10 16:35:15 +01:00
Alex Moreno
45facbba11 Alerting: Remove url based external alertmanagers config (#57918)
* Remove URL-based alertmanagers from endpoint config

* WIP

* Add migration and alertmanagers from admin_configuration

* Empty comment removed

* set BasicAuth true when user is present in url

* Remove Alertmanagers from GET /admin_config payload

* Remove URL-based alertmanager configuration from UI

* Fix new uid generation in external alertmanagers migration

* Fix tests for URL-based external alertmanagers

* Fix API tests

* Add more tests, move migration code to separate file, and remove possible am duplicate urls

* Fix edge cases in migration

* Fix imports

* Remove useless fields and fix created_at/updated_at retrieval

Co-authored-by: George Robinson <george.robinson@grafana.com>
Co-authored-by: Konrad Lalik <konrad.lalik@grafana.com>
2022-11-10 16:34:13 +01:00
Gilles De Mey
738e023d13 Alerting: Fix threshold expression rewire (#58334) 2022-11-10 16:15:38 +01:00
Emil Tullstedt
990d8cd22e Chore: Upgrade go-sqlite3 to v1.14.16 (#58581) 2022-11-10 15:49:28 +01:00
Piotr Jamróz
039f4cb4dd Explore: Support fields interpolation in logs panel (#58426) 2022-11-10 15:33:17 +01:00
ying-jeanne
b13b58ebf8 Add move endpoint into folder service (#58575)
* add move endpoint

* change signatures
2022-11-10 09:06:52 -05:00
Leon Sorokin
778337e522 BarChart: Fix coloring from thresholds and value mappings (#58285) 2022-11-10 07:43:32 -06:00
idafurjes
30f0d66983 Folder: Add implementation for Update for nested folder (#58479)
* Add implementation for Update nested folder

* Remove parent uid from Update

* Fix update
2022-11-10 14:28:55 +01:00
brendamuir
bd6ac793a0 Docs: adds explore content for alerting (#58573) 2022-11-10 12:35:24 +00:00
Timur Olzhabayev
f451332e36 Chore: Switching to new output format for detect breaking changes action (#58516)
* Switching to new output format for detect breaking changes action

* linting: wrap $GITHUB_OUTPUT with double quotes

* linting: fix shellcheck issues in the right place 🤦‍♂️

Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>
2022-11-10 06:02:04 -05:00
Levente Balogh
181640b080 Connections: Support standalone plugin pages (#57772)
* feat(Connections): create sub-pages wrapped by `<Page>`

* feat(Connections): rename the Connections page and update routes

* feat(Connections): use new url for editing datasources

* refactor(Connections): remove unused tab components

* feat(Connections): update routes and nav titles

* tests: fix tests for Connections

* tests: fix typo in backend tests
2022-11-10 11:14:23 +01:00
George Robinson
c5ae1bcfe0 Alerting: Fix logging pointer address of DashboardUID and PanelID variables (#58539) 2022-11-10 09:58:38 +00:00
George Robinson
68600c224b Alerting: Log when alert rule cannot be screenshot to help debugging (#58537) 2022-11-10 09:41:31 +00:00
Sofia Papagiannaki
bf5a08e039 API: Support creating a nested folder (#58508)
* API: Support nested folder creation

* Update swagger

* fixup

* Update pkg/api/dtos/folder.go

Co-authored-by: Serge Zaitsev <serge.zaitsev@grafana.com>

* Fix some tests

* create legacy folder url from title and uid

Co-authored-by: idafurjes <36131195+idafurjes@users.noreply.github.com>
Co-authored-by: Serge Zaitsev <serge.zaitsev@grafana.com>
Co-authored-by: Ida Furjesova <ida.furjesova@grafana.com>
2022-11-10 04:41:03 -05:00
Timur Olzhabayev
b5388bb080 Switching to new output format for bump-version action (#58514) 2022-11-10 10:24:19 +01:00
Timur Olzhabayev
c9138ebb68 Switching to new output format for publish docs action (#58518) 2022-11-10 10:14:23 +01:00
ying-jeanne
accb4dea55 [Nested Folder] Delete folder methode (#58444)
* transfer DeleteFolder changes from larger PR

* finish some thingies

* add the simplest delete logics

* some intermedia steps

* fix tests

* add test

* fix some comments

Co-authored-by: yangkb09 <yangkb09@gmail.com>
2022-11-10 03:42:32 -05:00
Andres Martinez Gotor
1201170724 GoogleCloudMonitoring: Refactor query type definition (#58512) 2022-11-10 09:30:47 +01:00
Kristin Laemmert
70dac35348 chore(tests): return a copy of the map to avoid concurrency issues in tests (#58547) 2022-11-09 22:12:18 +01:00
Alexander Weaver
2bfdda5b68 Alerting: Break dependency between state and image packages (#58381)
* Refactor state and manager to not depend directly on image interface

* Move generic errors to models package

* Move NotAvailableImageService to state as its only references are in state tests

* Move NoopImageService to state package

* Move mock to state package

* Fix linter error

* Fix comment styling

* Fix a couple added references introduced by rebase

* Empty commit to kick build
2022-11-09 15:06:49 -06:00
Yuri Tseretyan
bad4f28d0d Alerting: update test TestAlertingTicker to not rely on clock (#58544)
* extract method processTick
* make processTick return scheduled rules
* move state manager tests to state manager
* update test
* move all tests into one file
* remove unused fields
2022-11-09 15:08:57 -05:00
Galen Kistler
ee7348afee Prometheus: Query builder label filters dropdown UI overload fix (#58266)
* WIP: try to support removing series endpoint for supported clients

* add other filter variables to match param for label values query against filter values, in order to resolve bug in which filter value options would display that aren't relevant in the current query editor context, i.e. options would display that upon select would display no data

* clean up console logs

* refactor and comment

* expanding current unit test coverage to cover calls to new API

* fix unit test

* whitespace

* prettier

* WIP: need to merge in other PR

* WIP giving up and trying again

* WIP: most functionality is working, split out shared loki/prom code

* fix bug in which search results wouldn't take other label context into the query

* Fix bug in which the previously selected value would conflict with the async search

* interpolate the label name string instead of the match promql expression

* remove type assertions

* remove type assertion

* clean up generic confusing types, and add back in a type assertion

* remove generic type

* make sure to interpolate label names

* fix bugs with variables not interpolating before query

* remove debug

* assert partial properties on QueryBuilderLabelFilter

* Force update betterer results :(

* update regex so dropdown UX more closely matches current behavior

* add eslint ignore

* add eslint ignore and update betterer
2022-11-09 14:54:51 -05:00
Sofia Papagiannaki
000b4f878d Chore: Retry queries by default in tests (#58535) 2022-11-09 19:56:47 +02:00
Christopher Moyer
ad374efcbd adjusts the stem sentence (#58538) 2022-11-09 11:24:29 -06:00
George Robinson
7e852720e3 Alerting: Fix images cached on rule instead of dashboard panel signature (#58510) 2022-11-09 17:01:48 +00:00
George Robinson
b92a0223e3 Alerting: Improve debug logs in image service (#58507) 2022-11-09 16:32:58 +00:00
Sasha Melentyev
febcaeff3a Chore: Use strings.ReplaceAll and preallocate containers (#58483) 2022-11-09 17:17:09 +01:00
Christopher Moyer
2dfe0a4060 Docs: adjusts topics to align with task templates (#58478)
* updates topic to align with multiple task template

* updates goal intro

* aligns formatting with single task topic template

* Update docs/sources/administration/team-management/index.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* adds permissions requirements to two tasks

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>
2022-11-09 10:09:46 -06:00
George Robinson
acfa066ba2 Alerting: Change TestConditionsCmd to assert on mathexp.Results (#58434) 2022-11-09 16:07:43 +00:00
Giuseppe Guerra
33f02839f0 Plugins: CallResource: Use canonical MIME headers when writing response (#58506)
* Plugins: CallResource: use canonical MIME headers when writing response

* Plugins: add tests for canonical mime headers and Set-Cookie filter

* Removed extra new line
2022-11-09 15:47:32 +01:00
Ashley Harrison
159607fe6f Navigation: Convert PluginDetails page to use new Page extensions (#58509)
* Added labels

* App page fixes

* Switch to switch

* wip

* Updates

* I am stuck

* Minor tweak

* This props interface could work

* removed change

* use new page extensions in plugin details page

* add link separator, fix action button spacing

* some renaming

* Move PageInfo into it's own folder + add tests

* add support for new props in old page header

* remove PluginDetailsHeader as it's no longer used

* Fix unit tests

* fix some badge alignments

* center align actions

* badge alignment + only show downloads for community/commercial plugins

* better link alignment

* conditionally render description

* move install control warnings to below subtitle + refactor

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-11-09 14:44:38 +00:00
Esteban Beltran
cced175ccf Docs: Replace toolkit command to scaffold plugins with create-plugin (#58462)
* Replace command to scaffold plugin with create-plugin

* Change link text
2022-11-09 08:15:23 -06:00
Gareth Dawson
fa5a304de8 Elasticsearch: fix typo (#58519) 2022-11-09 14:10:47 +00:00
Timur Olzhabayev
008c554d7f Echo: Add config option to prevent duplicate page views for GA4 (#57619) 2022-11-09 15:09:19 +01:00
Matias Chomicki
463f993186 feat(loki-monaco-editor): update e2e test with autocomplete steps (#58455)
* feat(loki-monaco-editor): update e2e test with autocomplete steps

* Chore: replace typing method

* Test simpler POC test

* Chore: refactor test

* Chore: use selector to get the editor value
2022-11-09 13:37:00 +01:00
George Robinson
1290951b65 Alerting: Small improvements to staleResultsHandler (#58007) 2022-11-09 11:08:32 +00:00
Gareth Dawson
966b47c2ef Loki: Rename log browser to label browser (#58416)
* rename loki log browser to label browser

* rename loki log browser to label browser
2022-11-09 09:57:05 +00:00
Torkel Ödegaard
b5651803e0 Scene: ObjectVariable for supporting the built in system variables and object scoped variables (__data for example) (#58291)
* Scene: Adds ObjectVariable to support the built-in/system variables

* fixed lint issue
2022-11-09 10:27:20 +01:00
George Robinson
fdeefaee42 Alerting: Reorder tests in classic_test.go (#58425) 2022-11-09 09:13:47 +00:00
Ashley Harrison
b3c761aaa7 Navigation: Expose new props to extend Page/PluginPage (#58465)
* add extensions and customisation to `Page`

* adjust alignment
2022-11-09 09:05:01 +00:00
Andres Martinez Gotor
9778d642df GoogleCloudMonitoring: use typed struct in newInstanceSettings (#58440) 2022-11-09 09:38:06 +01:00
Torkel Ödegaard
6ed35292fe Variables: SceneVariable update process (#57784)
* First baby steps

* First baby steps

* No progress really

* Updates

* no progress

* refactoring

* Progress on sub menu and value selectors

* Some more tweaks

* Lots of progress

* Progress

* Updates

* Progress

* Tweaks

* Updates

* Updates to variable system

* Cleaner tests

* Update

* Some cleanup

* correct test name

* Renames and moves

* prop rename

* Fixed scene template interpolator

* More tests for SceneObjectBase and fixed issue in EventBus

* Updates

* More tweaks

* More refinements

* Fixed test

* Added test to EventBus

* Clone all scene object arrays

* Simplify

* tried to merge issue

* Update

* added more comments to interface

* temp progress

* Trying to simplify things, but struggling a bit

* Updated

* Tweaks

* Progress on fixing the select componenet and typing, and sharing code in a base class

* Updated

* Multi select

* Simpler loading state

* Update

* removed failOnConsole

* Removed old funcs

* Moved logic from update manage to MultiValueVariable

* Added tests for MultiValueVariable logic

* Made value a more abstract concept to support object values

* renamed func to getValueText

* Refactored and moved logic to VariableSet

* Added test for deactivation and query cancelling

* Tweaks

* Fixed lint issues
2022-11-09 08:02:24 +01:00
George Robinson
c646ff0ce3 Alerting: Fix screenshots were not cached (#58493) 2022-11-09 01:52:16 +00:00
Ryan McKinley
238a3f820c Store: use "at" suffix for time base fields more consistently (#58486) 2022-11-08 17:42:32 -05:00
George Robinson
ad9ac85ee0 Alerting: Use hash of opts in singleflight (#58474) 2022-11-08 22:37:49 +00:00
George Robinson
72275e97d2 Use fnv64 for InmemCacheService (#58468) 2022-11-08 22:05:15 +00:00
Sofia Papagiannaki
4d2be7a277 Nested Folders: Use recursive query if the driver supports it (#58178)
* Nested Folders: Try first recursive query and fallback if it's not supported

* Apply suggestion from code review

Fix error msgID
2022-11-08 14:53:05 -05:00
Andreas Christou
ed64133943 grafana/e2e: Update add dashboard flow (#58360)
* Update variable editor e2e flow

- Use correct selector for Variables
- Add variable query form
- Add label for variable apply button

* Use data-testid instead of aria-label

* Add jsdoc
2022-11-08 12:15:21 -05:00
Adam Simpson
3e92a2dc77 Tooltips: Make tooltips in FormField and FormLabel interactive and keyboard friendly (#57706)
* Tooltips: add tabindex and interactive

A couple tooltips used in configuration of datasources like ADX were not
clickable or didn't show on keyboard focus.

- fixes #56561
- Same solution as #47137

* test: add test around tabbing to tooltips
2022-11-08 16:55:53 +00:00
Hamas Shafiq
43a0afeac4 Tempo: Fix start time column sorting when using search (#56635) 2022-11-08 16:39:21 +00:00
Grot (@grafanabot)
512584558f Changelog: Updated changelog for 8.5.15 (#58467) 2022-11-08 16:32:41 +00:00
Laura Fernández
96d70c37bd Internationalization: Translate TimeZonePicker component (#58461) 2022-11-08 17:25:35 +01:00
Emil Tullstedt
75701695d8 pkg/web: avoid shared middleware slice (#58458) 2022-11-08 10:58:04 -05:00
Grot (@grafanabot)
2e6761b4e4 Changelog: Updated changelog for 8.5.15 (#58459) 2022-11-08 10:49:30 -05:00
Laura Fernández
d0f173665f Internationalization: Translate TimePickerContent component (#58316) 2022-11-08 16:30:03 +01:00
Dan Cech
d593aede3d properly format new .drone.yml in verify-drone (#58436) 2022-11-08 10:27:57 -05:00
Torkel Ödegaard
50a197014f Panels: Fixes crashing issue when migrating angular panels (#58232) 2022-11-08 16:26:02 +01:00
Matias Chomicki
25f79ef2b9 Loki: enable Monaco Query Editor by default (#58080)
* feat(loki-monaco-editor): update tests

* chore(loki): use unified datasource mock function in tests

* chore: enable monaco feature flag in tests

* feat(loki-monaco-editor): add test case for disabled feature

* feat(loki-monaco-editor): enable by default

* Revert "feat(loki-monaco-editor): enable by default"

This reverts commit 08904f94a707a4fa32aa1e7f3f0de377575a7636.

* feat(loki-monaco-editor): enable from registry

* feat(loki-monaco-editor): make feature flag frontend only
2022-11-08 10:22:40 -05:00
Gábor Farkas
29fcc46333 devenv:elastic: update version (#58439) 2022-11-08 15:00:23 +00:00
Laura Fernández
3790e105e5 Internationalization: Translate TimePickerFooter component (#58390) 2022-11-08 15:56:19 +01:00
Andres Martinez Gotor
42b2e630b7 GoogleCloudMonitoring: Refactor annotation code (#58417) 2022-11-08 15:41:17 +01:00
Galen Kistler
9281746914 Prometheus: remove /series endpoint calls in query builder label names and values for supported clients (#58087)
* add other filter variables to match param for label values query against filter values, in order to resolve bug in which filter value options would display that aren't relevant in the current query editor context, i.e. options would display that upon select would display no data

* expanding current unit test coverage to cover calls to new API

* interpolate the label name string instead of the match promql expression
2022-11-08 08:37:11 -06:00
Jack Westbrook
904c6f1ea9 Chore: update latest.json to 9.2.4 (#58433) 2022-11-08 09:26:32 -05:00
Ashley Harrison
831ecb467c Add new PageInfo component (#58421) 2022-11-08 14:20:05 +00:00
Joe Blubaugh
f07da85d8b Dashboards: Provide better error messages in SaveDashboardAsForm (#57866)
The existing code uses `instanceof Error` to check for a `message` field on the thrown object. The objects that are thrown are never instances of the error interface. This change introduces a new type that extends Error so that the check works properly and displays a meaningful error message in the UI.
2022-11-08 22:11:02 +08:00
Kristin Laemmert
a255c32e1a nested folders: support creation of nested folders in folder service when feature flag is set (#58364)
* nested folders: support creation of nested folders in folder service when feature flag is set
2022-11-08 08:59:55 -05:00
Grot (@grafanabot)
94573d3e61 Changelog: Updated changelog for 9.2.4 (#58429) 2022-11-08 14:58:19 +01:00
Laura Fernández
c1d677c174 Internationalization: Translate TimeRangeContent component (#58343) 2022-11-08 14:55:50 +01:00
George Robinson
aa69a8463f Revert "Alerting: Fix mathexp.NoData in ConditionsCmd (#56812)" (#58423)
This reverts commit 5fa0936b7e.
2022-11-08 13:35:58 +00:00
Levente Balogh
bfd14709c9 Levitate: Only run workflows when the NPM packages change (#58206)
* chore: only run Levitate when our NPM packages have changes

* chore: show the Levitate workflow as passed even if it was skipped
2022-11-08 14:26:31 +01:00
Julien Duchesne
f1f401147f Linux repositories: Document apt|rpm.grafana.com (#57527)
* Linux repositories: Document `apt|rpm.grafana.com`
We'll be moving off packages.grafana.com (it will be linked to the new repositories)
The new package repositories are easier to use, so let's document them instead

Question: Are the scripts in `scripts/build/update_repo` and `scripts/verify-repo-update` still used? They seem very old, and seem like the generation of scripts before grabpl was created

* Shorter RPM docs. No need to copy the same snippet twice

* Add warning about repository migration

* oops
2022-11-08 07:10:56 -05:00
Julien Duchesne
786c7faff2 Grafana Enterprise Packaging: Set to conflict with grafana, not replace (#58189)
* Grafana Enterprise Packaging: Set to conflict with `grafana`, not replace
When `grafana` and `grafana-enterprise` are in the same RPM repository, grafana-enterprise takes precedence over Grafana
This is not what we want. Users should be able to install either OSS or Enterprise

* Set it only one way. It's how it's currently tested
2022-11-08 13:08:01 +01:00
George Robinson
5fa0936b7e Alerting: Fix mathexp.NoData in ConditionsCmd (#56812)
This commit fixes an issue where mathexp.NoData would return an error
in ConditionsCmd (Classic Condition) instead of no data. It further
refactors the Execute method to make it easier to understand.
2022-11-08 11:41:57 +00:00
ying-jeanne
0e87d27e5b Support folderUID in import dashboard service (#58415)
* add folder service and get folderid

* remove storage?
2022-11-08 06:36:18 -05:00
Kristin Laemmert
ef7145e4aa feat(nested folders): Add CountAlertRulesInFolder to ngalert store (#58269)
* chore: refactor CountDashboardsInFolder to use the more efficient Count() sql function

* feat(nested folders): Add CountAlertRulesInFolder to ngalert store

This commit adds CountAlertRulesInFolder and a new model for the CountAlertRulesQuery. It returns a count of alert rules associated with a given orgID and parent folder UID. (the namespace referenced inside alert rules is the parent folder).

I'm not sure where this belongs in the ngalert service, so that will come in a future commit.
2022-11-08 11:51:00 +01:00
idafurjes
af2f51f196 Folder: Add folder service implementation (#58182)
* Folder: Add folder service implementation

* Add Move

* Add tests

* Add new servie method and adjust Update, Delete and Move

* Remove contains

* GetTree return children of depth one
2022-11-08 11:33:13 +01:00
Andreas Christou
5cfd983cc2 AzureMonitor - E2E tests drone update (#57100)
* Update e2e command with video flag

* Add Cloud Plugins E2E tests to drone

* Update env variable names

* Add vault Azure secrets

* Update e2e steps

* Update secrets path

* Update image and rebuild drone file

* Readd drone changes

* Rebuild drone

* Remake drone

* Correct reference to secret

* Remake drone file

* Remove unneeded step

* Clear values in Arg query
2022-11-08 11:27:54 +01:00
Giordano Ricci
e4c394dfcd Correlations: add tracking for add, update, delete, and details expanded (#58239)
* Correlations: add tracking for add, update, delete, and details expanded

* add tests

* change delete event

* rename handlers
2022-11-08 10:10:09 +00:00
Sofia Papagiannaki
96cdf77995 Revert "Chore: Refactor quota service (#57586)" (#58394)
This reverts commit 326ea86a57.
2022-11-08 11:52:07 +02:00
Timur Olzhabayev
228ec4c0f3 Chore: Switch Grafana to using faro libraries (#58186) 2022-11-08 10:36:27 +01:00
Shirley
82d09e0647 CloudWatch: Refactor test mock by removing GetMetricsData from FakeMetricsAPI (#58355) 2022-11-08 10:28:50 +01:00
Sofia Papagiannaki
326ea86a57 Chore: Refactor quota service (#57586)
* Chore: refactore quota service

* Apply suggestions from code review
2022-11-08 10:25:34 +02:00
Marcus Efraimsson
faa0fda6eb Prometheus: Upgrades http client to v1.13.1 (#58363) 2022-11-08 08:35:05 +01:00
Christopher Moyer
0315f6317e Docs: corrects outer join example (#58348)
* corrects outer join example

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

* adds query tables back in
2022-11-07 13:40:09 -06:00
ismail simsek
93c1fbbe3f Remove data comparison tool and feature flag (#58196) 2022-11-07 19:20:00 +01:00
Eric Leijonmarck
76947b10e2 Auth: conflicting users validation improvements (#58136)
* WIP

* add: better validation of conflict file

* add: better description of validation and ingest command

* add: check for at least one user to delete

* add: example in terraform to setup for conflicts

* Update pkg/cmd/grafana-cli/commands/conflict_user_command.go

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>

* Add: print of conflict block for error

- adds conflict block to error output for validation of the file to
  easier diagnose in the file

* fix: formatting of errors

* fix: info strings improvements

* add: default 0 to blocks to check for users

* fixed: tests

* test integration

* fix strings fmt

* set store in resolver

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
2022-11-07 18:12:17 +00:00
Gareth Dawson
2027f4702c Loki: Add case insensitive line contains operation (#58177)
* add line-contains-case-insensitive operation definition

* add loki operation id for line-contains-case-insensitive

* make query case-insensitive when using line filter

* remove console log from operationUtils.ts

* add line-does-not-contain-case-insensitive operation definition

* add loki operation id for line-does-not-contain-case-insensitive

* make query case insensitive when using line-does-not-contain-case-insensitive

* update title and min-width for line-contains-case-insensitive

* add caseInsensitive optional parameter

* toggle case insensitive on operations

* remove console log

* update operation names

* add test coverage

* update to implement suggestions

* add suggestion
2022-11-07 17:01:06 +00:00
Andres Martinez Gotor
0a8fdc4550 GoogleCloudMonitoring: Remove unused code (#58347) 2022-11-07 17:51:49 +01:00
Matias Chomicki
17cce38545 Loki Monaco Editor: implement extracted label keys (#57368)
* feat(loki-monaco-editor): implement extracted label keys

* Chore: add missing responseUtils tests

* feat(loki-monaco-editor): suggest extracted labels

* Chore: fix test case name

* feat(loki-monaco-editor): dont suggest labels in logs query

* Chore: remove console log

* Chore: remove extracted keyword from suggested label

* feat(loki-monaco-editor): do not suggest duplicated labels

* refactor(loki-monaco-editor): pass query and offset to the completions resolver

* Revert "refactor(loki-monaco-editor): pass query and offset to the completions resolver"

This reverts commit d39464fd1a4624d5cd5420156dd2d1e2dad2eecf.

* refactor(loki-monaco-editor): refactor label completions for grouping

* Chore: remove obsolete function
2022-11-07 11:45:07 -05:00
George Robinson
8353f307aa Alerting: Fix test fails in some environments (#58251) 2022-11-07 16:34:37 +00:00
Ben Sully
480277f612 CallResource: don't set Content-Type header if status is 204 (#50780)
Grafana's HTTPServer ensures that the Content-Type header is always set
in the response to a CallResource call, but when the status code is
204 No Content this shouldn't be done; the body should be empty and no
Content-Type header should be set.

We ran into this in the Grafana ML plugin where we were sending an empty
response with status 204, but the frontend client saw that the content
type was JSON and tried to parse it, resulting in an error that made it
to the JS console.
2022-11-07 17:25:49 +01:00
Giordano Ricci
43436bd6f0 Explore: Remove explore2Dashboard feature toggle (#58329) 2022-11-07 16:06:40 +00:00
Zoltán Bedi
b472306239 MSSql/Postgres: Fix visual query editor filter disappearing (#58248) 2022-11-07 17:04:53 +01:00
Yuri Tseretyan
3621cf5a12 Alerting: Update handling of stale state (#58276)
* delete all stale states in one lock
* do not use touched states to detect stale rely only on LastEvaluationTime maintained correctly
* fix tests to use correct eval time
* delete unused method
2022-11-07 11:03:53 -05:00
Neel
db1fd10ff1 Alerting: Append org ID to alert notification URLs (#57123) 2022-11-07 16:03:25 +00:00
Si Mon
bc280d0749 Datasource Loki: preserve header X-ID-Token (#57878) 2022-11-07 16:53:42 +01:00
Emil Tullstedt
89eba7a108 Server: Write internal server error on missing write (#57813) 2022-11-07 16:14:41 +01:00
Galen Kistler
6bc8ec0f9b fix thanos semver string (#58335) 2022-11-07 09:03:42 -06:00
Emil Tullstedt
1ba25b2baa Preferences: Create indices (#48356) 2022-11-07 15:52:26 +01:00
Yuri Tseretyan
623de12e35 Alerting: Create AlertInstanceKey in one place (#58278)
* use method GetAlertInstanceKey
* do not add key if error
2022-11-07 09:35:29 -05:00
Torkel Ödegaard
1fb37b54b3 Scenes: Enforce explicit accessibility modifiers (ESLint) (#58331)
* Public test

* Update

* Update

* revert

* Added some public accessability modifiers

* Force public acessability only for scenes/* folder

* Fixes
2022-11-07 15:32:02 +01:00
Levente Balogh
eb3ee35e1c Frontend Routing: Always render standalone plugin pages using the <AppRootPage> (#57771)
* chore: fix go lint issues

* feat(Routing): route standalone plugin pages to the `AppRoutePage`

* feat(plugin.json): introduce a new field called `isCorePage` for `includes`

* chore: add explanatory comments for types

* refactor(AppRootPage): receive the `pluginId` and `pluginSection` through the props

Now we are able to receive these as props as the pluginId is defined on navLinks
that are registered by plugins.

* chore: update teests for AppRootPage

* fix: remove rebase issue

* tests(applinks): add a test for checking isCorePage plugin page setting

* refactor(applinks): update tests to use FindById() and be more resilient to changes

* fix: Go lint issues

* refactor(routes): use cleaner types when working with plugin nav nodes

Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>

* chore: fix linting issues

* t: remove `isCorePage` field from includes

Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>
2022-11-07 15:19:31 +01:00
Yuri Tseretyan
f9c88e72ae Alerting: Update saveAlertStates in state manager to not return results (#58279) 2022-11-07 09:09:19 -05:00
Laura Fernández
e5d4d00c1f Internationalization: Translate CalendarFooter component (#58326) 2022-11-07 14:42:20 +01:00
Virginia Cepeda
97df6e682e [Alerting] - make rule groups the default view (#58271) 2022-11-07 09:44:20 -03:00
Conor Evans
40ba2ba18d fix(config/jwt): the value should be "expect_claims", not "expected_claims" (#58284)
Signed-off-by: Conor Evans <coevans@tcd.ie>
2022-11-07 12:29:27 +00:00
Josh Hunt
d4e3d47f56 Chore: Disable dashboard-time-zone e2e tests (#58320) 2022-11-07 06:37:47 -05:00
Gábor Farkas
6dd5ce7ab0 Tracing: Allow trace to logs for OpenSearch (#58161)
* tracing: allow trace-to-opensearch functionality

* more consistent naming
2022-11-07 12:24:01 +01:00
Andres Martinez Gotor
d001a1b035 @grafana/e2e: Fix addPanel for small screen size (#57398) 2022-11-07 12:10:30 +01:00
Jo
2ce5dcfb91 ServiceAccounts: Add background service to check for token leaks (#53658)
* add secret scan service

* add token batching

* Apply suggestions from code review

Co-authored-by: Victor Cinaglia <victor@grafana.com>

* fix: finish constant renaming

Co-authored-by: Victor Cinaglia <victor@grafana.com>
2022-11-07 05:46:19 -05:00
Giuseppe Crinò
b40f192c7e chore(docs): clarify how to refer to GH teams (#57679) 2022-11-07 11:39:59 +01:00
Gabriel MABILLE
30fae33f66 RBAC: Allow role registration for plugins (#57387)
* Picking role registration from OnCall POC branch

* Fix test

* Remove include actions from this PR

* Removing unused permission

* Adding test to DeclarePluginRoles

* Add testcase to RegisterFixed role

* Additional test case

* Adding tests to validate plugins roles

* Add test to plugin loader

* Nit.

* Scuemata validation

* Changing the design to decouple accesscontrol from plugin management

Co-authored-by: Kalle Persson <kalle.persson@grafana.com>

* Fixing tests

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Add missing files

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Remove feature toggle check from loader

* Remove feature toggleimport

* Feedback

Co-Authored-By: marefr <marcus.efraimsson@gmail.com>

* Fix test'

* Make plugins.RoleRegistry interface typed

* Remove comment question

* No need for json tags anymore

* Nit. log

* Adding the schema validation

* Remove group to take plugin Name instead

* Revert sqlstore -> db

* Nit.

* Nit. on tests

Co-authored-by: ievaVasiljeva <ieva.vasiljeva@grafana.com>

* Update pkg/services/accesscontrol/plugins.go

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>

* Log message

Co-Authored-By: marefr <marcus.efraimsson@gmail.com>

* Log message

Co-Authored-By: marefr <marcus.efraimsson@gmail.com>

* Remove unecessary method. Update test name.

Co-authored-by: ievaVasiljeva <ieva.vasiljeva@grafana.com>

* Fix linting

* Update cue descriptions

* Fix test

Co-authored-by: Kalle Persson <kalle.persson@grafana.com>
Co-authored-by: Jguer <joao.guerreiro@grafana.com>
Co-authored-by: marefr <marcus.efraimsson@gmail.com>
Co-authored-by: ievaVasiljeva <ieva.vasiljeva@grafana.com>
2022-11-07 11:30:45 +01:00
Ashley Harrison
334b498632 group d3 updates together (#58309) 2022-11-07 10:30:23 +00:00
Will Browne
09e8cff06e Plugins: Make "README" the default markdown request param (#58264)
* Plugins: Make README the default markdown request param

* undo devdboard changes

* fix missing prefix

* rm newline

* re-add space UFFFFF
2022-11-07 11:16:17 +01:00
Oscar Kilhed
b1bfae0350 MySQL: make it possible to add CA cert without using tlsAuth (#58226) 2022-11-07 09:38:42 +01:00
Victor Marin
d673c8809b Timeseries: Fix null pointer when matching fill below to field (#58030)
* Fix timeseries fill below to error

* wip

* modifications

* add tests for fillBelowTo option
2022-11-06 16:19:50 +02:00
Dimitris Sotirakis
bdb8fe3b02 Update drone-cli go mod to v1.6.1 (#58245) 2022-11-05 09:52:21 +02:00
Ryan McKinley
bff19747bd Timeseries: Use standard editor for fillBelowTo field picker (#58283) 2022-11-04 22:00:46 -07:00
Ryan McKinley
a83fdc6b87 Live: remove json exact converter (#58282) 2022-11-04 18:33:02 -04:00
Ryan McKinley
eb1cc80941 Storage: include SQL implementation (#58018) 2022-11-04 17:30:22 -04:00
Yuri Tseretyan
978f1119d7 Alerting: Run state manager as regular sub-service (#58246) 2022-11-04 17:06:47 -04:00
Ryan McKinley
e6a9fa1cf9 ServiceAccounts: enable service accounts after IsRealUser change (#58263)
* suppor service accounts

* add: IsServiceAccount to scheduleUser in scheduler

Co-authored-by: eleijonmarck <eric.leijonmarck@gmail.com>
2022-11-04 15:53:35 -04:00
Todd Treece
d80abd173b Chore: Sort generated jsonnet dashboards by full path (#58267) 2022-11-04 15:14:56 -04:00
Yuri Tseretyan
dce8879145 Alerting: Update state manager to accept rule store as Warm method argument (#58244) 2022-11-04 14:23:08 -04:00
juanicabanas
8f6cdd4cda PublicDashboards: Add delete public dashboard button in public dashboard modal (#58095)
- Delete public dashboard button added in public dashboard modal
- Delete public dashboard button refactored in order to be used in audit table and public dashboard modal
- Tests added
- RTK Query api modified, in order to keep cached data because of having to show public dashboard modal once delete modal is closed.
- RTK Query specific cached data invalidated for public dashboard
- Save button text changed: Create public dashboard when it was never created. Save public dashboard when there's a public dashboard already created
- Public Dashboard modal subscribed to DashboardModel metadata changes
2022-11-04 14:08:50 -04:00
Ezequiel Victorero
ae30a0688a PublicDashboards: refactor using new grafana error types (#58078) 2022-11-04 14:14:32 -03:00
renovate[bot]
5f5b3521d9 Update dependency rollup-plugin-dts to v5 (#58258)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-04 17:04:00 +00:00
renovate[bot]
85d15b6292 Update dependency uuid to v9 (#58260)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-04 16:54:12 +00:00
renovate[bot]
10ee9f129d Update dependency rollup-plugin-node-externals to v5 (#58259)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-04 16:52:15 +00:00
Ashley Harrison
ca3bcc691c hide sectionnav items when collapsed, ensure focus ring overlays active items (#58250) 2022-11-04 16:42:34 +00:00
Ryan McKinley
22628d1f7e Storage: fix failing test (set IsServiceAccount=true) (#58257) 2022-11-04 12:37:25 -04:00
Will Jordan
d581b368bd Alerting: Remove duplicate Slack notification title (#58107)
Move mentions to a markdown-formatted pretext field
to prevent issues mixing blocks and legacy-attachment content.
2022-11-04 17:09:24 +01:00
Torkel Ödegaard
4d2bf41efb AppChrome: Fixes kiosk mode toggling (#58240) 2022-11-04 16:49:31 +01:00
Alexander Weaver
cc8c1380e2 Alerting: Persist annotations from multidimensional rules in batches (#56575)
* Reduce piecemeal state fields

* Read data directly off state instead of rule

* Unify state and context into single struct

* Expose contextual information to layer above setNextState

* Work in terms of ContextualState and call historian in batches

* Call annotations service in batches

* Export format state and reason and remove workaround in unrelated test package

* Add new method to annotation service for batch inserting

* Fix loop variable aliasing bug caught by linter, didn't change behavior

* Incl timerange on annotation tests

* Insert one at a time if tags are present

* Point to rule from ContextualState rather than copy fields

* Build annotations and copy data prior to starting goroutine

* Rename to StateTransition

* Use new bulk-insert utility

* Remove rule from StateTransition and pass in directly to historian

* Simplify annotations logic since we have only one rule

* Fix logs and context, nilcheck, simplify method name

* Regenerate mock
2022-11-04 10:39:26 -05:00
renovate[bot]
c1ea944c79 Update dependency @types/node to v18 (#58139)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-04 15:28:47 +00:00
Gareth Dawson
4749f45fe8 Loki: Replace hardcoded css values (#57770)
* replace hardcoded margin/padding in getLogRowStyles.ts

* replace hardcoded margin/padding in LogDetails.tsx

* replace hardcoded values in LogDetailsRow.tsx

* replace hardcoded values in LogLabels.tsx

* replace hardcoded values in LogLabelStats.tsx

* replace hardcoded values in LogLabelStatsRow.tsx

* replace hardcoded values in LogRowContext.tsx

* replace hardcoded values in LogRowMessage.tsx

* replace hardcoded values

* remove forced theme spacing values
2022-11-04 15:18:55 +00:00
Giordano Ricci
4758bbcb61 Explore: don't re-init the Graph on every data change (#57906)
* Perf: remove structureRev logic from Graph in Explore

* Avoid reinitializing uPlot when not needed

* move fieldConfigRegistry

* restore usememo for dataWithConfig
2022-11-04 15:05:06 +00:00
renovate[bot]
7078871ab6 Update dependency react-i18next to v12 (#58238)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-04 14:45:20 +00:00
Dan Cech
da9c646f24 Build: add explicit build step for go codeql (#58195)
* add explicit build step for go codeql

* support workflow_dispatch for codeql checks

* syntax fix

* enable on push to codeql-go branch

* test

* use go version from go.mod

* explicitly set go version

* tidy up, add workflow_dispatch support to all codeql actions
2022-11-04 10:20:08 -04:00
Dan Cech
9ea6a43089 Build: clean up and document integration test convention (#58170)
* clean up and document integration test convention

* clarify integration test conventions

* clean up integration tests that don't follow convention

* mark testIntegration* functions as helpers to avoid confusion
2022-11-04 10:14:21 -04:00
Emil Tullstedt
428dd54094 Chore: Upgrade Go to 1.19.3 (#58052) 2022-11-04 14:50:43 +01:00
renovate[bot]
a6f302648b Update dependency @wojtekmaj/enzyme-adapter-react-17 to v0.7.0 (#58233)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-04 13:49:09 +00:00
renovate[bot]
9b8e3b9619 Update dependency jest-fail-on-console to v3 (#58219)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-04 13:39:51 +00:00
Yuriy Tseretyan
ff5cc3e640 Chore: Update cloud monitoring and Azure data sources to support contextual logs (#57844)
* update cloud monitoring to use log from context
* update azure monitor to use contextual logger
2022-11-04 09:28:38 -04:00
Eric Leijonmarck
72d0c6b428 Auth: add IsServiceAccount to IsRealUser (#58015)
* add: IsServiceAccount to SignedInUser and IsRealUser

* fix: linting error

* refactor: add function IsServiceAccountUser()

By adding the function IsServiceAccountUser() we use it to identify for
ServiceAccounts in the HasUniqueID() since caching is built up on having
a uniqueID, see comment: https://github.com/grafana/grafana/pull/58015#discussion_r1011361880
2022-11-04 12:39:54 +00:00
Laura Fernández
b7efd46e2d Internationalization: Translate TimeRangeList component (#58131) 2022-11-04 12:21:46 +01:00
Dimitris Sotirakis
9c1c10ab9a Remove base and arch args (#58209) 2022-11-04 13:21:18 +02:00
Josh Hunt
9ff2765bb9 Auth: Check for OrgUsersAdd on frontend to display pending invites (#58217) 2022-11-04 11:14:59 +00:00
Gilles De Mey
e410dfbab8 Alerting: Encode path separators to side-step proxies (#58141) 2022-11-04 06:58:17 -04:00
Andreas Christou
7bb76e0975 Azure Monitor: E2E Tests (#54619)
* Update credentials form with data-testids and aria-labels

* Update gitignore

* Add example dashboard

* Stub out E2E test for creating ds and importing dashboard

* Add component selectors

* Remove subscription check temporarily

* Appropriately set disabled prop

* Fix lint issues

* Update to use selectors and wait on subscriptions request

* Add test for metrics panel

- Add required selectors for resource picker and metrics query editor

* Add logs and ARG basic query scenarios

- More selector updates

* Add E2E test for template variables

- Tests advanced resource picker
- Adds required selectors

* Remove log and add annotation e2e test

* Update test

* Prettier/betterer updates

- Remove gitignore change

* Lint issues

* Update betterer results

* Lint issue and remove unneeded import

* Don't print certain commands

* Avoiding flakiness

- Ensure code editor has sufficient time to load in ARG test
- Avoid flakiness around correct template variable being selected by typing in resource name

* Remove be.visible requirement

* Update test

* Update selector name

* Reuse datasource

* Fix datasource reuse and combine query tests

* Remove import dashboard step as unneeded

* Review

- Randomise datasource name
- Skip annotations test
- Remove unused example dashboard

* Update to ensure e2e test works in CI

* Update e2e test

- Update environment variables (process is not available in cypress)
- Add wait on resource picker searches to avoid flakiness
- Update subscription and resource group names

* Update CODEOWNERS

* Parse credentials in CI from outputs file

* Update outputs file path

* Fix selector

* Undo selector change

* Update e2e tests

- Set default subscription
- Fix datasource selection in variable editor
- Fix resource picker search flakiness
- Set subscription in ARG query test
- Fix resource group selection
- Update resource group

* Review

* Review 2
2022-11-04 10:47:54 +00:00
renovate[bot]
aa9039a841 Update dependency i18next to v22 (#58156)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-04 10:46:19 +00:00
renovate[bot]
1e7d9c6360 Update dependency sass to v1.56.0 (#58207)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-04 10:44:00 +00:00
renovate[bot]
3f38c95377 Update dependency @types/k6 to v0.41.0 (#58165)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-04 10:42:45 +00:00
Jo
e3ea7ee145 Doc: Add groups mapping config to readme (#58208) 2022-11-04 10:43:38 +01:00
renovate[bot]
17f7cbf0f6 Update dependency babel-loader to v9.1.0 (#58155)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-04 09:20:27 +00:00
Ashley Harrison
871d98e550 hopefully improve slate test reliability (#58171) 2022-11-04 09:20:03 +00:00
Sofia Papagiannaki
d131733f55 Nested Folder: Modify store Update() (#58183)
* Nested Folder: Modify store Update()

* fixup
2022-11-04 10:04:24 +01:00
Ryan McKinley
3dfa49b376 Playlist: cleanup object store implementation (#58201) 2022-11-03 16:35:20 -07:00
Levente Balogh
376f4b0cc7 Navigation: Add pluginId to standalone plugin page NavLinks (#57769)
* feat(Navigation): add `pluginId` to NavLink and override sibling navlinks with the same URL

* test replacing page from plugin

* chore: fix go lint issues

* fix(NavLink): change `PluginId` to `PluginID`

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

* fix(NavLink): make the `PluginId` -> `PluginID` change everywhere

* chore(navModel.ts): update explanatory comment for `pluginId`

Co-authored-by: Miklós Tolnai <miklos.tolnai@grafana.com>
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-11-03 21:19:42 +01:00
Jeff Levin
6fcc5b42c0 publicdashboards: split create/update api paths (#57940)
This PR splits the create and update paths for public dashboards and includes assorted refactors toward a proper REST API. Additionally, we removed the concept of a "public dashboard config" in favor of "public dashboard" 

Co-authored-by: juanicabanas <juan.cabanas@grafana.com>
Co-authored-by: Ezequiel Victorero <ezequiel.victorero@grafana.com>
2022-11-03 11:30:12 -08:00
ismail simsek
0367f61bb3 Share azureauth between prometheus clients (#58122)
* Move azureauth to upper package

* Refactor http transport options
2022-11-03 19:44:37 +01:00
Christopher Moyer
1722000309 fixes typo (#58159) 2022-11-03 13:42:23 -05:00
kay delaney
a8c181bf6a Chore: Migrate usage of v1 theme to v2 (#58154) 2022-11-03 18:15:55 +00:00
lean.dev
c1b10e4f0c Docs: Adding documentation for custom branding on public dashboards (#58090)
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2022-11-03 14:58:43 -03:00
Timur Olzhabayev
de7f411e20 Removing workflow_call from update-changelog and bump-version action (#58181) 2022-11-03 17:47:04 +00:00
Giuseppe Guerra
7996a1c8ad Chore: Update grafana-plugin-sdk-go to v0.142.0 (#58115)
* Chore: Update grafana-plugin-sdk-go to v0.142.0

* Update tests and golden files for 207 status code

* Chore: Move update flag definition at the top in response_parser_test.go

* retrigger

Co-authored-by: Will Browne <will.browne@grafana.com>
2022-11-03 18:34:27 +01:00
Ryan McKinley
857e545c5a FeatureFlags: set defaults in the registry rather than the ini file (#58106) 2022-11-03 17:34:01 +00:00
Adela Almasan
9c7b6b1ce8 Canvas: Extend root context menu (#58097) 2022-11-03 17:30:12 +00:00
dessen-xu
b799be3052 Toolkit: Fix Webpack less-loader config (#57950) 2022-11-03 16:13:18 +01:00
Todd Treece
e105b5a107 Chore: Add jsonnet library for devenv dashboards (#57928) 2022-11-03 11:04:39 -04:00
Laura Fernández
813ebf988d Internationalization: Translate TimePickerTitle component (#57909) 2022-11-03 16:03:28 +01:00
Kyle Cunningham
05f630a566 Add VSCode launch configuration to debug in remote Chrome (#58108) 2022-11-03 21:08:38 +07:00
Sven Grossmann
4b1ddba0a8 fixed explain handlers for label- and lineformat (#58135) 2022-11-03 14:57:29 +01:00
kay delaney
f37e53f060 Chore: Migrate more theme v1 usage to v2 (#58121) 2022-11-03 09:54:18 -04:00
Ashley Harrison
c1c8dc8749 remove e2e-api-tests + axios dependency (#58148) 2022-11-03 13:52:58 +00:00
renovate[bot]
0792ff8e20 Update dependency eslint-plugin-jest to v27 (#58143)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-03 13:37:00 +00:00
Leon Sorokin
4d88e2b542 TimeSeries: more thorough detection of negative values for stacking dir (#57863) 2022-11-03 07:24:01 -06:00
Marcos Vinicius
372ba83534 reduce the number of requests in folder section (#55876) 2022-11-03 13:22:07 +00:00
Sofia Papagiannaki
5c973e58bd Nested Folders: Add tests for store methods (#57662)
* Nested Folders: Add store tests

* Fix parent order

* Fix update

* skip tests!

* Export test helpers for now
2022-11-03 14:21:41 +01:00
renovate[bot]
89548df5a4 Update dependency @types/ol-ext to v3 (#58140)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-03 13:18:47 +00:00
lean.dev
49e36c5c05 Public Dashboards: Renaming PubdashFooter (#58137) 2022-11-03 10:12:27 -03:00
Todd Treece
d45fe6e25c Chore: Add NewAnonymousSignedInUser to user service (#57537) 2022-11-03 14:03:29 +01:00
Beto Muniz
8fe02612b6 Graphite: Allow metric name to use true/false as name (#57996) 2022-11-03 09:34:34 -03:00
Sonia Aguilar
c8f87f4413 Alerting: Improving group modal with validation on evaluation interval (#57830)
* Show rules list for the group with the For duration, and add validation for keeping all rules in the same group with a valid For

* Sort rules by For duration

* Add number evaluations column in alert list

* Add Error badge in column #evaluations in case of invalid For

* Add test for getNumberEvaluationsToStartAlerting method

* Move re-usable new InfoIcon component into a separate file in unified components folder

* Add edge case for getNumberEvaluationsToStartAlerting method, and change some namings
2022-11-03 12:50:32 +01:00
renovate[bot]
15b553c11c Update dependency @rollup/plugin-node-resolve to v15 (#58130)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-03 11:43:28 +00:00
renovate[bot]
2095bbcfa7 Update dependency react-select to v5.6.0 (#58127)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-03 11:32:46 +00:00
renovate[bot]
5b86474733 Update dependency eslint-plugin-jsdoc to v39.6.2 (#58126)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-03 11:29:25 +00:00
renovate[bot]
ed31f0fe20 Update dependency @rollup/plugin-json to v5 (#58083)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-03 11:17:52 +00:00
Joey Tawadrous
130f848f74 Flame Graph: Add units and value to blocks (#57959)
* Added unit to block label

* Tests

* Throw if value field is undefined
2022-11-03 11:15:42 +00:00
Villena Guillaume
e9dc7fb85c Rendering: Add configuration options for renderKey lifetime (#57339)
* Add configuration options for `renderKey` lifetime

* Rename config key to `render_key_lifetime`

* Update conf/defaults.ini

Co-authored-by: Joan López de la Franca Beltran <5459617+joanlopez@users.noreply.github.com>

* Add `render_key_lifetime` to sample.ini

Co-authored-by: Joan López de la Franca Beltran <5459617+joanlopez@users.noreply.github.com>
2022-11-03 12:06:55 +01:00
Andre Pereira
90ac300d10 Tempo: Make usage of time range for TraceID query optional (#58057)
* Added switch to toggle the TraceID query time shift

* Fix and improve tests
2022-11-03 11:01:22 +00:00
renovate[bot]
0071b949e1 Update typescript-eslint monorepo to v5.42.0 (#58073)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-03 07:00:00 -04:00
renovate[bot]
cf5f88ca47 Update dependency @rollup/plugin-commonjs to v23 (#58075)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-03 06:56:11 -04:00
Ashley Harrison
514d3111f4 Accessibility: Enable rule jsx-a11y/no-noninteractive-element-interactions (#58077)
* fixes for no-noninteractive-element-interactions

* remaining fixes

* add type="button"

* fix unit tests
2022-11-03 10:55:58 +00:00
renovate[bot]
65bd5c65d8 Update emotion monorepo (#58066)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-03 10:49:50 +00:00
Ashley Harrison
c3206167a6 increase select placeholder contrast to be WCAG AA compliant (#58034) 2022-11-03 10:45:57 +00:00
Ashley Harrison
f76ba90078 Accessibility: Enable jsx-a11y/mouse-events-have-key-events (#58050)
* implement VizLegend keyboard accessibility

* add onBlur/onFocus
2022-11-03 10:22:50 +00:00
Giordano Ricci
e6b088fbf5 Explore: Fix shared crosshair for logs, logsvolume and graph panels (#57892)
* Explore: enable shared corsshair for logs, logsvolume & graph panel

* avoid recreating a scoped bus on every render
2022-11-03 09:55:02 +00:00
Alex Moreno
3558cadb7e Alerting: Add title and description to Webhook contact point (#58058)
* Add title and description to Webhook contact point

* Remove deprecation message
2022-11-03 10:52:07 +01:00
Alexander Komarov
76532c1f27 Fix an indentation issue in example config in doc (#57814)
Fix this issue:
"Error loading config (--config.file=/etc/prometheus/prometheus.yml)" file=/etc/prometheus/prometheus.yml err="parsing YAML file /etc/prometheus/prometheus.yml: yaml: line 8: did not find expected '-' indicator"
2022-11-03 10:44:14 +01:00
Alex Moreno
ba15d675e7 Alerting: Add values to annotations (#57738)
* Add values to annotations

* Fix imports

* Use State attrs instead of Result attrs

* Remove unnecessary variable
2022-11-03 10:35:34 +01:00
Ashley Harrison
b8303fd431 Chore: Convert SpanTreeOffset test to RTL (#56195)
* convert SpanTreeOffset tests to RTL (minus mouseenter/mouseleave tests)

* fix remaining tests
2022-11-03 09:31:09 +00:00
Eric Leijonmarck
fc1b647474 Auth: Add fixed repeat migration w. checks for subset of permissions (#58054)
* add: added a repeat migration w. fixed checks for permissions

* add: migration to migrations

* refactor: fix migration instead of making a new one

* fix: removed the old id

* fix: keep old name but change id

* add: migration for patched previous migration

* add: migration from missing file
2022-11-03 08:57:20 +00:00
Ivana Huckova
a83dee6031 Elasticsearch: Add trace to logs functionality (#58063)
* Elasticsearch: Implement trace to logs

* Fix tests
2022-11-03 09:52:40 +01:00
Jo
eb84358aa7 Auth: Validate Azure ID token version on login is not v1 (#58088) 2022-11-03 09:47:44 +01:00
Ivana Huckova
77f47ccba3 Loki: Remove redundant feature flag in defaults.ini (#58084) 2022-11-03 09:40:13 +01:00
Torkel Ödegaard
915ebcf832 Search: Refactor state and logic to be less fragmented and spread out (#57973)
* Started search state refactor

* Things are working

* Move more to statemanger

* minor tweaks

* Fixed name of hook

* revert yarn.lock changes

* Harderning StateManagerBase

* More tests and refinements

* Fixed unit test

* More polish

* fixing tests

* fixed test

* Fixed test
2022-11-03 08:29:39 +01:00
Drew Slobodnjak
94d9baa9ff Geomap: Add photo layer (#57307)
* Geomap: Add photo layer

* Remove unrelated changes

* Add todos for follow up

* Geomap: simplify photos layer (#57320)

* photos layer

* Remove unused import

Co-authored-by: drew08t <drew08@gmail.com>

* Add field selector for image source

* Add radius slider

* Fix rendering issue

* Only update vector layer after image load

* Add border color selection

* Update question mark source

* Add gdev dashboard for photo layer

* Add panel title to gdev dashboard

* Add photo validation

* Update geomap gdev dashboard to remove null value for threshold

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2022-11-02 16:50:59 -07:00
George Robinson
f2e4cb7c4e Alerting: Fix feedback (#57922) 2022-11-02 22:36:14 +00:00
George Robinson
215ffee437 Alerting: Fix screenshot is not taken for stale series (#57982) 2022-11-02 22:14:22 +00:00
brendamuir
f1b6660b54 Docs: fixes alias (#58060)
* Docs: fixes alias

* adds file ext
2022-11-02 17:00:26 -04:00
owensmallwood
7de093738d PublicDashboards: Adds command to generate map of supported datasources (#57841)
generates map of supported datasources for pubdash
2022-11-02 13:35:57 -06:00
Dimitris Sotirakis
7a12132237 DEB/RPM Packages: Remove old package publishing steps (#58071)
* Remove old publish package steps

* Don't ignore publish packaging failures
2022-11-02 18:42:01 +00:00
Andrej Ocenas
9e03355e53 Flamegraph: Add self to tooltip (#57548)
* Add self to tooltip

* Fix tests

* Update layout

* Fixed too much space on the bottom
2022-11-02 19:07:11 +01:00
lean.dev
d5a92e8f42 Public Dashboards: Extracting config of Public Dashboard (#57788)
Co-authored-by: juanicabanas <juan.cabanas@grafana.com>
2022-11-02 14:32:29 -03:00
renovate[bot]
7954ac3948 Update dependency webpack-bundle-analyzer to v4.7.0 (#58055)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-02 16:17:28 +00:00
Marcus Andersson
b804b2f073 Plugins: Added hook to make it easier to track interactions in plugins (#56126)
* first stab at context away plugin tracking.

* adding a plugin context and a hook to get hold of a tracker that always appends the plugin context information.

* wip

* improved the code a bit.

* wip

* Fixed type errors.

* added datasource_uid to data sources.

* fixed error message when trying to use hook outside of context.

* small refactoring according to feedback.

* using the correct provider for data source context.

* check not needed.

* enforcing the interaction name to start with grafana_plugin_

* exposing guards for the other context type.

* added structure for writing reporter hook tests.

* added some more tests.

* added tests.

* reverted back to inheritance between context types.

* adding mock for getDataSourceSrv
2022-11-02 16:57:57 +01:00
Leo
932429a545 LibraryPanels: Replace folderID with folderUID (#56414)
* user essentials mob! 🔱

lastFile:pkg/services/libraryelements/writers.go

* user essentials mob! 🔱

lastFile:pkg/services/libraryelements/writers.go

* user essentials mob! 🔱

lastFile:pkg/services/libraryelements/writers.go

* user essentials mob! 🔱

lastFile:pkg/services/libraryelements/writers.go

* user essentials mob! 🔱

lastFile:pkg/services/libraryelements/database.go

* user essentials mob! 🔱

lastFile:pkg/services/libraryelements/writers.go

* user essentials mob! 🔱

lastFile:pkg/services/libraryelements/writers.go

* user essentials mob! 🔱

* support filterFolderUIDs in the frontend

* move common logic to a variable

* fixed FolderLibraryPanelsPage and improved unit test

* fix backend lint error

* fix formatting error

Co-authored-by: Joao Silva <joao.silva@grafana.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
Co-authored-by: eledobleefe <laura.fernandez@grafana.com>
Co-authored-by: joshhunt <josh@trtr.co>
2022-11-02 16:49:02 +01:00
Kristina
5a99aff7b8 construct the datasource for the example query if not added (#57936) 2022-11-02 09:50:10 -05:00
Yuriy Tseretyan
3a5ddbfbdf use logger context in cloudwatch (#57842) 2022-11-02 10:14:02 -04:00
Yuriy Tseretyan
e3a4bde622 Alerting: Condition evaluator with cached pipeline (#57479)
* create rule evaluator
* load header from the context
* init one factory
* update scheduler
2022-11-02 10:13:39 -04:00
Yuriy Tseretyan
d9c40ca41e Chore: Update sqleng, elasticsearch, tempo and opentsdb plugins to support contextual logs. (#57777)
* make sql engine use pick log context for logs
* update tempo to get log context
* update opentsdb to use log context
* update es client to use log context
2022-11-02 10:03:50 -04:00
renovate[bot]
17ebeab02c Update dependency webpack-dev-server to v4.11.1 (#58056)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-02 13:56:56 +00:00
Carl Bergquist
06705a49e2 Instrumentation: Log plugin and datasource info for each plugin request. (#54769)
Signed-off-by: bergquist <carl.bergquist@gmail.com>
2022-11-02 14:51:51 +01:00
Simon Podlipsky
d32a9a62b5 Docker: Remove Edge repos (#53875)
Co-authored-by: Leonard Gram <leo@xlson.com>
2022-11-02 09:44:39 -04:00
Gábor Farkas
ce13ab7077 renovate: group @types/slate* with slate* (#58053) 2022-11-02 13:42:53 +00:00
Dan Cech
6a4a10fa92 remove unneeded package updates (#58005) 2022-11-02 09:30:20 -04:00
Emil Tullstedt
d0dfb28ee4 Security: Upgrade x/text to version unaffected by CVE-2022-32149 (#57797) (#57803)
Co-authored-by: emerson_gong <yong-jie.gong@microfocus.com>
2022-11-02 14:28:43 +01:00
renovate[bot]
78bef1c7e1 Update dependency eslint-plugin-jsdoc to v39.5.0 (#58039)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-02 13:22:54 +00:00
Kristin Laemmert
706b301285 feat(nested folders): add CountDashboardsInFolder (#57847)
* feat(nested folders): add CountDashboardsInFolder

This commit adds a new method to the Dashboard service and stores: CountDashboardsInFolder. The command struct takes a folderUID, but the store implementation still depends on the parent folder ID. This is temporary; eventually we will replace all references to FolderIDs (associated with Dashboards) with folder UIDs.

There are some unfortunate additional test changes that were necessary after generating the service & store mocks; it looks like that hasn't been generated since the last change(s).

* more test updates
* don't forget the service test
* that didn't end up used, so bye for now
* agree to disagree with the linter
2022-11-02 09:15:50 -04:00
renovate[bot]
409ed84136 Update dependency stylelint to v14.14.0 (#58051)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-02 09:02:41 -04:00
renovate[bot]
09d91d1f53 Update dependency react-select to v5.5.9 (#58012)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-02 12:35:24 +00:00
renovate[bot]
a18ee16dd9 Update dependency sass-loader to v13.1.0 (#58047)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-02 12:28:28 +00:00
renovate[bot]
38ad824f7a Update dependency rudder-sdk-js to v2.18.1 (#58013)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-02 12:27:30 +00:00
George Robinson
4c581b5f85 Alerting: Fix response is not returned for invalid Duration in Provisioning API (#58046) 2022-11-02 08:21:23 -04:00
renovate[bot]
909d0f4ced Update Monthly patch updates (#58002)
* Update Monthly patch updates

* update typescript sdk, add ignore for emotion css prop

* fix unit tests

* type fixes

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-11-02 12:05:32 +00:00
Sriram
c58542348d chore: updated plugin-ci go dependency to 1.19.3 (#58035) 2022-11-02 11:11:29 +00:00
renovate[bot]
9e25cf7e12 Update dependency rc-slider to v10 (#49242)
* Update dependency rc-slider to v10

* start migrating to rc-slider 10

* rc-slider 10 changes

* fix

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: joshhunt <josh@trtr.co>
2022-11-02 07:00:49 -04:00
Torkel Ödegaard
d7f9093ccd LibrayPanels: Fix unlinking libray panel (#57825) 2022-11-02 11:38:48 +01:00
kay delaney
30dc0f56a4 Chore: Migrate more usage of v1 themes to v2 (#57680)
* Chore: Migrate more usage of v1 themes to v2

* Implement suggested changes
2022-11-02 10:25:08 +00:00
Piotr Jamróz
dd5e3a0818 Explore: Track data links usage (#56868)
* Add tracking for data links in explore

* Add tracking for data links in explore

* Fix tests

* Retrigger build
2022-11-02 11:22:09 +01:00
Julien Duchesne
c46a4a0b26 Linux Packages: Handle publish to beta (#57528)
Uses the feature added here: https://github.com/grafana/deployment_tools/pull/46301
When a version is named "beta", it will be distributed in the beta distribution, rather than in stable

Co-authored-by: dsotirakis <dimitrios.sotirakis@grafana.com>
2022-11-02 06:21:41 -04:00
Gabriel MABILLE
101ce57a94 RBAC: Allow listing user permissions with scope (#57538)
* RBAC: Allow listing user permissions with scope

* Add docs

* Document the api endpoint

* Update docs

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

* Split endpoint in two

* document reloadcache

* Update docs/sources/developers/http_api/access_control.md

* Fix test

* Ieva's nit.

* Simplify flag description

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>
2022-11-02 10:48:11 +01:00
Ashley Harrison
f1f0a6f88b Revert "Update React Aria (#57975)" (#58001)
This reverts commit 44069b64cd.
2022-11-02 09:39:32 +00:00
Jack Westbrook
68a3a867ce chore(npm): patch bump msw to fix nested dep vuln (#57671) 2022-11-02 04:20:33 -04:00
Dimitris Sotirakis
f3b8cd1c98 CI: Remove *-test-backend-enterprise2 pipelines (#58028)
* Remove test-backend-enterprise2 pipelines

* Remove leftover
2022-11-02 04:13:12 -04:00
Zoltán Bedi
26659baf8f PostgreSQL: Migrate to React (#52831)
- Migrate Postgres query editor to react
- Add support for field aliasing in SELECT clauses to SQL based datasources

Co-authored-by: Kyle Cunningham <kyle@codeincarnate.com>
Co-authored-by: Oscar Kilhed <oscar.kilhed@grafana.com>
2022-11-02 11:30:35 +07:00
Ryan McKinley
0c3ed0219e Storage: fix dummy implementation and tests (#58019) 2022-11-01 20:33:36 -04:00
Eric Leijonmarck
c43e97cf37 Docs: Add prerequisites to enable auth.jwt for url login (#57806)
* docs: add prerequisites

* Update docs/sources/setup-grafana/configure-security/configure-authentication/jwt/index.md
2022-11-01 17:21:07 -04:00
juanicabanas
fb5401b8b9 PublicDashboards: Orphaned public dashboard item list modified (#58014)
PublicDashboards: Orphaned public dashboard item list modified
2022-11-01 16:56:19 -03:00
Christopher Moyer
088a4e02e8 Docs: removes writing guidelines, points contributors to Writers' Toolkit (#58011)
* removes writing guidelines, points contributors to the Writers' Toolkit

* Update contribute/documentation/README.md

Co-authored-by: Ursula Kallio <ursula.kallio@grafana.com>

Co-authored-by: Ursula Kallio <ursula.kallio@grafana.com>
2022-11-01 14:48:52 -05:00
Alexander Weaver
ea8c5ce929 SQLStore: Create utility for bulk inserts (#57632)
* Add batchsize to dialects

* Some intermediary progress

* Reflection-based implementation

* Validate batch size

* Implement a few simple tests

* Fix linter error

* Add debug message when falling back to default batch size
2022-11-01 13:24:32 -05:00
Grafana I18n Bot
d8a4a7c90d I18n: Crowdin sync (#57998)
* New translations grafana.json (French)

* New translations grafana.json (French)
2022-11-01 12:38:55 -04:00
renovate[bot]
02f9853c4f Update dependency mocha to v10.1.0 (#58004)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-01 16:28:29 +00:00
renovate[bot]
bb51afee69 Update dependency i18next-parser to v6.6.0 (#57999)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-01 16:24:59 +00:00
renovate[bot]
0ed71dbdd4 Update dependency marked to v4.2.0 (#58000)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-01 16:02:49 +00:00
Ryan McKinley
5736b46962 Storage: add support for snapshots, dataframes, and raw json objects (#57934) 2022-11-01 08:28:13 -07:00
Garrett Guillotte
852d069a3c Docs: Refactor data sources content (#57573)
* Docs: Revise data source index

* Docs: Consolidate data source administration docs

* Docs: Revise panels docs related to data sources

* Docs: Revise Alertmanager data source

* Docs: Reorganize AWS CloudWatch data source docs

* Docs: Reorganize Azure Monitor data source docs

* Docs: Move azuremonitor to azure-monitor

* Docs: Revise Elasticsearch docs

* Docs: Move Elasticsearch index into bundle

* Docs: Revise GCM docs

* Docs: Revise Graphite docs

* Docs: Move Graphite index into bundle

* Docs: Revise InfluxDB docs

* Docs: Revise Jaeger docs

* Docs: Move Jaeger index into bundle

* Docs: Revise Loki docs

* Docs: Move Loki index into bundle

* Docs: Revise MS SQL docs

* Docs: Move MS SQL index into bundle

* Docs: Revise Prometheus docs

* Docs: Move Prometheus index into bundle

* Docs: Revise Tempo docs

* Docs: Move Tempo index into bundle

* Docs: Revise TestData DB docs

* Docs: Move TestData DB index into bundle

* Docs: Revise Zipkin docs

* Docs: Move Zipkin index into bundle

* Docs: Move other data sources' index pages into bundles

* Docs: Revise frontmatter

* Fixing hugo markdown errors

* Docs: Add query editor and template var sections to overview doc

* Docs: Remove CTAs across data source docs

* Docs: Remove CTA

* Docs: Remove CTA

* Docs: Fix links, images, typos, and usage consistency.

* Docs: Fix typos

* Docs: Fix CI issues

* Update docs/sources/datasources/_index.md

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

* Update docs/sources/datasources/_index.md

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

* Docs: Fix query editor links

* Update docs/sources/panels-visualizations/_index.md

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

* Update docs/sources/panels-visualizations/_index.md

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

* Docs: Rebundle child pages per writers' toolkit

* Docs: Fix prettier for CI

* Docs: Fix relrefs from outside data sources docs

* Docs: Fix broken relrefs within datasources

* Docs: Fix relrefs to data sources docs

* Fixed some more refs

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-11-01 10:22:06 -05:00
Ryan McKinley
22648d8581 GRN: minor cleanup (#57924) 2022-11-01 11:09:39 -04:00
dependabot[bot]
09908b6602 Bump actions/cache from 2.1.7 to 3.0.11 (#56910)
Bumps [actions/cache](https://github.com/actions/cache) from 2.1.7 to 3.0.11.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](https://github.com/actions/cache/compare/v2.1.7...v3.0.11)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-01 15:00:07 +00:00
renovate[bot]
c0526e1905 Update dependency eslint to v8.26.0 (#57986)
* Update dependency eslint to v8.26.0

* update eslint sdk as well

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-11-01 14:55:41 +00:00
dependabot[bot]
f6376ead29 Bump actions/stale from 5 to 6 (#57864)
Bumps [actions/stale](https://github.com/actions/stale) from 5 to 6.
- [Release notes](https://github.com/actions/stale/releases)
- [Changelog](https://github.com/actions/stale/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/stale/compare/v5...v6)

---
updated-dependencies:
- dependency-name: actions/stale
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-01 14:46:04 +00:00
dependabot[bot]
86d7542234 Bump actions/setup-node from 3.4.0 to 3.5.1 (#57865)
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 3.4.0 to 3.5.1.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](https://github.com/actions/setup-node/compare/v3.4.0...v3.5.1)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-01 14:44:37 +00:00
Santiago
a3f828de8a Alerting: Fix flaky test in notifiers (#57927)
* Alerting: Fix flaky test in notifiers

* remove TODO comment
2022-11-01 11:39:14 -03:00
Ashley Harrison
e5c68f40c2 Accessibility: enable rule jsx-a11y/label-has-associated-control (#57964)
* use labels correctly

* fix opentsdb labels

* fix unit tests

* use aria-label instead of data-testid
2022-11-01 14:37:58 +00:00
dependabot[bot]
3770f4f2b7 Bump slackapi/slack-github-action from 1.14.0 to 1.23.0 (#56836)
Bumps [slackapi/slack-github-action](https://github.com/slackapi/slack-github-action) from 1.14.0 to 1.23.0.
- [Release notes](https://github.com/slackapi/slack-github-action/releases)
- [Commits](https://github.com/slackapi/slack-github-action/compare/v1.14.0...v1.23.0)

---
updated-dependencies:
- dependency-name: slackapi/slack-github-action
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-01 14:36:40 +00:00
renovate[bot]
c9104c97a8 Update dependency eslint-plugin-jsdoc to v39.4.0 (#57987)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-01 14:34:23 +00:00
dependabot[bot]
28fc518ec8 Bump actions/cache from 2.1.7 to 3.0.10 (#56218)
Bumps [actions/cache](https://github.com/actions/cache) from 2.1.7 to 3.0.10.
- [Release notes](https://github.com/actions/cache/releases)
- [Changelog](https://github.com/actions/cache/blob/main/RELEASES.md)
- [Commits](https://github.com/actions/cache/compare/v2.1.7...v3.0.10)

---
updated-dependencies:
- dependency-name: actions/cache
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-11-01 14:28:52 +00:00
renovate[bot]
5b43ca7d7d Update dependency @visx/tooltip to v2.16.0 (#57980)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-01 14:19:29 +00:00
unknowndevQwQ
6dd3584f77 Server: Make unix socket permission configurable (#52944) 2022-11-01 15:04:01 +01:00
renovate[bot]
44069b64cd Update React Aria (#57975)
* Update React Aria

* fix unit tests

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-11-01 13:36:00 +00:00
Dimitris Sotirakis
57ee0e4a4b CI: Use full dockerhub repository name (#57979)
* Add full dockerhub repo name

* Update grabpl version
2022-11-01 15:33:16 +02:00
renovate[bot]
9fa2da2724 Update dependency core-js to v3.26.0 (#57981)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-01 13:25:26 +00:00
Grafana I18n Bot
b30a0887bd I18n: Crowdin sync (#57978)
* Update source file grafana.json

* New translations grafana.json (French)

* New translations grafana.json (Spanish)

* New translations grafana.json (German)

* New translations grafana.json (Chinese Simplified)
2022-11-01 13:07:06 +00:00
renovate[bot]
511be7d35f Update dependency @react-types/shared to v3.15.0 (#57970)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-01 13:01:35 +00:00
renovate[bot]
deef046626 Update dependency @rushstack/ts-command-line to v4.13.0 (#57972)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-01 12:23:45 +00:00
renovate[bot]
1b8409dff8 Update Moveable (#57967)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-11-01 12:11:20 +00:00
Petr Stupka
e99f75f0ca Alerting: Linking external images securely - Azure Blob (#1) (#56598) 2022-11-01 13:02:17 +01:00
Carl Bergquist
3188af9be3 metrics: expose when the binary was built as an gauge (#57951)
Signed-off-by: bergquist <carl.bergquist@gmail.com>
2022-11-01 13:00:47 +01:00
Ashley Harrison
cff6d1cf8b Chore: group some packages to reduce number of PRs (#57912)
* group some packages to reduce number of PRs

* Group slate + slate-react together

* kick drone
2022-11-01 11:52:17 +00:00
Josh Hunt
2de6cd0692 Chore: Stories for Select performance (#57965)
* user essentials mob! 🔱

* user essentials mob! 🔱

lastFile:packages/grafana-ui/src/components/Select/SelectPerf.story.internal.tsx

* user essentials mob! 🔱

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-11-01 11:51:53 +00:00
Marcus Andersson
5c30b0cca1 Chore: update latest.json to 9.2.3 (#57960) 2022-11-01 07:01:37 -04:00
Grot (@grafanabot)
02add89b53 Changelog: Updated changelog for 9.2.3 (#57955) 2022-11-01 11:32:34 +01:00
Andrej Ocenas
dfb75815b1 Profiling: Add docs for Parca and Phlare (#57833)
* Add docs for Parca and Phlare

* Add feature toggle note

* Wording fixes

* Update images and some links

* Update links
2022-11-01 11:14:36 +01:00
Joey Tawadrous
00ebd7a983 FlameGraph: Add docs for flame graph (#57834)
* Flame graph docs

* Remove aliases

* Add flame graph to viz page

* Update text

* Update feature toggle text

* Update docs/sources/panels-visualizations/visualizations/flame-graph/index.md

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* Update docs/sources/panels-visualizations/visualizations/flame-graph/index.md

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* Update docs/sources/panels-visualizations/visualizations/flame-graph/index.md

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* Update docs/sources/panels-visualizations/visualizations/flame-graph/index.md

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* Update docs/sources/panels-visualizations/visualizations/flame-graph/index.md

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* Update docs/sources/panels-visualizations/visualizations/flame-graph/index.md

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* Update docs/sources/panels-visualizations/visualizations/flame-graph/index.md

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* Update links

* Remove heading

* Update docs/sources/panels-visualizations/visualizations/flame-graph/index.md

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* Update docs/sources/panels-visualizations/visualizations/flame-graph/index.md

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* Update docs/sources/panels-visualizations/visualizations/flame-graph/index.md

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* Update docs/sources/panels-visualizations/visualizations/flame-graph/index.md

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* Update docs/sources/panels-visualizations/visualizations/flame-graph/index.md

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* Update docs/sources/panels-visualizations/visualizations/flame-graph/index.md

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* Update text

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>
2022-11-01 09:51:58 +00:00
Torkel Ödegaard
3991be4c1d Search: Fixes searching by current folder when opened by clicking dashboard folder name (#57716)
* Search: Read from url on mount no on app boot

* Fixed tests

* Remove unused type
2022-11-01 10:11:42 +01:00
Lion Ralfs
1f7c84f125 CloudWatch: Fix all-log-groups endpoint when called without logGroupNamePrefix (#57483) 2022-11-01 08:50:04 +01:00
Dimitris Sotirakis
1eaf7cbfc0 Add GCP_KEY to publish-grafanacom step (#57910) 2022-11-01 09:41:15 +02:00
Leon Sorokin
45234e76eb TimeSeries: Render null-bounded points at data edges (#57798) 2022-10-31 17:50:43 -05:00
Leon Sorokin
fbfd0fd51b BarChart: Fix stacked hover (#57711) 2022-10-31 16:48:21 -05:00
Christopher Moyer
6aa3003a54 removes CTAs (#57931) 2022-10-31 16:24:51 -05:00
juanicabanas
48120f2594 PublicDashboards: Delete public dashboard in public dashboard table (#57766)
PublicDashboards: delete button added in public dashboard table in order to delete a public dashboard.

Co-authored-by: Jeff Levin <jeff@levinology.com>
2022-10-31 17:16:07 -04:00
Ryan McKinley
6e3a6cce61 Storage: move http wrapper into its own subpackage (#57929) 2022-10-31 13:37:05 -07:00
Gilles De Mey
6d2dced218 Alerting: fix filtering in notification policies (#57824) 2022-10-31 13:11:29 -04:00
George Robinson
b0a927b138 Alerting: Add debug logs in validateAndGetPrefix (#57002) 2022-10-31 16:40:28 +00:00
Alexander Weaver
0dfd78c88c Attempt to preserve UID from migrated channel (#57639) 2022-10-31 11:29:07 -05:00
renovate[bot]
96c3a8339e Update dependency @leeoniya/ufuzzy to v0.8.0 (#57894)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-31 09:45:46 -06:00
Ryan McKinley
9149544086 Store: Add SQL tables for SQL based object store (dev mode only) (#57785) 2022-10-31 11:28:19 -04:00
Jo
07991c76fe Doc: Fix wrong default callback URL (#57908)
* doc: fix wrong default callback URL

* doc: fix gitlab typos
2022-10-31 16:13:27 +01:00
Konrad Lalik
a59dc8b7ad Alerting: Query time logging (#57585) 2022-10-31 15:55:47 +01:00
Ieva
5c1a1c8318 change json command parameter names from userID to userId and teamID to teamId (#57902) 2022-10-31 14:32:28 +00:00
Ryan McKinley
3527cad9dc Store: protobuf based GRN/identifier (#57714) 2022-10-31 07:26:16 -07:00
Ezequiel Victorero
46093c1267 PublicDashboards: do not return errors when resource not found from store layer (#57838) 2022-10-31 11:22:27 -03:00
Torkel Ödegaard
f0ab4bea8c Scene: SceneObject and SceneObjectBase refinements and stricter typing (#57851) 2022-10-31 15:16:16 +01:00
Joan López de la Franca Beltran
0864994bcb Docs: Update Auditing docs (#57867)
* Docs: Update Auditing docs

* Update docs/sources/setup-grafana/configure-grafana/enterprise-configuration/index.md

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
2022-10-31 14:53:46 +01:00
Andres Martinez Gotor
9391a8ab9b Google Cloud Monitoring: Set frame interval to draw null values (#57768) 2022-10-31 14:48:32 +01:00
Sonia Aguilar
30cb04f205 Alerting: move alert rule View/Edit/Delete action buttons to collapsed row (#57687)
* Move view edit and delete buttons to RulesTable

* Move tests for edit and delete buttons to a new test file for RulesTable

* Action buttons: Only show icon for non large screens, and add a Tooltip

* Remove buttons moved from the RuleDetailsActionButtons component

* Fix horizontal aligment for icons for non large devices
2022-10-31 14:42:09 +01:00
Andres Martinez Gotor
ce38840f29 Google Cloud Monitoring: Ensure selectors fit in the screen (#57817) 2022-10-31 12:52:25 +01:00
Ieva
2546437e20 add an endpoint for updating several managed permissions with one call (#57893) 2022-10-31 11:46:58 +00:00
Josh Hunt
fd5c147574 Chore: Update footer changelog link to github (#57871) 2022-10-31 07:34:21 -04:00
renovate[bot]
2417b9151c Update dependency @cypress/webpack-preprocessor to v5.15.0 (#57873)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-31 11:28:39 +00:00
xiyu95
77be89eb1c Tempo: Fix dropdown issue on tag field focus (#57616) 2022-10-31 11:35:38 +01:00
Ieva
7e62352aea Access Control: documentation for RBAC provisioning with Terraform (#57747)
* add docs for RBAC provisioning with Terraform

* remove unnecessary bit

* shuffle the structure around, as docs can't go more than four levels deep

* Update index.md

* Update index.md
2022-10-31 06:32:32 -04:00
Erik Sundell
92ed9a4f2f CloudWatch: Fix broken test (#57879)
* mock date.now

* fix broken test
2022-10-31 06:26:43 -04:00
Torkel Ödegaard
19b961465c TopNav: Make it possible to to have sections without children (#57815) 2022-10-31 11:01:34 +01:00
renovate[bot]
656f159ae9 Update babel monorepo (#57665)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-31 09:25:01 +00:00
Karl Persson
052d1426f9 Oauth: Display friendly error message when role_attribute_strict=true and no valid role found (#57818)
* Oauth: change error type to a struct that unwraps into a social error

* Oauth: Handle empty role in error and fix unwrap

* Oauth: provide more informatio in error

* Oauth: return InvalidBasicRoleError

* Oauth: Fix tests

* Login: Remove casing

* Oath: Change to warning logs
2022-10-31 09:11:31 +01:00
Joe Blubaugh
89d917b196 Docs: Add information about DB version support to upgrade guide. (#57643)
In v9.2 Grafana added an official DB version support policy. That change
is now noted in the upgrade guide.
2022-10-31 15:23:51 +08:00
Jo
61774ae7f1 Docs: Add keycloak oauth setup guide (#57685)
* use scopes for generic_oauth devenv. Support refresh_tokens

* add keycloak section

* add teamsync support to oauth devenv

* Add keycloak guide

* Upgrade keycloak to version 19

* Update devenv/docker/blocks/auth/oauth/readme.md

Co-authored-by: Misi <mgyongyosi@users.noreply.github.com>

* feedback

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>

Co-authored-by: Misi <mgyongyosi@users.noreply.github.com>
Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
2022-10-28 17:57:56 -04:00
Karl Persson
1cc6dde836 GenericOauth: Only fetch user data from api if api_url is configured (#57827) 2022-10-28 21:44:09 +00:00
Virginia Cepeda
c73b499ec5 [Alerting] Avoid invalid characters in copied rule expression (#57839)
* Avoid copying UTF8 BOM chars in rule expression

* Add comment
2022-10-28 15:40:55 -03:00
idafurjes
d7bee33398 Add implementation for Create and GetParents of foder store (#57829)
* Add Move implementation

* Remove Move from store

* Add Create and GetParents implementation for folder store
2022-10-28 20:07:25 +02:00
Esteban Beltran
4abf4d90b4 Toolkit: Deprecate plugin:github-publish command (#57726)
* Toolkit: Deprecate `plugin:github-publish` command

* Remove wrong console log message

* Update link to recommended workflows
2022-10-28 19:44:59 +02:00
Adela Almasan
a5c492b033 Canvas: Add tabs to inline editor (#57778) 2022-10-28 13:36:19 -04:00
Yuriy Tseretyan
3294918e9f Alerting: Update state manager to support nil stores and metrics (#57791) 2022-10-28 13:10:28 -04:00
Yuriy Tseretyan
d848cc629b Alerting: Refactor rule interval validation to be reusable (#57792) 2022-10-28 14:40:11 +00:00
kay delaney
e4d1d8d70c Dashboards: Add workaround for react-grid-layout rearrange bug (#57832) 2022-10-28 15:36:37 +01:00
Yuriy Tseretyan
fa043efb2c Fix: correctly close trace span in Prometheus and Loki data sources (#57774)
* rename span for loki
2022-10-28 10:17:56 -04:00
Kyle Brandt
6126f56ef0 Prometheus: Do not drop errors in streaming parser (#57698)
- Fixes #57692
- and also takes care of #42776 when using the streaming parser, not an ideal fix for #42776 but makes explore work better I think. https://github.com/grafana/grafana/issues/57365 might be a better longer term solution
2022-10-28 10:11:06 -04:00
Shirley
c2e9e797b3 CloudWatch: fix non-deterministic test (#57831) 2022-10-28 10:05:55 -04:00
idafurjes
6b483a8dca Add implementation for folder store methods (#57700)
* Add implementation for folder store methods

* Add Move implementation

* Add back comment and fix query

* Remove Move from store

* Adjust GetChildren

* Fix errutil error declaration and usage

* Add org id to get children query
2022-10-28 15:35:49 +02:00
Kyle Brandt
2cd9cbd359 Prometheus: Chore - Remove incorrect FrameType from exemplar frame (#57695) 2022-10-28 09:15:01 -04:00
Kristin Laemmert
6a6fdbc1f9 chore: updates to the new folder model (#57776) 2022-10-28 08:23:39 -04:00
Christopher Moyer
b9a0576638 docs: Refactors remaining enterprise topics, corrects relrefs (#57707)
* moves topics, correct relrefs

* Update docs/sources/dashboards/create-reports/index.md

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

* Update docs/sources/administration/data-source-management/index.md

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-security/audit-grafana.md

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-security/configure-request-security.md

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

* Update docs/sources/setup-grafana/configure-security/configure-team-sync.md

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

* Update docs/sources/administration/data-source-management/index.md

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

* Update docs/sources/dashboards/create-reports/index.md

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

* Update docs/sources/dashboards/create-reports/index.md

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

* Update docs/sources/administration/recorded-queries/index.md

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

* Update docs/sources/dashboards/create-reports/index.md

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

* Update docs/sources/dashboards/create-reports/index.md

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

* Update docs/sources/dashboards/create-reports/index.md

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

* Update docs/sources/dashboards/create-reports/index.md

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

* Update docs/sources/dashboards/create-reports/index.md

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

* Update docs/sources/dashboards/create-reports/index.md

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

* Update docs/sources/dashboards/create-reports/index.md

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

* removes link that goes nowhere

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>
2022-10-28 07:13:40 -05:00
brendamuir
f34dd29ac4 Docs: adds view notification errors topic (#57820) 2022-10-28 12:44:23 +01:00
Armand Grillet
ee7adc081b Remove Sensu from docs (#57812)
We do not support Sensu in Grafana Alerting, only Sensu Go.
2022-10-28 12:40:46 +01:00
Andrej Ocenas
0845ac2f53 Profiling: Add Phlare and Parca datasources (#57809)
* Add phlare datasource

* Rename

* Add parca

* Add self field to parca

* Make sure phlare works with add to dashboard flow

* Add profiling category and hide behind feature flag

* Update description and logos

* Update phlare icon

* Cleanup logging

* Clean up logging

* Fix for shift+enter

* onRunQuery to set label

* Update type naming

* Fix lint

* Fix test and quality issues

Co-authored-by: Joey Tawadrous <joey.tawadrous@grafana.com>
2022-10-28 13:33:37 +02:00
brendamuir
1d53a6f57e Docs: Change GA to Alerting (#57811)
* Docs: Change GA to Alerting

* typos
2022-10-28 10:28:02 +01:00
Kevin Minehart
fd16cad7da Only provide version ot build-frontend-packages if it's a valid semver (has 2 digits) (#57808) 2022-10-28 05:04:59 -04:00
brendamuir
5edd511461 Docs: fixes alerting links (#57805)
* Docs: fixes alerting links

* fixes grafana relrefs to alerting

* changing GA to Alerting
2022-10-28 10:01:43 +01:00
brendamuir
f9d2801249 Docs: alerting refactor (#57804)
* Docs: alerting refactor

* fixes broken relrefs
2022-10-28 09:58:39 +02:00
Victor Marin
953fdfe76f TimeseriesPanel: Fill below to override works with name override (#57728) 2022-10-28 09:27:54 +03:00
Jeff Levin
bf672f960a public dashboards: rename api functions (#57789)
This PR imposes better naming conventions on public dashboards api

* rename api functions and remove use of _config_ noun

* fix tests

Co-authored-by: Ezequiel Victorero <ezequiel.victorero@grafana.com>
2022-10-27 17:08:11 -08:00
Jeff Levin
6b7d6fe0cb public dashboards: rename route paths (#57787)
This PR fixes the naming of routes for public dashboards to be more accurate and descriptive.

Co-authored-by: Ezequiel Victorero <ezequiel.victorero@grafana.com>
2022-10-27 14:41:56 -08:00
Leon Sorokin
7d020d3f6e Candlestick: Maintain candle width at different display resolutions (#57709) 2022-10-27 17:36:59 -05:00
Drew Slobodnjak
cf4c0a5db4 Canvas: Minor fixes for canvas gdev dashboard (#57781) 2022-10-27 15:02:40 -07:00
Alex Moreno
c08c14f8dd Alerting: Add custom title to pushover contact point (#57530)
* Add custom title to pushover contact point

* Update pkg/services/ngalert/notifier/channels/pushover.go

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>

* Use simplejson

* Use more verbose variable names

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>
2022-10-27 19:07:01 +02:00
Will Browne
9f77bd4728 Plugins: Use public store instead of internal registry (#57631)
* Plugins: Use public store instead of internal registry

* update comments

* fix import

* fix test
2022-10-27 18:44:28 +02:00
Yuriy Tseretyan
facf2b1ee8 Chore: Update prometheus, loki, graphite and influx plugins to support contextual logs. (#57708) 2022-10-27 12:05:06 -04:00
yinjialu
9aac0d32f9 Prometheus: fix Raw query is not updated when label op change. (#57492) (#57493) 2022-10-27 18:00:14 +02:00
Selene
bff9671b81 Rendering: Check timeout error when the request failed (#57654)
* Check timeout error when the request failed

* Update error and check

* Uses errors.As to fix the lint
2022-10-27 17:27:03 +02:00
Gilles De Mey
2a36301817 Alerting: Fall back to "range" query type for unified alerting when "both" is specified (#57288) 2022-10-27 17:22:23 +02:00
Artur Wierzbicki
616db7f68b Storage: k6 tests (#57496)
* object store k6

* update script

* refactor

* rename scripts

* fix paths

* fixes

* fix client - check connected state

* add teardown timeout

* rename to grpc object store client

* fail if health check fails

* abort rather than fail

* stale import

* create `run.sh`

* adjust for dummy server

* fix mkdir

* clean up dependencies

* remove name and version

* bring back name and version!

* remove clean webpackk plugin

* remove copy plugin

* update yarn lock

* remove stale import

* update yarn lock

* move perf tests to devenv/docker/loadtest-ts

* add codeownres
2022-10-27 23:22:04 +08:00
Alex Moreno
10fdfa8583 Alerting: Change handling of settings to pagerduty contact point (#57524)
* Add custom title to pagerduty contact point

* Fix tests by saving decrypted key

* Use simplejson
2022-10-27 16:20:10 +02:00
Alex Moreno
f8d12af021 Add custom title to googlechet contact point (#57517)
* Add custom title to googlechet contact point

* Update pkg/services/ngalert/notifier/channels/googlechat.go

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>

* Use simplejson

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>
2022-10-27 16:19:48 +02:00
Sofia Papagiannaki
40a59c2793 Chore: Update developer guide for running integration tests (#57758) 2022-10-27 17:18:20 +03:00
Alex Moreno
3d437117ad Alerting: Add custom title to discord contact point (#57506)
* Add custom title to discord contact point

* Update pkg/services/ngalert/notifier/channels/discord.go

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>

* Use simplejson

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>
2022-10-27 16:17:18 +02:00
Alex Moreno
1ab0af1eb2 Alerting: Add custom title to DingDing contact point (#57498)
* Add custom title to DingDing contact point

* Update pkg/services/ngalert/notifier/channels_config/available_channels.go

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>

* Update pkg/services/ngalert/notifier/channels/dingding.go

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>

* Add error checking before URL templating

* Remove comment

* Use simplejson

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>
2022-10-27 16:16:36 +02:00
Alex Moreno
fb62660df7 Alerting: Add title and description to VictorOps contact point (#57458)
* Add title and description to VictorOps contact point

* Update pkg/services/ngalert/notifier/channels_config/available_channels.go

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>
2022-10-27 16:12:14 +02:00
Alex Moreno
73a9e2a115 Add title and description to Threema contact point (#57429) 2022-10-27 16:11:38 +02:00
Jo
cae900c6f9 fix GF_AUTH_JWT_URL_LOGIN not working (#57689) 2022-10-27 15:57:01 +02:00
Gabriel MABILLE
4d380978d3 Fix: Unlock new button based on user permissions (#57733) 2022-10-27 15:48:07 +02:00
Alex Moreno
6839154720 Alerting: Add missing custom title and description to Line contact point (#57388)
* Add title and description to Line receiver

* Fix labal names for LINE contact point
2022-10-27 15:27:04 +02:00
Alex Moreno
1dcc432537 Alerting: Add missing custom title and description fields in Kafka contact point (#57361)
* Add description and details to Kafka notifier

* Fixed testing and add new logic testing

* Add proper description to kafka contact point UI

* Update pkg/services/ngalert/notifier/channels_config/available_channels.go

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>

* Update pkg/services/ngalert/notifier/channels_config/available_channels.go

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>

Co-authored-by: Santiago <santiagohernandez.1997@gmail.com>
2022-10-27 15:25:54 +02:00
Esteban Beltran
91ee5fec14 Toolkit: Deprecate plugin:update-circleci command (#57743) 2022-10-27 15:05:32 +02:00
brendamuir
998093a280 Docs: more refactoring for alerting (#57741)
* docs: more refactoring alerting

* performance limitations

* typo

* fix relrefs
2022-10-27 13:21:02 +01:00
Shirley
96beb3a3f1 Cloudwatch: refactor parsing metric data queries (#57624) 2022-10-27 14:10:49 +02:00
Esteban Beltran
b4633fc516 Toolkit: Deprecate plugin:bundle-managed command and move its functionality to a bash script. (#57719)
* Toolkit: Deprecate `plugin:bundle-managed` command

* Replace yarn script with bash command
2022-10-27 13:15:45 +02:00
Gareth Dawson
8b44ca1b0c Loki: Add devenv dashboard (#57519)
* Add loki devenv dashboard

* remove dashboard auto refresh

* set time range to 5m for timeseries graph

* add adhoc filters

* override with new export

* Chore: run stripnulls script

Co-authored-by: Matias Chomicki <matyax@gmail.com>
2022-10-27 12:07:20 +01:00
brendamuir
279ac50d59 Docs: refactors notifications in alerting (#57734)
* Refactors noticifacations section

* adds hover over error icon detail
2022-10-27 11:19:03 +01:00
idafurjes
50fb47dba0 Chore: Remove methods from sqlstore (#57545)
* Remove methods from sqlstore

* Remove commented out code

* Remove GetUserById from tests

* Adjust fake for get user profile

* Adjust test

* Adjust go mod files

* Try fix test

* Test adjustment

* Adjust test 2

* Remove commented out code
2022-10-27 11:44:09 +02:00
Pepe Fagoaga
1340c2c358 docs(config): Include admin_email documentation (#55789) 2022-10-27 10:15:14 +02:00
Artur Wierzbicki
1df8a85a42 Search: load dashboard performance improvements (#57509)
* fix windows storage init

* fixxx

* close session asap

* fix span end

* error handling

* add comment

* simplify

* simplify

* fix limit

* pass readDashboardCtx to summary builder

* add string slice validation
2022-10-27 14:52:42 +08:00
Santiago
cdb5d4230a Alerting: Fix "Not Implemented" responses (#57710)
* fix swagger spec, return 404 instead of 501 when an endpoint does not exist

* update number of paths in authorization_test.go
2022-10-26 23:35:52 -03:00
Yuriy Tseretyan
0a4121cef8 Alerting: Contextual log provider for rule key (#57476)
* create contextual log context provider
* use contextual provider in scheduler
* init logger in the package
* use context for log context
* use context in state manager
2022-10-26 19:16:02 -04:00
Brendan O'Handley
59ffd9571e Transformations : Add partition by values to transformation docs (#57697)
* add partition by values to tranformation docs

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* include leon's suggestions

* include leon's suggestions

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

* Update docs/sources/panels-visualizations/query-transform-data/transform-data/index.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>
Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
2022-10-26 19:01:45 -04:00
Ryan McKinley
7346280316 LibraryPanels: Load library panels in the frontend rather than the backend (#50560)
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-10-26 15:38:20 -07:00
Garrett Guillotte
0db946977b Docs: Reassign docs ownership (#57701) 2022-10-26 15:20:25 -07:00
Yuriy Tseretyan
2d20c8db7b Chore: Expression engine to support relative time range (#57474)
* make TimeRange interface and add relative range
* make Execute methods support the current time
* update resample to support relative time range
* update DSNode to support relative time range
* update query service to create queries with absolute time
* make alerting evaluator create relative time ranges
2022-10-26 16:13:58 -04:00
brendamuir
596b4fecb0 Docs: Refactors notifications in alerting (#57653)
* Refactors notifications in alerting

* Fixes broken links

* adds headings

* fixes broken links

* Adds line space and intro sentences
2022-10-26 19:07:49 +01:00
Ezequiel Victorero
7b819284c1 PublicDashboards: use orgId when querying dashboards (#57696) 2022-10-26 14:49:43 -03:00
Kyle Brandt
dfdc9bcbc1 Docs: (Whats new 9.2) Prom Stream Parser (#57603)
* Docs: (Whats new 9.2) Prom Stream Parser

* Update docs/sources/whatsnew/whats-new-in-v9-2.md

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>
2022-10-26 12:37:27 -04:00
Ezequiel Victorero
fe9c0c881e PublicDashboards: remove function with business logic from database layer and use it at service layer (#57684) 2022-10-26 12:53:33 -03:00
Kristin Laemmert
6c982e5b71 some file moving and struct renaming (#57686) 2022-10-26 11:52:01 -04:00
Selene
8917bd57e6 Clarify that audit logs are generated only for API requests (#57521) 2022-10-26 17:08:21 +02:00
Emil Tullstedt
1e2b7c5368 Errors: Add HTTP writer for errutil.Error (#57661) 2022-10-26 16:57:53 +02:00
kay delaney
05872283b5 ServiceAccounts: Wrap ServiceAccountPage route in dynamic import (#57669) 2022-10-26 15:54:28 +01:00
Kristin Laemmert
b346ae0310 feat: add new Folder table migration & define nested folder interfaces (#56882)
* feat: add new Folder table migration

Add a new folder table to support the Nested Folders feature.

https://github.com/grafana/grafana/issues/56880

* register nested folders feature flag (unused)

* feat: nested folder service (experiment)

This commit adds a NestedFolderSvc interface and stubbed out implementation as an alternative to the existing folder service. This is an experimental feature to try out different methods for backwards compatibility and parallelization, so that Grafana can continue to store folders in the existing (non-nested) manner while also using the new nested folder service.

Eventually the new service will (hopefully) become _the_ service, at which point the legacy service can be deprecated (or remain, with the new service methods replacing the original. whatever makes sense at the time).


* nested folders: don't run the new migration

This commit removes the nested folder migration from the list of active migrations so we can merge this branch and continue development without impacting Grafana instances built off main.
2022-10-26 10:15:14 -04:00
Erik Sundell
237ff2699d CloudWatch: Refactor metrics resource request frontend (#57602)
* refactor metric resource request frontend

* remove dupe interface
2022-10-26 15:59:26 +02:00
Erik Sundell
94aa090fb0 Cloudwatch: Refactor namespaces resource request (#57590)
* add route tests

* remove not used method

* pr feedback

* change variable name
2022-10-26 15:54:23 +02:00
Matias Chomicki
c8689fd591 Loki Monaco Editor: grab operator documentation from the operations module (#57525)
* feat(loki-operations): add method to resolve operation docs

* feat(loki-operations): read operation and strip markdown links

* feat(loki-monaco-editor): read parser docs from operations

* feat(loki-monaco-editor): grab docs for more operations

* Chore: update completions test

* Chore: add tests for the operations module

* Chore: fix typo

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

* Chore: fix typo

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

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2022-10-26 15:44:44 +02:00
juanicabanas
e81ce1dae7 PublicDashboards: Fix GET public dashboard that doesn't match
PublicDashboards: Fix GET public dashboard that doesn't match
2022-10-26 09:25:24 -04:00
kay delaney
05ceff5188 Chore: Migrate usage of v1 themes to v2 (#57617) 2022-10-26 13:28:12 +01:00
Jo
77437f2c89 Add multi-auth devenv (#57609)
* add authentik devenv

* remove direct dependency on spew

* use cn

* add authentik instructions

* add backup instructions
2022-10-26 13:46:50 +02:00
Ieva
92531c5596 move data source permission model to enterprise repo (#57615) 2022-10-26 11:49:45 +01:00
Esteban Beltran
987d4fd459 Toolkit: Deprecate and replace toolkit:build with plain yarn scripts (#57620)
* Toolkit: Deprecate and replace toolkit:build with plain yarn scripts

* Remove "generated" from copied files in the script
2022-10-26 10:11:15 +02:00
Esteban Beltran
cbe7fe3d8d Toolkit: Deprecate searchTestData command (#57589) 2022-10-26 08:54:51 +02:00
Ryan McKinley
a3acfb1a48 Chore: Register a feature flag for "newDBLibrary" (#57468) 2022-10-25 18:20:41 -07:00
Ezequiel Victorero
860380d893 PublicDashboards: refactor following naming convention for services (#57625) 2022-10-25 21:40:42 -03:00
Michael Mandrus
5879805e4b PublicDashboards: Fix unsafe code snippets (#57641)
* return an error if we can't extract queries from a panel

* check for null or undefined
2022-10-25 20:16:10 -04:00
Ryan McKinley
e6575bab76 Playlist: allow using object store as the backend (#57467) 2022-10-25 16:51:01 -07:00
Artur Wierzbicki
6abd4cd8e8 Chore: pointerify dummy server (#57640) 2022-10-25 19:27:31 -04:00
owensmallwood
b5f1876ba3 PublicDashboards: Update docs with supported datasources (#57629)
Updates public dashboards docs with compatible datasources
2022-10-25 17:06:02 -06:00
kay delaney
b49713d323 Chore: Remove unused files (#57515) 2022-10-25 23:34:53 +01:00
Beto Muniz
069a4cb21b Fix orderFieldsTransformer sorting (#57635) 2022-10-25 17:48:14 -03:00
Ezequiel Victorero
c5e420a94c PublicDashboards: move methods from store to service (#57599) 2022-10-25 16:29:18 -03:00
Galen Kistler
c27aac0d38 Prometheus query builder: Replace select with AsyncSelect to support high cardinality prometheus instances (#57300)
* Replace current select with AsyncSelect component to facilitate autocomplete via prometheus server instead of client application
Co-authored-by: Kyle Brandt <kyle@grafana.com>
2022-10-25 13:05:21 -05:00
Andrej Ocenas
82d79780d8 Flamegraph: Fix vertical offset (#57618) 2022-10-25 17:55:49 +02:00
Gilles De Mey
8788f7d2d8 Alerting: Always allow configuring AM configuration (#57522) 2022-10-25 16:52:11 +02:00
Gilles De Mey
7414ba7279 Expressions: make reduce inputs compacter (#56404) 2022-10-25 16:28:11 +02:00
Shirley
76a3a1eda7 CloudWatch: migrate tests to metrics data query request parsing level, add tests (#57431) 2022-10-25 15:53:54 +02:00
Virginia Cepeda
9eae793b5d Alerting: Remove the alert manager selection from the data source configuration (#57369)
* Remove alertmanager dropdown from datasource config

* Avoid sending alertmanagers from loki/prom config editors

* Add test

* Remove unneeded param
2022-10-25 10:53:20 -03:00
Artur Wierzbicki
a63c529ad1 Chore: add query_retries=3 to querylibrary_integration_test.go (#57607) 2022-10-25 09:52:56 -04:00
Matias Chomicki
cc820062c6 Chore: update latest.json to 9.2.2 (#57608) 2022-10-25 13:39:23 +00:00
brendamuir
58b15f3e54 Adds information on what's new label to PR template (#57594) 2022-10-25 14:25:41 +01:00
Kristin Laemmert
225ed4cc0a GRN parsing service (#56750)
* GRN parsing service
* move GRN package into infra and update fields
* remove orgID from GRNs (collapse into tenantID)
2022-10-25 09:07:24 -04:00
Erik Sundell
5daa87d7a1 Cloudwatch: Remove unused code (#57593)
* remove not used code and refactor check health

* fix broken test

* remove not used variable
2022-10-25 15:03:51 +02:00
Esteban Beltran
8d42e1b169 Toolkit: Deprecate node-version-check command (#57591)
* Toolkit: Deprecate node-version-check command

* Do not check for nodejs version on frontend-test
2022-10-25 14:53:53 +02:00
Grot (@grafanabot)
f64b0e1fae Changelog: Updated changelog for 9.2.2 (#57601) 2022-10-25 14:36:46 +02:00
Erik Sundell
4c654ddb76 Cloudwatch: Refactor metrics resource request (#57424)
* refactor metrics request

* Update pkg/tsdb/cloudwatch/routes/dimension_keys_test.go

Co-authored-by: Shirley <4163034+fridgepoet@users.noreply.github.com>

* return metric struct value intead of pointer

* make it possible to test hard coded metrics service

* test all paths in route

* fix broken test

* fix one more broken test

* add integration test

Co-authored-by: Shirley <4163034+fridgepoet@users.noreply.github.com>
2022-10-25 14:00:54 +02:00
Todd Treece
53d7404e2b Chore: Add appcontext.WithUser and appcontext.User (#57534) 2022-10-25 07:51:24 -04:00
sh0rez
beaaabd770 live: explicitely reply with http 200 (#57428)
`pkg/web` triggers a panic when a http handler chain does not return any
response to the client.
This has been put in place, because it usually means a middleware along
the way did not call the next one.

In this specific case however, the handlers meant to return 200, but did
not do so explicitely, instead relying on the default behavior of `net/http`
2022-10-25 11:45:54 +02:00
Jack Westbrook
588e64d9f5 Chore: Fix vulnerabilities in webpack loader-utils (#57533)
* chore: remove unused webpack loaders from core and toolkit

* chore: refresh yarn.lock file

* chore(yarn): refresh lock file for loader-utils update to 2.0.3

* chore: force ngtemplate-loader to use loader-utils@2.0.3

* chore(e2e): bump ts-loader@8.4.0 for loader-utils@2.0.3

* chore(yarn): remove unused packageExtensions

* chore(storybook): force unused webpack deps to v5. force plugins and loaders for loader-utils@2.0.3

* chore(storybook): update config for type changes from webpack v4 to v5
2022-10-25 11:37:41 +02:00
Joey Tawadrous
8f75ec4007 Flame Graph: Exact search (#56769)
* Use exact match

* Create searchable FlameGraphPanel.tsx
2022-10-25 10:24:27 +01:00
Karl Persson
7386f8652c RBAC: Improve performance of dashboard filter query (#56813)
* RBAC: Move UserRolesFilter to domain package

* Dashboard Permissions: Rewrite rbac filter to check access in sql

* RBAC: Add break when wildcard is found

* RBAC: Add tests for dashboard filter

* RBAC: Update tests

* RBAC: Cover more test cases

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
2022-10-25 11:14:27 +02:00
Ashley Harrison
d2a70bc42d Chore: more any/type assertion improvements (#57450)
* more friday any/type assertion improvements

* Apply suggestions from code review

Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>

* Update public/app/angular/promiseToDigest.test.ts

Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>

Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>
2022-10-25 11:04:35 +02:00
Erik Sundell
8adbacb18e Cloudwatch: Refactor datasource instance factory method (#57452)
* wip

* fix broken test
2022-10-25 09:52:12 +02:00
Joey Tawadrous
d9a6c3f398 FlameGraph: Add newly designed flame graph icon (#57514)
* Add newly designed flame graph icon

* Update expectedListResponse
2022-10-25 07:18:17 +01:00
Victor Marin
c30716a073 TablePanel: Fix updating footer values on data change (#57518)
* TablePanel: Fix updating footer values on data change

* tests
2022-10-25 08:32:16 +03:00
Artur Wierzbicki
e485ddd13d Store: don't marshall/unmarshall the dashboard when building a summary (#57520)
* dont pretty print the dashboard

* stop marshalling the dashboard

* do not sanitize for searchV2

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-10-25 09:39:17 +08:00
Artur Wierzbicki
749b3b6263 Storage: Fix initialization on windows (#57504) 2022-10-25 09:27:22 +08:00
Nathan Marrs
9d857f4d61 Canvas: Improve resource picker initialization (#57319) 2022-10-24 13:40:28 -07:00
Ryan McKinley
37b011d79e Annotations: Disable "Add annotation" button when annotations are disabled (#57481) 2022-10-24 13:24:33 -07:00
Galen Kistler
e59ddd6bc5 Revert "Revert "Prometheus: Provide label values match parameter API when supported prometheus instance is configured (#56510)" (#57551)" (#57553)
This reverts commit e7671bf909.
2022-10-24 15:02:15 -05:00
Galen Kistler
f93c3acc51 Prometheus: Flavor/version configuration (#57554)
* Revert "Revert "Prometheus: Type and flavor configuration (#56496)" (#57552)"
This reverts commit 2432ce619a.
* Adds new fields and documentation for Prometheus datasource configuration: prometheus type, and version
2022-10-24 14:53:11 -05:00
Guilherme Caulada
cfd9e72da5 Add dashboards to the navtree on public dashboards (#57542) 2022-10-24 16:34:27 -03:00
Erik Sundell
c23a7bdcf8 refactoring dimension values frontend req (#57475) 2022-10-24 20:45:02 +02:00
Joan López de la Franca Beltran
5d18b41857 Docs: Database encryption corrections (#57503)
* Docs: Database encryption corrections

* Fix relref links

* Additional corrections
2022-10-24 20:07:32 +02:00
Galen Kistler
2432ce619a Revert "Prometheus: Type and flavor configuration (#56496)" (#57552)
This reverts commit 7ecbc98b3e.
2022-10-24 12:33:11 -05:00
Galen Kistler
e7671bf909 Revert "Prometheus: Provide label values match parameter API when supported prometheus instance is configured (#56510)" (#57551)
This reverts commit 3cbbf706cf.
2022-10-24 11:56:49 -05:00
brendamuir
e48fac9d91 Proposal for PR template text (#57267)
* Proposal for PR template text

* adds full stop
2022-10-24 16:51:26 +01:00
Zoltán Bedi
c0b778134e Revert: Query editor components from grafana-ui (#57436)
* Revert: QueryEditor components from grafana-ui

* Use local version of experimental

* Use experimental for query editor components

* Fix type issues in MSSQL

* point to actual version of experimental package

* point to latest version of experimental

Co-authored-by: Erik Sundell <erik.sundell87@gmail.com>
2022-10-24 17:12:36 +02:00
Galen Kistler
3cbbf706cf Prometheus: Provide label values match parameter API when supported prometheus instance is configured (#56510)
Provide label values API with match parameter when prometheus datasource has configured supported prometheus type and version
2022-10-24 09:47:35 -05:00
Ivana Huckova
3d7439d97d Loki: Fix input history (#57344) 2022-10-24 16:27:56 +02:00
Galen Kistler
7ecbc98b3e Prometheus: Type and flavor configuration (#56496)
* Adding two new fields to the data JSON in the prometheus datasource configuration: prometheusType, and prometheusVersion.
* Version field will attempt to auto-detect via buildinfo API when prometheus Type is selected
2022-10-24 09:26:32 -05:00
Gábor Farkas
8d0e24a622 explore: fix filtering logs-data in table-display (#57356) 2022-10-24 14:18:56 +00:00
Erik Sundell
017da781cf Cloudwatch: Refactor dimension values resource request (#57346)
* refactor dimension values backend

* fix test file name
2022-10-24 15:04:25 +02:00
Shirley
9ebed91eed CloudWatch: Refactor to extract DataQuery grouping by region out of request parsing (#57392)
* CloudWatch: Extract request parsing grouping by region from ParseQueries

* Rename ParseQueries to ParseMetricDataQueries
2022-10-24 14:57:32 +02:00
idafurjes
1bda67ab11 Chore: Delete unused mocks (#57512)
* Chore: Delete unused mocks

* Add back used methods

* Add back used mocks 2

* Add back used mocks 3

* Add back used mocks 4

* Add back the alerting mocks

* Remove mock variables

* Add bacl needed mock var
2022-10-24 14:00:22 +02:00
Karl Persson
78c849ac29 RBAC: Fetch service account permissions in oss (#57343) 2022-10-24 12:11:59 +02:00
Eric Leijonmarck
924d6a82a3 add: postgresql as a database for resolving conflicts (#57466) 2022-10-24 10:59:26 +01:00
Andrej Ocenas
67aa99af78 NodeGraph: Fix rendering issues when values of arc are over 1 (#57460) 2022-10-24 11:28:49 +02:00
Yaelle Chaudy
6ee69853dc Datasource Config Editor: Add event-based funnel for measuring CVR (#55105)
* Added start event on adding new DS from datasources/new page

* Added end event + tests

* revert analytics.ts changes

* revert azure tracking changes

* changed version in doc

* update props name for consistency with plugin-platform PR to come

* Updated tests
2022-10-24 11:09:26 +02:00
Gabriel MABILLE
fce0a49284 LDAP: inline toml with devenv (#57499) 2022-10-24 11:01:58 +02:00
Armand Grillet
42871fcb2a Clarify notification policies. (#57465) 2022-10-24 09:46:04 +01:00
Joey Tawadrous
52dbd67a11 Node Graph: Always show context menu (#56876)
* Ensure context menu always appears

* Close the context menu after selecting the alternative layout

Co-authored-by: Hamas Shafiq <hamas.shafiq@grafana.com>
2022-10-24 09:14:42 +01:00
Adela Almasan
73c215ae41 Canvas: Button element (alpha) (#57491) 2022-10-23 20:39:10 -04:00
Artur Wierzbicki
6e3de8d016 gRPC Server: Fix logging unauthenticated request error (#57490) 2022-10-23 03:51:23 +08:00
ismail simsek
4053cbea38 Fix broken image links (#57480) 2022-10-22 09:15:45 -07:00
Leon Sorokin
0640eeef0a Number formatting: only 0-trim decimals in y axis ticks. omit currency, locale units. (#57386) 2022-10-21 21:35:29 -06:00
Leon Sorokin
45707ccf99 TimeSeries: fix negative stacked percent y-axis range (#57470) 2022-10-21 15:45:00 -06:00
Ezequiel Victorero
1f3d34ecda PublicDashboards: service and store methods rename (#57463) 2022-10-21 18:25:20 -03:00
Alexander Weaver
de46c1b002 Alerting: Improve logs in state manager and historian (#57374)
* Touch up log statements, fix casing, add and normalize contexts

* Dedicated logger for dashboard resolver

* Avoid injecting logger to historian

* More minor log touch-ups

* Dedicated logger for state manager

* Use rule context in annotation creator

* Rename base logger and avoid redundant contextual loggers
2022-10-21 16:16:51 -05:00
Ryan McKinley
910154c102 ObjectStore: Add folder to kind registry (#57461) 2022-10-21 16:48:32 -04:00
owensmallwood
0b8fb543fc Public Dashboards: Can toggle annotations in modal (#57312)
adds toggle for pubdash annotations
2022-10-21 13:42:14 -06:00
Zoltán Bedi
7f3b567657 TimeSeries: Fix stacking when first value is negative zero (#57257)
* TimeSeries: Fix stacking when first value is negative zero

* More test + refactor
2022-10-21 20:58:23 +02:00
Emil Tullstedt
2c9526fdf7 Docs: Update errors documentation (#57402)
Expand on what a base should represent and update some out of date info.
2022-10-21 20:50:29 +02:00
lean.dev
654db452cd Public Dashboards: Fixing annotations validations for public dashboards (#57455) 2022-10-21 12:06:39 -03:00
Hamas Shafiq
07ac388e8b Tempo: Update the query whenever the value of the TraceQL editor changes (#57199) 2022-10-21 16:01:53 +01:00
Kristina
5d7d54d076 Auth: Write the redirect cookie if denied - do not write a blank redirect (#57381)
* Write the redirect cookie if denied - do not write a blank redirect

* Remove redundant code, reverse polarity
2022-10-21 09:53:17 -05:00
bikashmishra100
98053cfde8 Tempo: Add start time and end time parameters while querying traces (#48068)
* Add start time and end time parameters while querying tempo traces

* Added configurable time shift to query by trace id

* Test that the URL is formatted correctly

* Added test to check for time shift

* Improved label and tooltip of new time shift settings

Co-authored-by: André Pereira <adrapereira@gmail.com>
2022-10-21 15:38:10 +01:00
Yuriy Tseretyan
245c1ee3d3 Chore: Add last downsampling function to Resample expression (#57379) 2022-10-21 10:03:43 -04:00
Sonia Aguilar
cd0e0fcc53 fix: add alerting enabled condition FOR adding alerting tab in folder view (#57434) 2022-10-21 15:32:59 +02:00
Sven Grossmann
842b629cd1 use inherited colors on svg (#57427) 2022-10-21 15:24:02 +02:00
Karl Persson
d55e5b8862 [main] Login email before username (#57400)
* Swap order of login fields

* Validate email field before validating the username field.

Co-authored-by: linoman <2051016+linoman@users.noreply.github.com>
2022-10-21 15:21:21 +02:00
Ashley Harrison
7e631e7239 A11y: Enable jsx-a11y/interactive-supports-focus (#57391)
* first batch of fixes for interactive-supports-focus

* remove role and aria attributes since this won't be focusable to a screenreader anyway
2022-10-21 13:52:46 +01:00
Beto Muniz
9fb6cdae8a Support resize Flux Query Editor (#57214) 2022-10-21 09:40:09 -03:00
Ezequiel Victorero
5b9959014c PublicDashboards: refactor service (#57372) 2022-10-21 09:37:38 -03:00
Victor Marin
f161c5407a OutsideRangePlugin: Exclude leading and trailing null values when checking limits (#57335)
* OutsideRangePlugin: Exclude null limit values from calculation

* refactor

* Update OutsideRangePlugin.tsx

Co-authored-by: Leon Sorokin <leeoniya@gmail.com>

Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
2022-10-21 08:33:21 -04:00
Marcus Efraimsson
6f8fcae01b [main] Plugin fixes (#57399)
* Plugins: Remove support for V1 manifests

* Plugins: Make proxy endpoints not leak sensitive HTTP headers

* Security: Fix do not forward login cookie in outgoing requests

(cherry picked from commit 4539c33fce)

Co-authored-by: Will Browne <wbrowne@users.noreply.github.com>
2022-10-21 13:54:55 +02:00
brendamuir
af17123b5f Docs: fixes silences typo (#57418) 2022-10-21 12:48:33 +01:00
Josh Hunt
e417387bc7 I18n: Add German (#57397) 2022-10-21 11:47:17 +01:00
Josh Hunt
fc75076b72 I18n: Show languages in local names (#57367)
* I18n: Show languages in local names

* fixed test
2022-10-21 05:29:03 -04:00
Konrad Lalik
5c710a5590 Alerting: Add Alertmanager choice warning (#55311) 2022-10-21 11:01:07 +02:00
Laura Fernández
e402a8f27d A11y: enable rule jsx-a11y/anchor-is-valid (#56690) 2022-10-21 09:13:32 +02:00
Leon Sorokin
7eac79b5f8 Number formatting: Strip trailing zeros after decimal point when decimals=auto (#57373) 2022-10-20 17:56:21 -05:00
Leon Sorokin
883d61d191 Transformers: PartitionByValues (#56767)
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-10-20 17:22:02 -05:00
Brendan O'Handley
60b14a2ec2 Opentsdb: Allow template variables for filter keys (#57226)
* allow template variables for filter keys

* add types to interpolate var function
2022-10-20 15:53:29 -05:00
Brendan O'Handley
c34c1d0cb4 Graphite: Never escape asPercent function params as string (#56593)
* handle asPercent func by never esc params as string

* add test and clean up
2022-10-20 15:49:40 -05:00
Adela Almasan
5128659d19 Canvas: Improve text element readability (#57371) 2022-10-20 15:01:28 -05:00
lean.dev
552d9d70eb PublicDashboards: Validate access token (#57298)
Adding validation for access token
2022-10-20 16:43:33 -03:00
Alexander Weaver
5ee4744d62 Alerting: Improve operational logs in sender package (#57134)
* Audit logs in sender package

* Fix casing and touch up a few key names

* Avoid logging entire alert struct

* Log configuration ID being applied

* Revert change to errorf rather than log

* Tune levels further and remove some redundancies

* Adjust logger naming and standardize log context

* Adjust logger naming in router

* Move log and get rid of dead error handling code
2022-10-20 14:19:04 -05:00
Yuriy Tseretyan
f3c219a980 Alerting: update format of logs in scheduler (#57302)
* Change the severity level of the log messages
2022-10-20 13:43:48 -04:00
Josh Hunt
8cebaf345d User: Fix externalUserId not being populated (#57341) 2022-10-20 18:12:53 +01:00
Sonia Aguilar
a61e044d00 Contact points tab: Remove error count in integrations details and show only Error label (#57325) 2022-10-20 18:24:32 +02:00
Sergey Kostrukov
47eb7f785d Use resource call query_result query (#57232) 2022-10-20 09:46:36 -05:00
Hamas Shafiq
84a5ced72a Tempo: Integrate TraceQL API (#56867) 2022-10-20 10:44:59 -04:00
Zoltán Bedi
0232927591 CODEOWNERS: Change owner for DateTimePickers (#57357)
Also remove @jessover9000 as she is not part of grafana anymore 😢
2022-10-20 16:32:48 +02:00
Guilherme Caulada
96a97f9827 Build: Add github release command to build/cmd (#56349)
* Add github release command to build/cmd

* Use go-github library and implement dry-run

* Make tag optional and default to metadata

* Fix minor bug with tag default

* Make some refactors to ease testing

* Add tests for publish github command

* Refactor publish github tests

* Refactor test helper function name

* Isolate local test
2022-10-20 11:11:53 -03:00
Josh Hunt
4b68918b0b I18n: Update crowdin config and codeowners (#57264)
* update config and codeowners for i18n

* update codeowners
2022-10-20 14:59:02 +01:00
mikkancso
a4e66a2a01 Connections: New "Connect data" page with data source catalog (#56772)
* remove Plugins and CloudIntegrations tab and add ConnectData tab

* ConnectData: add Search component and use it

* ConnectData: add DataSourcePluginList component

* add CardGrid component

* add CategoryHeader component

* ConnectData: restructure content

DataSourcePluginList is removed, because its responsibilities are
actually the same as ConnectData's responsibilities.

NoResults was added as a reusable component, and was moved out of
CardGrid, since there could be more CardGrid on one page, but only one
NoResults.

* fix spacer

* use LoadingPlaceholder

* CardGrid: add margin

* generalize CardGridProps

* move isLoading and error into CardGrid

We'd like CardGrid to be reusable, even multiple times within a page.
In this case, it's better UX if we show the loading or error states per
card grid, not for the whole page.

* ConnectData: fix NoResults condition

* fix and add meaningful tests

* fix indentation

* move isLoading and error back to ConnectData

* make `url` required for CardGrid items
2022-10-20 15:53:10 +02:00
Sriram
8b2d35bdb9 updated plugin-ci go dependency to 1.19.2 (#57200) 2022-10-20 14:50:22 +01:00
Joey Tawadrous
5e27a6f276 Flame Graph: Fix for dashboard scrolling (#56555)
* Flamegraph dash scrolling

* Separate scroll for top table and for flame graph

* Custom scroll behavior for explore vs vs dash etc and sticky flame graph header

* Final UI tweaks

* Update tests
2022-10-20 14:20:48 +01:00
Gabriel MABILLE
f184f9211c GoogleOAuth: Unlock UI (#57350) 2022-10-20 14:52:36 +02:00
Ivana Huckova
ef78f03a6f Loki: Fix the name of exported component from LokiQueryEditor.tsx (#57340)
* Loki: Fix editor

* Fix names
2022-10-20 14:49:55 +02:00
Grafana I18n Bot
060c804449 I18n: Crowdin sync (#57345)
* New translations grafana.json (French)

* New translations grafana.json (Spanish)

* New translations grafana.json (German)

* New translations grafana.json (Chinese Simplified)
2022-10-20 12:37:47 +00:00
Ashley Harrison
630c18d79d make border-radius part of the base styles so focus styles are consistent (#57353) 2022-10-20 13:34:14 +01:00
Timur Olzhabayev
66d2fe7d9d Fixing upload failure (#57290) 2022-10-20 14:18:33 +02:00
Leon Sorokin
79afad3888 StateTimeline: fix hover overlays when browser-zoomed (#57224) 2022-10-20 06:02:29 -06:00
Erik Sundell
b0c2ca6c1b Cloudwatch: Refactor dimension keys resource request (#57148)
* use new layered architecture in get dimension keys request

* go lint fixes

* pr feedback

* more pr feedback

* remove not used code

* refactor route middleware

* change signature

* add integration tests for the dimension keys route

* use request suffix instead of query

* use typed args also in frontend

* remove unused import

* harmonize naming

* fix merge conflict
2022-10-20 12:53:28 +02:00
Jo
7f3536a6d2 OAuth: Fix misleading warn log related to oauth and increase logged content (#57336)
* only emit warn log when sync is not skipped. Fix warn log that had wrong recommendation

* log presence of refresh token
2022-10-20 05:50:12 -04:00
Ivana Huckova
3ee450e66b Loki: Remove unused query editors (#57192)
* Loki: Remove not used query editors

* Move Loki editor to components and rename

* Update public/app/plugins/datasource/loki/components/LokiQueryEditorByApp.test.tsx

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

* Fix test

Co-authored-by: Matias Chomicki <matyax@gmail.com>
2022-10-20 11:46:48 +02:00
Shirley
cadc6088db CloudWatch: move QueryData input parsing types to separate package (#57165)
* CloudWatch: move parse request types separate package

* Move metric query constants, unexport metricDataQuery json decoding type

* Unexport isSearchExpression
2022-10-20 11:21:13 +02:00
brendamuir
ee6ff18122 Docs: fixes endpoint for mimir (#57330) 2022-10-20 09:39:19 +01:00
Gábor Farkas
e8cad52132 devenv: fix loki&elastic naming conflict (#57268) 2022-10-20 07:49:52 +00:00
Karl Persson
764d5b9929 RBAC: Cleaup team api rbac tests (#57265)
* RBAC: Remove the access control evaluator fake

* API: Change to use access control implementation instead of mocks with
rbac disabled in tests

* Tests: Set cfg and access control defaults after applying options

* Tests: Rewrite team legacy access control tests

* Tests: Add helper function to create user with permissions

* Tests: set fake quota service as default

* Team: Add ExpectedTeamDTO and set in query result

* RBAC: Revert change

* RBAC: Add deprecation notice to mock
2022-10-20 09:11:47 +02:00
Victor Marin
0dd721d4ce StatuHistoryPanel: Fix zoom not working (#57240) 2022-10-20 09:15:51 +03:00
Ryan McKinley
ed1176adc8 Storage: export dashboards + playlists to object store (#57313) 2022-10-19 17:05:51 -07:00
Ryan McKinley
e3c2859e83 Geomap: Upgrade to openlayers 7.x (#57317) 2022-10-19 17:03:44 -07:00
Alexander Weaver
3ddb28bad9 Find-and-replace 'err' logs to 'error' to match log search conventions (#57309) 2022-10-19 17:36:54 -04:00
Ezequiel Victorero
3e6bdf0439 PublicDashboards: filter by permissions on audit list (#57228) 2022-10-19 17:24:00 -03:00
Kristina
d81a3e524d Panel Menu: Use config explore enabled as an override to access control (#57225)
* Use config explore as an override to access control

* Change logic to need something explicitly false

* Keep logic consistent
2022-10-19 15:21:40 -05:00
Leon Sorokin
bdb97496ec Routing: an unexpected spelling error happened (#57295) 2022-10-19 16:01:50 -04:00
Yuriy Tseretyan
3e6bc28de5 Alerting: Change severity level of fetcher log messages (#57299) 2022-10-19 16:00:47 -04:00
juanicabanas
4418d78440 PublicDashboards: Delete public dashboard when dashboard is deleted (#57291)
PublicDashboards: Delete public dashboard when dashboard is deleted
2022-10-19 16:47:08 -03:00
Alexander Weaver
4eb8e4ff66 Alerting: Add traceability headers for alert queries (#57127)
* Define EvaluationContext

* Refactor ConditionEval to use new context struct

* Refactor QueriesAndExpressionsEval to use EvaluationContext

* Remove dead field from AlertExecCtx

* Refactor Validate to use EvaluationContext

* Get rid of privately used AlertExecCtx

* Move EvaluationContext to new file and add helper

* Add builder pattern and bind rule info to context

* Extract header logic and add rule UID header

* Fix missing call
2022-10-19 14:19:43 -05:00
Santiago
85cda0db69 Alerting: Templated URLs for webhook type contact points (#57296)
* templated URLs for webhooks

* clear tmplErr before using tmpl() again
2022-10-19 16:14:53 -03:00
Garrett Guillotte
c70bb592fe Docs: Fix reference to Enterprise licensing restrictions (#57230) 2022-10-19 13:20:47 -05:00
Garrett Guillotte
a0d83e7db7 Docs: Add missing alias for field options (#57234) 2022-10-19 14:13:17 -04:00
Michael Mandrus
86b0581021 add public dashboard token to metric panel issued queries (#57293) 2022-10-19 13:29:19 -04:00
Selene
8a35cb57fa Fix null pointer (#57292) 2022-10-19 13:20:03 -04:00
Gabriel MABILLE
717bd4a6c0 RBAC: Add a feature toggle for primitives we provide to OnCall (#57289) 2022-10-19 18:10:09 +02:00
Zoltán Bedi
09ab156480 MSSQL: Support tables from all schemas (#53099) 2022-10-19 17:27:29 +02:00
Ivana Huckova
7928f170ce Loki: Fix adding of adhoc filters to stream selector when query with empty stream selector (#57280)
* disable double stringify

* Refactor test for addLabelToQuery

* Add tests (TDD for expected behaviour)

* Fix adding ad hoc filters to correct place when no stream selector

* Update

* Update comment

* Fix getAllPositionsInNodeByType

Co-authored-by: Sven Grossmann <svennergr@gmail.com>
2022-10-19 17:24:00 +02:00
Garrett Guillotte
e14ef50d02 Docs: Fix broken InfluxDB starting guide links (#57235)
* Docs: Fix broken InfluxDB starting guide links

* Docs: Fix another link to panel adding docs
2022-10-19 07:52:15 -07:00
Garrett Guillotte
9680249066 Docs: Fix links in old What's New docs (#57231)
* Docs: Fix placeholder URL in release notes link

* Docs: Fix link to refactored docs and add missing alias

* Docs: Fix malformed links

* Docs: Fix alias with correct path
2022-10-19 07:51:49 -07:00
Ryan McKinley
15517f8329 SQLX: Expose sqlxdb query functions (#57227) 2022-10-19 07:33:40 -07:00
Ryan McKinley
de3737b5de Store: Add resolver service (#57112) 2022-10-19 07:33:26 -07:00
Matias Chomicki
93f39b5178 Loki Monaco Editor: add missing documentation and new autocompletion type (#57186)
* feat(loki-monaco-editor): add documentation and pipe operators

- Added documentation for line filters
- Added documentation for parsers
- Improved parser suggestions
- Introduced new PIPE_OPERATION category
- Added missing label_format pipe operation

* feat(loki-monaco-editor): update tests

* Chore: remove unused completion type

* Chore: remove line format
2022-10-19 10:30:44 -04:00
Ashley Harrison
2987734832 only get organizations if user is signed in (#57279) 2022-10-19 14:24:52 +01:00
Galen Kistler
0b66abba18 add case for empty influxdb 1 versions, so the health check doesn't fail (#56426) 2022-10-19 08:15:32 -05:00
Kristin Laemmert
05709ce411 chore: remove sqlstore & mockstore dependencies from (most) packages (#57087)
* chore: add alias for InitTestDB and Session

Adds an alias for the sqlstore InitTestDB and Session, and updates tests using these to reduce dependencies on the sqlstore.Store.

* next pass of removing sqlstore imports
* last little bit
* remove mockstore where possible
2022-10-19 09:02:15 -04:00
AJ Tomko
5285d34cc0 Dashboard: Alerts user to incorrect tag format for JSON import (#54657)
* Dashboard: Alerts user to incorrect tag format for JSON import

Fixes #54285: Malformed tags cause hidden title and settings page crash

* Update public/app/features/manage-dashboards/utils/validation.ts

Co-authored-by: Polina Boneva <13227501+polibb@users.noreply.github.com>

* Included Suggestions

- Removed Comments
- Updated Code Block accordingly
- Updated Tests to camelCase over snake_case

* Updates per comments

- Re-wrapped function in try{}, catch{} as I appear to have overlooked including it in the initial refactor
- Re-worded errors to align with initial error
- Added a test case for invalid json

* Update validation.ts

Updated errors to read correctly to the root cause.
Updated dashboard variable as const.

* Update actions.test.ts

Fix tests according to error output rewording

* Update validation.ts

- Included test for an empty string of non-array

* Update actions.test.ts

-- Commented incorrect commit for validation.ts, update:
- Refactored code to better align and separate from generic JSON package tests followed by our manual checks of (1) Is array, and (2) if array, is of strings

- Test cases now include a check for non-array empty string in the tag property

Co-authored-by: Polina Boneva <13227501+polibb@users.noreply.github.com>
2022-10-19 08:59:24 -04:00
Garrett Guillotte
e52c98ba99 Docs: Fix links in panels and vis docs (#57233) 2022-10-19 07:41:34 -05:00
Hamas Shafiq
f50ab457bd Tempo: Fix Node Graph visualization type in dashboard (#56931)
Co-authored-by: Andrej Ocenas <mr.ocenas@gmail.com>
2022-10-19 13:11:33 +01:00
Grafana I18n Bot
de24a444b5 I18n: Crowdin sync (#57260)
* New translations grafana.json (French)

* New translations grafana.json (Spanish)

* New translations grafana.json (German)

* New translations grafana.json (Chinese Simplified)
2022-10-19 12:14:55 +01:00
Dimitris Sotirakis
e829b50149 CI: Add CreateTempDir func and use it in publish packages logic (#57171)
* Add CreateTempDir func and use it in publish packages logic

* Fill err return in defer func
2022-10-19 12:58:22 +02:00
Ivana Huckova
b4a03d0cff Loki: Fix explain section about $__interval variable (#57188)
* Loki: Update  explain section

* Update

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

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

Co-authored-by: Matias Chomicki <matyax@gmail.com>
2022-10-19 12:01:29 +02:00
Sven Grossmann
598da14d88 disable double stringify (#57243) 2022-10-19 11:58:16 +02:00
Karl Persson
9adaf1565c RBAC: Allow to list users for dashboard / folder admins (#57080)
* RBAC: Use query struct in tests

* RBAC: If access control enforcement is disabled don't filter out users
when fetching permissions
2022-10-19 11:53:59 +02:00
Dimitris Sotirakis
0b72c36527 Replace json decoder with io.ReadAll (#57178) 2022-10-19 12:51:24 +03:00
Ivana Huckova
b997bc4200 Loki: Remove already selected options from next label filter options in builder (#57187)
* Loki: Filter out duplicated options in loki query builder label name options

* Update test
2022-10-19 11:32:01 +02:00
Gareth Dawson
c0f5183330 Logs: Add feature tracking to the load more button in log row context (#57079)
* add feature tracking for the load more button in log row context

* fix test by mocking reportInteraction

* track the new log row limit
2022-10-19 10:02:26 +01:00
Gareth Dawson
20616eef8c Logs: Add feature to tracking show context button click (#57074)
* report interaction on context open

* report interaction on context close_esc

* replace deprecated feature (KeyboardEvent.keyCode)

* update to report interaction on toggle context

* remove redundant if statement
2022-10-19 10:01:45 +01:00
Ashley Harrison
96660992f4 Navigation: Ignore null children in ToolbarButtonRow (#57201)
* filter out any null buttons to prevent padding being added for them

* ignore null children in toolbarbuttonrow
2022-10-19 10:00:57 +01:00
Gábor Farkas
0491c19712 elastic: backend-mode: fix trimEdges functionality (#56985) 2022-10-19 10:40:42 +02:00
Dimitris Sotirakis
f0b882ebad Add token to init-enterprise (#57246) 2022-10-19 04:23:12 -04:00
Erik Sundell
8949e574e6 cache api calls when args are the same (#57082) 2022-10-19 08:40:03 +02:00
Erik Sundell
a30885c523 CloudWatch: Make sure adoption tracking is done on valid, migrated queries (#56872)
* make sure adoption tracking is done on valid, migrated queries

* ignore hidden queries

* fix test

* remove obsolete test
2022-10-19 08:39:18 +02:00
aimuz
c0cc85b5f1 Alerting: Add support for wecom apiapp (#55991)
This change adds new functionality to the wecom alerting contact point. In addition to a webhook address, you can now send alerts to the wecom apiapp endpoint.

Based on https://github.com/grafana/grafana/discussions/55883

Signed-off-by: aimuz <mr.imuz@gmail.com>
2022-10-19 12:17:37 +08:00
owensmallwood
b2408dd7c5 Publicdasboards: Add annotations support (#56413)
adds annotations support for public dashboards
2022-10-18 19:48:20 -06:00
Sobuno
cc6245df8e Fix typo (#57223) 2022-10-18 22:52:56 +00:00
Ezequiel Victorero
22b5e574b1 PublicDashboards: hide topnav (#56873) 2022-10-18 19:51:09 -03:00
Christopher Moyer
cafdbc1644 restructures directories, corrects relrefs (#57130) 2022-10-18 15:07:15 -05:00
Christopher Moyer
e5fc1b85e0 restructures directories, correct relrefs (#57131) 2022-10-18 15:06:58 -05:00
Michael Mandrus
2a8a82e2af PublicDashboards: Don't filter datasources from FrontendSettings in a public dashboard (#57208)
* add filter skip to avoid issues with RBAC

* update comment
2022-10-18 15:44:33 -04:00
Torkel Ödegaard
69bfd923be RefreshPicker: Fix issue clearing auto refresh (#57215) 2022-10-18 21:41:37 +02:00
Kristina
3cb1ec58f0 Add information about tempo in devenv (#57204) 2022-10-18 14:29:28 -05:00
Sarah Zinger
b2e2879b07 Cloudwatch: Fix issue where selected log groups clear from dashboards if there are more than 50 results (#57196) 2022-10-18 14:34:27 -04:00
Misi
9c954d06ab Auth: Refresh OAuth access_token automatically using the refresh_token (#56076)
* Verify OAuth token expiration for oauth users in the ctx handler middleware

* Use refresh token to get a new access token

* Refactor oauth_token.go

* Add tests for the middleware changes

* Align other tests

* Add tests, wip

* Add more tests

* Add InvalidateOAuthTokens method

* Fix ExpiryDate update to default

* Invalidate OAuth tokens during logout

* Improve logout

* Add more comments

* Cleanup

* Fix import order

* Add error to HasOAuthEntry return values

* add dev debug logs

* Fix tests

Co-authored-by: jguer <joao.guerreiro@grafana.com>
2022-10-18 18:17:28 +02:00
Artur Wierzbicki
984ec00aac Search: load dashboards optimization (#56933)
* search: load dashboards optimization

* search: load dashboards optimization

* search: close dashboard channel, return error when context is done

* search: refactor

* search: return err on ctx done

* search: remove sleep
2022-10-18 23:53:15 +08:00
Torkel Ödegaard
ca98dba053 Page: Refine responsive paddings and margins (#57132) 2022-10-18 17:43:09 +02:00
Victor Marin
e91135cf19 Fix NumberInput empty values (#57142)
* Fix NumberInput empty values

* tests

* tests
2022-10-18 16:59:34 +03:00
juanicabanas
71f79b9de0 PublicDashboards: Fix hidden queries execution (#57004)
PublicDashboards: Fix hidden queries execution
2022-10-18 10:47:24 -03:00
ying-jeanne
ed98d7bc27 Chore: remove busmock (#57170) 2022-10-18 13:31:56 +00:00
Sven Grossmann
4b1b0344e4 Chore: update latest.json to 9.2.1 (#57185) 2022-10-18 15:26:17 +02:00
Victor Marin
9c514748f7 Revert data links code for sorted vector case (#57175) 2022-10-18 08:59:53 -04:00
Grot (@grafanabot)
4cee910971 Changelog: Updated changelog for 9.2.1 (#57176) 2022-10-18 14:45:30 +02:00
Gilles De Mey
423643aaa6 Alerting: use virtualized list of namespaces / groups for cloud rules (#56415) 2022-10-18 13:38:59 +02:00
Eric Leijonmarck
fa45742abc Quota(fix): remove service accounts from quota count (#56700) 2022-10-18 12:26:38 +01:00
Victor Marin
76d6e3c075 TimeseriesPanel: Fix variables in data links (#56729)
* TimeseriesPanel: Fix variables in data links

* Refactor variable fix for all Timeseries panels

* cr mods
2022-10-18 14:22:31 +03:00
Ashley Harrison
178b05160a make betterer a required step on PRs again (#57099) 2022-10-18 12:22:13 +01:00
Julien Duchesne
44ad4ec9d4 Add RPM package publishing (#56797)
Just tested deb publishing, and confirmed it works. Noticed that RPM packages aren't published though
It's the exact same step, targetting the RPM files instead
Both steps will run in parallel

Co-authored-by: dsotirakis <dimitrios.sotirakis@grafana.com>
2022-10-18 13:41:23 +03:00
Matias Chomicki
d2abcbe4a5 feat(loki-monaco-editor): improve line filter suggestions (#57103) 2022-10-18 12:40:12 +02:00
Laura Fernández
4d0dd0647e Browse: Fix General folder not showing in FolderPicker (#57156) 2022-10-18 12:38:51 +02:00
Gabriel MABILLE
3963ed3754 RBAC: Allow access to /dashboards when user has dashboards create (#56712)
* RBAC: Allow access to dashboards when user has dashboards create

* Remove eval any that I didn't add on purpose
2022-10-18 11:15:52 +02:00
Shirley
65939ce5b1 CloudWatch: Move logger to its own package and minor refactoring (#57107)
* Move log to its own package

* Rename test-data to testdata

* Change alias to string type

* Remove parseQueries from a method of cloudWatchExecutor
2022-10-18 04:21:18 -04:00
Gábor Farkas
2815343ee5 logs: handle mixed datasources in filters (#56560)
* logs: handle mixed datasources in filters

* removed unnecessary special handling

* added explanation comment

* more consistent type-handling
2022-10-18 09:27:17 +02:00
Erik Sundell
36734f3cef CloudWatch: Move hard coded metrics, namespaces and dimensions to its own package (#57089)
* move hard coded metrics to its own package

* remove comment
2022-10-18 09:23:47 +02:00
Dimitris Sotirakis
7a71482371 Update grabpl to 3.0.14 (#57144) 2022-10-18 02:44:31 -04:00
Artur Wierzbicki
c26cf6a517 Search: Sort alphabetically in the folder view, increase the limit of the folder search from 50 to 1000 (#57078)
* search: sort folders

* search: increase the limit for folder search to 1000

* add folder view sort test

* search: getFolderViewSort

* search: revert test

Co-authored-by: Todd Treece <todd.treece@grafana.com>
2022-10-18 14:10:53 +08:00
Matthew Jacobson
0db339d82f Alerting: Improve notification policies created during migration (#52071)
* Alerting: Improve notification policies created during migration

Previously, migrated legacy alerts were connected to notification policies through
a `rule_uid` label in a 1:1 fashion. While this correctly mimicked pre-migration routing,
it didn't create a notification policy structure that is easy to view/modify. In addition,
having one policy per migrated alert is, in some ways, counter to the recommended approach of
Unified Alerting.

This change replaces `rule_uid`-based migrated notification policies with a private
label called `__contacts__`. This label stores a list of double quoted strings containing the names of
all contact points an AlertRule should route to (based on legacy notification channels). Finally,
one notification policy is created per contact point with each matching AlertRules via regex on this
`__contacts__` label.

The result is a simpler, clearer, and easier to modify notification policy structure, with the
added benefit that you can see which contact points an AlertRule is being routed to from the
AlertRule creation page.
2022-10-18 00:47:39 -04:00
Guilherme Caulada
313c88f3e1 Reapply public dashboard granularity fix (#57129) 2022-10-17 22:11:59 -03:00
Adela Almasan
7f5914ff05 Canvas: Text input cursor jumping (#57133)
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2022-10-17 18:36:18 -04:00
Jeff Levin
7146f2731c Public Dashboards: audit log paths and add traceId where user facing error is different (#56914)
Audit all paths for publicdashboards and implement traces where user facing error is different from the internal error.
2022-10-17 13:17:24 -08:00
Christopher Moyer
d09d39ddd4 Docs/restructures setup (#57125)
* builds out configure grafana directory to align with hugo

* restructures configure authentication, corrects relrefs

* correct alias

* corrects final relrefs
2022-10-17 15:24:33 -05:00
Santiago
6ad405e256 fix swagger spec for receivers API response (#57124) 2022-10-17 16:58:55 -03:00
Yuriy Tseretyan
888bdfd4ad Alerting: Use correct response body for silence post API (#57114) 2022-10-17 15:43:37 -04:00
Sofia Papagiannaki
46fb4081ba SQLStore: Optionally retry queries if sqlite returns database is locked (#56096)
* SQLStore: Retry queries if sqlite returns database is locked

* Configurable retries

* Apply suggestions from code review

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2022-10-17 21:23:44 +03:00
Beto Muniz
920d2aa599 InfluxDB: Interpolate ad-hoc filters from Dashboard to Explore (#56996) 2022-10-17 13:28:54 -03:00
Ahmed
5c2b722287 Docs: Fix broken link (#57083)
* Docs: Fix broken link

* Update docs/sources/setup-grafana/configure-security/configure-authentication/auth-proxy.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2022-10-17 09:09:31 -07:00
Jack Westbrook
24c04740e3 Grafana UI: Export prop types for queryfield, modal and field components (#57097)
* chore(grafana-ui): export prop types for queryfield, modal and field components

* docs(migration-guide): add notes for react peerdependencies and additional type exposure

* Update docs/sources/developers/plugins/migration-guide.md

Co-authored-by: Timur Olzhabayev <timur.olzhabayev@grafana.com>

Co-authored-by: Timur Olzhabayev <timur.olzhabayev@grafana.com>
2022-10-17 17:54:43 +02:00
brendamuir
b7feb34acf Fix broken relrefs (#57092)
* Fixes relrefs

* Fixes more relrefs
2022-10-17 08:54:00 -07:00
Garrett Guillotte
2bed451990 Docs: Contextualize base64 encoding in Basic Authorization (#57046) 2022-10-17 08:53:17 -07:00
kay delaney
ed71b7b884 Chore/React18: Remove enzyme slate tests and replace with e2e tests (#57095) 2022-10-17 16:31:59 +01:00
Dimitris Sotirakis
c96b6a6ab0 CI: Move CreateTempFile - use it for rpm/deb packages (#56990)
* Move CreateTempFile - use it for rpm/deb packages

* Fix typo

* Fix tests:
2022-10-17 16:23:57 +01:00
Jack Westbrook
fd0fcffc24 Toolkit: Fix Cannot use "import statement outside" error in tests (#57071) 2022-10-17 16:31:12 +02:00
Selene
ba6c715708 Chore: Delete unused db in orgs and use db in datasources (#57085)
* Delete unused db in orgs and use db in datasources

* Sort imports
2022-10-17 16:27:56 +02:00
Alexa V
6524a0b437 Chore: Rename grafana core PanelChrome and use grafana-ui - PanelChrome component (#56659) 2022-10-17 16:03:38 +02:00
Christopher Moyer
de1cfc120f Docs: adds modify dashboard settings docs (#56826)
* adds modify dashboard settings docs

* Quick updates

* minor corrections

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-10-17 09:02:22 -05:00
kay delaney
5d53a983d8 React18: Update useCallback arg types where needed (#57084) 2022-10-17 14:52:12 +01:00
kay delaney
b1128e0b8c Chore/React18: Update context types where needed (#57018) 2022-10-17 13:29:44 +01:00
Torkel Ödegaard
0d9b321058 DashboardsList: Fixes issue with overflow hidden causing input focus state to be obscured (#57021) 2022-10-17 14:19:57 +02:00
Torkel Ödegaard
0f9e6dda2d Page: Refactor out section nav state logic and move it to SectionNav component (#57036) 2022-10-17 14:19:29 +02:00
Sonia Aguilar
3f26ffde94 Alerting: Add relativeTimeRange from dataSource when using Resample expresions (#56652)
* Fix: Add relativeTimeRange from dataSource when using Resample expression

* Add test for relativeTimeRange when updating resample expression

* update time range for expressions when data sources are updated

* Get data source recursively from expression up to the last query that this tree is referencing to

* Remove unnecessary produce from immer, and check if there is a cycle in the queries structure
2022-10-17 12:29:05 +02:00
Karl Persson
21792fdf37 RBAC: Make uid for managed role names deterministic during migrations (#56620)
* RBAC: Change the generate uid function to be deterministic so we can avoid collision

* RBAC: Use fmt.Errorf

* RBAC: Add comment

* RBAC: Export GenerateManagedRoleUID
2022-10-17 12:15:20 +02:00
brendamuir
ecc252429e Docs alerting: copy edit terraform provisioning (#55978) (#57068) 2022-10-17 11:48:39 +02:00
Esteban Beltran
0abf04a20f Toolkit: Remove unused close-milestone command (#57062)
* Toolkit: Remove unused close-milestone command

* Remove import line
2022-10-17 11:27:27 +02:00
Dimitris Sotirakis
27f072beb3 Don't trigger tag event when merging (#57063) 2022-10-17 12:27:10 +03:00
Jan Garaj
03248e9cd8 Alerting: Missing config option in the sample (#54179) 2022-10-17 11:10:41 +02:00
Ashley Harrison
3cca8e3676 any/type assertion fixes (#57009) 2022-10-17 10:10:10 +01:00
Dimitris Sotirakis
e25475b9c8 Make publish packages depend on compile-build-cmd and run from bin/build (#56713) 2022-10-17 10:58:36 +03:00
Labesse Kévin
c8402b4b50 GoogleCloudMonitoring: fix typo tooltip pre-processing (#57049) 2022-10-17 09:45:35 +02:00
Leon Sorokin
da39c7297b BarChart: use dashboard timezone for x axis (#57047) 2022-10-17 14:06:45 +07:00
Garrett Guillotte
4831091115 Docs: Fix provisioning table formatting (#57042) 2022-10-16 11:05:47 -05:00
Garrett Guillotte
0889c3ad07 Docs: Clarify and document dashboard URL query parameters for variables (#56055) 2022-10-15 18:07:25 -07:00
Vũ Quốc Phong
800754e7e8 Add document for jsondata field alertmanagerUid (#52895)
alertmanagerUid can be used to specify Alert Manager for a particular Prometheus/Loki data source.

Co-authored-by: Garrett Guillotte <garrett.guillotte@grafana.com>
2022-10-15 15:32:11 -07:00
Ben Golding
a46fa16b4e <Documentation> Document usage of environment variables/files in GitHub Auth login (#52891)
* Document usage of environment variables/files

* Updating Github Auth Login Documentation

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>
2022-10-15 09:20:50 -07:00
Torkel Ödegaard
9f5e691994 Theme: Inter font (behind feature toggle) (#56441)
* Theme: Inter font change with new line-height

* Add it behind feature toggle

* make buildVariant easier to read + enforce integer multiples of 2 (#56486)

* Minor update

* Update

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-10-15 16:22:33 +02:00
Alexander Weaver
129a28919b Alerting: Cache result of dashboard ID lookups (#56587)
* Create caching dashboard resolver

* A couple tests for dashboard resolving

* Log warning on not found

* Additional polish + review nits

* Move to singleflight instead of a plain mutex

* Store errors instead of -1 in cache and use reflection when reading

* Address linter error

* One more linter error
2022-10-14 15:48:02 -05:00
Kristin Laemmert
c61b5e85b4 chore: replace sqlstore.Store with db.DB (#57010)
* chore: replace sqlstore.SQLStore with db.DB

* more post-sqlstore.SQLStore cleanup
2022-10-14 15:33:06 -04:00
Garrett Guillotte
2b4d57fe60 Docs: Note end of release notes publication (#57013)
* Docs: Note cessation of release notes

* Docs: Update What's New index mention of release notes

* Docs: Update links and references to the release notes

* Docs: Fix relrefs

* Docs: Spellcheck
2022-10-14 18:24:32 +01:00
kay delaney
64b0f8072b Themes: Add color-scheme attribute to :root (#57001) 2022-10-14 16:30:07 +01:00
Michael Mandrus
ea8549b8c2 Datasources: Support mixed datasources in a single query (#56832)
* initial cut at refactor - need to run more tests

* fix unit tests

* change newly unused function to test helper

* create unit tests for parsing query requests that cover a range of cases

* add some comments

* rename function to avoid dev confusion
2022-10-14 10:27:06 -04:00
Yaelle Chaudy
2ccbb4d3a3 Configuration page: Fix dropdown menus keyboard a11y (#56986)
* Made dropdown menu keyboard accessible

* ul menu and left align
2022-10-14 15:57:45 +02:00
Josh Hunt
2e16d5499e Dashboard: Add dashboard validation warning to save drawer (#55732)
* add api route for validating a dashboard json

* add feature flag for showDashboardValidationWarnings

* tidy up

* comments and messages

* swagger specs

* fix typo

* more swagger

* tests!

* tidy test a little bit

* no more ioutil

* api will return different status code depending on validation error

* clean up

* handle 4xx errors

* remove console.log

* fix backend tests

* tidy up

* Swagger: Exclude alpha endpoints

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>
2022-10-14 09:51:05 -04:00
Arpit Bhardwaj
e4b1347ca5 Select Dropdown alignment fix (#56858) 2022-10-14 13:24:08 +00:00
Kristina
3dbb0f1659 Add in logic to send root datasource as override if needed (#56904) 2022-10-14 08:12:04 -05:00
George Robinson
2f85172718 Alerting: Remove blank comment (#56889) 2022-10-14 13:28:41 +01:00
Josh Hunt
8e512de308 I18n: update contributing docs (#56860)
* update contrib i18n docs

* update contrib i18n docs

* remove lingui references, rearrage plain js usage
2022-10-14 11:55:15 +01:00
Gabriel MABILLE
0f4d126109 AzureAD: Add option to force fetch the groups from the Graph API (#56916)
* Add a new option to systematically fetch AzureAD groups from the Graph API
2022-10-14 12:55:00 +02:00
Jorge Luis Betancourt
e4f2006cce Elasticsearch: Fix calculation of trimEdges (#56148)
* Elasticsearch: Fix calculation of trimEdges

When a value of trimEdges is set greater than 1 we need to drop both the
first and last sample of the data from the response.

* Elasticsearch: Fix reading trimEdges from the query settings

Currently the trimEdges property in the JSON panel is stored as a string
and not directly as a number.

This caused that the reading of the value failed in the go backend
because the simplejson.Int() method doesn't properly handle this case.
This failure when decoding the value goes unnoticed because of the early
return causing the trimEdges configuration to be ignored.

* Refactor castToInt to also return an error

Add a new test case that sets the `trimEdges` property as a quoted
number.
2022-10-14 12:53:12 +02:00
GitStart
4ecc9f42ac Last Table Column Not Centered (#56047)
Co-authored-by: gitstart <gitstart@gitstart.com>
Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Thiago Nascimbeni <tnascimbeni@gmail.com>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: RubensRafael <rubensrafael2@live.com>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Matheus Muniz <87545749+matheusmuniz03@users.noreply.github.com>
Co-authored-by: Matheus Muniz <matheusmuniz100@hotmail.com>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>

Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: gitstart <gitstart@gitstart.com>
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Thiago Nascimbeni <tnascimbeni@gmail.com>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: RubensRafael <rubensrafael2@live.com>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Matheus Muniz <87545749+matheusmuniz03@users.noreply.github.com>
Co-authored-by: Matheus Muniz <matheusmuniz100@hotmail.com>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
2022-10-14 13:25:40 +03:00
Gareth Dawson
b047316ef4 Logs: Add feature tracking to the replace line button (#56883) 2022-10-14 11:10:53 +01:00
Ashley Harrison
a904372269 Accessibility: enable rule jsx-a11y/no-noninteractive-element-to-interactive-role (#56870)
* enable rule `jsx-a11y/no-noninteractive-element-to-interactive-role` and switch to extending recommended preset

* fix unit tests

* better unit test
2022-10-14 11:02:01 +01:00
kay delaney
e85917f041 Chore/React18: Update component prop types (#56898) 2022-10-14 10:24:32 +01:00
Leon Sorokin
4eea326ee8 Candlestick: re-init config when series length changes (#56913) 2022-10-14 04:12:28 -05:00
Leon Sorokin
53ac77d4a5 Heatmap: honor dashboard timezone in x axis and fix tooltip time range (#56909) 2022-10-14 04:11:20 -05:00
sam boyer
7767002e12 dashboards: Use @grafanamaturity(NeedsExpertReview) in schema (#56888) 2022-10-14 05:10:39 -04:00
Victor Marin
b374b01260 MSSQL/MySQL: Add correct refId when fetching variable query results (#56919) 2022-10-14 11:52:12 +03:00
Victor Marin
902a230867 MSSQL/MySQL: Fix variable interpolation (#56879)
* MSSQL/MySQL: Fix variable interpolation

* Escape string vars
2022-10-14 11:52:08 +03:00
kay delaney
e819ed0f51 PlotLegend: Memoize for better performance (#56123) 2022-10-14 09:51:27 +01:00
Matias Chomicki
08ffcfdf16 feat(loki-monaco-editor): escape autocompleted label values (#56890) 2022-10-14 08:29:03 +00:00
Konrad Lalik
e5d644d991 Alerting: Fix source and rule name decoding on Find route (#56805) 2022-10-14 10:06:00 +02:00
Konrad Lalik
9d0380cbdd Alerting: Fix folder picker clear action (#56864) 2022-10-14 08:48:05 +02:00
Nathan Marrs
527690d19a Docs: Fix Canvas doc link and add call to action for feedback (#56908)
* Fix canvas documentation link on what's new page; add feedback CTA in canvas doc

* PORK: replace allows with enables for better language

* Fix a few more instances of allow to enable

* Move feedback above video in intro canvas section

* Revert changing link change
2022-10-13 19:02:44 -07:00
Christopher Moyer
385079bea7 Docs: Basics docs refactor (#56905)
* renames directory

* fixes relrefs
2022-10-13 15:57:58 -05:00
Christopher Moyer
c137cf60f0 moves canvas to proper directory, corrects relref (#56902) 2022-10-13 14:39:05 -05:00
Leon Sorokin
5acda40248 Search/ActionRow: drill placeholder to SortPicker (#56475) 2022-10-13 13:30:20 -06:00
Alexander Weaver
145b970557 Propagate all headers on main QueryData (#56896) 2022-10-13 14:18:53 -05:00
Joan López de la Franca Beltran
1ca5c347d3 Analytics: Add datasource UID to events (#56852)
* Analytics: Add datasource UID to events
2022-10-13 17:41:52 +02:00
Beto Muniz
5d86dc507a Fix Meta Data tab breaking condition (#56646) 2022-10-13 12:39:01 -03:00
juanicabanas
75a5777e36 PublicDashboards: Validate access token not to be duplicated and add retries. (#56755)
PublicDashboards: Validate access token not to be duplicated and add retries.
2022-10-13 11:32:32 -03:00
Ryan McKinley
3b4b528993 Storage: Dashboard summary builder cleanup (#56665) 2022-10-13 09:29:19 -04:00
Gareth Dawson
b8b25f7e31 Logs: add app to feature tracking in ad-hoc statistics (#56865)
* add app tracking to adhoc statistics

* use the object property value shorthand
2022-10-13 14:26:59 +01:00
Armand Grillet
83aa006c98 Add Alerting API to list of HTTP APIs (#56863)
This link has been asked many times and is only viewable on old docs pages.
2022-10-13 15:09:49 +02:00
Santiago
9996dbd577 use Prometheus' format for notification attempts durations (#56822) 2022-10-13 10:08:09 -03:00
Santiago
3c56fd8da0 Fix duplicated receivers in API response (#56829) 2022-10-13 10:01:28 -03:00
idafurjes
ef651daed2 Use org service instead of sqlstore (#56407)
* Use org service instead of sqlstore

* Remove methods from sqlstore

* Remove commented out code

* Fix lint

* Fix lint 2
2022-10-13 08:40:46 -04:00
Gareth Dawson
b0cb02568a Logs: Add feature tracking for filters in log rows (#56808)
* Add feature tracking for log details filter clicks

* use deconstructed prop values

* use deconstructed prop values
2022-10-13 11:21:17 +01:00
Laura Benz
b71e08ad59 Explore: Remove camel case from tracking labels (#56809)
* refactor: remove camel case from tracking labels

* refactor: remove camel case from tracking labels
2022-10-13 12:12:50 +02:00
Sven Grossmann
efe214a293 LogContext: Change line highlighting to match the hover state (#56811)
* add hover background also to logs with context

* add inherit display
2022-10-13 11:42:40 +02:00
Sonia Aguilar
d957fe01f4 Simplify mocking useGetContactPointsState (#56842) 2022-10-13 11:06:20 +02:00
Yaelle Chaudy
0295177bb0 Cloud Monitoring: Fix missing data when result is paginated (#56270)
* Added nextPageToken prop

* Adding first and pageToken condition to while loop

* clean up

* revert gitignore

* fix go lint

* Added logic to builder too

* Removed pageSize - was for local testing

* gofmt

* extracted doRequest function

* extracted doRequest in query too

* Adressed filter comments

* Adressed query comments

* go fmt

* removed pageSize added for testing

* go fmt again
2022-10-13 10:58:07 +02:00
Dimitris Sotirakis
b9d449529a Update grabpl to v3.0.12 (#56823) 2022-10-13 11:35:05 +03:00
Sofia Papagiannaki
97730aec10 Chore: Bump golang.org/x/text (#56841) 2022-10-13 11:26:25 +03:00
Gábor Farkas
5a0d90b104 logs: refactor: remove unused param "index" (#56543) 2022-10-13 10:04:51 +02:00
Sonia Aguilar
277803a894 Alerting: Refactor fetch for receivers for using RTKQuery (#56624)
* Refactor fetch for reveivers for using  RTKQuery

* Simplify receiversApi contactPointsState endpoint

* Fix tests and create useGetContactPointsState hook for using receiversApi.useContactPointsStateQuery
2022-10-13 10:00:59 +02:00
Ashley Harrison
5af36e48ba convert ThresholdsEditor to RTL (#56791) 2022-10-13 08:56:36 +01:00
Jeff Levin
cc27214dca Public Dashboards: Add audit table (#54508)
This PR adds an audit table for public dashboards allowing a user to view all public dashboards on an instance of grafana. The public dashboards team is working on a proposal for adding RBAC support to the audit table for 9.3

Co-authored-by: juanicabanas <juan.cabanas@grafana.com>
2022-10-12 21:36:05 -08:00
Joe Blubaugh
c7c640d903 Alerting: Fix email image embedding on Windows. (#56766)
The email notifier was incorrectly handling Windows filepaths. This is
fixed by using the `path/filepath` package.
2022-10-13 10:24:00 +08:00
Adela Almasan
254bb0c99e Canvas: Clear current selection in dashboard mode (#56830) 2022-10-12 17:18:56 -04:00
George Robinson
004bb7689d Alerting: Fix mathexp.NoData for ConditionsCmd (#56816) 2022-10-12 17:34:28 +01:00
Ashley Harrison
61fd369b3f ensure the first item in the sectionnav is always the section root (#56815) 2022-10-12 17:02:31 +01:00
Ashley Harrison
8846778f9b fix title of config node (#56810) 2022-10-12 16:37:14 +01:00
Alex
94ed744454 Auth: Make built-in login configurable (#46978) 2022-10-12 15:34:59 +00:00
Ashley Harrison
7d18460d8f Chore: convert MetricSelect test to RTL (#56801)
* convert MetricSelect test to RTL

* remove type param
2022-10-12 16:33:12 +01:00
Michael Mandrus
26e7228cd9 fix typo (#56802) 2022-10-12 09:44:21 -04:00
Gareth Dawson
f30ba0d34e Explore/Logs: Add feature tracking for ad-hoc statistics in log rows (#56681)
* Add feature tracking for ad-hoc statistics in log rows

* Make row prop mandatory in LogDetailsRow.tsx

* Remove optional chaining

* fix: failing test by mocking reportInteraction
2022-10-12 14:37:24 +01:00
Karl Persson
b1761908c2 RBAC: Add primary key to seed_assignment table (#56540)
* RBAC: Add seed_assignment migrations from enterprise

* RBAC: Create migration to add primary key to seed_assignment table
2022-10-12 15:18:07 +02:00
Gabriel MABILLE
5fcec05695 LDAP: log that organization mapping is skipped (#56796) 2022-10-12 08:41:11 -04:00
Joey Tawadrous
78061260fb Default to flamegraph (#56733) 2022-10-12 13:39:08 +01:00
Ivana Huckova
7c10082c57 Devenv: Fix influx dashboard (#56775) 2022-10-12 14:01:48 +02:00
Josh Hunt
b7d969baf1 I18n: Improve tooling (#56731)
* Delete en-US.json before extracting strings so it's always up to date

* Add 'comment' to message jsons

* Enable Pseudo-locale option only in dev mode

* don't load english messages

* fix package.json

* fix
2022-10-12 07:51:16 -04:00
ying-jeanne
80ede174dd update the feature toggle usage in backend (#56787) 2022-10-12 13:43:35 +02:00
Gabriel MABILLE
10c080dad1 LDAP: Add skip_org_role_sync configuration option (#56679)
* LDAP: Add skip_org_role_sync option

* Document the new config option

* Nit on docs

* Update docs/sources/setup-grafana/configure-security/configure-authentication/ldap.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Docs suggestions

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Add test, Fix disabled user when no role

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Jguer <joao.guerreiro@grafana.com>
2022-10-12 13:33:33 +02:00
Julien Duchesne
72b9555487 Publish Linux Packages: Fix bad secret name (#56708)
🤦

Co-authored-by: dsotirakis <dimitrios.sotirakis@grafana.com>
2022-10-12 14:07:13 +03:00
Josh Hunt
719769ee7c I18n: Add Chinese (Simplified) (#56739)
* Prevent _old.json files from being created

* Add contrib docs for adding new locale

* add chinese (simplified)
2022-10-12 06:12:46 -04:00
Torkel Ödegaard
85e3ed491d DashboardsList: Fix height issue in topnav (#56661) 2022-10-12 11:00:45 +01:00
George Robinson
67d93ceea0 Alerting: Add doc comments to classic.go (#56724) 2022-10-12 10:55:48 +01:00
Ashley Harrison
dd9e1498f9 only render direct children on the landing page routes (#56720) 2022-10-12 10:01:33 +01:00
Matt
26bb139470 Fixes 48972 - Exposes channels.WebhookMessage (#56140) 2022-10-12 09:50:28 +01:00
kay delaney
45edce90d3 VariableEditor: Use new form styles (#56326) 2022-10-12 09:43:41 +01:00
Alex
6edce00b1a Inspect: Handle JSON tab crash when the provided object is too big to stringify. (#55939)
* fix(inspector): handle json tab crash when too much data

* message update when JSON stringify fails due to obj size
2022-10-12 00:52:23 -07:00
Victor Marin
48c27872af TablePanel: Footer now updates values on column filtering (#56354)
* Table footer now updates values on column filtering

* Backwards compatibility
2022-10-12 07:57:49 +03:00
Nathan Marrs
17433f2166 Docs: Fix what's new canvas doc video file reference #56754 2022-10-11 15:57:48 -07:00
Michael Mandrus
6827ca01a0 Docs: Add missing documentation for enterprise features (#56753)
* add documentation about protected roles

* add section about sync debug

* add link to recorded queries to main enterprise pages

* Update docs/sources/setup-grafana/configure-security/configure-authentication/ldap.md

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* fixes from pr review

* add missing char

* Apply suggestions from code review

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* fix other incorrect lines to match review

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>
2022-10-11 15:57:27 -07:00
Christopher Moyer
414d536186 Docs: refactors config panels and visualizations, corrects relrefs (#55940)
* refactors config panels and visualizations, corrects relrefs

* adds an alias

* Remove some old content

* moves visualizations topic to the root

* moves out panels and visualization topics to the root

* adds move and resize panel to add/organize panel; creates a create dashboard topic under build dashboards; adjusts context of add a panel to be from within an existing dashboard

* updates aliases

* creates search at root, moves dashboard preview to search, creates standalone search dashboard topic

* moves Set dashboard time range to use-dashboards, creates modify dashboard settings and adds moves Modify dashboard time settings to that topic

* moves existing query-options topic from working with panels to configure-panel-visualizations, moves panel time overrides and timeshift content to query options

* Moving things to better category, fixing links, improving ordering

* Move panel inspector to main panel topic

* completes partial fix of relrefs

* relref fixes con't

* restructures remaining panels topics

* more relref fixes

* Minor fix

* Minor tweak

* finishes fixing relrefs

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
Co-authored-by: Jack Baldry <jack.baldry@grafana.com>
2022-10-11 15:31:20 -05:00
Garrett Guillotte
f4a3400a9c Docs: Update Canvas videos to mp4 URLs (#56748) 2022-10-11 11:39:52 -07:00
Garrett Guillotte
abd7b7dccc Docs: Remove Beta tag from 9.2 What's New post-release (#56746) 2022-10-11 13:16:24 -05:00
Garrett Guillotte
4a99470e22 Docs: Add CODEOWNER to setup docs (#56745) 2022-10-11 13:43:58 -04:00
Garrett Guillotte
c98db1615f Docs: Clarify JOIN feature change (#56740) 2022-10-11 18:23:48 +02:00
Dimitris Sotirakis
62314bbf66 Remove grabpl dependency from yarn-install (#56692) 2022-10-11 18:58:03 +03:00
Matias Chomicki
6a74cd207a feat(loki-monaco-editor): add support for in_aggregation situation (#56680) 2022-10-11 15:52:57 +00:00
Junaid Ali
33eb4a2807 Exclude full OAuth token details from printing out on stdout (#55426)
* remove token details from printing out on stdout

* Update login_oauth.go

* address comment
2022-10-11 17:20:49 +02:00
Hamas Shafiq
9db61f54ff Tempo: Fix the inconsistency between the query limit values in the options component (#56566) 2022-10-11 16:08:53 +01:00
Dimitris Sotirakis
94fe605175 Update latest json (#56732) 2022-10-11 14:35:50 +00:00
Giordano Ricci
e3e32c7d04 chore: bump code coverage action version (#56710) 2022-10-11 15:35:35 +01:00
Konrad Lalik
5ddf7b85df Alerting: Alert list performance improvements (#56247)
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2022-10-11 16:24:01 +02:00
Grot (@grafanabot)
8627b2131f Changelog: Updated changelog for 9.2.0 (#56725) 2022-10-11 17:18:15 +03:00
Sofia Papagiannaki
7e24e19230 Swagger: Remove license (#56716) 2022-10-11 17:06:36 +03:00
Nathan Marrs
a9c0afcc1f Canvas: Docs for 9.2 (#56219)
Co-authored-by: Adela Almasan <adela.almasan@grafana.com>
2022-10-11 06:34:49 -07:00
Grot (@grafanabot)
5cebb94e01 Changelog: Updated changelog for 9.1.8 (#56714) 2022-10-11 16:31:10 +03:00
Neel
86a1fe578a Grafana UI: Fix alignment issue with http method dropdown (#56592)
- Removed custom width prop from the http method Select component to fix the alignment issue for prometheus HTTP request type dropdown
2022-10-11 08:20:13 -05:00
Grot (@grafanabot)
ae72742b76 Changelog: Updated changelog for 8.5.14 (#56709) 2022-10-11 16:15:07 +03:00
Giordano Ricci
f1a0a5cb47 Glue: improves validation & fix api docs for correlations (#56682) 2022-10-11 14:04:55 +01:00
Andres Martinez Gotor
cf2ba7e41c Google Cloud Monitoring: Adapt default crossSeriesReducer (#56693) 2022-10-11 14:51:25 +02:00
Piotr Jamróz
ae927eab73 Glue: Enrich query results data frames in Explore with correlations to generate static links from correlations (#56295)
* Attach static generic data link to data frames in Explore

* WIP

* Always load correlations config when the query is run

This will be moved to Wrapper.tsx and called only once Explore is mounted

* remove comment

* Load the config when Explore is loaded

* Clean up

* Check for feature toggle, simplify cod

* Simplify the code

* Remove unused code

* Fix types

* Add a test for attaching links

* Revert package.json changes

* Display title provided in the correlation label

* Add missing mocks

* Fix tests

* Merge branch 'main' into ifrost/integration/attach-generic-data-link

# Conflicts:
#	public/app/features/explore/Wrapper.tsx
#	public/app/features/explore/state/main.ts

* Remove redundant async calls

* Do not block Wrapper before correlations are loaded (only delay the query)

* Test showing results after correlations are loaded

* Post-merge fix

* Use more consistent naming

* Avoid null assertions

Co-authored-by: Elfo404 <me@giordanoricci.com>
2022-10-11 14:40:55 +02:00
Jorge Luis Betancourt
95b9fa3346 Alerting: Fix duration calculation when testing a rule (#56616)
When testing a rule within the legacy alerting the `timeMs` field could
sometimes show negative (and/or wrongly calculated) durations. This happens if the alert evaluation crosses a second boundary. This change uses the full timestamp to compute the eval duration.
2022-10-11 20:40:18 +08:00
Leo
0a183d1ba2 Navigation: Mobile support for topnav items (#56568)
* add topbar layout and wrapper

* mobile support for topnav icons

* improved hooks implementation

* added tests for TopSearchBarSection

* support css overrides for select and valuepicker

* make singlevalue inherit the color from select
2022-10-11 14:24:02 +02:00
Ashley Harrison
90cf76e05e Navigation: Integrate Explore actions into topnav (#56381)
* integrate Explore actions into topnav toolbar

* add keys

* fix unit test

* fix bug with ToolbarButtonRow overflow

* make the render function a bit more readable

* fix overflow not updating when children change
2022-10-11 12:59:17 +01:00
brendamuir
d6fa12c5bc Docs: updates numbering (#56695)
* Docs: updates numbering

* removes full stop
2022-10-11 12:58:15 +01:00
Leo
a91d77003d AnnotationList: Support html content (#54916)
* support html content in annolistpanel

* improve panel tests

* add RenderUserContentAsHTML ui

* sanitize content
2022-10-11 13:35:03 +02:00
Josh Hunt
6969354490 Chore: remove i18n console log (#56691) 2022-10-11 07:22:48 -04:00
Grafana I18n Bot
11c4ab8397 I18n: Crowdin sync (#56688)
* New translations grafana.json (French)

* New translations grafana.json (Spanish)

* New translations grafana.json (German)

* New translations grafana.json (Chinese Simplified)
2022-10-11 07:04:33 -04:00
Dimitris Sotirakis
efc8f985cb Remove build-frontend-packages step from docs pipelines (#56686) 2022-10-11 06:56:43 -04:00
Armand Grillet
74a79b517d Update Alerting changelog (#56684)
Now simpler to use.
2022-10-11 10:55:18 +00:00
Ashley Harrison
8348f486d9 Navigation: Make sure topnav is translated (#56643)
* initial translation progress

* more nav translations

* add subtitle translations

* more specific gitignore path

* fix unit tests
2022-10-11 11:45:58 +01:00
brendamuir
8a3294dcdf Docs: adds external Alertmanager config (#56636)
* Docs: adds external Alertmanager config

* Adds link to add external alertmanager

* updating with george feedbacj
2022-10-11 11:29:11 +01:00
Josh Hunt
d52ab5de2e EchoSrv: Remove $.ajax for loading scripts (#56678)
* user essentials mob! 🔱

lastFile:public/app/core/services/echo/backends/analytics/RudderstackBackend.ts

* user essentials mob! 🔱

lastFile:public/app/core/services/echo/backends/analytics/ApplicationInsightsBackend.ts

* user essentials mob! 🔱

Co-authored-by: Joao Silva <joao.silva@grafana.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-10-11 11:11:23 +01:00
sam boyer
5641029a4a coremodels: Always take runtime arg for NewBase() (#56677) 2022-10-11 05:39:29 -04:00
Gareth Dawson
10a34a041c Add feature tracking for LogRow.tsx (#56656)
* Add feature tracking for LogRow.tsx

* Add type and logRowUid to reportInteraction

* Rename logs variable
2022-10-11 10:04:43 +01:00
GitStart
bc632f239d Tempo: Tab button doesn't work when in the Tags field (#56458)
Co-authored-by: gitstart <gitstart@gitstart.com>
Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: RubensRafael <rubensrafael2@live.com>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Matheus Muniz <87545749+matheusmuniz03@users.noreply.github.com>
Co-authored-by: Thiago Nascimbeni <tnascimbeni@gmail.com>
Co-authored-by: Matheus Muniz <matheusmuniz100@hotmail.com>
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
2022-10-11 10:03:59 +01:00
Dimitris Sotirakis
66cb56de79 CI: Trigger tag on CI changes (#55388)
* Trigger tag on CI changes

* Use github token available for PRs

Remove remote addition

* Replace origin with full url

Remove fetch for origin

Fix fetch

Remove --quite

Add rebase

Stash changes from verify-gen-cue

Cleanup

* Add --quiet when fetching
2022-10-11 12:01:18 +03:00
Joan López de la Franca Beltran
ef17f12c23 Docs: Fix caching.memcached setting name (#56606) 2022-10-11 10:47:57 +02:00
sam boyer
e5a6547a94 coremodels: Update to latest Thema with generics (#56602)
* Update thema to latest

* Deal with s/Library/*Runtime/

* Commit new, working results of codegen
2022-10-11 09:45:07 +01:00
Dimitris Sotirakis
668cb25b82 Fix release test pipelines dependencies (#56671) 2022-10-11 11:42:24 +03:00
George Robinson
52965de369 Alerting: Add doc comments to state struct and normalize fields (#56647) 2022-10-11 09:30:33 +01:00
Gareth Dawson
fa09aef4ba Loki: Add tests for NestedQuery.tsx (#56538)
* WIP: Testing the NestedQuery component

* Add tests for NestedQuery.jsx

* Add aria-labels to select elements

* Update aria-labels

* Create datasource using createLokiDatasource()
2022-10-11 09:22:32 +01:00
Andres Martinez Gotor
8d9da34827 @grafana/ui: EditorField tooltip interactive (#56557) 2022-10-11 10:19:37 +02:00
Matias Chomicki
1b7e31cd27 Loki Monaco Editor: add component tests (#56658)
* feat(loki-monaco-editor): add component tests

* feat(loki-monaco-editor): rename test case

* Chore: add missing export
2022-10-11 04:15:48 -04:00
Dimitris Sotirakis
811f6054c8 Add dependencies (#56666) 2022-10-11 10:05:13 +03:00
Serge Zaitsev
53baecd71f Chore: Move folder service into a separate package (#56591)
* Chore: move folder service interface into a separate package

* copy implementation into a standalone package

* move implementation and tests to the new folder package

* remove leftovers from wire

* add test doubles for folder service

* fix tests in library panels/elements

* fix provideservice in ngalert
2022-10-10 21:47:53 +02:00
Dimitris Sotirakis
eb077db2b0 Add clone-enterprise and init-enterprise steps (#56662) 2022-10-10 22:46:12 +03:00
Grafana I18n Bot
3f89de1747 I18n: Crowdin sync (#56660)
* New translations grafana.json (Chinese Simplified)

* delete zh-CN

Co-authored-by: joshhunt <josh@trtr.co>
2022-10-10 12:15:21 -04:00
Ivana Huckova
3e856da2e4 LabelFilters: Remove redundant css styling (#56653)
* LabelFilters: Remove redundant css

* Remove unused import
2022-10-10 17:59:13 +02:00
kay delaney
0696cd3549 i18n: Fix unnecessary ampersand escaping (#56654) 2022-10-10 11:56:28 -04:00
Dimitris Sotirakis
75c5845749 CI: Split release test pipelines (#56655)
* Split test release pipelines

* Add missing dependencies

* Add release branch case when naming pipeline
2022-10-10 11:46:56 -04:00
Polina Boneva
129a5a29e7 PanelChrome: New Panel Header design Feature Flag (#56450)
* add feature toggle newPanelHeader

* add feature toggle newPanelHeader

* more explicit naming and description of PanelChrome feature flag
2022-10-10 18:03:16 +03:00
kay delaney
efed72096f TagsInput: Prevent adding duplicate tags + refactor, restyle (#56485) 2022-10-10 15:56:02 +01:00
Sven Grossmann
fb31daa92f LogContext: Fix wrong width if lines are wrapped (#56650) 2022-10-10 16:31:14 +02:00
Andres Martinez Gotor
65e56c9fb8 Google Cloud Monitoring: Fix bucket bound for distributions (#56565) 2022-10-10 16:08:33 +02:00
Alex Khomenko
d332747c38 TimeRangeInput: Fix clear button type (#56545) 2022-10-10 17:05:30 +03:00
Grafana I18n Bot
08f9605d83 I18n: Crowdin sync (#56645)
* New translations grafana.json (German)

* New translations grafana.json (Chinese Simplified)
2022-10-10 09:58:36 -04:00
Laura Benz
bc9a37ee8d Glue: Add configuration support to PATCH (#56117)
* feat: add config to tests v0

* feat: add config to UpdateCorrelationCommand

* refactor: repair some tests

* refactor: repair another test

* refactor: repair last test

* refactor: remove possible test

* refactor: add comments

* refactor: add changes from code review

* refactor: implement more detailed patch

* feat: add tests for partial config update

* refactor: make error handling more detailed

Co-authored-by: Giordano Ricci <me@giordanoricci.com>

Co-authored-by: Giordano Ricci <me@giordanoricci.com>
2022-10-10 15:36:14 +02:00
Josh Hunt
680dfde90d I18n: Update crowdin config for i18next json files (#56640) 2022-10-10 14:02:25 +01:00
George Robinson
802d67eeca Alerting: Support values in notification templates (#56457)
We have received a lot of feedback regarding the ValueString in alert notifications. Perhaps one of the most frequent complaints about ValueString is that it is difficult to read because it contains a lot of information, and the information is shown as a JSON-like string. Users have often asked how it can be templated and the answer is that it can't.

Until now users have been able to add custom annotations to their alert rules which contains values via the $values variable added in previous versions of Grafana. However, these custom annotations must be added for each of the user's alert rule, instead of once in a template that all of their alerts can be notified via.

This commit adds then the much requested feature to support values in notification templates. Users can then create a single template that prints the annotations, labels and values of their alerts in a format of their choice!
2022-10-10 13:40:21 +01:00
Sven Grossmann
62674604b4 Loki: Escape label-values in context queries (#56614) 2022-10-10 14:31:19 +02:00
brendamuir
137d332d4f Docs: deletes provisioning from grafana and adds link (#56637)
* Docs: deletes provisioning from grafana and adds link

* updates link
2022-10-10 13:30:23 +01:00
Sven Grossmann
be68bb6b3b LogContext: Fix wrong position of logcontext (#56613)
* fix styling issues

* remove unused class
2022-10-10 14:17:22 +02:00
Giordano Ricci
da9d8fe14f Correlations: Add query editor and target field to settings page (#55567)
* Fix: use type=button in editor

* Grafana-UI: TextArea: make ctextare a block element

* WIP: add field & target query to correlations

* add table query helpers & test ordering

* refactor some tests for disappearance

* chore: move QueryEditorField & add tests

* cleanup & fix typo

* revert textarea changes

* update form to support new config

* move defaults
2022-10-10 12:32:21 +01:00
brendamuir
db68fa358f Docs: removes duplicate sentence in silences (#56629) 2022-10-10 06:56:21 -04:00
brendamuir
2aff817ea8 Docs: adds note on aurora incompatibility (#56621)
* Docs: adds note on aurora incompatibility

* updates with feedback

* adds issue link
2022-10-10 12:51:19 +02:00
Torkel Ödegaard
03e887723a ErrorPage: Fix position of chunk loading error (#56473) 2022-10-10 12:47:33 +02:00
Torkel Ödegaard
462f6b7797 Page: Pages that have hideFromBreadcrumbs set to true should not be added to page Title (#56596)
* Page: Pages that have hideFromBreadcrumbs set to true should not be added to page Title

* Updated test
2022-10-10 12:47:04 +02:00
Josh Hunt
d405f3a877 GrafanaUI: InputGroup: Fix invalid children borders (#56169)
* GrafanaUI: InputGroup: Fix invalid children borders

* tidy story

* zindex priority stack

* clarify comment

* fix inputgroup children type
2022-10-10 06:43:29 -04:00
brendamuir
a84edb274b Docs: changes alert groupings to groups (#56617)
* Docs: changes alert groupings to groups

* One more alert grouping
2022-10-10 12:41:14 +02:00
Timost
f90e72991d docs/provisioning: fix typo in notification policies (#54917) 2022-10-10 10:51:29 +01:00
Alec Sears
c61d6c39a0 Configuration: Update ssl_mode docs in sample.ini to match default.ini (#55138) 2022-10-10 09:04:51 +00:00
kay delaney
d79f60d73f QueryEditorRow: Fix broken drag-and-drop reordering (#56515) 2022-10-10 09:40:54 +01:00
Sven Grossmann
1bcce79d4e LogContext: Add header and close button to modal (#56283)
* added context header

* Rename to Log Context

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

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2022-10-10 09:33:18 +02:00
Sofia Papagiannaki
4cdbfb7606 Chore: Timeout integration package tests faster (#56287) 2022-10-10 09:27:04 +02:00
Serge Zaitsev
169610fd27 Chore: Reduce test timeouts to 5 minutes (#56599) 2022-10-10 09:26:47 +02:00
Joe Blubaugh
7312a2dab0 Alerting: Mark all tests that interact with the database as Integration tests. (#54875)
Previously, two tests were not explicitly marked as integration tests
and so were not run against all 3 supported databases in the CI
environment.
2022-10-10 01:54:54 -04:00
Ryan McKinley
b24be6c0fc ObjectStore: add a kind registry (#56507) 2022-10-08 12:05:46 -04:00
Nathan Marrs
ac91df0ea2 Canvas: Add demo dashboards (#56351)
Co-authored-by: drew08t <drew08@gmail.com>
Co-authored-by: Adela Almasan <adela.almasan@grafana.com>
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-10-07 21:34:18 -04:00
Yuriy Tseretyan
3487e68d15 Alerting: Fix migration to create rules with group index 1 (#56511) 2022-10-07 17:20:01 -04:00
Yuriy Tseretyan
e2f1201382 Alerting: Fix migration to not add label "alertname" (#56509)
* do not add label alertname because it is overridden in state manager anyway
* update state manager to not consider labels with same value as dupe
2022-10-07 15:06:53 -04:00
Artur Wierzbicki
4b2a940659 Search: wrap data.Frame in a backend.DataResponse and return it directly when the index is not ready (#56522) 2022-10-07 11:32:37 -07:00
Artur Wierzbicki
bf264d2f76 Query library: requiresDevMode dummy backend (#56466)
* query library - dummy backend

* fix tests

* dont explicitly marshall backend dataresponse

* skip integration tests

* null check for tests

* added query library to codeowners

* null check for tests

* lint
2022-10-07 11:31:45 -07:00
Ivana Huckova
23e04c0f9c Elasticsearch: Add integration tests for http header handling (#56542)
* Elasticsearch: Add integration test

* Fix lint
2022-10-07 18:21:48 +02:00
Eric Leijonmarck
53f0928321 Docs: Add variable expansion recommendation (#56368)
* docs: add variable expansion recommendation

* docs: updated the ldap docs in configure grafana
2022-10-07 17:04:37 +01:00
Leo
9c50131c2c Navigation: Added organisation switcher next to grafana logo (#56361)
* added org dropdown to topnav

* render icon and dropdown for mobile screen

* remove switch org from profile node

* adjust styles to be mobile first

* add test for select

* hide profile node only when topnav is on

* replace margin with gap instead

* improve tests

* add aria labels

* fix broken test
2022-10-07 17:52:13 +02:00
Sonia Aguilar
3990d2b2b3 Alerting/handle 0s last notify duration notification error feedback (#56541)
* Show '-' in notifiers table when lastNotifyAttemptDuration is 0s

* Add tests for no attempt (lastNotifyAttempt null date) and no last duration (lastNotifyAttemptDuration 0s)
2022-10-07 17:07:02 +02:00
Torkel Ödegaard
754fc37972 PluginPage: Fix finding root section for standalone pages (#56554) 2022-10-07 16:33:36 +02:00
Ashley Harrison
ff41b9544b Chore: more typing improvements to @grafana/ui (#56544)
* improve grafana-ui types

* more type improvements

* better useState type
2022-10-07 15:22:21 +01:00
Ivana Huckova
a4c5801440 Loki: Fix redundant escaping in adhoc filter with regex match (#56447)
* Loki: Fix redundant escaping in adhoc filter with regex match

* Update data.js

* Simplify test

* Simplify test

* Update

* Add more tests
2022-10-07 16:21:59 +02:00
Konrad Lalik
d945091ff1 Alerting: Fix evaluation interval validation (#56115)
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
2022-10-07 15:01:47 +02:00
Andres Martinez Gotor
76868bad04 AzureMonitor: Allow multiple resources in the API for Metrics (#56118) 2022-10-07 14:57:01 +02:00
Gabriel MABILLE
7595ed0668 FIX: Remove RBAC datasource permissions upon datasource deletion (#56530)
* FIX: Remove RBAC datasource permissions upon datasource deletion

* Use scope provider instead

* Fix test
2022-10-07 08:30:15 -04:00
GitStart
0eb3afbd14 Form validation problem in table panel option (column width & minimum column width) (#56452)
Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: gitstart <gitstart@gitstart.com>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Matheus Muniz <87545749+matheusmuniz03@users.noreply.github.com>
Co-authored-by: Thiago Nascimbeni <tnascimbeni@gmail.com>
Co-authored-by: Matheus Muniz <matheusmuniz100@hotmail.com>
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
2022-10-07 15:06:50 +03:00
Emil Tullstedt
22756913ba Errutil: Update documentation for Go 1.19 (#55807) 2022-10-07 12:47:43 +02:00
Emil Tullstedt
c2d3a31772 Chore: Upgrade Go to 1.19.2 (#56355) 2022-10-07 12:47:24 +02:00
Josh Hunt
891f9c00a1 I18n: Add lint rule to enforce correct i18n imports (#56487)
* I18n: Add lint rule to enforce correct i18n imports

* ignore in gui wrapper
2022-10-07 11:46:28 +01:00
Joey Tawadrous
74c809f544 Plugins: Introduce new Flame graph panel (#56376)
* Flamegraph

* Updated flame graph width/height values

* Fix top table rendering issue

* Add feature toggle for flamegraph in explore

* Update tests

* Hide flamegraph from dash panel viz list if feature toggle not enabled

* Show table if no flameGraphFrames

* Add flame graph to testdata ds

* Minor improvement
2022-10-07 11:39:14 +01:00
Sonia Aguilar
a18a3d7628 Show No attempts instead of OK when there is no attempt for notifier (#56494) 2022-10-07 11:41:18 +02:00
brendamuir
939caa67a2 Docs: adds alertmanager overview (#56527)
* Docs: adds alertmanager overview

* updating with georges feedback

* adds deprecation note to API docs

* update to provisioning instuctions
2022-10-07 10:26:51 +01:00
George Robinson
762688d67f Alerting: Fix pq: missing FROM-clause for table "a" (#56453)
This commit fixes a bug where changing the Folder or Rule Group of an existing rule returns the following error in PostgreSQL "pq: missing FROM-clause for table a"
2022-10-07 10:18:49 +01:00
Joe Blubaugh
13067b39da Alerting: Update replacement of prometheus-alertmanager (#56519)
grafana.com/grafana/prometheus-alertmanager has been updated to a
version that fixes some bugs upstream. This change just updates that
dependency and a few shared ones.
2022-10-07 17:10:20 +08:00
Torkel Ödegaard
6c39a1995f Page: More easily support full height pages (#56524)
* Page: More easily support full height pages

* tweaks to JSONSettingsPage
2022-10-07 10:56:12 +02:00
Dimitris Sotirakis
df2abf09c2 Use io.ReadAll instead of json.Decode (#56528) 2022-10-07 04:27:18 -04:00
Ivana Huckova
eef3f28447 Loki: Add integration tests for http header handling (#56478)
* Loki: Add integration tests for http header handling

* Fix linting
2022-10-07 10:16:41 +02:00
Emil Tullstedt
bb479e030a RBAC: Redirect to /login when forceLogin is set (#56469) 2022-10-07 08:18:56 +02:00
Victor Marin
b622a87aee StateTimeline: Fix tooltip showing erroneously in shared crosshair dashboards (#55809)
* StateTimeline: Fix shared crosshair

* Fix for StatusHistory also
2022-10-07 08:56:15 +03:00
Leon Sorokin
21d9cf0db4 Thresholds: fix line rendering with multiple y axes (#56516) 2022-10-06 17:18:47 -06:00
Beto Muniz
b5cb917dfa Fix queries with repeated references (#56497) 2022-10-06 17:59:14 -03:00
lean.dev
356318e387 Docs: Updating Public Dashboard documentation (#56504)
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2022-10-06 17:47:38 -03:00
Jeff Levin
331110bde5 refactor public dashboards middleware testing (#55706)
This PR refactors how we add the orgId to the context on a public dashboard paths. We also split out accessToken handling into its own package and rework status code for "RequiresValidAccessToken". We will be modeling all endpoints to use these status codes going forward. Additionally, it includes a scaffold for better middleware testing and refactors existing tests to table drive tests.
2022-10-06 12:35:19 -08:00
Ryan McKinley
609abf00d1 ObjectStore: Write json as json when possible (#56433) 2022-10-06 15:48:53 -04:00
Yuriy Tseretyan
7b6437402a Alerting: Refactor state manager's cache (#56197)
* remove ResetAllStates because it's not used
* refactor cache to accept logs, metrics and url as method args
* update manager Warm method to set the entire state at once
* remove unused reset method
* introduce ruleStates
* change getOrCreate to belong to ruleStates
* update Get to not return error
2022-10-06 15:30:12 -04:00
Drew Slobodnjak
15d2653b89 Geomap: Docs for 9.2 (#56493) 2022-10-06 11:32:39 -07:00
Misi
1de0f4453e Chore: Make NewCookieOptions exported in cookies.go (#56476) 2022-10-06 20:00:54 +02:00
Josh Hunt
5361efc225 I18n: Migrate to I18next (#55845)
* Switch from lingui from i18next

* Change lingui messages to i18next messages

* Change lingui messages to i18next messages (grafana-ui)

* Init i18n for tests
2022-10-06 16:34:04 +01:00
Nicolas Janicaud Gondoin
c1d6df4eb7 Fix issue 55626 (#55636)
Reset the mapping table for Dynamic Geojson
2022-10-06 08:30:03 -07:00
Virginia Cepeda
48f0f4bb91 Alerting: subscribe to Dashboard refresh interval for alert panels (#56347)
* Subscribe to Dashboard refresh interval for alert panels

* Add test

* Remove unused import

* Use useEffectOnce when obtaining dashboard
2022-10-06 12:02:19 -03:00
Matias Chomicki
729ce8bb72 Loki: query editor using Monaco (#55391)
* loki: switch to a monaco-based query field, step 1 (#46291)

* loki: use monaco-logql (#46318)

* loki: use monaco-logql

* updated monaco-logql

* fix all the tests (#46327)

* loki: recommend parser (#46362)

* loki: recommend parser

* additional improvements

* more improvements

* type and lint fixes

* more improvements

* trigger autocomplete on focus

* rename

* loki: more smart features (#46414)

* loki: more smart features

* loki: updated syntax-highlight version

* better explanation (#46443)

* better explanation

* improved help-text

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

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

* Fix label

* feat(loki-monaco-editor): add monaco-logql as a dependency

* feat(loki-monaco-editor): add back range function removed during merge

* feat(loki-monaco-editor): sync imports with recent changes

* feat(loki-monaco-editor): add missing lang provider functions

* feat(loki-monaco-editor): fix imports

* feat(loki-monaco-editor): display monaco editor by default

Temporarily

* Chore: remove commented code

* Chore: minor refactor to NeverCaseError

* Chore: minor code cleanups

* feat(loki-monaco-editor): add history implementation

Will see how it behaves and base the history slicing on tangible feedback

* feat(loki-monaco-editor): turn completion data provider into a class

* Chore: fix missing imports

* feat(loki-monaco-editor): refactor data provider methods

Move complexity scattered everywhere to the provider

* Chore: clean up redundant code

* Chore: minor comments cleanup

* Chore: simplify override services

* Chore: rename callback

* feat(loki-monaco-editor): use query hints implementation to parse expression

* feat(loki-monaco-editor): improve function name

* Chore: remove superfluous variable in favor of destructuring

* Chore: remove unused imports

* Chore: make method async

* feat(loki-monaco-editor): fix deprecations and errors in situation

* feat(loki-monaco-editor): comment failing test case

* Chore: remove comment from test

* Chore: remove duplicated completion item

* Chore: fix linting issues

* Chore: update language provider test

* Chore: update datasource test

* feat(loki-monaco-editor): create feature flag

* feat(loki-monaco-editor): place the editor under a feature flag

* Chore: add completion unit test

* Chore: add completion data provider test

* Chore: remove unwanted export

* Chore: remove unused export

* Chore(loki-query-field): destructure all props

* chore(loki-completions): remove odd string

* fix(loki-completions): remove rate_interval

Not supported

* fix(loki-completions): remove line filters for after pipe case

We shouldn't offer line filters if we are after first pipe.

* refactor(loki-datasource): update default parameter

* fix(loki-syntax): remove outdated documentation

* Update capitalization in pkg/services/featuremgmt/registry.go

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

* refactor(situation): use node types instead of names

* Chore: comment line filters pending implementation

It's breaking the build due to a linting error.

* Chore: update feature flag test after capitalization change

* Revert "fix(loki-completions): remove line filters for after pipe case"

This reverts commit 3d003ca4bc.

* Revert "Chore: comment line filters pending implementation"

This reverts commit 84bfe76a6a.

Co-authored-by: Gábor Farkas <gabor.farkas@gmail.com>
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
Co-authored-by: Ivana Huckova <ivana.huckova@gmail.com>
2022-10-06 10:35:30 -04:00
Galen Kistler
8fd4fcb987 Prometheus: Annotation query filtering values less then 1 (#53969)
* prevent annotation query from filtering values less then 1
* unit tests were asserting that gaps in data (0 value) are removed from annotation, update filter to exclude 0
2022-10-06 09:26:08 -05:00
Sonia Aguilar
01526d9053 Add error details in notification error feedback tooltip (#56472) 2022-10-06 16:20:07 +02:00
Dimitris Sotirakis
66e8f39ce8 Packaging: Change from 0750 to 0755 folder permissions when packaging (#56436)
* Change from 0750 to 0755

* Change to 0o755

* Skip lint when creating dir
2022-10-06 17:11:11 +03:00
Sonia Aguilar
d8d8ef1aff Alerting: Add Notification error feedback on contact points view (#56225)
* Alerting: Receivers integrations error feedback: WIP - Add notifications error at the top right on contact points view (#52390)

* Add interfaces for contact point errors

* [WIP] Create fake response for the new service to get contact point errors

* [WIP] Create action an reducer for the new service to get contact point errors

* Fetch fetchContactPointStates in Contact Points tab every 20s and when AM changes

* [WIP] Use store to get error count

* Show number of integrations errors at the contact points main view

* Add warning icon and refactor styles using getStyles

* Change lastNotify type to string instead of DateTime

* Use Stack component from experimental library when it is possible

* Alerting: Add receivers error feedback in contact point list (#52524)

* Refactor types for contact points state

* Add health column in ReceiversTable in case error state is available for this AM

* Create method for converting contact points state DTO to the FE type used in Redux store

* Update types

* Fix indexOf criteria getting integration type

* Change type name to integrationType name

* Change new components to be named functions to follow the FE style-guide

* Fix typos

Co-authored-by: Konrad Lalik <konrad.lalik@grafana.com>

* Decouple ReceiversTable from Redux state

* Create private useContactPointsState hook to simplify code in ReceiversTable component

* Add tests for getIntegrationType and refactor the method to validate the name

* Add tests for contactPointsStateDtoToModel method

* Remove unnecessary check

* Use Badge compoment for health status in contact point list

* Create new method parseIntegrationName to simplify getting types and index from integration name

Co-authored-by: Konrad Lalik <konrad.lalik@grafana.com>

* Alerting: Show integrations error feedback when expanding contact point in list (#52920)

* Use DynamicTable for rendering list of contact points and make them expandable if error status is available

* Render expanded content for contact points integrations

* Style and format last notify column

* Add send resolve column to the integration details

* Fix receiver id for DynamicTable row

* Update clock icon in integration state

* Fix tests

* Add PR review sugestions

* Alerting/integrations error feedback handle null dates in response 3 (#55659)

* Update fake response with lastNotify ISO8601 formatted, to be aligned with latest BE changes

* Update LastNotify in ReceiversTable component to handle null date

* Alerting/integrations error feedback handle 404 state not available (#55803)

* Create fetchContactPointsState using the future contact point url and handle 404 error

* Add contact points state tests

* Alerting/update receivers dto naming 2 (#56201)

* Update NotifierStatus naming and fix sendResolved not being updated in UI

* Return always empty ContactPointsState array when catching an error in the request response

* Fix test

* Show notification status only in notifications main view

* Calculate total error count from the final contactPointsState object, to avoid errors when duplicated entries are returned wronly in the response

* Add PR review suggestions

Co-authored-by: Konrad Lalik <konrad.lalik@grafana.com>
2022-10-06 15:23:38 +02:00
Torkel Ödegaard
9300ae7ce6 NavTree: Don't add license and stats page unless your a Grafana Admin (#56410) 2022-10-06 14:30:51 +02:00
Gábor Farkas
3a76c7aac3 grafana-ui: removed obsolete test that cause jest warnings (#56444) 2022-10-06 11:35:21 +00:00
Ashley Harrison
c5171b84a0 actually convert Cloudwatch ConfigEditor test to RTL (#56461) 2022-10-06 12:14:41 +01:00
Torkel Ödegaard
a8b883b1fa TopNav: Adding sign in to topnav and hiding it mega menu (#56403)
* TopNav: Adding sign in to topnav and hiding it mega menu

* Added target _self

* remove scss change

* Fix sign in link

* Fix other link
2022-10-06 13:00:32 +02:00
Torkel Ödegaard
0958d9ba55 Theme: Change body line-height to fix alignment issue (#56442)
* Theme: Change body line-height to fix alignment issue

* Updates
2022-10-06 12:59:43 +02:00
Levente Balogh
55187ebc48 Navtree: Make it possible to configure standalone plugin pages (#56393)
* feat: make it possible to register standalone app plugin pages under different sections

* refactor(sample.ini): use "admin" instead of "starred" section in the INI

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

* feat(defaults.ini): add app navigation settings to the defaults.ini as well

* fix: use the correct key in the tests

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-10-06 12:57:03 +02:00
Joe Blubaugh
b1df15c4b9 Alerting: Add basic test wrappers to notification channel API test. (#56432)
Adds t.Run calls that supply the name of a receiver and its integrations
when the API response is being verified. This test has a rare flake and
it's difficult to track down without more context for the test failure.
2022-10-06 17:38:54 +08:00
Leo
b0ba94f316 Navigation: Use page nav in silence and policy notification pages (#55753)
* use pagenav in mutetiming form

* use pagenav in alert policy page

* use pageNav for Silence page

* added missing breadcrumbs
2022-10-06 11:18:43 +02:00
Dimitris Sotirakis
3aacda5579 Move files under pkg/build/packaging (#56435) 2022-10-06 03:33:40 -04:00
Dimitris Sotirakis
ec7d9e196e Change from grabpl to build for grafana-com (#56434) 2022-10-06 08:14:38 +01:00
Torkel Ödegaard
fe1395a1ec Revert "TopNav: Section styling fix (#56372)" (#56399)
This reverts commit b396f16fe1.
2022-10-06 08:23:29 +02:00
Joe Blubaugh
b476ae62fb Alerting: Write and Delete multiple alert instances. (#55350)
Prior to this change, all alert instance writes and deletes happened
individually, in their own database transaction. This change batches up
writes or deletes for a given rule's evaluation loop into a single
transaction before applying it.

These new transactions are off by default, guarded by the feature toggle "alertingBigTransactions"

Before:

```
goos: darwin
goarch: arm64
pkg: github.com/grafana/grafana/pkg/services/ngalert/store
BenchmarkAlertInstanceOperations-8           398           2991381 ns/op         1133537 B/op      27703 allocs/op
--- BENCH: BenchmarkAlertInstanceOperations-8
    util.go:127: alert definition: {orgID: 1, UID: FovKXiRVzm} with title: "an alert definition FTvFXmRVkz" interval: 60 created
    util.go:127: alert definition: {orgID: 1, UID: foDFXmRVkm} with title: "an alert definition fovFXmRVkz" interval: 60 created
    util.go:127: alert definition: {orgID: 1, UID: VQvFuigVkm} with title: "an alert definition VwDKXmR4kz" interval: 60 created
PASS
ok      github.com/grafana/grafana/pkg/services/ngalert/store   1.619s
```

After:

```
goos: darwin
goarch: arm64
pkg: github.com/grafana/grafana/pkg/services/ngalert/store
BenchmarkAlertInstanceOperations-8          1440            816484 ns/op          352297 B/op       6529 allocs/op
--- BENCH: BenchmarkAlertInstanceOperations-8
    util.go:127: alert definition: {orgID: 1, UID: 302r_igVzm} with title: "an alert definition q0h9lmR4zz" interval: 60 created
    util.go:127: alert definition: {orgID: 1, UID: 71hrlmR4km} with title: "an alert definition nJ29_mR4zz" interval: 60 created
    util.go:127: alert definition: {orgID: 1, UID: Cahr_mR4zm} with title: "an alert definition ja2rlmg4zz" interval: 60 created
PASS
ok      github.com/grafana/grafana/pkg/services/ngalert/store   1.383s
```

So we cut time by about 75% and memory allocations by about 60% when
storing and deleting 100 instances.
2022-10-06 14:22:58 +08:00
Ryan McKinley
b4e23e5d32 ObjectStore: update dev protobuf definitions (#56428) 2022-10-05 18:46:17 -07:00
Leon Sorokin
8300702524 Search: fuzzy match dashboard names in frontend from full list (#55721) 2022-10-05 18:32:35 -04:00
juanicabanas
69c49f6ba2 PublicDashboards: Make mixed datasource calls concurrently (#56421)
PublicDashboards: Make mixed datasource calls concurrently
2022-10-05 18:45:17 -03:00
ying-jeanne
d9cc292066 Star: Add uid in the endpoint (#54340)
* add new uid endpoing for star

* add store pool into service

* fix the endpoint caller

* udpate swagger file

* Update pkg/api/stars.go

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>

* remove useless code for star dashboard

* add new uid endpoing for star

* add store pool into service

* fix the endpoint caller

* Update pkg/api/stars.go

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>

* Update pkg/api/stars.go

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>

* solve linter

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>
2022-10-05 22:32:49 +02:00
Alexander Weaver
8df830557a Alerting: Move annotation functionality behind a history persistence interface (#56133)
* Move annotation functionality behind a history persistence interface

* Rename to RecordState

* Fix lint error in import aliasing

* One more import linter error
2022-10-05 15:32:20 -05:00
Kevin Yu
b3087cfcd1 QueryEditorRow: Only pass error to query editor if panel is not loading (#56350) 2022-10-05 12:19:49 -07:00
Ryan McKinley
97d19830cf ObjectStore: rename modified to updated (#56420) 2022-10-05 14:58:46 -04:00
Artur Wierzbicki
a94acb7f61 Object store: get user from context (#56346)
* GRPC Server: Add signedInUser to context after auth

* add permissions to signedInUser

* add access control permissions test

* add additional signedInUser checks

* get user from context

* move `UserFromContext` to object/auth.go

Co-authored-by: Todd Treece <todd.treece@grafana.com>
2022-10-05 17:00:34 +00:00
Beto Muniz
4a14d75086 Add prop to improve memory usage listing metrics (#56398) 2022-10-05 12:19:12 -03:00
Andres Martinez Gotor
2cdbd05634 Azure Monitor: Fix subscription selector when changing data sources (#56284) 2022-10-05 16:59:06 +02:00
Sven Grossmann
0d8ea2bb34 LogContext: Fix scroll position in upper context group (#56370)
* fix log row being falsely added to context

* do not add to many lines

* fix scroll position in context

* more flexible id comparison

* add original refid to context query

* added missing row comparison

* updated comment

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

Co-authored-by: Matias Chomicki <matyax@gmail.com>
2022-10-05 16:26:22 +02:00
Sven Grossmann
2410b88ad1 Logs: Show LogRowMenu also for long logs and wrap-lines turned off (#56030)
* show logrowmenu as new table-cell

* fix dashboard position

* added reasonable position

* fix log row message not beeing 100%
2022-10-05 16:11:08 +02:00
idafurjes
bc7a383252 Remove org methods from sqlstore interface (#56358)
* Remove org methods from sqlstore interface

* Remove some mocks

* Fix some tests
2022-10-05 15:47:56 +02:00
Yuriy Tseretyan
ad2a1dd680 Alerting: Start ticker only when scheduler starts (#56339) 2022-10-05 09:35:02 -04:00
Andres Martinez Gotor
8594e648e8 Azure Monitor: Adapt empty Logs response (#56378) 2022-10-05 15:29:34 +02:00
Ivan Ortega Alba
7fd613ec0d E2E: Remove time zone scenario flackyness (#55458)
Co-authored-by: polinaboneva <polina.boneva@grafana.com>
2022-10-05 16:00:33 +03:00
GitStart
48ebaa48cc Toolkit: Remove changelog command (already replaced by a github workflow) (#56073)
Co-authored-by: gitstart <gitstart@gitstart.com>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: Matheus Muniz <matheusmuniz100@hotmail.com>
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Thiago Nascimbeni <tnascimbeni@gmail.com>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
2022-10-05 14:44:53 +02:00
Gilles De Mey
87cba8836f Alerting: Expressions pipeline redesign (#54601) 2022-10-05 14:35:15 +02:00
Tania
222c33c307 Remove branding feature toggle (#56379) 2022-10-05 14:07:35 +02:00
Ashley Harrison
78a57f2064 Navigation: use ToolbarButton in TopSearchBar for consistency (#56371)
* use ToolbarButton in TopSearchBar for consistency

* Removed unnessary styles

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-10-05 12:22:47 +01:00
Dimitris Sotirakis
636ae8d091 Update grabpl version to v3.0.11 (#56377) 2022-10-05 14:18:28 +03:00
Torkel Ödegaard
b396f16fe1 TopNav: Section styling fix (#56372) 2022-10-05 13:06:51 +02:00
Jack Westbrook
dcc02a8ebe Storybook: Fix asset paths for hosted storybooks (#56319)
* feat(sass): introduce font-file-path var to define where to load fonts from

* feat(storybook): introduce storybook sass theme styles to set font file paths

* chore(sass): change imports so treated as sass rather than css

* feat(storybook): filter assets so builds dont contain thousands of files
2022-10-05 12:10:29 +02:00
Torkel Ödegaard
aa274500cf TopNav: Fixes to page and plugin page handling (#56278)
* Added labels

* App page fixes

* Switch to switch

* Fixing sort position for Apps
2022-10-05 11:46:27 +02:00
Ivana Huckova
4469572b27 Loki: Add support for range aggregations with by grouping (#56184)
* Loki: Fix unwrapped range operations with grouping

* Update, fix tests

* Fix modeller
2022-10-05 11:32:33 +02:00
Gilles De Mey
015651f860 @grafana/ui: adds a virtualized options for the Select component (#55629) 2022-10-05 10:33:47 +02:00
Ashley Harrison
7ac7f844f4 improve some grafana-ui types (#56318) 2022-10-05 09:04:10 +01:00
Levente Balogh
ae5e8bc53b refactor: rename Data Connections to Connections (#56353) 2022-10-05 09:56:58 +02:00
brendamuir
b1b3f9e24c Fixes alertmanagers whats new entry (#56356) 2022-10-05 08:39:50 +01:00
idafurjes
5167c55760 Chore: Move methods from sqlstore to user store (#56305)
* Copy sqlstore methods to suer store

* Adjust ProvideService signatures in test

* Add xorm tags and tests for search

* Remove methods from sqlstore

* fix lint in tests
2022-10-05 09:34:36 +02:00
Torkel Ödegaard
580ca144fd StyleGuide: Minor fix for themes.md (#56012)
* Update themes.md

* Update themes.md

* Updates
2022-10-05 08:50:39 +02:00
Gábor Farkas
3f4bf76324 cloudwatch-logs: use not-deprecated version of type (#56239) 2022-10-05 08:47:57 +02:00
Dimitris Sotirakis
5cdc932f8c CI: Stop publishing OSS images for security mode (#56088)
* No-op: Refactor publish images pipeline struct

* Stop publishing images for OSS
2022-10-05 09:39:38 +03:00
George Rodrigues
8950d86141 fix: some typos (#56171) 2022-10-04 18:43:49 -05:00
Todd Treece
4163f31d76 GRPC Server: Add signedInUser to context (#56059) 2022-10-04 16:31:02 -04:00
sam boyer
ba97b268d0 Playlist: Split PlaylistItem into standalone TS type (#56343)
* playlist: Split PlaylistItem into standalone TS type

* update playlist model

* actually set the title

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-10-04 16:08:26 -04:00
Nathan Marrs
2c1c98f3b6 Canvas: Promote to beta (#56217)
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-10-04 12:29:56 -07:00
Adela Almasan
8833e35b43 Canvas: Increase Add Item picker width (#56204) 2022-10-04 15:22:11 -04:00
Ryan McKinley
4fc9b9aa35 Storage: Cleanup object history API (#56215) 2022-10-04 14:57:26 -04:00
Kat Yang
7715672fb3 Chore: use org service methods (#55768)
* Chore: use org service methods

* fix tests

* fix errors

* adjust func signatures for getbyname

* 💩

* Use the same fake service to get the user in AC and in HS

* Fix middleware test

* Fix more middleware test

* Fix api tests

Co-authored-by: gamab <gabi.mabs@gmail.com>
Co-authored-by: Ida Furjesova <ida.furjesova@grafana.com>
2022-10-04 14:48:02 -04:00
Grot (@grafanabot)
169f1ab974 ReleaseNotes: Updated changelog and release notes for 9.1.7 (#56323) 2022-10-04 16:56:21 +00:00
Ryan McKinley
d5e2713168 Storage: Add HTTP endpoint for object store service (#56214) 2022-10-04 09:40:15 -07:00
Sofia Papagiannaki
bba6eb1f2d Chore: update latest.json to 9.1.7 (#56315) 2022-10-04 19:32:13 +03:00
Jack Westbrook
d7228829ad Grafana UI: Clean up bundle (#56100)
* chore(grafana-ui): don't bundle emotionPerfTest

* chore(grafana-ui): fix circular dependencies that cause esm chunks to not match up

* chore(grafana-ui): prevent bundling all css properties in package types
2022-10-04 17:51:45 +02:00
Grot (@grafanabot)
a50017da1d ReleaseNotes: Updated changelog and release notes for 9.1.7 (#56313) 2022-10-04 18:26:30 +03:00
Ryan McKinley
3b1a8d45ed Playlist: update service so it supports both read+write (#55959) 2022-10-04 11:11:18 -04:00
Ashley Harrison
d293055ef6 enable rule jsx-a11y/iframe-has-title (#56292) 2022-10-04 16:04:28 +01:00
Giordano Ricci
a7de5182b0 Explore: Revert split pane resize feature (#56310)
* Revert "Explore: Prevent panes from disappearing when resizing window in split view (#55696)"

This reverts commit 0a5aa19ca2.

* Revert "Explore: Add resize to split view, with Min/Max button (#54420)"

This reverts commit c3e4f1f876.
2022-10-04 15:42:43 +01:00
Ashley Harrison
d3f50f791c Convert test to RTL (#56279) 2022-10-04 15:37:47 +01:00
Dimitris Sotirakis
d94af21cac Replace filename with path without the local dir (#56296) 2022-10-04 17:18:07 +03:00
brendamuir
8176810b2b adds alertmanager to whats new (#56304) 2022-10-04 14:59:52 +01:00
Christopher Moyer
d0b437741e adds 4 links to blogs (#56193) 2022-10-04 08:28:00 -05:00
Gábor Farkas
291276e767 elasticsearch: improved types in the typescript files (#56293) 2022-10-04 15:08:57 +02:00
Todd Treece
152c7f149a Prometheus: Add Exemplar sampling for streaming parser (#56049) 2022-10-04 08:40:01 -04:00
Leo
4eea5d5190 Navigation: Use navid and pagnav in alert rules pages (#55722)
* add navid and pagenav to edit/add/view alert rules

* move ruleeditor smaller component to its own file

* fix form alignments with new layout

* fixed broken test

* reuse AlertingPageWrapper
2022-10-04 14:36:36 +02:00
idafurjes
a25516fbe3 Chore: Copy sqlstore methods to user store (#56280)
* Chore: Copy sqlstore methods to user store

* Fix xorm tag

* Add tests

* Remove unused methods from sqlstore
2022-10-04 14:14:32 +02:00
Mitch Seaman
3d58f39b25 Remove Custom Branding previews from What's new (#56273)
We need to remove the custom branding announcement from the 9.2 release, since we will not release the feature in Grafana Enterprise.
2022-10-04 13:06:10 +01:00
Gábor Farkas
3fb104209f explore: logs volume histogram: anchor graph to zero (#56200) 2022-10-04 13:54:39 +02:00
Ashley Harrison
e942a3d99d enable jsx-a11y/no-autofocus (#56288) 2022-10-04 12:54:14 +01:00
Gabriel MABILLE
80dfa788c6 Azure OAuth: Use TID from id_token by default (#56264)
Co-authored-by: Kalle Persson <kalle.persson@grafana.com>

Co-authored-by: Kalle Persson <kalle.persson@grafana.com>
2022-10-04 13:48:15 +02:00
Sofia Papagiannaki
91b4ce08a9 Update github.com/labstack/echo/v4 (#56226) 2022-10-04 14:31:05 +03:00
Will Browne
1038ac7308 DataSources: Remove unused cfg from core Grafana data source (#56188)
* remove unused cfg from grafana ds

* fix test
2022-10-04 06:32:25 -04:00
Todd Treece
2d433194d0 GRPC Server: Add tracing interceptors (#56045)
Co-authored-by: Artur Wierzbicki <artur.wierzbicki@grafana.com>
2022-10-04 14:27:14 +04:00
idafurjes
a863a4d95d Chore: Copy user methods over to user store (#56000)
* Chore: Copy user methods over to user store

* Fix some tests and bugs

* Add some more tests

* Move tests to user store

* Move back the tests

* Add some tests
2022-10-04 12:17:55 +02:00
Ashley Harrison
ab09f2783c fix section root styling, parentItem will be the home item now (#56266) 2022-10-04 11:17:12 +01:00
Dimitris Sotirakis
26d64a778e Add cronjob option at switch case (#56272) 2022-10-04 11:15:47 +01:00
renovate[bot]
cb5195329b Update dependency selecto to v1.20.2 (#56245)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-04 10:42:49 +01:00
Joe Blubaugh
ce89624ca2 Alerting: Update imported prometheus alertmanager version. (#56228)
Version 0.24.0 has a few bugs that cause panics. We update here to the
latest commit on github.com/prometheus/alertmanager's main branch.

Panic Bugs:
https://github.com/prometheus/alertmanager/issues/2936
https://github.com/prometheus/alertmanager/issues/3064
2022-10-04 17:41:34 +08:00
Ashley Harrison
7e5509891a Navigation: adjust megamenu position in mobile (#56262)
* adjust megamenu position in mobile

* improve mobile breadcrumb logic
2022-10-04 10:40:34 +01:00
Gábor Farkas
3c1de8750c GrafanaData: Deprecate the LogsParser type (#56242)
* added copy of code to main-grafana

* grafana-data: add depreceted-notice
2022-10-04 11:25:22 +02:00
Andreas Christou
462ca50512 AzureMonitor: Ensure resourceURI template variable is migrated (#56095)
* Ensure resourceURI template vars are migrated

- Do not filter queries containing a resource URI template
- Update migration
- Add test

* Update condition

* Review
2022-10-04 04:44:34 -04:00
renovate[bot]
efe4ce06a2 Update dependency sass to v1.55.0 (#56243)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-04 09:41:26 +01:00
Levente Balogh
cc6fae18db BackendSrv: Make it possible to pass options to .get|post|patch... methods (#51316)
* feat: make it possible to pass in `options` to `.get()`, `.post()`, etc methods

* feat(Datasource): make it possible to specify `optinos` for `getResource()` and `postResource()`

* fix(BackendSrv): use partial `BackendSrvRequest`

* feat(Datasource): make it possible to set `options` for resource requests

* refactor(BackendSrv): remove internal usage of `.request()`

* fix(GettingStarted): remove unnecessary import

* fix: fix type issues by typing the delete dashboard response

* refactor: use more strict types for `params`

By reusing the type of `BackendSrvRequest.params`

* refactor: make the options paramater partial

* fix: extract `data` from the fetch response

* docs: update the deprecation notice or `BackendSrv.request()`

* refactor: use `.request()` as if it was private

* refactor: remove unnecessary change
2022-10-04 10:40:21 +02:00
Giordano Ricci
489b302c03 Glue: Correlations minor APIs behavior improvements (#56078)
* add correlation config type, CorrelationConfig validator & default values

* make config required when creating correlations

* make targetUID optional, add validation for createCommand & configType

* fix tests

* update remaining tests

* fix lint error

* Update pkg/services/correlations/models.go

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

* update docs

Co-authored-by: Piotr Jamróz <pm.jamroz@gmail.com>
2022-10-04 09:39:55 +01:00
Giordano Ricci
3381629d3d Chore: Convert Wrapper to function component (#56172)
* WIP

* remove comment
2022-10-04 09:39:22 +01:00
Jesus Vazquez
cb99b94b01 Add error information to graphite queries tracing (#55249)
This commit extends graphite QueryData() instrumentation to include in
the traces information about possible errors.

I've added an attribute about the graphite response code as well as
records for errors if there are any.
2022-10-04 10:30:27 +02:00
Ashley Harrison
317b353b34 Navigation: Collapsible section nav implementation (#55995)
* initial collapsible section nav implementation

* fix unit tests

* automatically collapse sectionnav when below lg size

* fix unit tests

* only register 1 event listener each time

* fix display name for SectionNavToggle
2022-10-04 09:19:23 +01:00
Will Browne
4087ad413f re-use fake trace + feature toggles (#56186) 2022-10-04 10:15:10 +02:00
renovate[bot]
c83d576ffc Update dependency @cypress/webpack-preprocessor to v5.13.1 (#56072)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-04 09:14:09 +01:00
renovate[bot]
51cf573656 Update dependency rudder-sdk-js to v2.15.0 (#56196)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-04 09:11:37 +01:00
Esteban Beltran
25bb926a0a Toolkit: Deprecate component:create command (#56086)
* Mark component:create as deprecated

* Update message

* Update packages/grafana-toolkit/src/cli/index.ts

Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>

* Add alternative message

Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
2022-10-04 09:43:24 +02:00
Victor Marin
7b93d85a85 XYChart: Beta release (#55973)
* Bump state from alpha to beta

* Sync manual pointsize max with auto one

* Add xyChart to list
2022-10-04 10:41:36 +03:00
Dimitris Sotirakis
8eea6f7f4f Add edition as environment var (#56069) 2022-10-04 10:35:18 +03:00
Leon Sorokin
eeb31c2901 Heatmap: fix color scheme reversal (#56227) 2022-10-04 02:17:58 -05:00
Dimitris Sotirakis
f7c6fe0c97 Fix update-changelog.yml version input (#56224) 2022-10-04 02:55:13 -04:00
Victor Marin
6913623461 Take standard options min/max into account (#55972) 2022-10-04 08:58:35 +03:00
Brendan O'Handley
82d8015469 OpenTSDB: Convert the OpenTSDB Query Editor from Angular to React (#54677)
* add query editor to module

* add metric section, add tests, update query type

* remove use of any for betterer

* fix test

* add tooltip for alias

* run runQuery on select change, fix metric select loading

* add downsample row, differentiate for tsdb version

* add tests for mteric section and downsample section

* add filter section react component and tests

* add tag section and tests

* add rate section and tests

* remove angular code

* fix styling

* remove comments

* remove unused code
2022-10-03 17:00:46 -04:00
Ethan
ad48cee2bb init sbom action (#56177) 2022-10-03 15:53:28 +00:00
Torkel Ödegaard
dba0baec69 TopNav: Fix pages import dashboard and create new folder (#56182) 2022-10-03 17:30:53 +02:00
renovate[bot]
bcd1c48a4d Update dependency rollup-plugin-esbuild to v4.10.1 (#56191)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-03 16:27:37 +01:00
Gareth Dawson
05e958f689 Loki: Add tests for LokiOptionFields.tsx (#56183)
* WIP: Added tests to LokiOptionFields.test.tsx

* chore(loki-option-fields): fix error with `userEvent`

Using `fireEvent` prevents the running condition.

* Add tests for LokiOptionFields.tsx

* chore: remove unwanted comments

* chore: update test names

Co-authored-by: Matias Chomicki <matyax@gmail.com>
2022-10-03 15:56:30 +01:00
renovate[bot]
8f578d18ce Update dependency rollup to v2.79.1 (#56187)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-03 16:42:55 +02:00
Todd Treece
1c61c81dde Prometheus: Various buffered and streaming parsing fixes (#55941) 2022-10-03 10:26:54 -04:00
Ashley Harrison
8984507291 Navigation: show breadcrumbs correctly when on the home page (#55759)
* show breadcrumbs correctly when on the home page

* adjust breadcrumb unit tests

* update betterer

* fix backend tests

* update getSectionRoot to look at the home nav id

* remove redundant setting of home dashboard

* construct a home navmodelitem in the backend

* fix cases when the feature toggle is off

* fix unit test

* fix more unit tests

* refactor how buildBreadcrumbs works

* use HOME_NAV_ID

* move homeNav useSelector into NavToolbar

* remove unnecesary cloneDeep

* don't need locationUtil here

* restore using getUrlForPartial in DashboardPage

* special case for the editview query param

* remove commented out code

* add comment to clarify splice behaviour

* slightly cleaner syntax
2022-10-03 15:05:19 +01:00
Virginia Cepeda
0d348dc0b1 Alerting: log alert rule creation and clicking state filters (#55698)
* Add messages for new trackings

* Track clicking on alert state filters

* Track creating alert rule from panel

* Track creating alert rule from scratch

* Track on success and when cancelling a rule creation
2022-10-03 11:00:19 -03:00
Santiago
09f8e026a1 Alerting: Expose info about notification delivery errors in a new /receivers endpoint (#55429)
* (WIP) switch to fork AM, first implementation of the API, generate spec

* get receivers avoiding race conditions

* use latest version of our forked AM, tests

* make linter happy, delete TODO comment

* update number of expected paths to += 2

* delete unused endpoint code, code review comments, tests

* Update pkg/services/ngalert/notifier/alertmanager.go

Co-authored-by: Matthew Jacobson <matthew.jacobson@grafana.com>

* remove call to fmt.Println

* clear naming for fields

* shorter variable names in GetReceivers

Co-authored-by: Matthew Jacobson <matthew.jacobson@grafana.com>
2022-10-03 10:58:41 -03:00
Yuriy Tseretyan
1e16dd5b7c Docs: Update Grafana Alerting migration article to mention paused alert rules (#55590)
Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
2022-10-03 09:45:09 -04:00
Christopher Moyer
c5b68ed497 adds note about org_role being case sensitive (#56043) 2022-10-03 08:20:19 -05:00
Dimitris Sotirakis
d32c67b52a CI: Add packages-bucket flag to publish packages command (#56170)
* Add public bucket string

* Fix lint
2022-10-03 13:29:32 +01:00
Oscar Kilhed
3342e529b4 Docs: Update postgresql and mssql docs (#56011)
* Update mssql docs first draft

* Update postgresql docs first draft

* update image tag

* add missing >

* Update docs/sources/datasources/mssql.md

* Update docs/sources/datasources/mssql.md

* Update docs/sources/datasources/postgres.md

* Update docs/sources/datasources/postgres.md

* Update docs/sources/datasources/postgres.md

* Reflect updated image names

Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>
2022-10-03 14:06:51 +02:00
Oscar Kilhed
885e8efec6 Docs: update mysql docs to reflect editor changes (#54568)
* Docs: update mysql docs to reflect visual query builder/code editor changes

* Apply suggestions from code review

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>
Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>

* Add missing >

* Reflect updated image name

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>
Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
2022-10-03 14:06:20 +02:00
Dimitris Sotirakis
947838cca0 CI: Move grafanacom command to OSS (#55853)
* Move publish-packages command over from

* Fix lint

* Move grafanacom command to OSS

* Add GetLatestMainBuild to gsutil

* Fix lint

* More lint fixes

* Add tests for grafanacom

* Fix lint
2022-10-03 14:14:24 +03:00
renovate[bot]
abfd647283 Update dependency lerna to v5.5.4 (#54955)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-03 12:45:11 +02:00
renovate[bot]
eed8df5ccc Update dependency react-colorful to v5.6.1 (#56165)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-03 11:38:18 +01:00
ms-hujia
ec024ae960 Azure Monitor: Add support to customized routes (#54829) 2022-10-03 12:33:37 +02:00
Eric Leijonmarck
4200d7b246 Auth: fix check for conflict login in validation (#56154)
* fix: check for conflict login

* review comment fix
2022-10-03 06:24:26 -04:00
renovate[bot]
3372668889 Update dependency css-minimizer-webpack-plugin to v4.2.0 (#56153)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-10-03 10:58:26 +01:00
Jack Westbrook
d1b21a5981 Grafana UI: Prevent built storybook being bundled with package (#56158) 2022-10-03 11:41:38 +02:00
Ashley Harrison
f2b06abb33 Convert SpanDetail/index.test.js to RTL (#56019) 2022-10-03 10:22:50 +01:00
Ashley Harrison
3e688ecf7d Navigation: remove description from the backend navmodel and use subTitle instead (#56155)
* remove description from the backend navmodel and use subTitle instead

* only add admin subtitle in topnav
2022-10-03 10:09:32 +01:00
Eric Leijonmarck
f7de253cdd fix: remove permission grouping (#56157) 2022-10-03 10:59:24 +02:00
gotjosh
501e921b2b Alerting: Allow created by to be manually set when there's no creator for silences (#55952)
* Alerting: Allow created by to be manually set when there's no creator

Grafana has a mode that allows unauthenticated interaction, typically the created by field of a silence is inferred from the current logged user. When this is not present, the field is left black and thus the silence creation fails.

This allows us to set the created by when we is not possible to infer it from the current user.

* Show created by input field only if user is not logged

* Add test for new logic with createdBy input field

Co-authored-by: Sonia Aguilar <soniaaguilarpeiron@gmail.com>
2022-10-03 10:56:27 +02:00
Laura Fernández
fca252e7dc A11y: enable rule jsx-a11y/alt-text (#55832)
* Enable jsx-a11y/alt-text rule

* Fix errors

* Fix tests

* Enable jsx-a11y/alt-text rule after solving merge conflict

* Delete unused import

* Modify files according to the reviewer's comments

* Revert test changes and update snapshot

* tweaks to image alt names

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-10-03 09:27:04 +01:00
renovate[bot]
6856784134 Update Storybook updates to v6.5.10 (#49793)
* Update Storybook updates to v6.5.6

* refactor(storybook): fix up dependencies and webpack configs

* chore(storybook): bump to 6.5.7

* chore(yarn): refresh lock file

* chore(storybook): bump storybook to 6.5.10

* refactor(storybook): update configuration to use babel, tidy webpack config, clean dependencies

* chore(storybook): bump to 6.5.12

* chore(storybook): bump storybook-dark-mode to 1.1.2

* chore(storybook): workaround resolving storybook-docs addon for yarn pnp

* refactor(storybook): remove preview-head.html in favour of global theme styles

* chore(storybook): patch storybook-dark-mode to work with SB 6.5.x and yarn PnP

* feat(storybook): move to using MDXv2

* fix(icon): make sure icon story doesn't disappear offscreen and is scrollable

* chore(grafana-ui): clean up dependencies related to storybook

* feat(storybook): enable webpack5 filesystem cache

* feat(storybook): replace babel with esbuild

* fix(emotionperftest): fix jsx pragma for esbuild

* fix(emotionperftest): force jsxRuntime to classic so esbuild and babel compile without error

Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
2022-10-03 09:23:47 +02:00
Esteban Beltran
29ca8de6c0 Toolkit: Remove unused legacy cherrypick command (#56114) 2022-10-03 09:04:11 +02:00
Nathan Marrs
fc62f7ae23 Canvas: Add text element (#56137)
Co-authored-by: Drew Slobodnjak <drew08t@users.noreply.github.com>
2022-09-30 17:21:02 -07:00
Garrett Guillotte
ef1aa8ceb8 Docs: Add link to TimescaleDB docs (#56134)
* Added a link for more information

Added a link to TimescaleDB so that users can get additional information if need be.

* fixed formatting

* fixed the table

* made it prettier

* make it pretty for CI

Co-authored-by: Rajakavitha Kodhandapani <krajakavitha@gmail.com>
2022-09-30 15:35:11 -07:00
Ryan McKinley
385ebea540 Devenv: move timeseries dashboards to a timeseries folder (#56131) 2022-09-30 13:10:20 -07:00
Artur Wierzbicki
85b965cbec Storage: Dummy object server and basic integration tests (#56014)
* object extractors

* update bluge to use summary values

* gosec

* move to store/object package

* references

* references

* references

* same thign but with protobuf

* now the service

* now with summary

* now with summary

* from protobuf

* from protobuf

* cleanup

* remove hand crafted file

* update proto definitions

* update comments

* remove properties

* remove properties

* re-generate

* add batch

* move ref to raw struct

* GRPC test infra

* fix merge

* add delete

* lint

* rename to dummyobjectserver

* update comment

* refactor collection, simplify dummy server

* update

* refactor test structure

* more tests

* more tests

* replace collection with infra/persistentcollection

* skip if not integration test suite

* very important lint fix

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-09-30 15:56:07 -04:00
Ryan McKinley
268a49cb38 Devenv: add dashboard showing timeseries out of range points (#56130) 2022-09-30 15:47:23 -04:00
Alexander Weaver
c16317e5b8 Alerting: Move fake rule store to the test utilities package (#56062)
* Move fakeRuleStore to tests/fakes package

* Break stub dependencies on store

* Update existing tests to point to new location

* Remove unused stub of TimeNow

* Rename fake to take advantage of package name
2022-09-30 14:36:51 -05:00
Drew Slobodnjak
82d7f80a15 Canvas: Rename textbox to rectangle (#55633)
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2022-09-30 10:44:47 -07:00
Artur Wierzbicki
ea1334c01d Chore: Persistent collection (#56074)
* persistent collection

* dont remove temp dir

* temp dir change

* lint

* add experimental comment

* move to X package

* lint

* orgID -> namespace
2022-09-30 21:34:44 +04:00
Nathan Marrs
2eb24bbc4e Canvas: Add canvas editor options to inline editor (#55970)
Co-authored-by: Drew Slobodnjak <60050885+drew08t@users.noreply.github.com>
2022-09-30 09:52:30 -07:00
Andres Martinez Gotor
9958f938e0 @grafana/ui: Render PageToolbar Go Back icon for smaller window size (#55671) 2022-09-30 17:36:14 +02:00
kay delaney
81a39b7e5b Variables: Add confirmation modal when deleting variables (#56016) 2022-09-30 16:32:14 +01:00
Alexa V
e2ef41be72 Docs [Standard options definitions] Add missing information for prefix in custom unit (#56098) 2022-09-30 16:13:26 +02:00
renovate[bot]
c29667f35e Update dependency react-calendar to v3.9.0 (#55921)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-30 06:42:04 -07:00
Gareth Dawson
2338660a62 Loki: Add more assertions to loki-query-builder.spec.ts (#56044)
* Add more assertions to loki-query-builder.spec.ts

* Update assertions in loki-query-builder.spec.ts
2022-09-30 14:27:48 +01:00
Josh Hunt
80065c47ab Chore: Updating swagger spec (#56094) 2022-09-30 09:15:09 -04:00
Leo
7df49ca230 Navigation: Add News to top nav (#55466)
* added news feed component

* move button to news component

* create newsfeed hooks and conver NewsPanel to functional component

* added news_feed_enabled and news_feed_url to server settings ini

* add default value in defaults.ini

* set news drawer settings value to true by default

* remove server settings config

* use useToggle hook

* fix newsitem render

* support drawer on mobile screen

* use media query utility
2022-09-30 15:11:24 +02:00
juanicabanas
5eab922a16 Dashboard: Record the number of cached queries for usage insights. 2022-09-30 09:49:16 -03:00
Gábor Farkas
a069a01853 grafana-data: logs: add deprecated-info (#56077) 2022-09-30 14:22:04 +02:00
Ashley Harrison
5b1fdd535a Accessibility: turn on jsx-a11y/no-noninteractive-tabindex + fix/ignore errors (#56084)
* turn on jsx-a11y/no-noninteractive-tabindex + fix/ignore errors

* update comments
2022-09-30 13:20:39 +01:00
Shirley
09079bfb65 Upgrade to grafana-aws-sdk v0.11.0 (#56042) 2022-09-30 13:51:28 +02:00
Marcus Andersson
d406e6d899 Docs: Added icon type improvements to plugin migration guide (#56075) 2022-09-30 13:17:11 +02:00
Laura Benz
fc6afc6b84 Core: Implement aria attributes for query rows, improve a11y (#55563)
* feat: add aria-expanded prop

* refactor: remove console.log()

* feat: add aria-controls

* refactor: add id to expendable section

* refactor: create unique id
2022-09-30 13:03:55 +02:00
sam boyer
9ec7b202b6 playlist: introduce coremodel schema, swap in for backend DTO types (#56048)
* Add simplest possible playlist schema

* Add @grafana(decisionNeeded) attributes

* playlistid, not playlist_id
2022-09-30 06:33:11 -04:00
Gábor Farkas
d2601003cf Logs: move logs-functions from grafana-data to grafana-main (#55457)
* logs: move utils from grafana-data to grafana

* logs: adjust imports

* updated betterer checksum file
2022-09-30 12:16:47 +02:00
Sven Grossmann
0c1e4979af add correct overscroll-behavior to context modals (#56070) 2022-09-30 11:25:51 +02:00
renovate[bot]
62811c2141 Update dependency @rushstack/node-core-library to v3.53.0 (#56002)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-30 10:01:30 +01:00
Timur Olzhabayev
2ded4c12ab Chore: Rename one of the publish docs action steps (#55888) 2022-09-30 09:48:54 +02:00
Jeff Levin
e4157361d9 documentation: update documentation for enabling tracing on a grafana instance (#56068)
This PR improves docs around enabling traces on grafana.
In order to enable tracing and get a traceID, you must set the address field in your config.ini

https://github.com/grafana/grafana/blob/main/contribute/engineering/backend/instrumentation.md#2-enable-tracing-in-grafana
2022-09-30 03:44:12 -04:00
GitStart
2664575a4a Dashboard Edited/Saved notifications leak into other views (#55540)
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: RubensRafael <rubensrafael2@live.com>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Thiago Nascimbeni <tnascimbeni@gmail.com>
Co-authored-by: gitstart <gitstart@gitstart.com>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
Co-authored-by: Júlio Piubello da Silva Cabral <julio.piubello@gitstart.dev>

Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: RubensRafael <rubensrafael2@live.com>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Thiago Nascimbeni <tnascimbeni@gmail.com>
Co-authored-by: gitstart <gitstart@gitstart.com>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
Co-authored-by: Júlio Piubello da Silva Cabral <julio.piubello@gitstart.dev>
2022-09-30 09:18:50 +02:00
Ryan McKinley
213cfe5117 Object: use protobuf to declare the raw/summary types (#55646) 2022-09-29 22:18:15 -07:00
Alexander Weaver
d66ed6fe35 Alerting: Move stray model structs in store package to model package (#55968)
* Move stray command structs to model package like the rest

* Fix broken references
2022-09-29 15:47:56 -05:00
lean.dev
7bd8dbf2f8 Docs: Update Public Dashboard documentation (#56035) 2022-09-29 14:24:38 -03:00
Sven Grossmann
3afa3f5e21 fix wrong context height (#56024) 2022-09-29 18:12:20 +02:00
sam boyer
59a3e18bb2 Fix prefix dropper in Go codegen (#56041) 2022-09-29 12:01:02 -04:00
Mike McFarland
46da77d1a0 docs: fix typo in is_null expression explainer (#55988) 2022-09-29 10:04:43 -05:00
Sofia Papagiannaki
6099e55e62 SQLStore: Remove call to deleted store.NewSession() (#56025) 2022-09-29 10:17:33 -04:00
Sven Grossmann
6bc09a6390 Logs: Add Download logs button to log log-browser (#55163)
* move download functions to utils

* add downloads button

* removed unused export annotations

* changed button to `ToolbarButton`

* added tests and restructured download methods

* pin `blob-polyfill`

* add missing import

* changed type
2022-09-29 16:09:40 +02:00
Sofia Papagiannaki
8b77ee2734 SQLStore: Ensure that sessions are always closed (#55864)
* SQLStore: Ensure that sessions are always closed

Delete `NewSession()` in favour of `WithDbSession()`

* Add WithDbSessionForceNewSession to the interface

* Apply suggestions from code review
2022-09-29 15:55:47 +03:00
Sven Grossmann
c9e957a44e Logs: Center show context modal on click (#55989)
* added center implementation

* fixed passing `scrollElement` to wrong component

* rather destructure than direct ref

* removed unnecessary `undefined`
2022-09-29 14:51:20 +02:00
Artur Wierzbicki
64eff8196c Chore: expose grpc server address (#56013) 2022-09-29 08:42:01 -04:00
Eric Leijonmarck
1e8f8dff4b Auth: Adds validation and ingestion of conflict file (#53014)
* add users-manager command

* add users-manager command

* rename files

* refactor: imports and renaming

* Command: add conflict merge user command

- MergeUser will
	- replace all user_ids from conflicting users to the chosen userId
	- delete users whose user_ids are not the chosen user
- SameIdentification will
	- update chosen user with chosen email,login details
	- delete users whose user_ids are not the chosen user

* refactor: clean up

* refactor: create structure for read, validate, ingest

* feat: ls and generate-file for conflicting users

* remove usagestats

* added back pkg/services/login/authinfoservice/database/stats.go

* Revert "added back pkg/services/login/authinfoservice/database/stats.go"

This reverts commit 2ba6e3c4d6.

* Revert "remove usagestats"

This reverts commit 1e3fa97810.

* cherry pick

* Revert "cherry pick"

This reverts commit 461626c306.

* validation of picked merge user

* fix test

* make lint

* make test run

* tests for ingest working

* clean up and refactored to align with downstream refactoring

* formatting

* refactor: name list instead of ls

* fix: static lint error use trimprefix

* WIP: permissions for validation

* fix: remove unused functions in sqlstore

* fix: remove unused function

* handling of multiple users and resolve discarded users

* fix tests

* fix: bug that did not exclude the blocks

* ioutil is blacklisted

* WIP: validation

* tests for merging a user working

* add latest changes to output print

* refactor: removed conflictEmail and conflictLogin that was not used

* refactor: code clean up, showChanges working

* test and linting fixes

* test and linting fixes

* refactor: removed logging of config and added more info for vlidation command

* refactor: fix order of code

* fix time now

* refactor: no longer need for check casesensitive login/email

* removed unnessecary loop

* refactor: move functions around

* test: working

* docs: add docuemntationf for file

* Add failing test for generating the conflict login block

* Fix regex

* Fix some stuff/tests

Co-authored-by: eleijonmarck <eric.leijonmarck@gmail.com>

* add: docs for conflict file

* add: conflict_email, conflict_login fields

* add: conflict_email, conflict_login fields

* WIP

* fix: tests working as intended

* Update pkg/cmd/grafana-cli/commands/conflict_user_command.go

Co-authored-by: linoman <2051016+linoman@users.noreply.github.com>

* review comments

* Update pkg/cmd/grafana-cli/commands/conflict_user_command.go

Co-authored-by: Misi <mgyongyosi@users.noreply.github.com>

* Update pkg/cmd/grafana-cli/commands/conflict_user_command.go

Co-authored-by: Misi <mgyongyosi@users.noreply.github.com>

* missspelling

* trailing new line

* update to use userimpl store

* remove newline

* remove newline

* refactor: initializing of resolver for conflicts

* fix: test sqlStore

* refactor: removed lines

* refactor: remove TODOs

Co-authored-by: Mihaly Gyongyosi <mgyongyosi@users.noreply.github.com>
Co-authored-by: linoman <2051016+linoman@users.noreply.github.com>
2022-09-29 14:26:24 +02:00
Dimitris Sotirakis
9a68f8704f CI: Move publish-packages command over from grabpl (#55850)
* Move publish-packages command over from

* Lint fixes

* Update test
2022-09-29 07:32:42 -04:00
Ivana Huckova
b39d629142 Loki: Show invalid fields in label filter (#55751)
* Loki: Show invalid fields in Label filter

* Update

* Update comment

* Update comment
2022-09-29 13:32:01 +02:00
Torkel Ödegaard
b4f73c9f09 PluginPages: Support plugin pages that don't belong to a section (#55904)
* Fixing pages that don't exist in navtree

* Fix test

* fix lint warning

* Fixes
2022-09-29 13:27:51 +02:00
Artur Wierzbicki
34f18aacd6 Chore: add more input parameters to serviceaccounts/test/common.go (#55994) 2022-09-29 12:11:53 +01:00
Ashley Harrison
27abc32608 fix lockfile (#56003) 2022-09-29 06:52:33 -04:00
renovate[bot]
836b3b4dd6 Update dependency rc-tree to v5.7.0 (#55902)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-29 11:22:01 +01:00
Alexa V
c4500438a4 Variable: Limit variable name to 50 characters (#55406)
Co-authored-by: kay delaney <45561153+kaydelaney@users.noreply.github.com>
Co-authored-by: kay delaney <kay@grafana.com>
2022-09-29 12:13:07 +02:00
Ivana Huckova
21a99fba7e Loki/Prometheus: Fix adding of ad hoc filters when jumping from dashboard to explore (#55915)
* Loki, Prometheus: Fix adding of ad hoc filters when jumping from dashbaord to explore

* Update
2022-09-29 11:17:41 +02:00
Sven Grossmann
9cf1f2224c LogsContext: Added button to load 10 more log lines (#55923)
* added load-more button

* added missing px
2022-09-29 10:44:15 +02:00
Jack Westbrook
5c5228da61 Toolkit: Put back publishConfig access public (#55983) 2022-09-29 04:31:52 -04:00
brendamuir
ebdc13ed86 Docs alerting: copy edit terraform provisioning (#55978)
* Docs alerting: copy edit terraform provisioning

* changes intro sentence for explore
2022-09-29 10:19:16 +02:00
Sven Grossmann
998a368c69 Logs: Show copy button independently from context (#55934) 2022-09-29 10:00:01 +02:00
aimuz
bf07deb992 Fix showWhen failure (#55337)
When a contact point configuration field has `showWhen` set on it, the contact point form was not correctly displaying. This change fixes that so that forms display correctly.
2022-09-29 15:00:49 +08:00
Nathan Marrs
5a9dfd7173 Canvas: Fix inline edit toggle crash (#55961) 2022-09-28 15:31:30 -07:00
Drew Slobodnjak
b0cd511ecc Geomap: Fix tooltip display option (#55956) 2022-09-28 15:21:21 -07:00
Leon Sorokin
16c9c858b8 BarChart: add negY transform to fieldConfig overrides (#55930) 2022-09-28 14:32:37 -06:00
Marcus Andersson
fc09d5a8a7 GrafanaUI: Expose data links context types externally (#55905) 2022-09-28 21:35:46 +02:00
Ezequiel Victorero
b370a8e366 PublicDashboards: Allow disabling an existent public dashboard if it has template variables (#55778) 2022-09-28 15:34:53 -03:00
Todd Treece
a281c26580 GRPC Server: Move reflection to a separate gRPC service (#55872) 2022-09-28 14:00:46 -04:00
Giedrius Statkevičius
e8ac52ba0f Prometheus: fix proxy check (#54823)
The original check has been added ~3 years ago and since then a new
variable has been added that says whether the mode is browser or
proxied.

Start using the new variable in this function so that proxy mode could
be properly detected. It's important to us to get these headers and this
check is currently broken for HTTP/HTTPS URLs.

Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com>

Signed-off-by: Giedrius Statkevičius <giedrius.statkevicius@vinted.com>
2022-09-28 19:05:52 +02:00
Ivana Huckova
5bd65db8a8 Loki: Add new range operation range_counter (#55936)
* Loki: Add new range operation range_counter

* Update yarn.lock
2022-09-28 18:36:36 +02:00
Sofia Papagiannaki
b749cef78e Chore: Remove unnecessary transaction (#55819) 2022-09-28 18:50:19 +03:00
Jack Westbrook
b81f90cd0c Toolkit: Fix script failures due to missing import paths (#55857)
* fix(toolkit): package without dist folder so config file paths are correct

* chore(packages): make sure to bundle readme, changelog and apache2 license

* refactor(packages): recursively copy src when prepacking toolkit

* chore(toolkit): lock down babel dependencies. use grafana-eslint-config@5 for TS4.8 support
2022-09-28 17:04:55 +02:00
Tania
71578d0932 Docs: Document Reporting API (#55434)
* Docs: Document reporting api

* Update docs/sources/developers/http_api/reporting.md

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>

* Update docs/sources/developers/http_api/reporting.md

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>

* Update docs/sources/developers/http_api/reporting.md

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>

* Document the rest of endpoints

* Document more endpoints

* Fix scopes and links

* Remove rendering endpoints

* Fix status codes

* Apply review feedback

* Typo

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
2022-09-28 17:03:43 +02:00
emerson_gong
4ffa0532f0 Security: Fix CVE-2022-27664 (#55361)
* Fix CVE-2022-27664

* update golang.org/x/sys in go.sum
2022-09-28 17:35:06 +03:00
idafurjes
122e7c141d Chore: Delete UpdateUser, ChangeUserPassword, UpdateLastSeenAt from sqlstore (#55928) 2022-09-28 16:17:09 +02:00
Hamas Shafiq
0ec253bfa0 Tempo: Add a placeholder to the TraceQL query editor (#55257) 2022-09-28 15:07:10 +01:00
Emil Tullstedt
6aef353b59 Tracing: Fix bug where errors are not reported to OTel (#55925) 2022-09-28 15:54:47 +02:00
Emil Tullstedt
b0b1e8d568 Tracing: Document Tracer and Span interfaces (#55926) 2022-09-28 15:53:48 +02:00
Jimmie Han
c6dffb11a4 Tempo: Fix unexpected trimming of leading zeroes in traceID (#55167)
* tempo: fix unexpected trim traceID leading zero (#55166)

* fix lint
2022-09-28 15:49:12 +02:00
Sonia Aguilar
ef641ea9c9 Alerting: fix alert supported warning when editing data source name (#55886) 2022-09-28 14:41:54 +02:00
Joao Silva
cf1862ecc4 Storybook: Explicitly set init on a registry to stop Storybook from being broken (#55909) 2022-09-28 13:29:41 +01:00
ying-jeanne
2472777ce2 Chore: implement sqlx into tag service (#55908)
* add sqlx store to tag service

* add sqlx into tag service

* fix test

* change to camal cases

* change in xorm camal case
2022-09-28 08:23:40 -04:00
renovate[bot]
8869d6fe7a Update dependency rc-cascader to v3.7.0 (#55896)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-28 13:12:15 +01:00
Leon Sorokin
4ff7917039 TimeSeries: clamp log-y-axis min to 1 when decimals=0 (#55882) 2022-09-28 05:39:24 -06:00
Sven Grossmann
7e8738e01e LogContext: Improve text describing the loglines (#55475)
* changed messages before and after LogContext

* add comment explaining the if

* add tests

* removed unused divs

* improved if statements
2022-09-28 13:37:49 +02:00
idafurjes
a45ef61d25 Chore: Remove GetUserByEmail and GetUserByLogin from sqlstore (#55903)
* Chore: Remove GetUserByEmail and GetUserByLogin from sqlstore
 Rename GetUserProfile to GetProfile

* Fix lint

* Skip test for mysql

* Add missing method to sqlstore mock
2022-09-28 13:18:19 +02:00
Piotr Jamróz
a8f43b97a2 Glue: Return correlation config in GET /correlations (#55801)
* Fix getting and creating correlations config

* Fix tests
2022-09-28 12:17:43 +01:00
brendamuir
43dc92d12c fix index file for website (#55907) 2022-09-28 13:06:38 +02:00
Andreas Christou
37aa45001f AzureMonitor: Correctly update subscriptions value in ARG editor (#55860)
* Correctly update subscriptions prop in query

* Simplify setting of subscriptions value
2022-09-28 11:59:07 +01:00
renovate[bot]
678fb7c29a Update dependency eslint to v8.24.0 (#55727)
* Update dependency eslint to v8.24.0

* bump sdk as well

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-09-28 10:43:14 +01:00
brendamuir
4ba757e7b8 Update Alerting provisioning docs (#55892) 2022-09-28 11:03:36 +02:00
renovate[bot]
1bfc6413db Update dependency react-awesome-query-builder to v5.3.1 (#54988)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-28 09:55:49 +01:00
Dimitris Sotirakis
46037cff56 Remove prepare-release.yml (#55893) 2022-09-28 04:52:42 -04:00
brendamuir
b7f356df31 Docs: adds terraform provisioning docs (#55660)
* Docs: adds set up section and alertmanager

* deletes info that got copied to new file
2022-09-28 09:18:46 +01:00
Hamas Shafiq
445fed0875 Chore: Fix broken image link in Zipkin's documentation (#55847) 2022-09-28 09:18:26 +01:00
Vladimir
efef672d19 Documentation: clarify label matching (#55650)
* Documentation: clarify label matching

Behaviour in case of multiple matchers is not documented, but my experiments show they are reduced using logical AND. Please validate the updated description.

* Accept wording suggestion

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>

* Accept suggestion for docs/sources/alerting/fundamentals/annotation-label/labels-and-label-matchers.md

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>

* Improve wording according to review suggestions

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
2022-09-28 09:06:04 +01:00
Alexa V
51028b1b2e Panel Inspect JSON: Add instrumentation for "Apply" feature (#55179)
Co-authored-by: Ivan Ortega Alba <ivanortegaalba@gmail.com>
2022-09-28 09:56:58 +02:00
Leon Sorokin
bd50fd1606 Thresholds: Add option for dashed line style (#55875) 2022-09-28 00:48:09 -06:00
Torkel Ödegaard
e31cb93ec0 NavTree: Make it possible to configure where in nav tree plugins live (#55484)
* NewIA: Plugin nav config

* progress

* Progress

* Things are working

* Add monitoring node

* Add alerts and incidents

* added experiment with standalone page

* Refactoring by adding a type for navtree root

* First test working

* More tests

* more tests

* Progress on richer config and sorting

* Sort weight working

* Path config

* Improving logic for not including admin or cfg nodes, making it the last step so that enterprise can add admin nodes without having to worry about the section not existing

* fixed index routes

* removed file

* Fixes

* Fixing tests

* Fixing more tests and adding support for weight config

* Updates

* Remove unused fake

* More fixes

* Minor tweak

* Minor fix

* Can now control position using sortweight even when existing items have no sortweight

* Added tests for frontend standalone page logic

* more tests

* Remove unused fake and fixed lint issue

* Moving reading settings to navtree impl package

* remove nav_id setting prefix

* Remove old test file

* Fix trailing newline

* Fixed bug with adding nil node

* fixing lint issue

* remove some code we have to rethink

* move read settings to PrivideService and switch to util.SplitString
2022-09-28 08:29:35 +02:00
Artur Wierzbicki
202dce66ff Search: add basic e2e test for the folder view (#55820) 2022-09-28 09:46:24 +04:00
Nathan Marrs
d9d7bff793 Canvas: Fix resource picker folder UX (#55877) 2022-09-27 21:05:13 -07:00
Ryan McKinley
e7e7763252 Store/Search: Explore a general interface to extract summary data from a blob (#55598) 2022-09-27 18:08:47 -04:00
Yuriy Tseretyan
0b3c60fc22 Alerting: Refactor notifiers VictorOps, Threema, Telegram to use encoding/json to parse settings instead of simplejson (#55779)
* update victorops
* update threema
* update telegram
2022-09-27 16:58:18 -04:00
Leon Sorokin
b8da1ffdc3 TimeSeries: fix log-y-axis tick label skipping when decimals=0 (#55868) 2022-09-27 15:50:41 -05:00
Guilherme Caulada
2a12644778 Links: Fix opening links from different orgs on the same tab (#55837)
* Skip intercepting links of different orgs

* Check if orgId is present on query params

* Use locationSearchToObject instead of parseKeyValue

* Revert locationSearchToObject to parseKeyValue
2022-09-27 16:50:05 -03:00
Richard Hartmann
80daf05843 Relicense Tempo datasource plugin to Apache 2 (#55866)
As per Ash's request.

Signed-off-by: Richard Hartmann <richih@richih.org>
2022-09-27 20:53:11 +02:00
Alexander Weaver
e6f99fc418 Alerting: Decouple schedule package from store (#55858)
* Separate out fake for scheduler tests

* Delete extracted methods from older fake
2022-09-27 13:48:12 -05:00
owensmallwood
664aa795c1 PublicDashboards: Add metric for public dashboard datasource query success (#55701)
Adds metric for which datasource queries are successful or not with pubdash.
2022-09-27 12:25:56 -06:00
Garrett Guillotte
1485209287 Docs: Add screenshots to What's New in v9.2 (#55862)
* Docs: Add What's New in Grafana v9.2 Beta

* Docs: Add links to What's New in Grafana v9.2

* Docs: Apply updates to What's New
2022-09-27 11:11:14 -07:00
Artur Wierzbicki
814211282a Search: Fix tags query (#55851)
* Search: fix tags query

* Search: fix type
2022-09-27 21:16:49 +04:00
Garrett Guillotte
3409979288 Docs: Add What's New in Grafana v9.2 Beta (#55855) 2022-09-27 12:09:00 -05:00
Ashley Harrison
97f1524b66 Chore: move the a11y rules to the overrides section so they don't apply to t… (#55848)
* move the a11y rules to the overrides section so they don't apply to tests

* turn alt-text back off
2022-09-27 16:59:35 +01:00
Nathan Marrs
e160f19247 Canvas: Fix icon element resizing 2022-09-27 08:53:47 -07:00
Guilherme Caulada
6674407d3f Revert public dashboard granularity fix (#55844) 2022-09-27 12:41:14 -03:00
Alexander Weaver
81b631d1e9 Use separate fake for rule reader (#55835) 2022-09-27 10:33:32 -05:00
Victor Marin
3361f2c62d XYChart further improvements (#55152)
* Tooltip shows all data facets. Renamed options

* Add per series line style

* Remove line style option from manual panel options

* Refactored tooltip view

* sets selected after switch to manual

* remove facet prefixes

* in manual mode pull series names from config options, not y facet

* unused import

* Point size

* x & y axes labels

* Fix manual series prep

* betterer

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
2022-09-27 18:18:42 +03:00
Ashley Harrison
11eb02a183 enable rule role-has-required-aria-props (#55841) 2022-09-27 11:17:26 -04:00
idafurjes
edcf359473 Chore: Copy org sqlstore methods to org store (#55825)
* Chore: Copy org sqlstore methods to org store

* Remove GetByName, add some tests

* Rename GetByNameHandler to GetByName

* Fix fake name
2022-09-27 16:53:45 +02:00
Ashley Harrison
527c00dae5 enable rule jsx-a11y/role-supports-aria-props (#55839) 2022-09-27 15:42:46 +01:00
Ashley Harrison
422b22a513 enable img-redundant-alt rule (#55833) 2022-09-27 10:26:32 -04:00
Josh Hunt
615d86d902 Docs: Clarify contributions for translations (#55574)
* Docs: Clarify contributions for translations

* add comment to messages.po files
2022-09-27 10:21:23 -04:00
Ashley Harrison
afdb094983 turn on tabindex-no-positive rule (#55830) 2022-09-27 15:18:24 +01:00
Alexander Weaver
d17ab82b98 Alerting: Break up store.RuleStore interface, delete dead code (#55776)
* Refactor state manager to not depend on rule store interface

* Refactor grafana and proxied ruler APIs to not depend on store.RuleStore

* Refactor folder subscription logic to not use store.RuleStore

* Delete dead code

* Delete store.RuleStore
2022-09-27 08:56:30 -05:00
Dimitris Sotirakis
cd360f2d2a Add nightly cronjob (#55675) 2022-09-27 08:49:20 -05:00
Dimitris Sotirakis
2a3f423e10 Replace armhf with armhfp for RPMs (#55814) 2022-09-27 08:49:00 -05:00
Kristina
0a5aa19ca2 Explore: Prevent panes from disappearing when resizing window in split view (#55696) 2022-09-27 15:48:09 +02:00
idafurjes
56cfe02ca2 Chore: Remove methods from sqlstore interface (#55802)
* Remove SearchOrgUsers from sqlstore interface

* Remove RemoveOrgUser method from sqlstore interface

* Delete RemoveOrgUser from sqlstore

* Fix lint
2022-09-27 15:33:38 +02:00
GitStart
332e8477c7 Convert packages/grafana-ui/src/components/Graph/Graph.test.tsx to RTL (#55771)
Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: gitstart <gitstart@gitstart.com>
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Thiago Nascimbeni <tnascimbeni@gmail.com>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
Co-authored-by: Rubens Rafael <rubensrafael2@live.com>
2022-09-27 14:26:53 +01:00
ying-jeanne
b96a3832d0 StoreSplit: move dashboard thumbs into thumbs service (#55800)
* move dashboard thumbs into thumbs service

* rename some variables
2022-09-27 08:46:03 -04:00
Julien Duchesne
169df2fe90 Drone: publish-linux-packages should be privileged (#55816)
It's currently failing with a failure to mount s3fs
2022-09-27 15:44:39 +03:00
Oscar Kilhed
53a39e5037 Make LocalStorageProvider react to storage events (#55810) 2022-09-27 14:37:59 +02:00
Tania
4a4201ec92 Chore: Update versions (#55813) 2022-09-27 14:07:16 +02:00
Virginia Cepeda
27f022283d JS Agent: remove user email and add session id (#55767) 2022-09-27 08:59:32 -03:00
Kristin Laemmert
701f6d5436 UserService: use the UserService instead of calling sqlstore directly (#55745)
* UserService: update callers to use the UserService instead of calling sqlstore directly

There is one major change hiding in this PR. UserService.Delete originally called a number of services to delete user-related records. I moved everything except the actual call to the user table, and moved those into the API. This was done to avoid dependencies cycles; many of our services depend on the user service, so the user service itself should have as few dependencies as possible.
2022-09-27 07:58:49 -04:00
Tania
4f6c2d35c2 Chore: Update latest.json to 9.2.0-beta1 (#55811) 2022-09-27 11:52:55 +00:00
Hamas Shafiq
62046449d2 Tempo: Add a placeholder for the Limit field under the Search tab (#55557) 2022-09-27 12:27:40 +01:00
Tima Gixe
69f8b32dc0 Storybook: add controls to Segment story (#55264) 2022-09-27 12:19:00 +01:00
Grot (@grafanabot)
da7797014a ReleaseNotes: Updated changelog for 9.2.0-beta1 (#55788)
* ReleaseNotes: Updated changelog and release notes for 9.2.0-beta1

* Remove release notes

Co-authored-by: dsotirakis <dimitrios.sotirakis@grafana.com>
2022-09-27 13:16:53 +02:00
idafurjes
d8cd30d22a Chore: Remove DeleteOrg and UpdateOrgAddress from sqlstore (#55795)
* Chore: Remove DeleteOrg and UpdateOrgAddress from sqlstore

* Remove commented out methods
2022-09-27 12:30:10 +02:00
Gábor Farkas
d1375d31cd devenv: loki: remove unused devenv-config (#55752)
* devenv: jaeger: add it's own copy of promtail-config

* devenv: removed unused loki config
2022-09-27 11:58:08 +02:00
Martin Lehmann
85c26ea908 Alerting: Fix a typo in alerting rule annotation docs (#55730) 2022-09-27 10:56:22 +01:00
Laura Fernández
6b6882c141 Navigation: Align landing pages with designs (#55749) 2022-09-27 11:16:29 +02:00
Piotr Jamróz
becdf10f0e Glue: Add DB migration & support provisioning for user-defined correlations config (#55560)
* Allow provisioning correlation config

* Simplify code

* Fix reading correlations test

* Fix linting errors

* Fix linting errors

* remove simpleJson

* Clean up

* Fix tests

* Update swagger docs

* Fix linting

* Fix linting

* Clean up swagger definitions

Co-authored-by: Elfo404 <me@giordanoricci.com>
2022-09-27 11:08:02 +02:00
George Robinson
a49fcbdbbc Alerting: Add frames for all queries and expressions (#55609)
This commit is one of two commits to make the data frames for all queries and expressions in an alert rule available to the state package for rendering a graph. It renames Result to Condition, and creates an additional field called
Results that is a map of Ref ID to data.Frames.
2022-09-27 10:05:29 +01:00
Laura Fernández
4544494058 A11y: enable rule jsx-a11y/aria-role (#55760) 2022-09-27 10:55:16 +02:00
idafurjes
2bfd26249b Chore: Remove methods from store interface (#55765)
* Chore: Remove methods from store interface

* Fix api tests

* Remove sqlstore methods, add org store tests, add GetOrgUsers to org store interface

* Fix lint

* Remove debug logs

* Remove commented out methods
2022-09-27 10:34:31 +02:00
Jimmie Han
708225f69f feat: add tracesToMetrics span time shift options (#54710) (#55335) 2022-09-27 09:30:33 +01:00
Giordano Ricci
4cd4bc84b5 Fix: use type=button in editor (#55731) 2022-09-27 09:20:23 +01:00
Christopher Moyer
2bbc7c40e9 Docs: first draft of share panel with support docs (#55170) 2022-09-26 13:28:10 -07:00
Alexander Emelin
55aae79744 GRPC Server: Add gRPC server service (#47849)
Co-authored-by: Todd Treece <todd.treece@grafana.com>
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-09-26 16:25:34 -04:00
Alexander Weaver
f11495a4c3 Alerting: Remove dead functionality from alert instance store (#55774)
* Update tests to use ListAlertInstances

* Drop the actual methods rather than just updating tests
2022-09-26 14:38:53 -05:00
Alexander Weaver
a00879ae21 Alerting: Refactor store to not export its own interface for InstanceStore, delete dead dependency injection (#55772)
* Add consumer-side store interface to state manager

* Remove dead dependency

* Delete dead dependency in API struct

* Delete store-layer InstanceStore interface

* Move fake for state's InstanceStore interface to state package
2022-09-26 13:55:05 -05:00
Alexander Weaver
bd6a5c900f Alerting: Extract ticker into shared package (#55703)
* Move ticker files to dedicated package with no changes

* Fix package naming and resolve naming conflicts

* Fix up all existing references to moved objects

* Remove all alerting-specific references from shared util

* Rename TickerMetrics to simply Metrics

* Rename base ticker type to T and rename NewTicker to simply New
2022-09-26 12:35:33 -05:00
Andreas Christou
53c61b49bf AzureMonitor: Add region params (#55763)
* Ensure region params are included

* Fix betterer results change
2022-09-26 12:56:18 -04:00
idafurjes
846a4510b4 Chore: Use org service methods (#55738)
* Chore: Use org service methods

* Fix loginservice test

* User Serach from org service

* Fix test
2022-09-26 18:53:17 +02:00
Yuriy Tseretyan
29fdbf0354 Alerting: Refactor webhook notifier to use encoding/json to parse settings instead of simplejson (#55517)
* update webhook to use json marshaller
* make maxAlerts to be interface{}
2022-09-26 12:51:58 -04:00
owensmallwood
64dd9a0898 Adds docker block for clickhouse (#55702)
Adds clickhouse docker-compose block
2022-09-26 10:44:25 -06:00
Josh Hunt
00a90d3255 Chore: Regen swagger spec (#55750)
* Chore: Regen swagger spec

* Regenerate swagger after enteprise fix

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>
2022-09-26 12:37:27 -04:00
kay delaney
4d1b422b25 Chore: Remove empty and leftover files (#55757) 2022-09-26 11:33:07 -04:00
Dominik Prokop
70f48cc725 Library panels: Add backend route (#55746) 2022-09-26 08:27:26 -07:00
sam boyer
e2ff875976 codegen: Introduce TS codegen veneer (#54816)
* Split all named types out into defs, etc.

* Use latest cuetsy, refactor generators accordingly

* Return AST type from plugin TS generator

* Near-complete checkin of TS veneer code generator

* First full completed pass

* Improve the attribute name

* Defer use of the dashboard veneer type to follow-up

* Remove dummy index, prettier on veneer

* Fix merge errors in gen.go

* Add match field to SpecialValueMap

* Fix backend lint errors
2022-09-26 11:26:18 -04:00
Christopher Moyer
f8240e4b0a Docs: Refactors best practices and creates Build a dashboard section in the docs (#55101)
* starts refactor

* corrects broken relrefs
2022-09-26 10:07:24 -05:00
Marcos Vinicius
f4d7a6d869 Elasticsearch: Rename public/app/plugins/datasource/elasticsearch/elastic_response.ts to follow convention (#55533)
* Elasticsearch: Rename public/app/plugins/datasource/elasticsearch/elastic_response.ts to follow convention

* undo changes in this file

* fix import types
2022-09-26 16:53:25 +02:00
GitStart
ac875a1329 Loki: Remove any from public/app/plugins/datasource/loki/live_streams.test.ts (#55545)
Co-authored-by: gitstart <gitstart@gitstart.com>
Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Thiago Nascimbeni <tnascimbeni@gmail.com>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: Júlio Piubello da Silva Cabral <julio.piubello@gitstart.dev>

Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: gitstart <gitstart@gitstart.com>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Thiago Nascimbeni <tnascimbeni@gmail.com>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: Júlio Piubello da Silva Cabral <julio.piubello@gitstart.dev>
2022-09-26 16:42:53 +02:00
Gilles De Mey
9aa61ddd0e Alerting: Add threshold expression (#55102) 2022-09-26 16:05:44 +02:00
Emil Tullstedt
f7a3e50b23 UsageStats: Add traces when sending usage stats (#55474) 2022-09-26 15:10:54 +02:00
Giordano Ricci
d07abdd23c Correlations: Only return correlation for which both source and target datasources exist (#55454)
* Correlation: only return correlation for which both source and targe ds exist

* add test
2022-09-26 14:05:04 +01:00
Torkel Ödegaard
018733dd24 PluginDetails: Make plugin details page look good in topnav (#55571)
* PluginDetails: Make plugin details page look good in topnav

* Minor style tweak aligning things

* minor refactoring where I moved the logic to decide the default tab into its own hook.

* refactor(plugindetails): first pass at using navmodel for usePluginDetailsTabs hook

* refactor(plugindetails): move "reset page when uninstalling plugin" to installcontrols

this prevents a user from seeing a blank page if they uninstall an app plugin whilst viewing a
config page

* refactor(plugindetails): remove usage of toIconName and reduce nested if

* Trying to fix tests

* minor fix

* test(plugindetails): update selectors causing failing tests

* chore(plugindetails): remove commented out test code

* test(plugindetails): clean up - remove unnecesary usage of waitFor

Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>
Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
2022-09-26 15:04:07 +02:00
Ashley Harrison
1a830e6f45 don't add folder breadcrumb if there is no folderUid (#55739) 2022-09-26 14:02:50 +01:00
Gábor Farkas
d8b4f776aa Logs: Allow collapsing the logs volume histogram (#52808)
* logs: Allow disabling the logs volume histogram

* removed unnecessary code

* refactor: adjusted prop-name

* refactor: simplified code

* refactor: more readable code

* refactor: better naming

* refactor: better naming

* only unsubscribe when disabling the UI

* revert visual change

* re-apply visual change

This reverts commit 7fda5c197f.

* smoother transition

* adjusted visual

Co-authored-by: Giordano Ricci <me@giordanoricci.com>

* logs: top-gap reduced

* added feature tracking

* removed not-working feature-tracking property

* lint fix

Co-authored-by: Giordano Ricci <me@giordanoricci.com>
2022-09-26 14:28:12 +02:00
Gábor Farkas
2efd7fa481 Elasticsearch: Reuse http client in the backend (#55172)
* elastic: backend: reuse http client

* fixed lint error
2022-09-26 14:27:46 +02:00
Ivana Huckova
c0ecdf6783 Loki: Redesign and improve query patterns (#55097)
* WIP

* WIP

* Query patterns: Redesign and improve feature

* Remove duplicated pattern

* Remove empty line

* Refactor

* Add tests

* Update docs and e2e test

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

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

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

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

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

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

* Use capitalize

* Refactor to use QueryPatternsCard component

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

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

* Update feature tracking for v2

* QueryPatternsCard: Remove unnecessary key

* Update naming for card

* Mock reportInteraction in tests

Co-authored-by: Matias Chomicki <matyax@gmail.com>
2022-09-26 14:03:13 +02:00
Sven Grossmann
231de5a32f devenv: change default elasticsearch datasources (#55479)
* devenv: change default elasticsearch datasources

* remove metrics ds

* updated datasources
2022-09-26 13:00:29 +02:00
ying-jeanne
70c2a31513 move models of dashboard thumbs into its package (#55729) 2022-09-26 12:37:34 +02:00
Tania
40e6ac8fc0 Update whats new (#55726) 2022-09-26 12:24:57 +03:00
renovate[bot]
fc7727430e Update dependency html-loader to v4.2.0 (#55655)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-26 10:24:03 +01:00
renovate[bot]
8bc8778287 Update dependency css-minimizer-webpack-plugin to v4.1.0 (#55619)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-26 10:22:59 +01:00
Maksim Nabokikh
d1e50580a5 Add the file label to dashboard provisioning errors (#53282)
Signed-off-by: m.nabokikh <maksim.nabokikh@flant.com>

Signed-off-by: m.nabokikh <maksim.nabokikh@flant.com>
2022-09-26 10:57:37 +02:00
idafurjes
178cd0a232 Use OrgUser method from org service (#55674)
* Use OrgUser method from org service

* Use GetOrgUser from org service
2022-09-26 10:27:38 +02:00
Nathan Marrs
15de96286a Canvas: Add edit option to context menu for elements with an edit mode (#55697) 2022-09-23 15:43:34 -04:00
Michael Mandrus
f8bde4df09 Public Dashboards: Add Grafana logo to public dashboards (#55641)
* add floating footer logo to pubdash pages

* make it a link

* fix typo

* use rem instead of pixels

* Update public/app/features/dashboard/components/PubdashFooter/PubdashFooter.tsx

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>

* Update public/app/features/dashboard/components/PubdashFooter/PubdashFooter.tsx

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>

* Update public/app/features/dashboard/components/PubdashFooter/PubdashFooter.tsx

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>

* Update public/app/features/dashboard/components/PubdashFooter/PubdashFooter.tsx

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>

* PR feedback

* add todo

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
2022-09-23 14:32:34 -04:00
Artur Wierzbicki
af9e58eeeb Search: fix cache in the frontend search engine (#55681) 2022-09-23 10:13:14 -07:00
Kevin Minehart
2fadeeff4c CI: move grabpl package command to pkg/build (#55651)
* add grabpl package

* update .drone.yml

* resolve lint errors
2022-09-23 11:49:07 -05:00
Jean-Philippe Quéméner
f3a307778a Alerting: cache general folder in migration based on org id (#55620) 2022-09-23 18:22:45 +02:00
Ashley Harrison
366731d8d9 Navigation: Add descriptions to NavModelItems (#55669)
* add some descriptions!

* Update some descriptions

* Tweak playlist description

* fix unit tests + betterer
2022-09-23 16:08:08 +01:00
Ashley Harrison
c65a8d3cab reenable active state for home (#55566) 2022-09-23 16:03:01 +01:00
Michael Mandrus
fedc1cdb11 Revert "Plugins: Display "renderer" and "secretsmanager" plugin types under plugin catalog "Application" filter (#55597)" (#55686)
This reverts commit e981848026.
2022-09-23 10:58:57 -04:00
Josh Hunt
4e65f131d9 Chore: Update betterer results for elasticsearch (#55682) 2022-09-23 09:46:24 -04:00
Ashley Harrison
480a3b92d2 dispatch clearFilters when an item is selected (#55512) 2022-09-23 14:46:21 +01:00
Kristina
c3e4f1f876 Explore: Add resize to split view, with Min/Max button (#54420)
* Add split resize to Explore without keeping width in state

* debug commit

* ugly hack around split lib only supporting one child

* Use SplitView to accomodate one or two elements, remove debug code, fix test

* More cleanup, fix state action

* Fix even split from manual size scenario

* cleanup

* Add new state elements to test

* Handle scrollable on internal element for virtualized lists

* Left align overflow button for explore

* Change min/max buttons

* Apply suggestions from code review

Co-authored-by: Giordano Ricci <me@giordanoricci.com>

* Add more suggestions from the code review

* Fix problems tests found

* commit broken test with debug info

* Add test, remove debug code

* Remove second get of panes

* Remove second get of panes

Co-authored-by: Elfo404 <me@giordanoricci.com>
2022-09-23 08:20:33 -05:00
Ashley Harrison
80c49688a1 turn on all the rules that are working anyway (#55679) 2022-09-23 09:18:23 -04:00
Jack Westbrook
ba10548547 CI: Update grabpl to 3.0.10 (#55678) 2022-09-23 15:15:04 +02:00
Jean-Philippe Quéméner
0f2afb6417 Alerting: support env variables in contact point settings when provsioning (#55666) 2022-09-23 08:06:51 -05:00
Ashley Harrison
717e9b0a34 add eslint-plugin-jsx-a11y (#55677) 2022-09-23 14:02:16 +01:00
Sonia Aguilar
e714d750f2 Alerting: Character / allowed in dashboard folder names, but not in alert folder names (#54395)
* Refactor FolderPicker to functional componment and add dissalowSlashes as an optional prop

* Update DetailsStep component to use FolderPicker dissalowing slashes in folders

* Adds icon that links to the Github issue when showing slashes not allowed  warning

* Add test for slashed folders warning

* Fix merge conflicts with folder creation fix PR

* Move slashes filter to useRuleFolderFilter hook, and make folder warning an optional generic prop

* Apply PR review suggestions
2022-09-23 14:44:24 +02:00
Will Browne
d0d8544ded Plugins: Create single point of entry for adding / removing plugins (#55463)
* split out plugin manager

* remove whitespace

* fix tests

* split up tests

* updating naming conventions

* simplify manager

* tidy

* explorations

* fix build

* tidy

* fix tests

* add logger helper

* pass the tests

* tidying

* fix tests

* tidy and re-add test

* store depends on loader

* enrich tests

* fix test

* undo gomod changes
2022-09-23 14:27:01 +02:00
Virginia Cepeda
003a1cdaa0 Alerting: log some basic user interactions (#55401)
* Log leaving rule group edit without saving

* Log filtering alert instances by label

Also debouncing the search to prevent sending too many log requests

* Log loading the Alert Rules list

* Move log messages to centralized location

* Add tests on log trackings

* Fix linting
2022-09-23 08:51:16 -03:00
idafurjes
fb66439c3e Chore: Add orguser methods to org service interface (#55668)
* Move role types to a separate package

* Make role type singular and remove _ from directory name

* Add orguser methods to org service

* Fix fake method
2022-09-23 07:19:34 -04:00
idafurjes
7f98f4b411 Move role types to a separate package (#55665)
* Move role types to a separate package

* Make role type singular and remove _ from directory name
2022-09-23 12:40:02 +02:00
Gareth Dawson
3eaeffda07 Elasticsearch: Remove any type from elastic_response.test.ts 2022-09-23 11:25:42 +01:00
Sofia Papagiannaki
d0e7765c6a Annotation: Optionally allow storing longer annotation tags (#54754)
* Annotation: Optionally allow longer annotation tags

* Do not accept configuration lower than today's default (500)

* Apply suggestion from code review
2022-09-23 06:04:41 -04:00
idafurjes
883c7a802b Chore: Use AddUserOrg from org service (#55657)
* Chore: Copy methods from sqlstore to org store

* Rename method, add test

* Add comments of tests

* Chore: Add methods from sqlstore to org service interface

* Avoiding import cycle

* Add and remove some methods

* User AddOrgUSer from org service in api

* Fix test function calls
2022-09-23 11:59:07 +02:00
Tania
96cb415497 Docs: Describe applying a license (#55078)
* Docs: Describe adding a license via API

* Add missing word
2022-09-23 11:57:51 +02:00
Konrad Lalik
7114c51f9f Alerting: Add alert preview to cloud rules editor (#54950) 2022-09-23 10:05:08 +02:00
idafurjes
e8a60c1988 Chore: Add methods from sqlstore to org service interface (#55635)
* Chore: Copy methods from sqlstore to org store

* Rename method, add test

* Add comments of tests

* Chore: Add methods from sqlstore to org service interface

* Avoiding import cycle

* Add and remove some methods
2022-09-23 09:58:17 +02:00
Torkel Ödegaard
c9b5acfefc Frontend: Update frontend styleguide emotion example (#55608)
* Frontend: Update frontend styleguide emotion example

* Update styling guide

* Fixes

* Add back link to cx

* prettier

* Update contribute/style-guides/frontend.md

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>

* prettier

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-09-23 08:22:16 +02:00
Dimitris Sotirakis
61c50ca1aa Update grabpl version to v3.0.9 (#55621) 2022-09-23 09:19:55 +03:00
renovate[bot]
07733a2ec1 Update dependency @kusto/monaco-kusto to v5.2.0 (#54134)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-23 05:53:34 +00:00
Jan Garaj
b1b4110ab1 CloudWatch: Add missing AWS/Prometheus metrics (#54990) 2022-09-22 22:25:33 -04:00
Artur Wierzbicki
f8d69415ca Search: create a separate HTTP endpoint (#55634)
* search: create a separate http endpoint

* search: extract api uri

* search: rename uri

* search: replicate the readiness check

* search: replicate the readiness check metric

* search: update mock
2022-09-22 19:02:09 -04:00
Torkel Ödegaard
09f4068849 NavTree: Refactor out the navtree building from api/index.go and into it's own service (#55552) 2022-09-22 22:04:48 +02:00
Garrett Guillotte
8863c4c140 Update CODEOWNERS with specific docs responsibilities (#55522)
* Update CODEOWNERS with specific docs responsibilities

* Docs: Per Ursula, hand off enterprise docs
2022-09-22 15:26:03 -04:00
Garrett Guillotte
f0e3b9b16b Docs: Clarify "supported data sources" (#54337)
* Docs: Clarify "supported data sources"

The term "supported" is context-dependent. Clarify the data sources
index page to link to the plugins catalog with additional detail,
and specify that the links to data sources are for those with
additional documentation content as part of Grafana.

Add a link to the tutorial to build a data source plugin.

* Update docs/sources/datasources/_index.md

Co-authored-by: Fiona Artiaga <89225282+GrafanaWriter@users.noreply.github.com>

Co-authored-by: Fiona Artiaga <89225282+GrafanaWriter@users.noreply.github.com>
2022-09-22 15:23:15 -04:00
Garrett Guillotte
a98a33774b Docs: Fix relrefs in access control API docs (#51940)
* Fix relrefs in access control API docs

* Apply Prettier changes to fix CI
2022-09-22 15:13:23 -04:00
Garrett Guillotte
72ec1eba1a Docs: Note issue #13399 in database install docs (#55596)
* Docs: Note issue #13399 in database install docs

* Docs: Be more specific about serverless Aurora MySQL
2022-09-22 12:00:48 -07:00
Hamas Shafiq
4be78095c9 Tempo: Wrap the autocomplete value for a tag in double quotes (#55610) 2022-09-22 18:37:46 +01:00
Nathan Marrs
ff7225745a Canvas: Add metric value element type (#55205) 2022-09-22 10:21:45 -07:00
lean.dev
3ab4d543d4 GrafanaUI: Add icon to links on Plugin configuration page (#55581) 2022-09-22 14:16:45 -03:00
Serge Zaitsev
4c19e83ff0 Chore: Move team store implementation to a separate package (#55514)
* Chore: move team store implementation to a separate package

* trying to fix more tests

* fix tests in service accounts and access control

* fix common tests

* restore commented out test

* add todos
2022-09-22 19:16:21 +02:00
idafurjes
591df92265 Chore: Copy methods from sqlstore to org store (#55615)
* Chore: Copy methods from sqlstore to org store

* Rename method, add test

* Add comments of tests
2022-09-22 19:02:55 +02:00
Michael Mandrus
e981848026 Plugins: Display "renderer" and "secretsmanager" plugin types under plugin catalog "Application" filter (#55597)
* convert plugin filter options to use a type instead of string

* add secrets manager and renderer to app plugin filter

* update frontend tests

* more test updates

* fix function to handle all cases
2022-09-22 12:28:44 -04:00
sam boyer
8314baf9bc ci: Update CODEOWNERS for as-code team (#55334) 2022-09-22 17:59:29 +02:00
Laura Fernández
4da04ff16d Navigation: use pageNav and subTitle in Dashboards > Settings > Links (#55510) 2022-09-22 17:44:47 +02:00
Gabriel MABILLE
3ce76e1e78 SAML: Allow wildcard mapping to add user to all existing orgs (#55628) 2022-09-22 17:34:00 +02:00
Kyle Brandt
27288276a2 Prometheus: Restore FromAlert header (#55255)
This restores the FromAlert header to prometheus for Grafana managed alert Queries. 

It does this by reverting "Prometheus: Remove middleware for custom headers (#51518)" , but also changing it so it is only the FromAlert header.

This reverts commit 2372501368.
2022-09-22 11:03:13 -04:00
Marcos Vinicius
69f1ba3e6e Elasticsearch: Rename public/app/plugins/datasource/elasticsearch/index_pattern.ts to follow convention (#55532)
* Elasticsearch: Rename public/app/plugins/datasource/elasticsearch/index_pattern.ts to follow convention

* undo change in this file
2022-09-22 14:04:16 +00:00
Ieva
6f93630e97 RBAC: add check for whether a role is managed (#55617)
* add check for whether a role is managed

* fix typo
2022-09-22 15:00:42 +01:00
Andreas Christou
cf588bd083 AzureMonitor: Automate retrieval of supported Metrics namespaces (#53203)
* Automate retrieval of supported Metrics namespaces

- Pass AzMonitor datasource to resource picker
- Add function to fetch unique namespaces for all subscriptions
- Update tests

* Remove unused file and reference

* Remove final namespace reference

* Add missing arguments

* Remove spaces added to generated file
2022-09-22 14:05:29 +01:00
juanicabanas
c7419de2e5 PublicDashboard: Add RTK Query with loading and error state. Add MSW dependency for testing. (#55518)
PublicDashboard: Add RTK Query with loading and error state. Add MSW dependency for testing.
2022-09-22 09:35:04 -03:00
Sofia Papagiannaki
2f14575dd3 Chore: Move annotations cleanup to the annotations service (#55618) 2022-09-22 15:27:48 +03:00
renovate[bot]
4739ff06a5 Update dependency @rushstack/node-core-library to v3.52.0 (#55614)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-22 12:59:32 +01:00
Sofia Papagiannaki
55ef34bee4 Instrumentation: Add api/health to the unnamed handlers (#55478) 2022-09-22 13:03:20 +03:00
Jan Garaj
e5619c0fe6 CloudWatch: update AWS/States metrics (#55427) 2022-09-22 12:00:07 +02:00
Marcus Efraimsson
919a26f389 Instrumentation: Guidance/conventions for logs, metrics and traces (#55562)
A first rough draft of adding some guidance/conventions for instrumenting 
Grafana with logs, metrics and traces together with how to run things 
locally to query/visualize logs, metrics and traces.

Closes #55470

Co-authored-by: Emil Tullstedt <emil.tullstedt@grafana.com>
Co-authored-by: Kristin Laemmert <mildwonkey@users.noreply.github.com>
Co-authored-by: Carl Bergquist <carl.bergquist@gmail.com>
2022-09-22 11:39:14 +02:00
renovate[bot]
ab13b951ed Update dependency @opentelemetry/semantic-conventions to v1.7.0 (#55577)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-22 10:37:58 +01:00
Artur Wierzbicki
e341aa4dab Search: fix front end query search condition (#55611)
* fix frontend query condition

* refactor to `inludes`
2022-09-22 05:34:09 -04:00
Grafana I18n Bot
c56b3f39cf Update source file messages.po (#55575) 2022-09-22 09:08:21 +00:00
Erik Sundell
5eeba155f7 Cloudwatch: Refactor - move describe all log groups to call resource handler (#55582)
* refactor backend

* move describe log groups to api file

* fix lint issue
2022-09-22 10:32:05 +02:00
Leo
383602a850 Dashboard: Fix plugin dashboard save as button (#55197)
* render SaveDashboardErrorProxy only when error is not yet handled

* improve dashbaoard drawer test
2022-09-22 09:14:13 +02:00
Victor Marin
da78f33939 TablePanel: Fix FooterRow styling for Safari and Firefox (#55543)
* Fix FooterRow styling for Safari and Firefox

* Change column header th to div
2022-09-22 09:33:15 +03:00
tab0r
06b38133a9 Update usage insights docs (#55155)
* adding links for cloud usage insights

* adding todo stub

* adding more stubs

* basic description

* remove two changes

* tweaks and todos from pairing

* addressing more feedback and adding links

* fix grafana enterprise links

* fix grafana enterprise links (one more)

* updating dashboard links to match style

* add note about cloud in export logs page

* missing word

* change the Grafana Enterprise notes links to point to the Grafana Enterprise intro
2022-09-21 16:47:45 -07:00
Drew Slobodnjak
6e85dfa25a Geomap: Add dynamic initial view options (#54419)
* Geomap: Add dynamic initial view options

* Add control options for dynamic initial view

* Add handling for last only scope

* Remove stale todos

* Only reinitialize map view during data if fit

* Add options for data fit

In map init, remove dependency on layers input.

Add a boolean to map view config to handle all layers, with default
set to true. Also, add layer string to handle currently selected layer.

Change some verbage.

In map view editor, add controls for data extent options. Only display
layer selection when all layers is not selected.

Update layer extent function to handle all options permutations. When
all layers is selected, return all data for extent calculation. When
last only is selected, only return last data point in matching layer for
extent calculation. Otherwise, return all data points in matching layer
for extent calculation.

* Change padding tooltip and hide for last only

* Simplify getLayersExtent call

* Add enums for data scope options

* Update GeomapPanel for refactor merge

* Move view init functions back into geomap class

Re-apply data change handling and extent calculation handling.

* Update padding tooltip verbage

* Ensure geomap panel options layers are initialized

* Clean up GeomapPanel file (betterer)

* refactors / clean up

* more cleanup

Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2022-09-21 13:11:44 -07:00
Kristina
5be04f5336 Set ExploreDrawer Z index to one below dashboard search (#55323) 2022-09-21 14:49:29 -05:00
Dimitris Sotirakis
a9a86cbe54 Introduce lint-frontend pipeline (#55559) 2022-09-21 14:39:28 -05:00
Marcus Efraimsson
08d352a0ad Instrumentation: Improve instrumentation of server lock service (#55516)
Improve log and trace instrumentation of the server lock service.

Closes #55455
2022-09-21 15:17:26 -04:00
Yuriy Tseretyan
2d38664fe6 Alerting: Improve validation of query and expressions on rule submit (#53258)
* Improve error messages of server-side expression 
* move validation of alert queries and a condition to eval package
2022-09-21 15:14:11 -04:00
Yuriy Tseretyan
879241a48f Alerting: Fix state manager tests (#55593) 2022-09-21 13:57:18 -05:00
Garrett Guillotte
29018d522c Docs: Fix link to config docs (#55396) 2022-09-21 11:42:39 -07:00
Galen Kistler
89a20526e5 Prometheus: Update onblur ref with value of last changed monaco editor (#55513)
* add new monaco callback to update onBlurRef with current value on monaco editor change.

* don't overload onBlur, create new onChange tracker that doesn't initiate queries, just updates values

* Update public/app/plugins/datasource/prometheus/components/monaco-query-field/MonacoQueryField.tsx

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
2022-09-21 12:51:14 -05:00
Sven Grossmann
e55003174a slate-suggenstions: adding moveBackward (#55576) 2022-09-21 19:39:54 +02:00
kay delaney
9e0d349bf9 LibraryPanelSearch: Refactor and fix hyphen issue (#55314) 2022-09-21 18:37:17 +01:00
Yuriy Tseretyan
199996cbf9 Alerting: Resolve stale state + add state reason to notifications (#49352)
* adds a new reserved annotation `grafana_state_reason`
* explicitly resolve stale states
2022-09-21 13:24:47 -04:00
Guilherme Caulada
9c2f3045b4 PublicDashboards: Resolve interval for public dashboard data source (#55489)
* Resolve interval for public dashboard data source

* Remove type assertions in favor of 'in'

* Add org id to public dashboard requests
2022-09-21 13:29:27 -03:00
idafurjes
48a8b35ece Chore: Add org methods to org service and store (#55579)
* Add org methods to org service and store

* Fix name of fake

* Remove unused fake

* Add xorm tags and half of a test

* Add cmment for clarifying missing part of test

* Add some comments about future refactors

* Rename test

* Add test for update org address
2022-09-21 18:00:18 +02:00
Galen Kistler
23afb0c04e delete graphite angular partial (#55570) 2022-09-21 10:30:24 -05:00
Ashley Harrison
cf19baf80f improve responsiveness of breadcrumbs (#55572) 2022-09-21 15:52:06 +01:00
Jean-Philippe Quéméner
74c66b29d0 Alerting: Skip unsupported file types on provisioning (#55573) 2022-09-21 16:48:39 +02:00
Ashley Harrison
1978b935ba remove underlay fade out animation (#55578) 2022-09-21 10:42:08 -04:00
renovate[bot]
bc6a006fc0 Update dependency @lezer/lr to v1.2.3 (#54144)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-21 16:18:09 +02:00
Artur Wierzbicki
1f2cab9036 SearchV2: add more tracing spans (#55488)
* add additional spans to searchv2

* add initial setup span

* add dashboardCount attribute to readDashboard span

* add dashboard count to init org index span

* fix merge

Co-authored-by: Todd Treece <todd.treece@grafana.com>
2022-09-21 16:14:52 +02:00
Yuriy Tseretyan
0629d3922a stop flushing state when Grafana stops (#55504) 2022-09-21 10:10:17 -04:00
Andreas Christou
17fc5d82d3 Bump code coverage versions (#55554) 2022-09-21 13:38:02 +01:00
Emil Tullstedt
647997cc4c Alerting: Fix flaky test (#55551)
The length of the identifier from the underlying library is 9 or more characters depending on the rate at which the identifiers are generated. See https://pkg.go.dev/github.com/teris-io/shortid

The test previously made the assumption that the length will always be 10, which would intermittently fail.
2022-09-21 14:17:25 +02:00
ying-jeanne
7b4cea8151 Chore: StoreSplit tag service (#55453)
* move tag service outside

* fix dashboard

* fix test

* lint

* fix linter

* remove spew
2022-09-21 08:04:01 -04:00
Josh Hunt
e3e954cbba Docs: Fix decimals: auto docs for panel edit (#55477)
* Docs: Fix decimals: auto docs for panel edit

* Update docs/sources/panels/configure-standard-options/index.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2022-09-21 12:56:04 +01:00
Artur Wierzbicki
5a1f004fb1 Live: Fix live streaming with live-service-web-worker feature flag enabled (#55528) 2022-09-21 13:09:16 +02:00
Dimitris Sotirakis
c18432971b CI: Introduce lint-backend pipeline (#55476)
* Introduce lint-backend pipeline

* Use go image and install make

* Don't run lint pipeline on .drone.yml changes
2022-09-21 07:05:19 -04:00
Will Browne
b25ea75bac Plugins: Add secure JSON fields to plugin setting DTO (#55313)
* add secure JSON fields to plugin setting DTO

* add nil pointer fix

* adding secureJsonFields to the plugin meta.

Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>
2022-09-21 12:20:11 +02:00
Emil Tullstedt
c10a69c007 Cleanup: Add traces to cleanup jobs (#55465) 2022-09-21 12:01:21 +02:00
Torkel Ödegaard
8440baab91 NavBarMenu: Section as links and design tweak (#55538)
* scaffold new component + remove storing of expanded state

* some padding fixes

* simplify!

* move browse back to being a child of dashboards

* behaviour working

* improve child matcher to look recursively

* increase NavBarMenu zIndex to ensure it overlays explore drawer

* some renaming

* fix unit test

* make dashboards a top level item again and make chevrons their own buttons

* remove active background state

* Finished tweaks

* remove theme change

* Remove exit animation

* align button centrally + fix empty message alignment

* only show the empty message if there are no children

* ensure overflowing menu items truncate correctly

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-09-21 11:57:30 +02:00
Gábor Farkas
3a545007ca elastic: devenv: add nested objects to data generator (#55482) 2022-09-21 11:34:49 +02:00
George Robinson
bad4f7fec5 Alerting: Change screenshots to use components (#55156)
* Alerting: Change screenshots to use components

This commit changes screenshots to use a number of components instead of a set of functional wrappers.

It moves the uploading of screenshots from the screenshot package to the image package so we can re-use the same code for both uploading screenshots and server-side images; SingleFlight from the screenshot package to the image package so we can use it for both taking and uploading the screenshot, where as before it was used just for taking the screenshot; and it also removes the use of a cache because we know that screenshots can be taken at most once per tick of the scheduler.
2022-09-21 10:25:07 +01:00
George Robinson
7d20766ae9 Alerting: Fix mathexp.NoData cannot be reduced (#55347)
This commit fixes a bug where queries from datasources such as InfluxDB that returned no data would not create a DatasourceNoData alert, but instead an error "can only reduce type series, got type noData".
2022-09-21 10:01:51 +01:00
Erik Sundell
28ebdf1641 move describe log groups to resource api (#55485) 2022-09-21 10:55:54 +02:00
GitStart
79a5e3e802 Elasticsearch: rename public/app/plugins/source/elasticsearch/query_def.ts to follow convention (#55415) 2022-09-21 10:25:04 +02:00
GitStart
ff043aebef Elasticsearch: Rename public/app/plugins/datasource/elasticsearch/query_builder.ts to follow convention (#55413) 2022-09-21 09:38:25 +02:00
Julien Duchesne
a44c0040a9 Drone: Always have image_pull_secrets (#55530)
Having it doesn't prevent pulling any images, so it's easier if it's everywhere
2022-09-21 06:27:43 +00:00
GitStart
667993eae7 Dashboard: Single right-aligned y axis loses gridlines (#54206)
Co-authored-by: gitstart <gitstart@gitstart.com>
Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: Júlio Piubello da Silva Cabral <julio.piubello@gitstart.dev>
Co-authored-by: Thiago Nascimbeni <tnascimbeni@gmail.com>

Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: gitstart <gitstart@gitstart.com>
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: Júlio Piubello da Silva Cabral <julio.piubello@gitstart.dev>
Co-authored-by: Thiago Nascimbeni <tnascimbeni@gmail.com>
2022-09-20 23:58:12 -05:00
Torkel Ödegaard
96dfc4bac5 GrafanaRoute: Use React.Lazy instead of react-loadable and improve error handling (#55339)
* Things are working

* Add new GrafanaRoute tests

* removed old file

* Remove from package.json
2022-09-21 05:41:05 +02:00
GitStart
e0c630e915 Status History Panel: Show X-Axis Value in Tooltip (#54563)
Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: gitstart <gitstart@gitstart.com>
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Matheus Benini <matheus_benini@hotmail.com>
Co-authored-by: Júlio Piubello da Silva Cabral <julio.piubello@gitstart.dev>
Co-authored-by: juliopiubello <juliopiubellow@gmail.com>
2022-09-20 21:57:47 -05:00
Ryan McKinley
0c38a3ba97 Search: Investigate frontend search options (again) (#55526) 2022-09-20 20:24:29 -04:00
Artur Wierzbicki
c3ca5405ce Search: Add search index configuration options (#55525)
* Search: externalize config

* Search: update config descriptions

* Search: fix value

* Search: fix

* update

* Search: revert config values

* Search: rename copy/paste

* Search: fix tests
2022-09-20 19:09:55 -04:00
Artur Wierzbicki
9db2720016 Search: improve logging in case of failed dashboard loading phase (#55523) 2022-09-20 23:50:29 +02:00
Yuriy Tseretyan
57a0b6db2c Alerting: Refactor WeCom notifier to use encoding/json to parse settings instead of simplejson (#55423) 2022-09-20 14:37:24 -04:00
Ieva
6d5bdf12e8 resolve merge conflicts (#55503) 2022-09-20 13:31:08 -04:00
kay delaney
064a9ccd6e PanelHeader: Add deadzone to panel header click/drag detection (#55490) 2022-09-20 18:15:03 +01:00
Serge Zaitsev
305d494902 Chore: Switch over to team.Service instead of sqlstore (#55497)
* switch to using team service

* trying to fix tests

* more tests to fix

* add missing teamtest package
2022-09-20 18:58:04 +02:00
Torkel Ödegaard
40bc140a9a Refactoring and simplifying TopSearchBar (#55341) 2022-09-20 18:57:38 +02:00
Grot (@grafanabot)
80c0dc890a ReleaseNotes: Updated changelog and release notes for 9.0.9 (#55511) 2022-09-20 16:45:53 +00:00
owensmallwood
aae2c3c4f4 PublicDashboards: Tag is rerendered when dashboard meta changes in state (#55414)
Can update dashboard meta state using dashboard events.
2022-09-20 10:42:57 -06:00
Marcus Efraimsson
862a6a2fa6 Logging: Introduce API for contextual logging (#55198)
Introduces a FromContext method on the log.Logger interface that 
allows contextual key/value pairs to be attached, e.g. per request, 
so that any logger using this API will automatically get the per request 
context attached. The proposal makes the traceID available for 
contextual logger , if available, and would allow logs originating from 
a certain HTTP request to be correlated with traceID.
In addition, when tracing not enabled, skip adding
traceID=00000000000000000000000000000000
to logs.
2022-09-20 18:32:06 +02:00
Grot (@grafanabot)
c6ed7d6741 ReleaseNotes: Updated changelog and release notes for 9.0.9 (#55506) 2022-09-20 16:21:25 +00:00
Grot (@grafanabot)
ce10706f03 ReleaseNotes: Updated changelog and release notes for 8.5.13 (#55502) 2022-09-20 11:55:14 -04:00
Jo
006944a360 Auth: Add development manual override (#55496)
* Auth: Add development manual override

* rename to disable_sync_lock
2022-09-20 11:48:40 -04:00
Alexander Emelin
0e6a8cc6ac Live: Migrate to centrifuge-js v3 (new API and client protocol) (#51977) 2022-09-20 11:39:46 -04:00
renovate[bot]
42cf92a3f2 Update dependency @daybrush/utils to v1.10.0 (#55492)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-20 16:35:37 +01:00
Alexander Weaver
3a580dc3cd Alerting: Extract default message embed into named constant (#55424)
* Resolve conflicts

* Combine multiple const definitions
2022-09-20 10:20:06 -05:00
renovate[bot]
3195866596 Update dependency @babel/plugin-transform-runtime to v7.19.1 (#55289)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-20 16:00:06 +01:00
Artur Wierzbicki
03af63d52e SearchV2: add tracing to background jobs (#55250)
* searchv2: add tracing to background jobs

* searchv2: lint

* searchv2: lint

* searchv2: fix context passing

* searchv2: add init org index span

* searchv2: add traceid to logs

* searchv2: add db count to logs
2022-09-20 16:49:44 +02:00
Leonard Gram
a14bd4055f Chore: update latest.json to 9.1.6 (#55486) 2022-09-20 16:47:25 +02:00
Grot (@grafanabot)
bbb8bf08db ReleaseNotes: Updated changelog and release notes for 9.1.6 (#55481) 2022-09-20 16:31:35 +02:00
Jo
0be644031d Auth: Add SAML common resolutions to cookie issues (#55395)
* Auth: Add SAML cookie specifics

* Auth: remove legacy message

* HTTPS

Co-authored-by: Misi <mgyongyosi@users.noreply.github.com>

Co-authored-by: Misi <mgyongyosi@users.noreply.github.com>
2022-09-20 16:21:50 +02:00
Josh Hunt
070d44802f Chore: Type Rudderstack and AppInsights window APIs (#55162)
* Chore: Type Rudderstack and AppInsights window APIs

* remove rudder sdk to dev deps
2022-09-20 10:06:31 -04:00
Emil Tullstedt
4711454b81 Org: Fix service initialization (#55460) 2022-09-20 08:28:47 -04:00
Hamas Shafiq
d06ed3226c Jaeger: Add cheat sheet (#54521) 2022-09-20 12:48:17 +01:00
Konrad Lalik
4c4b758646 Alerting: Add templates autocomplete (#53655)
Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
2022-09-20 13:07:17 +02:00
idafurjes
43a1d1484d Add some org methods to org service interface (#55449)
* Add some org methods to org service interface

* Fix fake method name
2022-09-20 12:57:51 +02:00
Laura Benz
dbbab6e95c Explore: Add feature tracking events (#54514)
* feat: add tracking in query row button group

* feat: add tracking for split view

* feat: add tracking for query inspector tab open

* feat: add tracking for shortened link button

* feat: add tracking for change of datasource

* feat: add tracking for time range options

* refactor: clean up

* refactor: repair tests

* refactor: clean up

* feat: add details to change of data source

* refactor: remove duplicate tracking

* refactor: make tracking reusable in an easier way

* refactor: add property

* refactor: change data for time picker

* refactor: change tracking label for time picker

Co-authored-by: Ivan Ortega Alba <ivanortegaalba@gmail.com>

* refactor: store tracking in explore component

* refactor: add index signature

* refactor: remove ?

* refactor: split into 3 callbacks

* refactor: apply suggestions from code review

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

Co-authored-by: Ivan Ortega Alba <ivanortegaalba@gmail.com>
Co-authored-by: Piotr Jamróz <pm.jamroz@gmail.com>
2022-09-20 06:50:23 -04:00
idafurjes
eff4daacaf Bug: Rollback change in search (#55443) 2022-09-20 12:18:39 +02:00
Dimitris Sotirakis
cb93ed04a7 Add storybook bucket for main builds (#55448) 2022-09-20 13:15:06 +03:00
Serge Zaitsev
2ee3fd3994 Chore: Create structure for team service (#55444) 2022-09-20 10:14:00 +00:00
Giordano Ricci
d815e2cb56 Correlations: Return 200 instead of 404 for empt correlation lists (#55242)
* return 200 instead of 404 for empty correlations list

* handle empty list response & improve consistency
2022-09-20 11:13:33 +01:00
Josh Hunt
d014a3a09b Echo: Add support for Google Analytics 4 (#55446)
* user essentials mob! 🔱

lastFile:public/app/core/services/echo/backends/analytics/GA4Backend.ts

* user essentials mob! 🔱

* user essentials mob! 🔱

lastFile:public/app/core/services/echo/backends/analytics/GA4Backend.ts

* user essentials mob! 🔱

lastFile:public/app/core/services/echo/backends/analytics/GA4Backend.ts

* user essentials mob! 🔱

lastFile:public/app/app.ts

* user essentials mob! 🔱

Co-authored-by: eledobleefe <laura.fernandez@grafana.com>
Co-authored-by: Leodegario Pasakdal <leodegario.pasakdal@grafana.com>
2022-09-20 03:13:14 -07:00
Jo
13146cc812 Auth: reduce allocs (#55410) 2022-09-20 12:03:08 +02:00
Torkel Ödegaard
10b3c0787a CSSTransition fixes warnings (#55340) 2022-09-20 11:47:31 +02:00
Marcos Vinicius
c088f2be50 Elasticsearch: Rename public/app/plugins/datasource/elasticsearch/language_provider.ts to follow convention (#55430) 2022-09-20 11:34:07 +02:00
Serge Zaitsev
8f1e2ed658 Chore: Split temporary user (invite) service (#55397)
* Chore: Split temporary users

* change references to tempuser service

* fix api tests

* restore tests
2022-09-20 11:29:17 +02:00
matt abrams
9bf778d5d7 add triage/needs-confirmation to collector (#55189) 2022-09-20 11:11:12 +02:00
Sonia Aguilar
4270e5606c Alerting: Fix enter key 'clicking' first button on form (#55222)
* Add type='button' in button used in Heading component to prevent having the default value ='submit'

* Add type='button' for buttons used in form when grafana-managed alert type is selected

* Add type='button' for buttons used in form when mimir-or-loki alert type is selected
2022-09-20 11:02:41 +02:00
Konrad Lalik
20e6e0d593 Alerting: Fix default query's data source when no default datasource specified (#55435) 2022-09-20 10:43:39 +02:00
Gábor Farkas
323ca6825a devenv: removed obsolete elastic docker configs (#55402) 2022-09-20 10:16:28 +02:00
idafurjes
7ce7c9b64c Chore: Move SearchOrgs to org service (#55416)
* Chore: Move SearchOrgs to org service

* Fix lint

* Fix lint 2
2022-09-20 09:55:40 +02:00
Andrea Spadaccini
e25612092b Mention the need for Subscription Reader role (#51844)
Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
Co-authored-by: Andres Martinez Gotor <andres.mgotor@gmail.com>
Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>
2022-09-20 09:24:33 +02:00
Sven Grossmann
95ddfe8ee1 GrafanaUI: mark all Log components deprecated (#55404) 2022-09-20 08:48:32 +02:00
Erik Sundell
caba98590d Cloudwatch: Break out resource requests from datasource file (#55358)
* break out resource requests from datasource file

* fix lint issues
2022-09-20 07:50:54 +02:00
Alexander Weaver
4df41972f1 Alerting: Refactor one notifier to use encoding/json to parse settings instead of simplejson (#55271)
* Create struct for Slack's receiver settings

* Remove one layer of indirection when building slack notifier

* Delete un-used struct

* Validate against settings struct instead of simplejson object

* Genericize settings marshalling

* Remove repetition between fields on notifier and fields on settings struct

* Rename unmarshal settings wrapper

* Handle comma separated strings at marshalling time rather than validation time

* Address misc review feedback
2022-09-19 17:30:16 -05:00
Serge Zaitsev
7108b4331d Fix: return proper values in dashboard thumbs service (#55421) 2022-09-20 00:29:55 +02:00
owensmallwood
c946e44741 Ignore docker-compose override. (#55407)
adds docker-compose override to gitignore
2022-09-19 12:17:54 -06:00
Guilherme Caulada
3b1fc18692 PublicDashboards: Ignore time range input and changes on public dashboard (#55412)
* Ignore time range input and changes on public dashboard

* Use config instead of getConfig to access boot config
2022-09-19 15:16:27 -03:00
Timur Olzhabayev
80ff9fc0ef Chore: Handing over sigv4 middleware ownership (#55355) 2022-09-19 18:39:24 +02:00
Misi
8405a99fef Chore: Add changed enterprise devenv path to .gitignore (#55408) 2022-09-19 12:15:28 -04:00
sam boyer
4d0988b6b2 misc: Update to Go 1.18 (#53440) 2022-09-19 16:04:14 +00:00
Guilherme Caulada
ee899e8c3a PublicDashboards: Sanitize metadata from public dashboard queries (#55269)
* Add function to remove metadata from queries

* Add test for RemoveMetadataFromQueryData function

* Remove only custom data and executed query string

* Add sanity check to SanitizeMetadataFromQueryData
2022-09-19 12:44:29 -03:00
Torkel Ödegaard
d5e4b08a3a DashNav: Fixes missing key warning caused by public dashboard tag (#55336) 2022-09-19 17:01:14 +02:00
Jack Westbrook
db17a88193 Plugins: Expose emotion/react to plugins to prevent load failures (#55297) 2022-09-19 16:54:13 +02:00
Kristina
273ff02dde Explore: Add error handling function when retrieving datasource (#55055)
* Use datasource function with error handling

* Check datasource exists when validating query, add test

* Add mock to test that now requires it

* Add comment explaining verbose validity logic
2022-09-19 09:43:16 -05:00
Dimitris Sotirakis
b26e443173 Fix fetch-images command (#55365) 2022-09-19 17:17:56 +03:00
Dimitris Sotirakis
2c872b0d94 Run enterprise downstream after OSS CI is done (#55366) 2022-09-19 17:17:36 +03:00
Dimitris Sotirakis
f058e1eae3 Add storybook bucket for main builds (#55379) 2022-09-19 17:17:25 +03:00
Torkel Ödegaard
cc4392d514 Devenv: Add compose block for elastic 8 (#55214)
* Devenv: Add compose block for elastic 8

* added filebeat and metricbeat configurations

* disable mount to `/var/log`

* renamed to elasticstack

Co-authored-by: Sven Grossmann <svennergr@gmail.com>
Co-authored-by: Gábor Farkas <gabor.farkas@gmail.com>
2022-09-19 16:05:42 +02:00
Jo
e1af4e72bc Auth: Add documentation on group overage claims in AzureAD (#55389)
* Auth: Add documentation on group overage claims in AzureAD

* add info on versioning
2022-09-19 15:45:05 +02:00
Sonia Aguilar
e677afabdf Use GrafanaAlertStateDecision.Error instead of Error string in RuleEditor test (#55385) 2022-09-19 15:04:24 +02:00
Giordano Ricci
93e4205caa chore: fix OX coverage report (#55386) 2022-09-19 13:55:09 +01:00
GitStart
6fb8abbbb6 Convert packages/jaeger-ui-components/src/TracePageHeader/SpanGraph/TickLabels.test.js to RTL (#55284)
Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: Toledodev <rafael.toledo@engenharia.ufjf.br>
Co-authored-by: Júlio Piubello da Silva Cabral <julio.piubello@gitstart.dev>
2022-09-19 15:02:33 +03:00
Giordano Ricci
d2adb1a3cd chore: add coverage repoort for OX-related PRs (#55316) 2022-09-19 13:01:15 +01:00
Torkel Ödegaard
2916b483eb Update a few more pages to use navId instead of navModel from store (#55342) 2022-09-19 13:21:41 +02:00
Gábor Farkas
5efeff4890 GrafanaUI: Deprecate logs components (#55364)
* grafana-ui: mark logs-components deprecated

* improved deprecation-message
2022-09-19 13:21:14 +02:00
Tima Gixe
e73a85dfb5 Chore: omit allowCustomValue and allowEmptyValue (#55352) 2022-09-19 13:40:58 +03:00
Will Browne
cd7a464f7e Plugins: Ensure plugin uninstall success for "pre-installed" community plugins (#55322)
* track pre-installed external plugins in store

* fix tests
2022-09-19 12:14:30 +02:00
kay delaney
64bbb7a7ce Chore: Update and enforce usage of typed react-redux hooks (#55349)
* Chore: Update and enforce usage of typed react-redux hooks
2022-09-19 10:49:35 +01:00
Sven Grossmann
a3ff758874 ElasticSearch: Fix dispatching queries at a wrong time (#55225)
* Loki: Fix running queries without an `expr`

* rever previous change

* only dispatch `initQuery` if the DS is uninitialized

* moved `isUninitialized` to static var
2022-09-19 11:45:21 +02:00
George Robinson
4a1ca7e32f Alerting: Change default alert state to Error on execution error or timeout (#55345) 2022-09-19 10:42:04 +01:00
Serge Zaitsev
96b032e103 Chore: Split dashboard thumbnail service (#55344)
* Chore: split dashboard thumbnail service

* fix typo

* move tests

* make linter happy
2022-09-19 11:29:22 +02:00
Gábor Farkas
1ee6a1f7c2 Logs: move logs-components from grafana-ui to grafana-main (#55041)
* logs: added a copy of the grafana-ui logs-files

* fix: added the ansicolor package to the main grafana package

* logs-components: import things from grafana-ui

* import from local files

* logs-components: other fixes

* add betterer-exceptions

* apply updates from grafana-ui package
2022-09-19 10:51:46 +02:00
Victor Marin
32c4245efd TablePanel/StatPanel: Fix values not being visible when background transparent (#55092)
* TablePanel/StatPanel: Fix values not being visible when background transparent

* Maintain backwards compatibility
2022-09-19 11:47:37 +03:00
Yaelle Chaudy
1e9f5a5080 Azure Monitor: Fix migration issue with MetricDefinitionsQuery template variable query types (#55262)
* updated imported dashboards

* Adds check for MetricDefinitionsQuery in migration

* Removed delete from migratio

* switched back to const for migratedQ

* Added depreacted to MetricDefinitionQuery
2022-09-19 10:32:27 +02:00
Dimitris Sotirakis
93e78e2146 CI: Move fetch-images sub-command from build-pipeline repo (#55298)
* Move fetch images from build-pipeline

* Modify drone

* Replace zerolog with builtin log

* Fix lint
2022-09-19 11:19:31 +03:00
Sofia Papagiannaki
754eea20b3 Chore: SQL store split for annotations (#55089)
* Chore: SQL store split for annotations

* Apply suggestion from code review
2022-09-19 10:54:37 +03:00
Erik Sundell
469f915b8c CloudWatch: Enable feature adoption tracking in the plugin (#54299)
* improve typing for DashboardLoadedEvent

* cleanup

* add cloudwatch tracking event

* add test

* revert test change

* fix typo

* remove optional

* pr feedback

* reactor test

* revert changes to api and azure

* cleanup

* refactoring test

* pr feedback
2022-09-19 08:53:42 +02:00
Erik Sundell
7bca193ecd CloudWatch: Refactoring - decouple logs and metrics in datasource file (#55079)
* break out query execution related logic

* betterer fixes

* remove unused

* cleanup

* remove unused variables

* remove not used file

* fix broken test

* pr feedback

* add comments
2022-09-19 08:50:41 +02:00
Leo
1a0cbdeabe Navigation: Add help menu to top search bar (#55062)
* add help menu to top search bar

* fixes

* handle preventDefault in node graph specifically

* use icon prop of MenuItem

* undo changes to ContextMenuPlugin/DataLinksContextMenu

* remove unused component

* revert storybook changes

* Tweaks

* remove unused style

* stop propagation on the header so version can be highlighted

* make sure useContextMenu has the exact same logic as before

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-09-17 18:17:00 +02:00
Ryan McKinley
17b2fb04e8 DashboardQuery: Expand query options (#53998) 2022-09-16 13:28:47 -04:00
Jean-Philippe Quéméner
4dc0d49025 Alerting: make sure that rules in rule group are nil if not provided (#55301) 2022-09-16 18:54:00 +02:00
Joao Silva
bf5b21563c StatPanel: Add padding between horizontal name and value (#55299) 2022-09-16 17:53:09 +01:00
brendamuir
c0c4409abc Docs: adds set up section with alertmanager, provisioning sections (#55291)
* Docs: adding setup, provisioning docs

* add set up, alertmanager

* Adds link to provisioning from set up page

* renames topics in set up section

* fixes alertmanager link

* removing article for alertmanager

* first connection to oncall

* updating armands intro text

* getting rid of blank line
2022-09-16 17:22:20 +01:00
Gareth Dawson
98a8908910 Loki: Remove any type from logs.test.ts (#55303)
* Remove any type from logs.test.ts

* Replace unknown types and move type casting to variables
2022-09-16 16:57:42 +01:00
Ryan McKinley
0c4d181d1e SupportSnapshots: Rename to "Get help" (#55206) 2022-09-16 08:51:14 -07:00
Yuriy Tseretyan
6539ae512c use filepath.Dir to get the parent (#55266) 2022-09-16 10:29:39 -04:00
Gregory Quinio
fb59702c74 Storybook: use div #root styles on storybook preview instead of additional div wrapper (#55023)
* feat: use styles on #root div instead of additionnal div wrapper

* Update packages/grafana-ui/src/utils/storybook/withTheme.tsx

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
2022-09-16 17:04:56 +03:00
Dave Henderson
801b61c963 Tracing: Add new [tracing.opentelemetry] custom_attributes config setting (#54110)
* tracing: Add new [tracing.opentelemetry] custom_attributes config setting

Signed-off-by: Dave Henderson <dave.henderson@grafana.com>

* Fix typos in config

Signed-off-by: Dave Henderson <dave.henderson@grafana.com>

* Return error when custom_attributes contains malformed entries

Signed-off-by: Dave Henderson <dave.henderson@grafana.com>

Signed-off-by: Dave Henderson <dave.henderson@grafana.com>
2022-09-16 09:54:25 -04:00
Kristina
18f4d02262 Docs: Update enter/shift+enter details for prometheus query field (#52607)
* Update for accuracy

* Update docs/sources/explore/query-management.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>
2022-09-16 09:50:18 -04:00
GitStart
46f0672215 Loki: Remove hardcoded values for parsed query parts (#54755)
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
Co-authored-by: gitstart <gitstart@gitstart.com>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Matheus Benini <matheus_benini@hotmail.com>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: Júlio Piubello da Silva Cabral <julio.piubello@gitstart.dev>

Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
Co-authored-by: gitstart <gitstart@gitstart.com>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Matheus Benini <matheus_benini@hotmail.com>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: Júlio Piubello da Silva Cabral <julio.piubello@gitstart.dev>
2022-09-16 15:35:20 +02:00
Piotr Jamróz
9b4cdfe652 Correlations: Hide Correlations Page behind a feature toggle (#55224)
* Hide Correlations Page behind a toggle

* Remove redundant defaults

* Ensure top nav is rendered when correlations are disabled

This is for the case when:

[feature_toggles]
topnav = true
2022-09-16 15:14:27 +02:00
Gareth Dawson
5c66c41220 Loki: Remove any type from logsModel.test.ts (#55287)
* Remove any type from logsModel.test.ts

* Remove duplicate type checks
2022-09-16 12:56:35 +01:00
Ivana Huckova
82a6872f0f Loki, Prometheus: Remove beta tag from query builder (#55150) 2022-09-16 12:31:33 +02:00
Dimitris Sotirakis
95512c19e0 CI: Refactor versions.go (#55238)
* Refactor versions.go

* s/ReleaseModeConfig/BuildConfig
2022-09-16 06:26:33 -04:00
ying-jeanne
e4741ce8d6 remove datasource from sqlstore (#55288) 2022-09-16 06:20:26 -04:00
Victor Marin
18f33871d1 Fix header/footer not sticky (#55285) 2022-09-16 13:14:34 +03:00
Eric Leijonmarck
9cdd1cde7f fix: order of database (#55232)
* fix: order of database

* fix: sort of results

* Update pkg/api/dtos/models_test.go

Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>

* Update pkg/api/dtos/models_test.go

Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>

* only one assert

Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
2022-09-16 05:24:24 -04:00
renovate[bot]
7565752644 Update dependency @swc/core to v1.3.1 (#55040)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-16 10:19:44 +01:00
GitStart
f26babf484 Loki: Rename public/app/plugins/datasource/loki/query_utils.ts file to follow convention (#55180) 2022-09-16 10:16:54 +02:00
Agnès Toulet
359685b051 Docs: RBAC update for insights and query caching (#52544)
* Doc: RBAC update for insights and query caching

* Fix RBAC actions table order

* Fix RBAC role definitions & assignments tables

Co-authored-by: Joan López de la Franca Beltran <joanjan14@gmail.com>
2022-09-16 09:59:59 +02:00
Leo
e7ae71a5cc Navigation: use pagenav and subtitle to the new team page (#55200)
* added pageNav to new team page

* improve copies

* improve copies

* improve test
2022-09-16 09:32:08 +02:00
Leo
896d684065 Browse: Hide dashboard actions if user does not have enough permission (#55218)
* hide dashboard actions if user does not have enough permission

* improve test description
2022-09-16 09:19:19 +02:00
Leo
3f413f6f94 Navigation: Use navId and pageNav for Create User page (#55201)
* added pageNav subttitle and used navid for usercreatepage

* improve subtitle copy and redirected to user page after creation

* improve title copy

* improve copies

* breadcrumbs redirect to users page instead of org
2022-09-16 09:16:26 +02:00
Leo
26e444c194 Navigation: Use navid and pagenav for new org page (#55203)
* use navid and pagenav for new org page

* Minor tweak

* improve copies

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-09-16 08:56:50 +02:00
GitStart
eb7fe07401 Loki: Rename public/app/plugins/datasource/loki/language_utils.ts file to follow convention (#55181) 2022-09-16 08:48:37 +02:00
Ryan McKinley
6947e276d6 Inspect: Hide Actions tab when it is empty (#55272) 2022-09-15 22:17:12 -07:00
Christopher Moyer
dd0be3012c adjusts structure of tasks (#55268) 2022-09-15 17:17:12 -05:00
Saverio Proto
a09e4b0e4f Update grafana version tag to 9.1.0 (#54049)
* Update grafana version tag to 9.0.5

The user doing cut and paste will not notice and will install a old version of Grafana

* Update version to 9.1.0

Current latest tag is 9.1.0: https://hub.docker.com/r/grafana/grafana/tags
2022-09-15 19:46:13 +00:00
Garrett Guillotte
97ca109d84 Docs: Fix Cloud availability of JWT URL Embedding (#55260)
* Docs: Fix Cloud availability of JWT URL Embedding

* Docs: Clarify JWT URL embedding availability in docs
2022-09-15 10:57:38 -07:00
Ezequiel Victorero
9770edb118 Docs: Grafana Live not supported by public dashboards (#55246) 2022-09-15 14:53:27 -03:00
Brendan O'Handley
331f3e2a58 small fix for new variable editor types (#55195) 2022-09-15 11:39:40 -05:00
George Robinson
5561f935e6 Alerting: Fix send resolved notifications (#54793)
This commit fixes a bug where we did not send resolved alerts to Alertmanager for resolved alert instances. This meant that resolved notifications did not have the annotations from the resolved state, and a result did not also have the resolved screenshot.
2022-09-15 17:25:05 +01:00
Michael Musenbrock
099d3cdf72 Provisioning Contact points: Support disableResolveMessage via YAML too (#54122)
Signed-off-by: Michael Musenbrock <michael.musenbrock@gmail.com>
2022-09-15 12:19:34 -04:00
Jo
3e2e9f93b9 Auth: Allow admins to manually change oauth user role if oauth_skip_org_role_update_sync is enabled (#55182)
* Auth: Allow admins to change oauth user info it it's not synced.

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>

* Update public/app/features/admin/UserAdminPage.tsx

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>

* Add missing import

* Simplify init

Co-authored-by: Josh Hunt <joshhunt@users.noreply.github.com>
Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>

* SAML: Add option to skip org role sync (#55230)

* SAML: Add option to skip org role sync

* Modify frontend accordingly

* Remove update from config option name

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Remove update from config option name

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Fix typo

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
Co-authored-by: gamab <gabi.mabs@gmail.com>
Co-authored-by: Josh Hunt <joshhunt@users.noreply.github.com>
2022-09-15 12:06:09 -04:00
Kim Nylander
ebcbb66548 Fix broken image rendering troubleshooting links (#55210) 2022-09-15 10:50:08 -05:00
owensmallwood
5121e32722 When generating the pubdash url, use the base url from the Grafana config. This allows the url generation to work in the case that Grafana is hosted on a subpath. (#55204)
Support subpaths when generating public dashboard url
2022-09-15 09:46:11 -06:00
Jo
00e7324bf6 Auth: Restore legacy behavior and add deprecation notice for empty org role in oauth (#55118)
* Auth: Add deprecation notice for empty org role

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>

* fix recasts

* fix azure tests missing logger

* Adding test to gitlab oauth

* Covering more cases

* Cover more options

* Add role attributestrict check fail

* Adding one more edge case test

* Using legacy for gitlab

* Yet another edge case YAEC

* Reverting github oauth to legacy

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Not using token

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Nit.

* Adding warning in docs

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* add warning to generic oauth

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Be more precise

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Adding warning to github oauth

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Adding warning to gitlab oauth

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Adding warning to okta oauth

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Add docs about mapping to AzureAD

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Clarify oauth_skip_org_role_update_sync

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Nit.

* Nit on Azure AD

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Reorder docs index

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

* Fix typo

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
Co-authored-by: gamab <gabi.mabs@gmail.com>
2022-09-15 17:35:59 +02:00
Sven Grossmann
f1e8a528d1 ElasticSearch: Fix lucene formatted variables being wrongly escaped (#54981)
* fixed negative numbers are encoded

* Chore: move variableModel to TypedVariableModel

* add tests
2022-09-15 17:18:57 +02:00
Seyaji
7ec1d137b4 Logs: Relocate "show context" button, add copy line log button (#50977)
* add context button to right side of log row

* add context button to right side of log row

* add context button to right side of log row

* add context button to right side of log row

* add show-context icon

Co-authored-by: Sven Grossmann <svennergr@gmail.com>
2022-09-15 17:13:58 +02:00
Brendan O'Handley
cd6b7ba688 InfluxDB: add scopedVars to tags to fix repeated panels querying all selected variables (#54934)
* add scoped vars for tags in influx to fix repeated panels

* test for adding scopedVars to tags
2022-09-15 09:29:19 -05:00
Adam Simpson
92857ef331 CloudMonitor: Remove cloudMonitoringExperimentalUI feature flag (#55054)
* CloudMonitor: remove cloudMonitoringExperimentalUI

* fix: address typecheck errors

* fix: fix SLO import and width cleanup

* fix wrong metricType when switching datasources

* fix: remove legacy SLO and fix queryType check
2022-09-15 14:12:26 +00:00
Joao Silva
13014dc0df Search: Fixes folder section not displaying dashboards (#55231) 2022-09-15 14:00:05 +01:00
Eric Leijonmarck
1d298b3e53 fix: min metric to hourly metric (#55228)
* fix: min metric to hourly metric

* Update pkg/services/login/model.go

Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>

Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
2022-09-15 14:17:34 +02:00
Marcus Efraimsson
cc583c5d87 Chore: Change default log level for errutil.CoreStatus (#55199) 2022-09-15 14:08:59 +02:00
Torkel Ödegaard
b8e72d6173 TopNav: KioskMode rewrite move to AppChrome responsibility and make it a global feature (#55149)
* Initial progress

* Moving keybindingSrv to context

* Simplfy KioskMode

* Removed unused logic

* Make kiosk=tv behave as before but when topnav is enabled

* Minor fix

* Fixing tests

* Fixing bug with notice when entering kiosk mode

* Fixed test
2022-09-15 14:04:58 +02:00
Piotr Jamróz
7352c181c2 Migrate user_id to BIGINT (#55084) 2022-09-15 13:29:46 +02:00
Karl Persson
b827df626d RBAC: Initiate store in service (#55081)
* RBAC: Dont inject store with wire

* RBAC: Use Store interface

* RBAC: Move store interface and initiate it from service
2022-09-15 11:34:15 +02:00
Sven Grossmann
aabd626403 Devenv: Fix filebeat level labels (#55217) 2022-09-15 10:33:39 +02:00
Dimitris Sotirakis
4e73766067 CI: Move store-storybook to OSS (#55212)
* Move store-storybook to OSS

* grabpl -> build for store-storybook command

* Replace zerolog with builtin log

* Remove flags from store-storybook

* Fix lint
2022-09-15 11:06:43 +03:00
Ryan McKinley
7700b529f9 SupportSnapshots: improved iframe support (#55059)
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-09-14 12:54:09 -07:00
owensmallwood
e37420f0a8 PublicDashboards: Log api layer errors and which datasources fail/succeed (#55056)
Adds pubdash api error logging and logs array of datasource names with success status when running pubdash queries.
2022-09-14 13:19:21 -06:00
Torkel Ödegaard
d639b5a7f8 Datasources: New data source page should work with new nav (#55094) 2022-09-14 21:12:09 +02:00
Torkel Ödegaard
7a10a0cb16 Gauge: Fixes empty/broken Gauge panels with datalinks (#55129) 2022-09-14 21:11:36 +02:00
matt abrams
6f0c4c7f82 Geomap: Add Africa, Australia, Oceania, South Asia, and East Asia as initial view options (#55142)
* add remaining continents + Asian regions

* capitalize South-East Asia

* Limit max zoom to 4 for view regions

Co-authored-by: drew08t <drew08@gmail.com>
2022-09-14 11:38:35 -07:00
Guilherme Caulada
82708df287 PublicDashboards: Add link to public dashboards docs to sharing modal (#55186) 2022-09-14 15:05:15 -03:00
Yuriy Tseretyan
8a62020211 Alerting: New API endpoint GET /api/v1/ngalert (#55134)
* declare new endpoint /api/v1/ngalert
* add authorization for new path
* add request handler for the new path
2022-09-14 14:03:10 -04:00
Joao Silva
ca2139e9ce Search: Avoid requesting all dashboards when in Folder View 2022-09-14 18:51:55 +01:00
juanicabanas
1e06b0170b PublicDashboards: UI improvements (#55130)
* Public dashboard modal UI modifications
2022-09-14 14:35:46 -03:00
Will Browne
29327cbba2 Plugins: Use error plane for api/ds/query (#54750)
* plugin client returns error base

* fix api test

* add plugin client test

* add fallback err

* fix linting

* wip

* replace bad query

* template is an error

* failing test of templated error

* add one test passing

* fix failing test

* move test

* rename ErrBadQuery to ErrQueryValidationFailure

* tidy diff

* Change to one error per specific error kind

* last err + fix test

* fix imports

* more tests

* keep req vars together

Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
2022-09-14 18:19:57 +02:00
owensmallwood
deb86e3250 PublicDashboards: Dont support exemplars (#54933)
Don't support exemplars in public dashboards
2022-09-14 09:49:10 -06:00
Ivana Huckova
926a3396ab Query patterns: Feature tracking (#55164)
* Query patterns: Feature tracking before redesign

* Update
2022-09-14 16:52:39 +02:00
Emil Tullstedt
104388dcc1 Chore: Update swagger to v0.30.2 (#55159) 2022-09-14 14:47:19 +00:00
Dimitris Sotirakis
244ccead9d Make lint-drone depend on compile-build-cmd (#55174) 2022-09-14 10:45:00 -04:00
Adam Simpson
65bdee3a90 AzureMonitor: Explain custom and metric namespace properties (#55048) 2022-09-14 14:28:25 +00:00
Dimitris Sotirakis
5c40b053d0 Update grabpl (#55061) 2022-09-14 10:20:58 -04:00
sam boyer
ced53a8dc2 plugins: Introduce generated, static core plugin registry (#54118)
* Refactor towards template/codegen framework

* Add templates for plugin gen

* Add Go codegen for plugins; overhaul framework, too

* Add new codegen output; assorted framework fixes

* Regenerate after merge

* Remove accidental commit file, update templates

* Export the pfs.Tree loader from plugin types

* Print details from cuetsy errors

* Generate loaders for all plugins and list in registry

* Use pfs_gen.go over lineage_gen.go

* Un-un-ignore main file

* Introduce simple List static registry for plugins

* Last tweaks to codegen

* remove unused tvars

* Ensure loop-local instances for both vars

* Generate pfs parsing in-place in registry

* Stop generating pfs_gen.go

* Move Tree into pfs, rename subdir

* Change package name to match dir

* Ignore gocyclo on HTTPServer.getNavTree
2022-09-14 10:15:09 -04:00
Kevin Minehart
c69a37f8c2 CI: grabpl verify-drone -> ./bin/build verify-drone (#55171)
* move grabpl verify-drone
2022-09-14 09:07:09 -05:00
Dimitris Sotirakis
5a1ba20856 CI: Split oss and enterprise steps for release pipelines (#55157)
* s/include_enterprise2/include_enterprise

* Get rid of get_steps def - include steps in separate defs
2022-09-14 09:47:02 -04:00
Will Browne
0571d98bba [WIP] Plugins: Introduce Plugins specific config (#54854) 2022-09-14 14:35:35 +01:00
Dimitris Sotirakis
8b38f9408d Run codespell only on docs changes (#55064) 2022-09-14 16:32:08 +03:00
Yuriy Tseretyan
896eeb65a9 Alerting: Fix alerting evaluation to use proper permissions (#55127)
* access control to log user name if it does not have permissions
* update ngalert Evaluator to accept user instead of creating a pseudo one
* update alerting eval (rule\query testing) API to provide the real user to the Evaluator
* update scheduler to create a pseudo user with proper permissions
2022-09-14 09:30:58 -04:00
Karl Persson
d896db6d30 RBAC: Batch permission creation (#55075) 2022-09-14 15:14:09 +02:00
Gábor Farkas
6dcc8534f7 elastic: simplify unit test (#55168) 2022-09-14 08:59:35 -04:00
GitStart
57bc472755 Loki: Rename public/app/plugins/datasource/loki/live_streams.ts file to follow convention (#55148)
Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: gitstart <gitstart@gitstart.com>
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: MuriloAmarals <muralha2000@gmail.com>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: Júlio Piubello da Silva Cabral <julio.piubello@gitstart.dev>
2022-09-14 14:55:15 +02:00
GitStart
017b7c7a7f Convert packages/jaeger-ui-components/src/TracePageHeader/SpanGraph/Scrubber.test.js to RTL (#54822)
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Toledodev <rafael.toledo@engenharia.ufjf.br>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: Júlio Piubello da Silva Cabral <julio.piubello@gitstart.dev>

Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Toledodev <rafael.toledo@engenharia.ufjf.br>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: Júlio Piubello da Silva Cabral <julio.piubello@gitstart.dev>
2022-09-14 14:40:39 +02:00
Ivan Ortega Alba
bed531f5fb Panel: Disable legends when showLegend is false prior to schema v37 (#55126) 2022-09-14 14:33:03 +02:00
Ivana Huckova
4503e0f417 Loki: Hide sample loki queries from inspector (#55158) 2022-09-14 14:25:25 +02:00
Sonia Aguilar
7a6f452f13 Alerting/fix folder creation dropdown (#54687)
*Refactor FolderPicker to be functional component.

* Add customAdd optional property to FolderPicker so we can add new values in the alert view but keeping the same behaviour in the rest of the ui.

* Add test for being able to add folder when no folders found.
2022-09-14 14:04:36 +02:00
brendamuir
ab774b47fb Docs: create new explore page for concepts (#55161)
* Docs: create new explore page for concepts

* Updates weighting of explore section to appear at top

* Weight for fundamentals page
2022-09-14 12:16:59 +01:00
Karl Persson
d1b9849946 RBAC: Fix background users to include permissions (#55147)
* RBAC: add function to construct background users

* PluginDashboards: Set rbac permissions for user

* Dashboards: use background user constructor
2022-09-14 11:26:05 +02:00
Karl Persson
870929b463 RBAC: Add cache for oss rbac permissions (#55098)
* RBAC: Add cache for oss permissions

* RBAC: include service account actions

* RBAC: revert changes to fetch service account permissions

* Update comment for setting

* RBAC: Disable permission chache for tests
2022-09-14 09:13:10 +02:00
Dimitris Sotirakis
716bdde3f6 CI: Make shellcheck a standalone pipeline (#55082)
* Make shellcheck standalone pipeline

* Run shellcheck on every .sh change

* Change base image

* Trigger on script changes

* Run shellcheck on PRs only
2022-09-14 09:00:06 +03:00
Kevin Minehart
ed5d617cb9 CI: move grabpl verify-drone (#55057)
* move grabpl verify-drone
2022-09-14 08:59:18 +03:00
Adrian Serrano
1366b87b34 Fix download link in macOS install instructions (#55133)
The link was pointing to non-existing `7.3.0-381ff45epre` version.

Updated to point to main download page, as with other platforms.
2022-09-13 15:06:01 -07:00
Ryan McKinley
927d97f1ab SupportSnapshots: Show type icons in table (#55119) 2022-09-13 13:42:19 -07:00
Adela Almasan
446b17f308 Canvas: Reload scene in panel view mode (#55122) 2022-09-13 16:22:29 -04:00
Alexander Weaver
9f45e2e706 Alerting: Fix legacy migration crash when rule name is too long (#55053)
* Extract standardized UID field length to constant

* Extract default length to constant

* Truncate rule names that are too long

* Add tests for name normalization

* Fix whitespace lint error

* Another linter fix

* Empty commit to kick build
2022-09-13 13:53:09 -05:00
Guilherme Caulada
b06eaf66b6 Public Dashboards: Replace simplejson with TimeSettings on dashboard struct (#55047)
* Replace simplejson for TimeSettings on PublicDashboard struct

* Implement xorm conversion interface to TimeSettings

* Fix minor test assertion issue
2022-09-13 13:33:41 -03:00
Ezequiel Victorero
6e99d8bba5 PublicDashboards: Add wait when fetching public dashboard data in e2e… (#55096) 2022-09-13 13:24:50 -03:00
Armand Grillet
b7825ea418 Make brendamuir owner of the Alerting docs (#55117) 2022-09-13 17:49:21 +02:00
Ashley Harrison
bd19a06fa9 Update create/edit playlist pages to work with topnav (#55104) 2022-09-13 16:18:50 +01:00
Oscar Kilhed
e2f5058a7d Chore: update latest.json to 9.1.5 (#55095) 2022-09-13 09:40:38 -04:00
Grot (@grafanabot)
4ff5fe718b ReleaseNotes: Updated changelog and release notes for 9.1.5 (#55091) 2022-09-13 15:14:46 +02:00
Dimitris Sotirakis
9b42cf009a CI: Update build-container image to v1.6.2 (#55083)
* Update build container to v1.6.2

* Update Dockerfile
2022-09-13 15:43:02 +03:00
Ashley Harrison
14d4e0eeca set font-weight correctly (#55074) 2022-09-13 13:34:02 +02:00
Marcus Andersson
c95b530502 DataSource: Adding possibility to hide queries from the inspector (#54892)
* adding the possibility to hide queries when they are executed via the DataSourceWithBackend.query
2022-09-13 13:27:16 +02:00
Laura Fernández
6bc0d97c49 Bar Gauge: fix flip direction when adding data links 2022-09-13 13:13:51 +02:00
Ivana Huckova
e70395f07a Query editor: Allow query editors to create new query (#55028)
* Query editor: Allow query editors to create new query

* Update

* Revert "Update"

This reverts commit d5b79d60dd.
2022-09-13 13:09:31 +02:00
Andreas Gerstmayr
2c622b912a Prometheus: Fix integer overflow in rate interval calculation (#52051)
Affecting only 32-bit architectures.
2022-09-13 12:51:26 +02:00
Dimitris Sotirakis
ac0f5c5556 CI: Add export-version command (#55072)
* Add export-version command

* Fix lint

* 1-line cleanup
2022-09-13 13:26:24 +03:00
Torkel Ödegaard
da001b01f1 TopNav: Section navigation UX (#55012)
* Design tweaks

* Updated

* Fixing unit tests

* Review fixes

* Text primary on active sections, and change home icon to text

* spacing fix

* More fix

* Fixes

* Updates
2022-09-13 12:24:23 +02:00
Ashley Harrison
031c186617 convert AlertRuleList test to RTL (#55045) 2022-09-13 09:29:29 +01:00
Torkel Ödegaard
ab045184e4 PanelMenu: Remove hide legend action as it was showing on all panel types (#54876)
* PanelMenu: Remove hide legend action

* Fix test

* Updated
2022-09-13 10:19:59 +02:00
GitStart
dc1f7cc226 Loki: Rename public/app/plugins/datasource/loki/live_streams_result_transformer.ts file to follow convention (#54919)
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Toledodev <rafael.toledo@engenharia.ufjf.br>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: Júlio Piubello da Silva Cabral <julio.piubello@gitstart.dev>

Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Murilo Amaral <87545137+MuriloAmarals@users.noreply.github.com>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Matheus Benini Ferreira <88898100+MatheusBeniniF@users.noreply.github.com>
Co-authored-by: Toledodev <rafael.toledo@engenharia.ufjf.br>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
Co-authored-by: Júlio Piubello da Silva Cabral <julio.piubello@gitstart.dev>
2022-09-13 10:16:04 +02:00
Matias Chomicki
c5223f7bf1 Loki: Update Query Variable docs (#54909)
* feat(loki-query-variable-editor): update docs

* Chore: fix typo in updated docs

* Chore: improve redaction

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>
2022-09-13 08:04:33 +00:00
Artur Wierzbicki
e19f36649f Storage: Content root storage (#54929)
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-09-12 18:34:46 -04:00
Adela Almasan
89d94eeab2 Canvas: Refine element duplication (#55050) 2022-09-12 14:33:08 -05:00
Kevin Minehart
d3af3e0431 CI: Move grabpl publish-metrics (#55042)
* move grabpl publish-metrics

* grabpl -> ./bin/build

* fix lint error
2022-09-12 13:28:08 -05:00
Torkel Ödegaard
d59bb1e4c2 IconName: Move to grafana/data and use type on NavModelItem (#55013)
* IconName: Allow strings

* Moving to grafana/data and adding type to NavModelItem

* Removed any type

* ts fix
2022-09-12 20:09:33 +02:00
Victor Marin
64869e3d90 Fix StateTimeline zoom function (#55033) 2022-09-12 18:45:31 +02:00
Matias Chomicki
445e1b3eae Loki: add missing interpolation to metric find query requests (#54979)
* feat(loki-variable-query-support): refactor datasource to support legacy and new variable query format

* Chore: fix comment

* Chore: use internal method to interpolate strings

* Chore: revert removed changes

* Chore: update test
2022-09-12 17:48:04 +02:00
Alexa V
18310785a1 Chore: Fix ShellCheck issue in the local a11y report (#55036) 2022-09-12 16:54:06 +02:00
Ashley Harrison
b90260b3ae Chore: convert LogRowContextProvider tests to RTL (#55031)
* convert LogRowContextProvider tests to RTL

* remove act
2022-09-12 15:00:09 +01:00
Torkel Ödegaard
49bc70c812 TopNav: Panel edit changes (#54746)
* Progress

* Progress

* Things are working

* More tweaks

* Fixing unit test

* Tweaks and fixing e2e tests

* Remove ... in Save as

* Fixing unit test

* Fixing e2e test

* Fixes

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-09-12 15:45:14 +02:00
Ashley Harrison
4c3e08db91 Chore: Convert ShareLink tests to RTL (#55026)
* Convert ShareLink tests to RTL

* use findByRole instead of findByLabelText to be more robust
2022-09-12 14:34:06 +01:00
kay delaney
f578adfede PluginLoader: Alias slate-react as @grafana/slate-react (#55027) 2022-09-12 09:22:01 -04:00
Alexa V
493a2c8e15 A11y: Add Dashboard Settings to Pa11y CI and Refactor local a11y report (#54476) 2022-09-12 15:14:45 +02:00
Torkel Ödegaard
7198fbaf47 AppChrome: Fix unmount on full page reload (#54897)
* AppChrome: Fix unmount on full page reload

* fix flickering on login page

* Changed logic a bit
2022-09-12 15:11:57 +02:00
Joey Tawadrous
be5369d6fa Traces: More visible span colors (#54513)
* Use colors array from position 0 for span colors

* Update/add tests

* Use service name hex to get color

* getTheme

* Only add colors that have a contrast ratio >= 3 for the current theme

* Add new tests
2022-09-12 13:20:10 +01:00
Erik Sundell
ab72d47850 Cloudwatch: Fix annotation query serialization issue (#54884)
* pass period as string and let backend handle conversion

* adding unit test

* adding unit test
2022-09-12 13:29:55 +02:00
Gustavo Santos
698a4fab26 GrafanaUI: Add required behavior to Inline Field (#54867) 2022-09-12 12:29:23 +01:00
Orlando Ortega Jr
28619d7a55 Chore: Added controls to IconButton & renamed Simple story to Examples (#54371) 2022-09-12 12:03:25 +01:00
Ashley Harrison
58e17f8144 CustomScrollbar: Add optional scroll indicators to CustomScrollbar (#54705)
* Add general scroll indicator behaviour to CustomScrollbar

* Extract ScrollIndicators logic into it's own file

* add scroll indicators to MegaMenu
2022-09-12 11:18:45 +01:00
Adam Simpson
879ee82b83 AzureMonitor: Fix custom namespaces (#54937) 2022-09-12 12:10:51 +02:00
Domas
b5c67fe0dd Frontend logging: handle logging endpoints without expensive middleware (#54960) 2022-09-12 13:04:43 +03:00
Emil Tullstedt
b287047052 Chore: Upgrade Go to 1.19.1 (#54902)
* WIP

* Set public_suffix to a pre Ruby 2.6 version

* we don't need to install python

* Stretch->Buster

* Bump versions in lib.star

* Manually update linter

Sort of messy, but the .mod-file need to contain all dependencies that
use 1.16+ features, otherwise they're assumed to be compiled with
-lang=go1.16 and cannot access generics et al.

Bingo doesn't seem to understand that, but it's possible to manually
update things to get Bingo happy.

* undo reformatting

* Various lint improvements

* More from the linter

* goimports -w ./pkg/

* Disable gocritic

* Add/modify linter exceptions

* lint + flatten nested list

Go 1.19 doesn't support nested lists, and there wasn't an obvious workaround.
https://go.dev/doc/comment#lists
2022-09-12 12:03:49 +02:00
Gábor Farkas
5388dc6a2f devenv: elastic: new version (#54841) 2022-09-12 11:48:39 +02:00
Alex Khomenko
8aa80078cd LoginLayout: allow providing custom branding (#54787)
* Branding: Customise values

* Branding: Customise loginLogo

* Branding: Add settings type

* Branding: Allow empty subtitle

* Branding: Allow custom footer links

* Branding: Allow empty subtitle
2022-09-12 12:24:45 +03:00
Ashley Harrison
cc5f8b9180 bump eslint sdk (#54968) 2022-09-12 10:00:09 +01:00
Carl Bergquist
72ae4a5aa3 toggles: add feature toggle to increase in mem caching (#55014)
Signed-off-by: bergquist <carl.bergquist@gmail.com>
2022-09-12 03:50:54 -04:00
Gábor Farkas
7c4c2fb341 codeowners: assign logs-devenvs to logs-squad (#54842) 2022-09-12 09:41:08 +02:00
Sofia Papagiannaki
b157fcdd87 Chore: fix formating for swagger definitions (#54993) 2022-09-12 10:40:35 +03:00
Leon Sorokin
7979463bbf PanelOptions: fix timezones editor save key (#55009) 2022-09-10 09:25:27 -07:00
Ryan McKinley
4125dd57ee Panels: Add panel debug support helper (#54678) 2022-09-09 14:35:52 -07:00
Ryan McKinley
c49c238974 Snapshots: Use the grafana datasource to render snapshot (#54870) 2022-09-09 13:16:24 -07:00
Leon Sorokin
dbb33eaba9 DataFrameJSON: add string enums inflation of field values (#54938)
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-09-09 13:59:29 -06:00
Adela Almasan
b08f839c4d Geomap: Map control options e2e (#54809) 2022-09-09 15:56:35 -04:00
Christopher Moyer
b6237a43e6 adds section shortcode, adjust topic titles (#55000) 2022-09-09 14:44:19 -05:00
Andre Pereira
c776131929 [Tempo] - Random API response and other improvements (#54905)
* Moved the SearchResponse type to types.ts.
Created a mockSearchResponse function to generate search responses.

* Generate spans in mocked response. Extend results table to accomodate spans

* Show the first spanset attributes in the table

* Added a shortcut to run the query in TraceQL editor. Added a label and link to docs above the editor

* Improved autocomplete list sorting. Improved value regex.

* Rename column to "Span"

* Tests are great!
2022-09-09 19:00:35 +01:00
Jean-Philippe Quéméner
bc4d929c67 Alerting: remove interpolation of annotations from alert rule file provisioning (#54975) 2022-09-09 18:47:54 +02:00
Misi
c5be9605a2 Chore: Use TimeNow instead of time.Now in user sql store to make it testable (#54983) 2022-09-09 18:43:14 +02:00
Leo
d5e28426ee hide overflow content for single left pane (#54882) 2022-09-09 18:01:30 +02:00
Joe Blubaugh
22c937340e Revert "Alerting: Write and Delete multiple alert instances. (#54072)" (#54885)
This reverts commit 5e4fd94413.
2022-09-09 17:44:06 +02:00
Leo
380fd45b04 Chore: update latest.json to 9.1.4 (#54992) 2022-09-09 15:22:48 +00:00
kay delaney
4c7732ad17 Chore: Upgrade Typescript to 4.8.2 (#54901)
* Chore: Upgrade typescript to 4.8.2
2022-09-09 16:17:58 +01:00
Ashley Harrison
4866898529 make sure AppRoot is lazily loaded (#54954) 2022-09-09 16:09:34 +01:00
Grot (@grafanabot)
1a285d2d0e ReleaseNotes: Updated changelog and release notes for 9.1.4 (#54987) 2022-09-09 16:41:49 +02:00
renovate[bot]
62ef9fb04c Update dependency prismjs to v1.29.0 (#54976)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-09 15:18:20 +01:00
Giordano Ricci
f0ec5961a4 fix: restore data source edit page access (#54973) 2022-09-09 09:50:56 -04:00
Tima Gixe
0598ff3743 Storybook: Add controls to CollapsableSection story (#54943) 2022-09-09 14:40:27 +01:00
Christopher Moyer
7147d17567 Docs/refactors variables topics (#54470)
* refactor and partial relref fix

* finishes variables refactor

* Update docs/sources/variables/add-template-variables/index.md

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

* removes duplicate general options, adds links to general options within tasks

* adds configure variable selection options topic

* starts phase II of refactoring

* incorporates feedback, updates relrefs

* corrects final relrefs

* updates alias

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-09-09 08:38:17 -05:00
renovate[bot]
b382c7ac1d Update dependency marked to v4.1.0 (#54972)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-09 09:09:32 -04:00
Matias Chomicki
4bed59efb3 Loki Query Variables: Add support to select from existing labels (#54625)
* feat(loki-variable-editor): replace input with select with datasource labels

* feat(loki-variable-editor): update test

* feat(loki-variable-editor): allow the editor to receive an existing query instance and edit it

* feat(loki-variable-editor): allow custom values in the label select

* feat(loki-variable-editor): mark stream field as optional

* feat(loki-variable-editor): add placeholder to stream selector and extend tooltip info
2022-09-09 08:59:07 -04:00
Tima Gixe
7104d90b39 Storybook: Add controls to FieldSet story (#54964) 2022-09-09 15:23:50 +03:00
Erik Sundell
a37fa758a2 CloudWatch: Fix display name of metric and namespace (#54860)
* convert value to option

* add unit test

* fix lint issue
2022-09-09 14:15:32 +02:00
renovate[bot]
34e06dbe18 Update dependency lru-cache to v7.14.0 (#54967)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-09 12:14:28 +00:00
renovate[bot]
1054ec2795 Update dependency eslint to v8.23.0 (#54951)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-09 12:57:07 +01:00
Hamas Shafiq
5169e79577 Chore: Add a README for Traces in the Plugins section (#54903) 2022-09-09 12:56:05 +01:00
Virginia Cepeda
d3a70de962 Alerting: Use original query time range when duplicating a query (#54805)
* Use original query time range when duplicating it

If there's no time range, then assign a default one

* Add tests

* Import default relative time range from common lib
2022-09-09 08:34:38 -03:00
Seyaji
096fc76e23 Chore: Convert TimelineHeaderRow to RTL (#51390)
* update data-testids

* update data-testids

* Convert TimelineHeaderRow test to RTL

* update data-testids

* Convert TimelineHeaderRow test to RTL

* Convert TimelineHeaderRow test to RTL

* modify TraceView test

* revert test

* Update packages/jaeger-ui-components/src/TraceTimelineViewer/TimelineRow.tsx

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>

* Ran yarn betterer

* update selector

Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
Co-authored-by: Hamas Shafiq <hamas.shafiq@grafana.com>
2022-09-09 06:44:05 -04:00
Tima Gixe
6b2ff6f25b Storybook: Add controls to LoadingPlaceholder story (#54939) 2022-09-09 13:35:41 +03:00
Tima Gixe
76f0037654 Storybook: Add controls to PanelChrome story (#54741) 2022-09-09 11:08:46 +01:00
Sven Grossmann
20b07fae6f fix bug in loki's adhoc filters (#54920) 2022-09-09 12:04:51 +02:00
Ashley Harrison
a861c10f1b Navigation: Integrate search into topnav (#54925)
* behaviour mostly there

* slight performance improvement

* slightly nicer...

* refactor search and add it to the store

* add comments about removing old component

* remove unneeded logic

* small design tweak

* More small tweaks

* Restore top margin

* add onCloseSearch/onSelectSearchItem to useSearchQuery

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-09-09 11:01:31 +01:00
renovate[bot]
ad19f018a9 Update dependency esbuild to v0.15.7 (#54928)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-09 10:56:49 +01:00
renovate[bot]
75c46885ca Update dependency @visx/shape to v2.12.2 (#54851)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-09 10:20:44 +01:00
Nicholas Wiersma
faf8eb3afb JWT: Allow conventional bearer token in Authorization header (#54821)
* fix: allow JWT to accept standard bearer token

* fix: linter issues

* fix: linter gosec false positive

* fix: refactor logic into JWT handler

* fix: move bearer trimming earlier
2022-09-09 11:05:58 +02:00
Andres Martinez Gotor
366129c14e AzureMonitor: Fix metric namespace list (#54826) 2022-09-09 10:17:10 +02:00
Jean-Philippe Quéméner
d88f1c8e35 Alerting: validate am config changes before persisting (#54908) 2022-09-09 10:05:52 +02:00
Gabriel MABILLE
101349fe49 RBAC: Add permissions to install and configure plugins (#51829)
* RBAC: Allow app plugins restriction

Co-authored-by: Kalle Persson <kalle.persson@grafana.com>

* Moving declaration to HttpServer

Co-Authored-By: marefr <marcus.efraimsson@gmail.com>

* Picking changes from the other branch

Co-authored-by: Alexander Zobnin <alexanderzobnin@gmail.com>

* Rename plugins.settings to plugins

Co-authored-by: Kalle Persson <kalle.persson@grafana.com>

* Account for PluginAdminExternalManageEnabled

Co-authored-by: Will Browne <will.browne@grafana.com>

* Set metadata on instantiation

Co-authored-by: Jguer <joao.guerreiro@grafana.com>

Co-authored-by: Kalle Persson <kalle.persson@grafana.com>
Co-authored-by: marefr <marcus.efraimsson@gmail.com>
Co-authored-by: Alexander Zobnin <alexanderzobnin@gmail.com>
Co-authored-by: Will Browne <will.browne@grafana.com>
Co-authored-by: Jguer <joao.guerreiro@grafana.com>
2022-09-09 09:44:50 +02:00
Dimitris Sotirakis
8c081d4523 Remove gen-version from windows pipelines (#54941) 2022-09-09 03:22:38 -04:00
Karl Persson
bcd7afd1f5 RBAC: Remove service dependency in Evaluator component (#54910)
* RBAC: Remove service dependency for Evaluator component

* RBAC: Add service and load permissions in target org if they are not
there

* RBAC: Use service if we need to load permissions for org

* API: remove service injection into evaluator

* API: set new user for each request in tests

* PublicDashboards: Use fake service to provide permissions

* RBAC: Set org id for dashboard provisioning user
2022-09-09 09:07:45 +02:00
Dimitris Sotirakis
e277ab0017 CI: Call for Grafana version on demand - remove need for version.json (#54638)
* Remove need for version.json

* Fix lint

* log.Info -> fmt.Print

* Add back tests

* Remove non-used file

* Fix lint

* Update grabpl version to v3.0.6
2022-09-09 02:35:10 -04:00
Guilherme Caulada
942be4215a Secrets: Improve error handling for secrets manager plugin (#54811)
* Improve error handling for secrets manager plugin

* Update sever lock log for secret migration to Error

* Move plugin started check to a separate function

* Fix nil pointer exception on HasPluginStarted
2022-09-08 17:26:47 -03:00
Torkel Ödegaard
f5fd9029ea DebugSnapshot: Change to use exisiting localstorage prop and open in new tab (#54877)
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-09-08 11:20:56 -07:00
Leon Sorokin
085db83cd9 DisplayProcessor: Handle reverse-ordered data when auto-showing millis (#54923) 2022-09-08 12:49:03 -05:00
Leon Sorokin
eb90d0c4b5 TimeSeries: Support for log scale and negative numbers (#54812) 2022-09-08 11:52:57 -05:00
renovate[bot]
6a7e1caced Update dependency core-js to v3.25.1 (#54915)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-08 17:46:16 +01:00
Polina Boneva
2f16c27e35 Docs: Mention queryparam function (#54526)
* Update data-link-variables.md

Add queryparam function and tables of output to match the other listed variables

* Update docs/sources/linking/data-link-variables.md

Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>

* Add r4j4h's suggestions to the new documentation space with some partial changes to the wording

* Add r4j4h's suggestions to the new documentation space with some partial changes to the wording

* mockery generated code as it is on main

* simplify changes in docs and go straight to the point

Co-authored-by: Jasmine Hegman <jasmine@jhegman.com>
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2022-09-08 17:14:37 +03:00
renovate[bot]
8f0473aa3e Update dependency @rushstack/node-core-library to v3.51.1 (#54835)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-08 15:14:18 +01:00
Christopher Moyer
e15c8cf535 Docs: moves reporting docs per customer request (#54591)
* moves reporting docs per customer request

* corrects relrefs

* adjusts link and menutitle

* corrects typo

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-09-08 08:55:57 -05:00
Christopher Moyer
f516b8c5d8 restructures user management docs (#54871) 2022-09-08 08:51:34 -05:00
Jean-Philippe Quéméner
e41f78a56d Alerting: make sure to update contact point references when updating (#54896) 2022-09-08 15:20:52 +02:00
Domas
9dd4eab553 ignore non-actionable errors in grafana agent (#54824) 2022-09-08 16:19:38 +03:00
Laura Fernández
c684babecc A11y: Make tooltip dismissible in Toolbar and Icon buttons (#54586) 2022-09-08 14:32:50 +02:00
GitStart
e9243f8a38 Loki: Rename public/app/plugins/datasource/loki/language_provider.ts file to follow convention (#54819) 2022-09-08 14:32:32 +02:00
Ezequiel Victorero
76edf1a727 PublicDashboards: Fix flaky e2e test (#54864) 2022-09-08 09:18:40 -03:00
Tima Gixe
8fb0d3421b Storybook: Add controls to UnitPicker (#54694) 2022-09-08 13:16:27 +01:00
Shirley
bdd0af0645 Build: Refactor cron_job_pipeline to take the cron name as a parameter (#54899) 2022-09-08 13:36:36 +02:00
Konrad Lalik
933ec4817f Alerting: Change the rule yaml data to reflect Prom-based rule format (#54520) 2022-09-08 12:52:36 +02:00
Jo
ef245874da OAuth: Allow assigning Server Admin (#54780)
* extract errors to errors file

* implement oauth server admin assignment

* add server admin tests

* deduplicate autoAssignOrgRole

* deduplicate strict setting

* deduplicate strict setting

* add support for generic oauth

* add role attribute strict support for generic oauth

* add support for github/gitlab

* assignGrafanaAdmin option is here to stay

* unify similar errors

* add config option

* add okta server admin mapping

* remove never used Company attribute

* unify generic oauth role extract with other methods

* case insensitive role match as in azure

* add ini settings

* add server admin to devenv

* remove duplicate fields

* add documentation to oauth

* fix titlecase test

* implement doc feedback
2022-09-08 06:11:00 -04:00
Artur Wierzbicki
1353177e15 Search: Add substring matcher (#54813)
* search: bring back substring search

* lint fix

* search: bring back ngram

* search: bring back ngram

* search: more tests
2022-09-08 12:10:30 +02:00
Carl Bergquist
b4e3c89f60 instrumentation: dont instrument ErrSkip at all (#54880)
Signed-off-by: bergquist <carl.bergquist@gmail.com>
2022-09-08 11:14:55 +02:00
Sven Grossmann
78a3f1fcea Chore: Upgrade @grafana/lezer-logql to 0.1.0 (#54878) 2022-09-08 10:29:58 +02:00
Joe Blubaugh
a101d127cb CI: Update Drone MySQL version to 5.7.39 to match database policy. (#54612)
The supported database policy is listed at: https://grafana.com/docs/grafana/latest/setup-grafana/installation/#supported-databases
2022-09-08 15:03:02 +08:00
Ezequiel Victorero
bcab0194f1 PublicDashboards: disable form if user does not has permissions (#54853) 2022-09-07 18:29:01 -03:00
matt abrams
9c88360ec5 change no-new-info label action (#54501) 2022-09-07 14:37:42 -05:00
Adela Almasan
5a3ae293cf Geomap: Layer types e2e (#54666) 2022-09-07 13:29:03 -05:00
Christopher Moyer
5b830e131e adjusts access control directory structure (#54865) 2022-09-07 13:27:32 -05:00
owensmallwood
108678a8cc Public Dashboards: Only use queries from dashboard for caching (#54596)
Don't accept frontend queries for query caching when its from a public dashboard. Use queries on the dashboard instead.
2022-09-07 12:08:52 -06:00
Leon Sorokin
4223d3a6a7 Heatmap: Add option to reverse color scheme (#54365) 2022-09-07 11:09:44 -05:00
Matthew Jacobson
940d18ad57 Alerting: Sanitize invalid label/annotation names for external alertmanagers (#54537)
* Alerting: Sanitize invalid label/annotation names for external alertmanagers

Grafana's built-in Alertmanager supports both Unicode label keys and values; however, if using an external
Prometheus Alertmanager label keys must be compatible with their data model.
This means label keys must only contain ASCII letters, numbers, as well as underscores and match the regex
`[a-zA-Z_][a-zA-Z0-9_]*`.

Any invalid characters will now be removed or replaced by the Grafana alerting engine before being sent to
the external Alertmanager according to the following rules:

- `Whitespace` will be removed.
- `ASCII characters` will be replaced with `_`.
- `All other characters` will be replaced with their lower-case hex representation.

* Prefix hex replacements with `0x`

* Refactor for clarity

* Apply suggestions from code review

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>

Co-authored-by: brendamuir <100768211+brendamuir@users.noreply.github.com>
2022-09-07 11:39:39 -04:00
Leon Sorokin
75de42fba7 BarChart: fix stale colorByField being used in value mappings (#54820) 2022-09-07 08:31:31 -06:00
Alexander Weaver
b193eaed6e Alerting: Resetting the notification policy tree to the default policy will also restore default contact points (#54608)
* Add test that resetting the route restores the default receiver

* Return error instead of panic

* Adjust error string to match styleguide
2022-09-07 09:28:10 -05:00
Ashley Harrison
8e8d0a08f9 reobserve elements when children change (#54827) 2022-09-07 15:07:35 +01:00
Hamas Shafiq
762432a921 Chore: Add a README for the Node Graph plugin (#54801) 2022-09-07 14:52:55 +01:00
renovate[bot]
04d15b5810 Update dependency @types/webpack-env to v1.18.0 (#54839)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-07 14:51:36 +01:00
Gustavo Santos
968e2218ac Chore: Add controls to InlineField (#54674) 2022-09-07 14:24:38 +01:00
majordookie
35751b2ab4 Fix typo (#54681) 2022-09-07 15:40:52 +03:00
mhuangwm
39102c6656 Admin: Add support to configure default admin email (#54363) 2022-09-07 14:38:40 +02:00
Gábor Farkas
687b0b1726 elastic: explain why moving_avg is 7.x only (#54840) 2022-09-07 14:31:11 +02:00
Gustavo Santos
c56907b879 Add controls for Date Picker story (#54806)
Signed-off-by: gefgu <gefgu@hotmail.com>

Signed-off-by: gefgu <gefgu@hotmail.com>
2022-09-07 15:30:46 +03:00
Dimitris Sotirakis
8e577ce9fa CI: Trigger *-storybook steps on UI changes (#54833)
* No-op, small starlark refactoring

* Make build and store storybook steps execute on ui changes
2022-09-07 15:08:13 +03:00
Nicholas Wiersma
9e704fec3c JWT: Add support for assigning org roles (#54277)
* feat: allow jwt role to be set

* chore: update documentation

* fix: cr suggestions

* fix: lint issues

* respect org auto assign and default org ID

* add server admin to devenv

Co-authored-by: jguer <joao.guerreiro@grafana.com>
2022-09-07 14:00:33 +02:00
Ashley Harrison
4825707853 Add basic unit tests for landing pages (#54696) 2022-09-07 12:40:53 +01:00
renovate[bot]
e22ed6b720 Update dependency @types/ol-ext to v2.3.0 (#54836)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-07 11:42:29 +01:00
renovate[bot]
84212d8746 Update babel monorepo to v7.19.0 (#54756)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-07 09:57:22 +01:00
renovate[bot]
bccf8e139e Update dependency @react-types/shared to v3.14.1 (#54830)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-07 09:55:08 +01:00
Matias Chomicki
c0b3cd3da0 refactor(loki-derived-fields): migrate test to testing library (#54729) 2022-09-07 08:54:28 +00:00
linoman
0324e9c60e Fix paths for auth/ build and volume paths (#54828) 2022-09-07 10:53:58 +02:00
renovate[bot]
86e432f25b Update dependency @react-types/menu to v3.7.1 (#54825)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-07 09:39:20 +01:00
Ashley Harrison
66ce33bc5b make Browse the root item of Dashboards when topnav is enabled (#54782) 2022-09-07 09:24:10 +01:00
renovate[bot]
ebf24da028 Update dependency @react-types/button to v3.6.1 (#54797)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-07 09:06:46 +01:00
Adela Almasan
3864de9425 Geomap: Cleanup GeomapPanel component (#54538) 2022-09-06 21:22:34 -04:00
Christopher Moyer
cdc2200273 restructures aws marketplace docs (#54810) 2022-09-06 16:47:47 -05:00
Leon Sorokin
bf052cb35e TimeSeries: omit non-integer y ticks when decimals: 0 (#54679) 2022-09-06 16:12:09 -04:00
Alexander Weaver
b8d1474609 Fix incorrect propagation of org ID in rule endpionts (#54603) 2022-09-06 14:51:54 -05:00
Guilherme Caulada
20589f76f4 Secrets: Convert secret migration to a background service (#54676)
* Convert secret migration to a background service

* Fix merge conflicts

* Return concrete type for secret migration provider
2022-09-06 16:21:25 -03:00
Christopher Moyer
0f549a44b0 changes _index files to index, adds aliases (#54804) 2022-09-06 12:58:07 -05:00
Kevin Minehart
1169f14d47 CI: move grabpl build-frontend-packages from grabpl to grafana (#53072)
* move grabpl build-frontend-packages

* add frontend and lerna packages

* grabpl build-frontend-packages -> ./bin/build build-frontend-packages

* move getgrafanaversion

* add noinstalldeps flag

* fix compiler error

* fix lint error

* add missing flags
2022-09-06 20:09:08 +03:00
Torkel Ödegaard
e5c32c8cc9 Dashboard: Unsaved changes warning fixes (#54706)
* Quick test of alternative method

* change order of if condition again for better readability

* Think I have something that is working

* Update
2022-09-06 13:00:32 -04:00
Joao Silva
ab79976a8d Navigation: Adds profile menu to top nav bar (#54720) 2022-09-06 17:32:05 +01:00
renovate[bot]
9cc828a00e Update dependency @react-stately/menu to v3.4.1 (#54784)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-06 17:23:16 +01:00
Ilya Galimyanov
b593d371ef Alerting: Telegram: truncate long messages (#54339)
Truncate messages longer than 4096 characters
2022-09-06 16:47:04 +01:00
Ashley Harrison
a4566eaf32 add unit tests for buildBreadcrumbs (#54785) 2022-09-06 16:43:59 +01:00
Laura Fernández
066710a7bc Navigation: use navId and pageNav on Alerting - Contact Points page (#54451) 2022-09-06 16:25:07 +02:00
kay delaney
a70aba1384 Chore: Update slate and related packages (#54566)
* Chore: Update slate and related packages
2022-09-06 15:23:48 +01:00
ismail simsek
9c6a6ca487 graphite and opentsdb integration tests (#54733) 2022-09-06 17:19:04 +03:00
Tima Gixe
ce1221cd59 Storybook: Add controls to InlineLabel story (#54604) 2022-09-06 15:18:38 +01:00
Tima Gixe
05c16d1da3 Storybook: Add controls to QueryField story (#54606) 2022-09-06 15:18:08 +01:00
linoman
c915cb2d5c Update auth/jwt_proxy and auth/oauth reference (#54781) 2022-09-06 15:46:01 +02:00
Matias Chomicki
baffc3d948 fix(elasticsearch): remove deprecated elastic versions (#54632)
* fix(elasticsearch): remove deprecated elastic versions

* fix(elasticsearch): make 8 the default and fallback version
2022-09-06 09:42:39 -04:00
renovate[bot]
7a01186324 Update dependency @react-aria/overlays to v3.10.1 (#54763)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-06 14:37:32 +01:00
Sofia Papagiannaki
e57fd88644 Swagger: restore missing enterprise endpoints (#54765) 2022-09-06 16:26:55 +03:00
Will Browne
15756ecf86 remove unused cfg (#54770) 2022-09-06 08:59:28 -04:00
Matias Chomicki
5767c01a79 Elasticsearch: fix types in test and add mock factory (#54582)
* refactor(elastic-test): add datasource mock factory

* refactor(elastic-test): use new factory and attempt to fix some type issues

* refactor(elastic-test): type fixes

* refactor(elastic-test): update test with mock changes

* refactor(elastic-test): remove commented code

Git history should be more than enough to go back to previous revisions instead of keeping commented code.

* refactor(elastic-test): use mock factory and fix type issues in language provider test

* Chore: rename mock parameter

* Chore: remove unnecessary conditional

* Chore: remove ts-expect-error
2022-09-06 14:35:54 +02:00
linoman
638fb5dc6d Fix docker compose for openldap and oauth (#54745)
* Fix reference for `openldap` block

* Fix volume reference for `oauth` block
2022-09-06 14:22:03 +02:00
Oscar Kilhed
661ac46e6c Chore: update latest.json to 9.1.3 (#54764) 2022-09-06 07:22:04 -04:00
renovate[bot]
3847e09750 Update dependency @react-aria/interactions to v3.11.0 (#54761)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-06 12:05:43 +01:00
Grot (@grafanabot)
fe848e93b3 ReleaseNotes: Updated changelog and release notes for 9.1.3 (#54759) 2022-09-06 12:54:58 +02:00
renovate[bot]
a36ef9cdfd Update dependency @react-aria/focus to v3.8.0 (#54718)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-06 11:50:44 +01:00
Laura Fernández
8ae6cf6b99 Navigation: add breadcrumbs in Explore page (#54547) 2022-09-06 12:11:00 +02:00
renovate[bot]
0e16456602 Update dependency @react-aria/dialog to v3.3.1 (#54717)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-06 11:07:26 +01:00
Hamas Shafiq
7779ae315b Chore: Use the DEFAULT_LIMIT variable for the default value of the TraceQL Limit field (#54723) 2022-09-06 10:02:37 +01:00
Josh Hunt
139705611a Chore: Remove remaining IconName type assertions (#54658)
* Chore: Remove remaining IconName type assertions

* fix lints
2022-09-06 09:15:36 +01:00
George Robinson
77e53f9986 Alerting: Fix boolean comparison on PostgreSQL (#54730) 2022-09-06 08:28:42 +01:00
Ryan McKinley
ac93cf1db2 Playlists: Migrate to UIDs and load dashboards in the frontend (#54125) 2022-09-05 20:40:01 -07:00
ismail simsek
3ea9ece16e Update graphite datasource testing query (#54635)
* Provide from and to parameters when testing the datasource

* Strongly typed test datasource query
2022-09-05 20:59:44 +02:00
George Robinson
c4d32dd687 Fix nil logger in SqlStore (#54726) 2022-09-05 18:24:19 +01:00
GitStart
d5d7e920a0 Loki: Remove any from public/app/plugins/datasource/loki/components/LokiOptionFields.test.tsx (#54239) 2022-09-05 18:25:12 +02:00
Karl Persson
ff35e35ce0 RBAC: Move service and evaluator to acimpl package (#54714)
* RBAC: Move access control evaluator to acimpl package

* RBAC: Move service to acimpl package
2022-09-05 18:15:47 +02:00
Gareth Dawson
73eb1f047a Loki/Prometheus: Make sections in log/metrics browser resizable (#54704)
* Make loki label browser resizable

* Make prometheus metric browser resizable

* Remove min-width from Label and Metrics browser

* Remove max-width from Prometheus Metrics Browser
2022-09-05 17:03:03 +01:00
GitStart
69f3e48962 Panel Header: Description tooltip expand to fit large elements (#54238)
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Rafael Toledo <87545086+Toledodev@users.noreply.github.com>
Co-authored-by: Júlio Piubello da Silva Cabral <julio.piubello@gitstart.dev>
Co-authored-by: Toledodev <rafael.toledo@engenharia.ufjf.br>
Co-authored-by: juliopiubello <juliopiubellow@gmail.com>
Co-authored-by: Rubens Rafael <70234898+RubensRafael@users.noreply.github.com>
2022-09-05 17:54:24 +02:00
Orlando Ortega Jr
042fbcc609 Chore: Added controls to ContextMenu story (#54373) 2022-09-05 16:43:02 +01:00
Kevin Yu
34fe7a1119 Plugins: Add feature toggles for long running queries (#54349)
* Add feature toggles for long running queries

* update feature flag name

* make feature toggle frontend only
2022-09-05 08:39:45 -07:00
Ezequiel Victorero
bfa35ff8d8 PublicDashboards: Add RBAC to secured endpoints (#54544) 2022-09-05 12:22:39 -03:00
Hamas Shafiq
295c36e4ec Tempo: Move interfaces & TempoQueryType from datasource.ts to types.ts (#54621) 2022-09-05 15:46:10 +01:00
Ivan Ortega Alba
fbfe2b2800 Library Panel: Allow to delete it when disabled or deprecated (#54662) 2022-09-05 16:45:45 +02:00
Hamas Shafiq
413c7c7d99 Tempo: Cache autocomplete values for tags (#54622) 2022-09-05 15:44:44 +01:00
Michael Musenbrock
78833b4a47 Alerting: Display alert's 'Created' time in local time instead of UTC (#54414)
Signed-off-by: Michael Musenbrock <michael.musenbrock@gmail.com>

Signed-off-by: Michael Musenbrock <michael.musenbrock@gmail.com>
2022-09-05 16:36:52 +02:00
Sven Grossmann
a4b86a194d changed lezer-logql version (#54712) 2022-09-05 16:25:26 +02:00
renovate[bot]
67cecef1b7 Update dependency @opentelemetry/api to v1.2.0 (#54669)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-05 15:04:33 +01:00
renovate[bot]
9b9e298896 Update dependency @react-aria/button to v3.6.1 (#54670)
* Update dependency @react-aria/button to v3.6.1

* bump @react-aria/menu at the same time

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-09-05 14:52:56 +01:00
ismail simsek
e912029ad3 influxdb integration tests (#54700) 2022-09-05 15:35:53 +02:00
kay delaney
65c3ad6721 LibraryElements: Fix inability to delete library panels under MySQL (#54600)
Closes #53456
2022-09-05 14:28:32 +01:00
Sofia Papagiannaki
950715b255 API: Do not expose user input in datasource error responses (#53483) 2022-09-05 16:10:45 +03:00
Torkel Ödegaard
11de1dfe40 TopNav: Plugin page layouts / information architecture (#53174)
* Change nav structure when topnav is enable to do initial tests with new information architecture

* Support for nested sections

* Updated

* sentance case

* Progress on plugin challange

* Rewrite to functional component

* Progress

* Updates

* Progress

* Progress on things

* missing file

* Fixing issue with runtime, need to use setter way to set component exposed via runtime

* Move PageLayoutType to grafana/data

* Fixing breadcrumb issue, adding more tests

* reverted backend change

* fix recursive issue with cleanup
2022-09-05 14:56:08 +02:00
Ashley Harrison
a423c7f22e Add scrolling to SectionNav (#54698) 2022-09-05 12:39:54 +01:00
Victor Marin
aee13563ce Fix StateTimeline duration bug + add hidden tooltip option (#54697) 2022-09-05 14:11:06 +03:00
Ashley Harrison
8d489dfd9b Navigation: Landing pages behind feature toggles (#54576)
* super quick attempt

* feature toggle everything

* only construct alertNav if there are navChildren

* fix toggle name

* plugin landing pages poc

* add apps route + put behind feature toggle

* use toIconName

* rename to NavLandingPage

* feature toggle new routes

* don't modify GetServerAdminNode

* some fairly hacky code to check if the plugin has a root page

* remove trailing slash
2022-09-05 10:07:13 +01:00
Victor Marin
6d2352735d XYPanel: Improvements (#54220)
* Fix panel option bugs and make tooltip options work

* Support multiple series in explicit mode. Rename XY/Explicit to Auto/Manual

* Fixes

* Fix

* Legend improvements

* Rewrite Pure Component to Function Component

* Add datalinks support

* Legend fixes and CR modifications

* Fix bugs that crash panel
2022-09-05 11:03:17 +03:00
Jo
4952b7f22d Add JWT url auth documentation (#54040)
* add jwt auth docs

* add appropriate warnings to docs

* remove unimplemented login_token assumptions

* Update conf/sample.ini
2022-09-05 03:46:50 -04:00
Carl Bergquist
78978048c3 Instrumentation: log the total number of db queries per request (#54647)
Signed-off-by: bergquist <carl.bergquist@gmail.com>
Co-authored-by: Emil Tullstedt <emil.tullstedt@grafana.com>
Co-authored-by: Dave Henderson <dave.henderson@grafana.com>
2022-09-05 07:39:22 +02:00
Ryan McKinley
7e53bd107c Panels: Add troubleshooting snapshot (#54417) 2022-09-02 15:38:35 -07:00
Adela Almasan
37a0207463 Canvas: Phantom mouse down fix (#54673) 2022-09-02 12:58:49 -07:00
Leon Sorokin
8273839539 Histogram: ensure y axis is unit-less (#54667) 2022-09-02 13:50:01 -05:00
Adela Almasan
aa897e4f40 Chore: Upgrade Moveable to v0.35.4 (#54559)
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-09-02 11:24:55 -07:00
Drew Slobodnjak
600ea254af Geomap: Fix duplicate layer bug (#54660)
* Geomap: Fix duplicate layer bug

* Remove dependency on name parameter
2022-09-02 10:53:21 -07:00
Adela Almasan
773a453108 Chore: Upgrade Selecto to v1.19.1 (#54598) 2022-09-02 10:41:36 -07:00
Ashley Harrison
0ab548a8b5 Chore: fixing some anys/type assertions (#54661)
* fixing some anys/type assertions

* make types consistent
2022-09-02 16:39:09 +00:00
linoman
d2bb72fb3c Login: Remove single admin team restriction (#54534)
* Remove single member team restriction

* Add label when permissions list is empty

* Fix unit tests

* Add co-author.

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
2022-09-02 18:16:39 +02:00
Esteban Beltran
4bba3223a0 Grafana/toolkit: Update README.md to include an alternative way to run local grafana/toolkit (#54203)
* Update README.md

* Run prettier
2022-09-02 17:49:39 +02:00
Guilherme Caulada
f4a35a4645 Secrets: Implement secrets manager plugin fallback store (#54496)
* Refactor fallback to be isolated to plugin secret store

* Check for error value on replace fallback test helper

* Move ResetPlugin from test_helpers.go to plugin.go

* Add check to GetUnwrappedStoreFromCache

* Add fallback GetAll query to WithFallbackEnabled

* Add mutex lock to WithFallbackEnabled

* Add cache to fallback store

* Fix linter issues

* Fix linter issues

* Fix linter issues
2022-09-02 12:39:18 -03:00
Josh Hunt
6b197f3fa9 Chore: Use react-highlight-words types (#54627) 2022-09-02 16:36:44 +01:00
Mihály Gyöngyösi
53c095aae7 RBAC: Disable RBACPermissionValidation by default (#54626)
* update conf/provisioning/access-control/sample.yaml
2022-09-02 17:18:01 +02:00
Kevin Minehart
a76ce1f567 CI: move grabpl e2e tests from grabpl to grafana (#53075)
* move grabpl e2e tests
2022-09-02 11:02:10 -04:00
Dimitris Sotirakis
8be3ea269d Default to pull_request events (#54640) 2022-09-02 17:39:05 +03:00
Leon Sorokin
28426219ce TimeSeries: fix padding, force 0-100% y range when % stacked (#54197) 2022-09-02 09:26:04 -05:00
Ashley Harrison
3e8d178fc1 convert LokiQueryEditor test to RTL (#54639) 2022-09-02 15:11:13 +01:00
Ashley Harrison
22e5ee3b52 update LokiExploreQueryEditor test to RTL (#54644) 2022-09-02 14:46:14 +01:00
Ieva
de6584b976 Auth: Extend auth token errors with user ID (#54633)
* add user ID to user token errors

* remove colon

* move user ID to debug log, so it wouldn't accidentally be added in response
2022-09-02 14:38:25 +01:00
ismail simsek
a230439679 Add monaco-editor section in grafana-toolkit faq (#54585)
* Add monaco-editor question in faq section

* Fix typo
2022-09-02 08:30:59 -04:00
Will Browne
ecdcafb258 manager exposes renderer + secrets manager (#54629) 2022-09-02 14:20:10 +02:00
Will Browne
43987e7f8c Plugins: Fix plugin registered startup log line (#54634)
* fix plugin registered log

* remove stale test
2022-09-02 14:01:52 +02:00
Ashley Harrison
11689c0385 convert ConfigEditor test to RTL (#54636) 2022-09-02 12:48:37 +01:00
Hamas Shafiq
21dd60ba60 Tempo: Map the status tag to status.code for autocomplete (#54593) 2022-09-02 11:55:55 +01:00
Josh Hunt
3cf8e9c72e Chore: Remove grafana-ui IconName type assertions (#54623) 2022-09-02 11:31:16 +01:00
Dimitris Sotirakis
4735de6aa4 Run gen-version in windows pipelines (#54624) 2022-09-02 06:27:20 -04:00
Hamas Shafiq
d79830fdd7 Chore: Replace deprecated toPromise() calls with lastValueFrom (#54234) 2022-09-02 11:17:36 +01:00
Kian Eliasi
6e4900dc45 Footer: Add release notes url to version label (#52909)
* Add release note url to footer's version label

* Filter out pre-release versions in release notes link at the footer

* correct links for beta/prerelease release notes

* make all links target blank

* Fix TeamPages test

Co-authored-by: joshhunt <josh@trtr.co>
2022-09-02 06:05:27 -04:00
Jack Westbrook
ffdda9296a Chore: Refresh out of date yarn lock file (#54620) 2022-09-02 11:08:27 +02:00
Jack Westbrook
4179f94959 Fix: Make sure grafana/e2e cypress config file is in correct location (#54588)
* fix(grafana-e2e): make sure cypress can find config file

* chore(yarn): refresh lock file
2022-09-02 10:37:50 +02:00
Joe Blubaugh
5e4fd94413 Alerting: Write and Delete multiple alert instances. (#54072)
Prior to this change, all alert instance writes and deletes happened
individually, in their own database transaction. This change batches up
writes or deletes for a given rule's evaluation loop into a single
transaction before applying it.

Before:
```
goos: darwin
goarch: arm64
pkg: github.com/grafana/grafana/pkg/services/ngalert/store
BenchmarkAlertInstanceOperations-8           398           2991381 ns/op         1133537 B/op      27703 allocs/op
--- BENCH: BenchmarkAlertInstanceOperations-8
    util.go:127: alert definition: {orgID: 1, UID: FovKXiRVzm} with title: "an alert definition FTvFXmRVkz" interval: 60 created
    util.go:127: alert definition: {orgID: 1, UID: foDFXmRVkm} with title: "an alert definition fovFXmRVkz" interval: 60 created
    util.go:127: alert definition: {orgID: 1, UID: VQvFuigVkm} with title: "an alert definition VwDKXmR4kz" interval: 60 created
PASS
ok      github.com/grafana/grafana/pkg/services/ngalert/store   1.619s
```

After:
```
goos: darwin
goarch: arm64
pkg: github.com/grafana/grafana/pkg/services/ngalert/store
BenchmarkAlertInstanceOperations-8          1440            816484 ns/op          352297 B/op       6529 allocs/op
--- BENCH: BenchmarkAlertInstanceOperations-8
    util.go:127: alert definition: {orgID: 1, UID: 302r_igVzm} with title: "an alert definition q0h9lmR4zz" interval: 60 created
    util.go:127: alert definition: {orgID: 1, UID: 71hrlmR4km} with title: "an alert definition nJ29_mR4zz" interval: 60 created
    util.go:127: alert definition: {orgID: 1, UID: Cahr_mR4zm} with title: "an alert definition ja2rlmg4zz" interval: 60 created
PASS
ok      github.com/grafana/grafana/pkg/services/ngalert/store   1.383s
```

So we cut time by about 75% and memory allocations by about 60% when
storing and deleting 100 instances.

This change also updates some of our tests so that they run successfully against postgreSQL - we were using random Int64s, but postgres integers, which our tables use, max out at 2^31-1
2022-09-02 11:17:20 +08:00
Matthew Jacobson
d706320d0a Alerting: Fix UI bug when setting custom notification policy group by (#54607)
Custom values were not being displayed in the multiselect for notification policy `Group by` even though
they were correctly being saved.
2022-09-01 19:06:42 -04:00
Hamas Shafiq
e17c2f1cb5 Tempo: Add an options component under the TraceQL query field (#54435) 2022-09-01 22:49:27 +01:00
Michael Mandrus
39c31416a4 improve log in plugin check (#54599) 2022-09-01 13:47:37 -04:00
Timur Olzhabayev
70802d270e Fix: publish_docs GitHub action needs to be updated after a script that was used there has been removed (#54597) 2022-09-01 16:37:17 +00:00
Timur Olzhabayev
b5b41988cf Docs: Deprecating packages_api and removing it from our pipelines (#54473) 2022-09-01 18:15:44 +02:00
Serge Zaitsev
927ddf9376 Chore: Move login attempt methods to separate service (#54479)
* Chore: Move login attempt methods to separate service

* attempt to fix tests

* fix syntax

* better time mocking

* initialise now func
2022-09-01 18:08:42 +02:00
Victor Marin
d2bdb01092 Fixed tooltip does not change data when hovering over other datapoints (#54517) 2022-09-01 18:57:51 +03:00
Adela Almasan
f35a36b9f1 Chore: Downgrade Selecto to v1.17.0 (#54558) 2022-09-01 10:13:18 -05:00
Dimitris Sotirakis
212f0609eb Check if dist dir exists (#54590) 2022-09-01 10:43:04 -04:00
Andrej Kiripolský
59ba64f29b Dashboard: Fix typos in feedback request sentence (#54429)
* Fix typo in feedback request

* prettier

Co-authored-by: Domas <domasx2@gmail.com>
2022-09-01 09:29:52 -05:00
Murtaza Ahmedi
f6827a0518 Plugins Catalog: Allow to filter plugins using special characters (#54474) 2022-09-01 16:25:25 +02:00
Timur Olzhabayev
f7302149d0 Fix: Adjusting plugin.json schema regex (#54515) 2022-09-01 15:53:38 +02:00
Christopher Moyer
ac12b6d7ff refactors usage insights topics (#54497) 2022-09-01 08:46:21 -05:00
Josh Hunt
fd7a30c0a9 Fix: Restore Grafana and Dashboard data source icons (#54580) 2022-09-01 09:46:06 -04:00
Christopher Moyer
8a23b1fd4f adds video (#54545) 2022-09-01 08:35:58 -05:00
Beto Muniz
29ff97a4b8 Fix create a dashboard from Explorer and edit panel flow (#54551) 2022-09-01 10:18:57 -03:00
Dimitris Sotirakis
7e2238cf6f CI: Generate Grafana version (and metadata) when the build binary is built (#54393)
* Add GenerateVersions as BeforeFunc

* Delete gen-version

* Fix lint

* Get build id from env var
2022-09-01 15:43:40 +03:00
Dominik Prokop
4ec03bad64 Revert 54400 (#54570)
* Revert "Add FocusScope to PanelEditor when open in the Dashboard Page so that a11y focus never catches invisible content. (#54400)"

This reverts commit ef32050508.

* Betterer <3
2022-09-01 05:42:06 -07:00
Josh Hunt
c3633feea8 Chore: Remove Dashboard IconName type assertions (#54573)
* Chore: Remove Dashboard IconName type assertions

* fix lint
2022-09-01 13:26:28 +01:00
Josh Hunt
caa0c91b1c Chore: Remove Nav + story IconName type assertions (#54572)
* Chore: Remove some IconName type assertions

* fix actually importing the function

* fix lint

* fix lint
2022-09-01 13:23:41 +01:00
Julien Duchesne
67f1778bf1 Add package publishing step (#53553)
Issue: https://github.com/grafana/deployment_tools/issues/36289
Based on the new image: https://github.com/grafana/deployment_tools/tree/master/docker/package-publish
This is a new step meant to replace the store-packages command. It will greatly improve publishing performace and it publishes to a common repository shared with all Grafana products

Co-authored-by: dsotirakis <dimitrios.sotirakis@grafana.com>
2022-09-01 07:13:44 -04:00
Karl Persson
be6b8d91eb Correlations: Use correct fallback handlers (#54511)
* Correlations: Use correct fallback handlers

* Add signed in middleware to all routes
2022-09-01 12:29:44 +02:00
Gustavo Santos
822d24c123 Chore: Add controls to Label stories (#54549)
* Add controls for Label's Simple story

* Add controls for Label's Categorised story
2022-09-01 13:03:50 +03:00
Josh Hunt
f15ce633c9 Navigation: Don't round app plugin icon images (#54543)
* Navigation: Don't round app plugin icon images

* round icon
2022-09-01 10:28:50 +01:00
renovate[bot]
7efefbaece Update dependency moment-timezone to v0.5.35 [SECURITY] (#54523)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-09-01 10:27:39 +01:00
Hamas Shafiq
610952ca8a TestData DB: Fix node graph not showing when the Data type field is set to random (#54298) 2022-09-01 09:53:33 +01:00
Hamas Shafiq
028ba2bf95 Chore: Change JSON file to JSON File for consistency with other tabs (#54453) 2022-09-01 09:09:13 +01:00
Josa Gesell
3b848fd91b Fix a typo on the Manage dashboard links page (#54525) 2022-09-01 08:01:22 +00:00
Sven Grossmann
d31f2889a2 update @grafana/lezer-logql (#54530) 2022-09-01 09:11:55 +02:00
Adela Almasan
565766cca4 selecto version 1.19.0 (#54548) 2022-08-31 16:07:14 -05:00
Kat Yang
58449d42ed Chore: Add dashboard thumbnails service (#54500)
* Chore: Add dashboard thumbnails service

* Fix errors in dashboard thumbs impl

* Inject dashboardThumbsService into wire
2022-08-31 16:45:41 -04:00
Ryan McKinley
55fe1506ba Plugins: unlock on plugin startup failure (#54555) 2022-08-31 16:02:07 -04:00
Galen Kistler
d19a125ada Prometheus: report metrics browser toggle click interaction (#54546)
* report metrics browser toggle click interaction

Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
2022-08-31 14:43:00 -05:00
Ryan McKinley
dd38ff7cc8 Collapse: remove explicit panel-container className from definition (#54359) 2022-08-31 11:50:24 -07:00
Andre Pereira
e3c72ef5b7 Tempo: Improve TraceQL editor autocomplete (#54461)
* Detect spansets and improve autocomplete

* Better situation detection. Autocomplete scopes

* Remove scopes from tag name to get autocomplete

* Stronger regexes. More autocomplete tests

* Split big regex in smaller regexes

* Fix autocomplete when writing a string value with spaces

* Added test for the space inside string value autocomplete case

* Syntax highlight fix when using >< operators
2022-08-31 17:31:54 +01:00
Kristina
5069747893 Fix RefID and mixed datasource equality (#54536) 2022-08-31 10:22:13 -05:00
Christopher Moyer
e64009fa88 moves time series up, fixes random relrefs (#54477) 2022-08-31 10:13:07 -05:00
owensmallwood
f4bbce15a0 Public Dashboards: Add Expressions Support (#54336)
Adds support for expressions with public dashboards
2022-08-31 09:11:10 -06:00
Yuriy Tseretyan
76ea0b15ae Alerting: Scheduler to fetch folders along with rules (#52842)
* Update GetAlertRulesForScheduling to query for folders (if needed)
* Update scheduler's alertRulesRegistry to cache folder titles along with rules
* Update rule eval loop to take folder title from the
* Extract interface RuleStore 
* Pre-fetch the rule keys with the version to detect changes, and query the full table only if there are changes.
2022-08-31 11:08:19 -04:00
Mihály Gyöngyösi
60839d9c30 RBAC: Config setting to disable permission validation (#54447)
* Add scope_validation_enabled config setting to rbac section

* Rename config setting
2022-08-31 16:58:45 +02:00
Kristina
38c1f3d054 Explore: Add Mixed Datasource (#53429)
* Toggle on the mixed mode option

* Ensure switching to mixed gives existing query prev datasource

* WIP - Populate datasource when switching between mixed and not

* WIP - handle change from mixed

* Remove preimport filter, refine filter to work for queries

* WIP debugging datasource transition

* Ensure creating a new query gets target data source if switching with no matches between

* Add mixed datasource to rich history display

* Cleanup console logs, add relevant comments

* Add feature toggle for mixed datasource

* Fix Wrapper tests

* Fix tests!

* Fix test types and add feature tracking

* Remove unnecessary default, remove explore/mixed workarounds for D2E

* Move display text logic to mixed datasource file

* Add in the default query parameters to a generated empty query

* Condense some code

* Apply suggestions from code review

Co-authored-by: Giordano Ricci <me@giordanoricci.com>

* Add more logic around mixed datasource being off for explore

* Build out logic to handle different datasource scenarios

* Add tests

* Finalize last test

* Fix mixed URL with mixed ds off, and relevant test

* Fix datasource to explore workflow

* Add datasource change function, call import queries if needed

* add logic for changing single query ds

Co-authored-by: Giordano Ricci <me@giordanoricci.com>
2022-08-31 09:24:20 -05:00
Torkel Ödegaard
e5fba788d6 AppRootPage: Fixes issue navigating between two app plugin pages (#54519)
* AppRootPage: Fixes issue where it was not possible to navigate to another plugin

* Externalize react-router

* fixing test
2022-08-31 15:36:08 +02:00
Dave Henderson
713075c494 Metrics: Fixed grafana_database_conn_* metrics, and added new go_sql_stats_* metrics as eventual replacement (#54405)
* metrics: Fix broken DBStats metrics

Signed-off-by: Dave Henderson <dave.henderson@grafana.com>

* Register the sqlstats metrics by default

Signed-off-by: Dave Henderson <dave.henderson@grafana.com>

Signed-off-by: Dave Henderson <dave.henderson@grafana.com>
2022-08-31 08:54:32 -04:00
Victor Marin
51e2f57ac9 Hidden series stay hidden in legend when toggling visibility (#54139) 2022-08-31 13:49:24 +03:00
Piotr Pomierski
e95bab1f2b Storybook: Add controls to button story (#54389) 2022-08-31 11:42:47 +01:00
Dimitris Sotirakis
87f2b13efa CI: Update grabpl verison to v3.0.5 (#54269)
* Update grabpl

* Update to grabpl v3.0.5
2022-08-31 06:27:53 -04:00
Gustavo Santos
3ba3d47b85 Chore: Added controls to Checkbox stories (#54372) 2022-08-31 11:19:37 +01:00
Ashley Harrison
9e74050472 Update latest.json (#54484) 2022-08-31 09:17:59 +01:00
Dimitris Sotirakis
239c4cdb25 Add CustomMode in versions.go (#54482) 2022-08-31 09:21:33 +03:00
Joe Blubaugh
56369457d4 Grafana Backend: Establish a database version support policy. (#54374)
As stated in the documentation, Grafana will support the versions of our backend database options that are supported by their projects at the time that a Grafana release is issued.
2022-08-31 09:40:35 +08:00
Grot (@grafanabot)
3a9a145ef7 ReleaseNotes: Updated changelog and release notes for 8.3.11, 8.4.11, 8.5.11 and 9.0.8 (#54493)
* ReleaseNotes: Updated changelog and release notes for 8.3.11, 8.4.11, 8.5.11 and 9.0.8

Co-authored-by: Joan López de la Franca Beltran <joanjan14@gmail.com>
2022-08-30 20:55:01 +02:00
Grot (@grafanabot)
ab959f9305 ReleaseNotes: Updated changelog and release notes for 9.1.2 (#54481) 2022-08-30 18:33:03 +01:00
Will Browne
166b981019 ensure process manager is background service (#54475) 2022-08-30 13:09:52 -04:00
Artur Wierzbicki
9284216880 Search: ordering tests (#54432)
* search ordering tests

* lintt
2022-08-30 18:58:19 +02:00
Christopher Moyer
dc2616f833 removes previously refactored content (#54416) 2022-08-30 11:24:31 -05:00
Matias Chomicki
6e6069a2ba Loki: Create Variable Query Editor for Loki. (#54102)
* feat(loki-query-editor): create base editor component

* feat(loki-query-editor): update editor to use loki query type

* feat(loki-query-editor): add custom variable support to datasource

* feat(loki-query-editor): prevent errors when no label is present

* Add unit test for LokiMetricFindQuery

* Update datasource test

* Add component test

* Add variable query migration support

* feat(loki-query-editor): add migration support for older-format variables

* Fix enum capitalization for consistency

* Move attribute to the top of the class

* Remove unnecessary from()

* Update capitalization of new enum

* Fix enum capitalization in component

* feat(loki-query-editor): replace unnecessary class with class method
2022-08-30 18:18:51 +02:00
Will Browne
4a707e2a88 Plugins: Split plugin manager into smaller components (#54384)
* split out plugin manager

* remove whitespace

* fix tests

* split up tests

* updating naming conventions

* simplify manager

* tidy

* add more fakes

* testing time

* add query verif to int test

* renaming

* add process tests

* tidy up manager tests

* add extra case to int test

* add more coverage to store and process tests

* remove comment

* fix capatilization

* init on provide

* remove addfromsource from API
2022-08-30 17:30:43 +02:00
Nathan Marrs
acbbdccba9 Canvas: Fix minor duplication bug #54462 2022-08-30 08:27:00 -07:00
Gabriel MABILLE
c2c319146a FIX: RBAC prevents deleting empty snapshots (#54385)
* FIX: RBAC prevents deleting empty snapshots

* Update pkg/api/dashboard_snapshot.go

Co-authored-by: Mihály Gyöngyösi <mgyongyosi@users.noreply.github.com>

* Simplify else case

Co-authored-by: Emil Tullsted <sakjur@users.noreply.github.com>

Co-authored-by: Mihály Gyöngyösi <mgyongyosi@users.noreply.github.com>
Co-authored-by: Emil Tullsted <sakjur@users.noreply.github.com>
2022-08-30 17:19:52 +02:00
Dimitris Sotirakis
933bbe228b Add PackagesBucketEnterprise2 field in config (#54449) 2022-08-30 10:47:12 -04:00
Artur Wierzbicki
7a340f486b Storage: add WithContents option to storage.Get() (#53105)
* Storage: add `WithContents` option to `storage.Get()`

* fix tests

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-08-30 15:23:16 +02:00
Esteban Beltran
fc348e6279 Plugins Catalog: Use appSubUrl to generate plugins catalog urls (#54426)
* Plugins Catalog: us appSubUrl to generate plugins catalog urls

* add tests for PluginList with app sub url

* remove unnecessary comments
2022-08-30 12:34:41 +02:00
Joan López de la Franca Beltran
6ec06f66b9 Rendering: Add support for renderer token (#54425)
(cherry picked from commit a4f75cc0438712c90b02d24740416f8615e3a0cb)
2022-08-30 12:09:38 +02:00
renovate[bot]
8291ec1e44 Update dependency @opentelemetry/semantic-conventions to v1.6.0 (#54316)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-30 10:28:48 +01:00
Ashley Harrison
db4a2d58a1 convert DerivedField test to RTL (#54334) 2022-08-30 10:28:06 +01:00
Jack Westbrook
5ea01dc9b9 Build: Introduce webpack manifest plugin (#49798)
* build(webpack): introduce manifest plugin

* build(webpack): move manifest.json to root of project and git ignore
2022-08-30 05:18:55 -04:00
Polina Boneva
ef32050508 Add FocusScope to PanelEditor when open in the Dashboard Page so that a11y focus never catches invisible content. (#54400) 2022-08-30 12:08:31 +03:00
Ashley Harrison
5e394c0385 Convert influxdb ConfigEditor test to RTL (#54332) 2022-08-30 09:30:10 +01:00
Yaelle Chaudy
711c504b39 Azure Monitor: Updated grafana_ds_azuremonitor_dashboard_loaded event, replaced array of queries for stats (#54286)
* Replaced array of queries for stats

* Added ds_version prop

* Added ds_version to tests

* Extracted event name to tracking file

* Extracted event to tracking file

* Removed ds_version - useless for core plugin

* Addressed comments

* Added note to event documentation
2022-08-30 09:55:40 +02:00
Esteban Beltran
56bceacfb1 Navigation Bar: Remove plugins link under Server Admin (#54386)
* Navigation Bar: Remove plugins link under Server Admin

* Modify frontend to handle admin plugins as just plugins

* update assets and documentation mentioned path

* Fix copy to remove redundant text
2022-08-30 03:40:04 -04:00
Adela Almasan
89236cf418 Geomap: Cleanup (#54415) 2022-08-29 17:34:42 -04:00
Ezequiel Victorero
722aca5c53 Public Dashboards: use intervalMs and maxDataPoints from request (#53613) 2022-08-29 18:13:06 -03:00
Matt Dodson
fcea9ac913 Fix admonition (#54408) 2022-08-29 15:33:54 -05:00
Michael Mandrus
2c21113917 Secrets: Implement admin mechanism for deleting all secrets stored on the secrets plugin (#54264)
* implement delete all secrets endpoint

* change deletion check to just check for installed plugin

* refactor function call
2022-08-29 14:44:55 -04:00
linoman
3f0beee362 Update README build references (#54394) 2022-08-29 16:36:06 +02:00
Adela Almasan
07dcb64e38 Geomap: Fix tooltip display (#54245) 2022-08-29 09:29:54 -05:00
Ivan Ortega Alba
4a0a6c8fd4 Analytics: Rename create dashboard event (#54390) 2022-08-29 16:26:54 +02:00
Adam Simpson
87375f570d QueryEditorRow: filter data on mount (#54260)
This works correctly on initial dashboard load. However, when an action
is taken that triggers a "re-mount", e.g. opening the options pane on
the right side of the page, the `data` prop becomes undefined.
2022-08-29 13:49:58 +00:00
Alex Khomenko
d574a5d98f TimeRangeForm: Do not use HTML form (#54318)
* TimeRangeForm: Do not use HTML form

* TimeRangeForm: rename to TimeRangeContent
2022-08-29 16:19:12 +03:00
Marcus Efraimsson
9ff2b33ff1 Chore: Fix prometheus docker block (#54388) 2022-08-29 08:42:46 -04:00
Mihály Gyöngyösi
990f673202 Docs: Fix typo in custom-role-actions-scopes.md (#54294)
* Fix typo in custom-role-actions-scopes.md

* Address lint issue
2022-08-29 11:59:17 +02:00
linoman
d2547bb832 Chore: Group auth docker blocks (#54274)
* Move auth docker images to parent folder

* Add README file for auth parent folder

* Add grafana-authnz-team as code owner

* Update `devenv` docs
2022-08-29 08:36:56 +02:00
Orlando Ortega Jr
72a143aaff Chore: Added controls to DatePickerWithInput story (#54360) 2022-08-28 16:44:51 +03:00
ying-jeanne
fe062f2eaa Chore: Use db.DB interface instead of sqlstore (#54358)
* use db.DB interface instead of sqlstore

* make store service depends on db.DB instead of sqlstore
2022-08-26 19:07:58 -05:00
Ryan McKinley
216185b7f0 Storage: Avoid UID errors from annotations api when loading dashboards from storage (#54346) 2022-08-26 15:09:56 -07:00
Jean-Philippe Quéméner
a932428057 Alerting: use raw query data in provisioning to bypass interpolation of macros (#54293) 2022-08-26 23:54:30 +02:00
Jean-Philippe Quéméner
49b1182f34 Alerting: add missing yaml tag to mute time struct (#54287) 2022-08-26 23:30:07 +02:00
Nathan Marrs
3be3b02f59 Geomap: cleanup (#54328) 2022-08-26 16:03:20 -05:00
Adela Almasan
0707d682e0 Geomap: Local color range for dimensions (#54348)
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
2022-08-26 15:39:59 -05:00
Jeff Levin
5cb9fca990 public-dashboards: Add log statement when public dashboard enabled or disabled (#54133)
* refactor apis for consistent outputs
* add dashboardUid validation at API layer
* add check for empty dashboardUid on SavePublicDashboard
* remove public dashboard errors from models package.

Co-authored-by: Ezequiel Victorero <evictorero@gmail.com>
2022-08-26 11:28:54 -08:00
Yuriy Tseretyan
b9be2815d3 Chore: Fix cue loader to use absolute path (#54257) 2022-08-26 14:08:12 -04:00
Brendan O'Handley
20d0aa9904 OpenTsdb: migrate annotations from angular to react (#53856)
* remove annotation angular dependency and migrate annotations

* add nullish coalescing operator

* remove annotations angular partial

* make annotation queries code and errors more readable

* handle the betterer issue with '^ Unexpected any. Specify a different type' at top of file

* run precommits

* run prettier
2022-08-26 13:44:10 -04:00
Ryan McKinley
2db6a199b8 Preferences: Support setting any dashboard as home, not just the starred ones (#54258) 2022-08-26 12:40:40 -04:00
Hamas Shafiq
93c5c175fe Jaeger: Show a better error msg if no service is selected when using search (#54172) 2022-08-26 17:09:18 +01:00
Karl Persson
9d2f5ef62f RBAC: Add function to generate wildcards from prefix (#54275)
* RBAC: Move metadata to own file

* RBAC: Rename test files

* RBAC: Add wildcard structure and helper function to generate wildcards
from prefix

* RBAC: Refactor filter to use WildcardsFromPrefix

* RBAC: Refactor GetResourceMetadata to use WildcardsFromPrefix
2022-08-26 17:10:35 +02:00
ying-jeanne
6227528ea0 Chore: SQL Store Split of datasource (#54262)
* refectory datasource

* fix linter
2022-08-26 11:03:38 -04:00
Selene
ec3697584a Move config nodes to another function (#54330) 2022-08-26 16:30:21 +02:00
Yuriy Tseretyan
db09a76125 update test environment to create folders (#54254) 2022-08-26 09:46:41 -04:00
Ivan Ortega Alba
c66c275342 SearchSrv: stop using IDs (#54296)
* SearchSrv: stop using IDs

* Remove IDs from test
2022-08-26 15:41:47 +02:00
Maria Alexandra
f4fa3e4ff4 Panel edit: Run queries when time range changes in table view (#53111) 2022-08-26 15:36:42 +02:00
Galen Kistler
6ed0787376 InfluxQL: Quoting tag values in the query editor (#54187)
* Quote numeric values in query editor
2022-08-26 08:26:44 -05:00
Giordano Ricci
26524e3ff1 GrafanaUI: Fix styles for invalid selects & DataSourcePicker (#53476)
* GrafanaUI: fix styles for invalid select & DataSourcePicker

* Apply suggestions from code review

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

* fix focus issues & tests

* remove unused import

* TypeScript work in progress

* Move react select props to types.ts

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
Co-authored-by: eledobleefe <laura.fernandez@grafana.com>
Co-authored-by: joshhunt <josh@trtr.co>
2022-08-26 13:48:51 +01:00
Gábor Farkas
a58edc9f5e elastic: always use millisecond-intervals for alerting (#54157) 2022-08-26 14:40:28 +02:00
renovate[bot]
6f72c4d10d Update dependency @testing-library/user-event to v14.4.3 (#54292)
* Update dependency @testing-library/user-event to v14.4.3

* use ReturnType instead of using a nested import

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-08-26 13:30:34 +01:00
Ashley Harrison
91948ce554 Convert elasticsearch ConfigEditor.test.tsx to RTL (#54301) 2022-08-26 13:29:31 +01:00
Giordano Ricci
b4334b26aa Chore: add missing properties to mocks (#54290)
* Chore: add missing properties to mocks

* update snapshot
2022-08-26 12:17:04 +01:00
renovate[bot]
526989e16b Update dependency @microsoft/api-extractor-model to v7.23.3 (#54283)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-26 11:51:16 +01:00
Giordano Ricci
c68d7f1e35 Correlations: Add CorrelationSettings Page (#53821)
* GrafanaUI: add option to close DeleteButton on confirm click

* add datasource readOnly info to frontend settings

* move isTruthy utility type guard

* add generic non-visualization table component

* Add correlations settings page

* add missing readOnly in mock

* Fix typo

* avoid reloading correlations after add/remove

* use DeepPartial from rhf

* validate source data source

* fix validation logic

* fix navmodel test

* add missing readonly property

* remove unused styles

* handle multiple clicks on elements

* better UX for loading states

* fix remove handler

* add glue icon
2022-08-26 11:27:28 +01:00
Vadim Beskrovnov
37fde2eec6 Dashboard save: Persist details message when navigating through dashboard save drawer's tabs. (#54084)
* Dashboard: Fix `changes note` textarea to save draft when going to other tabs

* Do not show Changes tab if there are no changes

* Fix comments

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
2022-08-26 03:25:40 -07:00
renovate[bot]
ed50af904f Update dependency @microsoft/api-extractor to v7.29.5 (#54281)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-26 11:01:00 +01:00
Marcus Efraimsson
87afd9cadc Plugins: Remove various custom headers logic (#54146)
Removes various custom headers logic sprinkled around in the backend. 
It should automatically be applied to outgoing HTTP requests via the 
CustomHeadersMiddleware.
This also removes decryption of SecureJSONData to populate custom 
headers in ngalert which seemed to have caused a ton of CPU usage.
2022-08-26 11:56:10 +02:00
renovate[bot]
2f4c8e1b3d Update dependency eslint-plugin-react to v7.31.0 (#49214)
* Update dependency eslint-plugin-react to v7.31.0

* fix displayName for OldNavOnly

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-08-26 10:31:16 +01:00
Josh Hunt
ebbeed8ad7 I18n: Use locale preference (#53293) 2022-08-26 10:27:14 +01:00
Jeff Levin
681bdf1a2d public-dashboards: refactor query method (#54119)
This PR refactors the GetPublicDashboard method so we don't need to make extra database calls. Also adds general documentation
2022-08-26 05:21:52 -04:00
Hamas Shafiq
cd26cade68 Chore: Remove unused theme (#54175) 2022-08-26 10:15:21 +01:00
Artur Wierzbicki
74158ed66b Search: use SQL search as a fallback during bluge's initial indexing (#54095)
* Search: use SQL search as a fallback when bluge indexing is ongoing

* Search: lint

* Search: feedback fixes - return an empty frame with a special name

* Search: revert readiness check query type

* Search: remove println

* remove sleep, get coffee
2022-08-26 12:36:41 +04:00
Karl Persson
5a1b9d2283 RBAC: Remove DeclareFixedRoles wrapper on Access control and inject service (#54153)
* RBAC: Remove DeclareFixedRoles wrapper on Access control and inject service when needed
2022-08-26 09:59:34 +02:00
Ivan Ortega Alba
c332bf885c Migrate to UID: Stop using search result ID (#54099)
* DashList: Stop using IDs

* DashLinks: Stop using IDs

* BackendSrv: Do not use ID for search endpoint

* DashboardDataDTO: Remove ID

* Remove unused properties from DashboardSearchItem
2022-08-26 09:42:46 +02:00
Leo
e27769da9c use navId and subtitle on api keys page (#54247) 2022-08-26 09:28:17 +02:00
Matias Chomicki
cd617b6520 Loki: refactor mock instance creation and clean up datasource test (#54176)
* refactor(loki-test): move mock creation to mock module

* refactor(loki-test): allow to pass custom settings to the mock constructor

* refactor(loki-test): refactor mock factory in datasource test

* refactor(loki-test): revert change in undefined test case for dsMaxLines

* refactor(loki-test): move type assertion to mock definition

* refactor(loki-test): fix more type issues

* refactor(loki-explore-query-editor): refactor test to use createLokiDatasource() and fix type issues

* refactor(loki-test): replace makeMockLokiDatasource with metadataRequest factory

* fix: remove any

* fix(loki-test): fix remaining usages of any

* Fix: add missing exported type
2022-08-26 09:26:48 +02:00
Gábor Farkas
448a67ab43 elastic: use millisecond-intervals (#54202) 2022-08-26 08:56:39 +02:00
Victor Marin
07c9c8ffd7 Histogram cue model fixes (#54022) 2022-08-26 09:45:19 +03:00
Adela Almasan
cea2b4b7b8 Geomap: Spatial operations location options transform e2e test (#54162) 2022-08-25 17:34:24 -04:00
Adela Almasan
9db66049c6 Devenv: Geomap global vs local field coloring (#54253) 2022-08-25 16:22:14 -05:00
Guilherme Caulada
f25c7f6ddd Chore: Refactor secrets kvstore to organize testing and migrations (#54249)
* Refactor migrations and tests for secrets kvstore

* Use fake secrets store as a shortcut on tests

* Update wire

* Use global migration logger

* Fix ds proxy tests

* Fix linting issues

* Rename data source test setup function
2022-08-25 18:04:44 -03:00
ying-jeanne
fd01161bcc Chore: replace xorm by sqlx in dashboardversion service (#53869) 2022-08-25 16:04:16 -05:00
Michael Mandrus
8deababa50 Chore: Refactor secrets plugin unit tests code (#54231)
* refactor test setup to return struct rather than many values

* changes to code style from review

* apply diff from Leandro for logging
2022-08-25 15:15:58 -04:00
Yuriy Tseretyan
03e746d9df Alerting: Delete state from the database on reset (#53919)
* make ResetStatesByRuleUID return states
* delete rule states when reset
* rule eval routine to clean up the state only when rule is deleted
2022-08-25 14:12:22 -04:00
Artur Wierzbicki
5c0bf2ba39 Storage: fix creating a new dashboard with dashboardsFromStorage feature flag enabled 2022-08-25 14:04:09 -04:00
Christopher Moyer
3f0636083d Docs/adds cloud support disclaimer (#54150)
* adds cloud support disclaimer to three sections

* starts add cloud disclaimer

* adds disclaimer to JWT and Org sections

* adds final Cloud disclaimer to the Loki data source
2022-08-25 12:53:41 -05:00
Christopher Moyer
948452034e Docs/refactors manage dashboard topics (#54178)
* makes prettier

* refactors manage dashboard topics

* Apply suggestions from code review

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

* incorporates review feedback

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-08-25 11:30:07 -05:00
GitStart
468597b687 Elasticsearch: Remove any from public/app/plugins/datasource/elasticsearch/components/AddRemove.test.tsx (#54232)
Co-authored-by: gitstart <gitstart@users.noreply.github.com>
Co-authored-by: gitstart <gitstart@gitstart.com>
Co-authored-by: Nitesh Singh <nitesh.singh@gitstart.dev>
Co-authored-by: Júlio Piubello da Silva Cabral <julio.piubello@gitstart.dev>
Co-authored-by: Toledodev <rafael.toledo@engenharia.ufjf.br>
Co-authored-by: juliopiubello <juliopiubellow@gmail.com>
2022-08-25 17:33:16 +02:00
Ashley Harrison
15e19cef95 Navigation: improve page toolbar responsiveness (#54223)
* improve page toolbar responsiveness

* rename emotion style to be more descriptive

* remove unnecessary max-width
2022-08-25 16:21:29 +01:00
Brendan O'Handley
c9a3b2d420 use metadata endpoint (#53980) 2022-08-25 10:59:49 -04:00
Christopher Moyer
ca3296da34 Docs: refactors and copy edits share dashboard topics (#53972)
* refactors and copy edits share dashboard topics

* fixes typo

* incorporates feedback

* completes splitting out reporting and playlists
2022-08-25 08:19:28 -05:00
Ashley Harrison
d765aaff49 use navId + pageNav on datasource pages (#54218) 2022-08-25 13:58:41 +01:00
Emil Tullstedt
0ffbf901d7 ContextHandler: Use stdlib format for middleware (#54219) 2022-08-25 14:35:21 +02:00
Mihály Gyöngyösi
aace0b1e7f Admin: Create/Edit Team/ServiceAccount UI changes (#53889)
* RolePicker: Handle inherited with

* Small ammendment to Create Service Account layout

* RolePicker: introduce maxWidth prop

* Clean up

* Change VerticalGroup spacing to large on Team Settings page

* Introduce constant for submenu width

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

Simplify style parameter

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>

* Add description to the improved calculation

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
2022-08-25 13:30:11 +02:00
Leo
9f8cb17b01 Navigation: Use new page layout in Service accounts item page (#54200)
* use navId, pageNav and update alignments of service account page

* Fixing item header when feature is disabled

* Fix orgs item page

* Minor tweak to subtitle for service account item page

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-08-25 13:11:30 +02:00
Karl Persson
552d3fec8d RBAC: Fix resolver issue on wildcard resulting in wrong status code for endpoints (#54208)
* RBAC: Test evaluation before attaching mutator

* RBAC: Return error if no resolver is found for scope

* RBAC: Sync changes to evaluation in mock

* RBAC: Check for resolver not found error and just fail the evaluation in that case
2022-08-25 12:50:27 +02:00
Gábor Farkas
89d264fecc logs: better names and comments (#53770)
* logs: better names and comments

* comment: updated capitalization
2022-08-25 12:49:35 +02:00
Hamas Shafiq
5148464c88 Jaeger: Make search form fields more consistent with Tempo (#54026) 2022-08-25 09:51:21 +01:00
Esteban Beltran
6200c6d70f Build: Force a specific nodejs version for levitate detect breaking changes pipeline (#54207) 2022-08-25 04:35:13 -04:00
Armand Grillet
0a18456507 Move GH workflow step to have node_id unchanged (#54201) 2022-08-25 10:15:04 +02:00
Carl Bergquist
ab59f3cb1a metrics: add operation name used in metrics/tracing for middlewares (#53949)
Signed-off-by: bergquist <carl.bergquist@gmail.com>
2022-08-25 10:11:27 +02:00
Dominik Prokop
8eac5706fd AdHoc variable: Correctly preselect datasource when provisioning (#54088)
* Adhoc variable: Correctly preselect datasource when provisioning

* Fix test

* Remove data sources from ad hoc variable state in favor of DataSourcePicker
2022-08-25 00:56:45 -07:00
Yaelle Chaudy
d0d6562f63 AzureMonitor: Added ARG query function for template variables (#53059)
* Added ARG query functionfor template variables

* removed unused import

* Tweak tests

* Fix tests

* Renamed query function - added 'Azure'

* Revert "Renamed query function - added 'Azure'"

This reverts commit a046bcdd7c.

* Adressed comments

* Fix uncaught error issue

* revert last commit

* Add back errorMessage check
2022-08-25 09:38:43 +02:00
Gábor Farkas
60d1668d74 Elasticsearch: Respect time range in ad hoc filters (#53874)
* elastic: respect time range in ad hoc filters

* added unit test
2022-08-25 09:29:15 +02:00
Dominik Prokop
f9a49aa3ed Fix: Correctly migrate mixed data source targets (#54152)
* Failing test case

* Fix mixed datasource targets migration
2022-08-25 00:07:10 -07:00
Jeff Levin
6128cb60b4 cleanup unused fields (#54115)
This PR removes unused struct fields in SavePublicDashboardCommand
2022-08-24 21:29:01 -04:00
Kim Nylander
fe87ffdda0 [Doc] Fix broken link in Tempo doc (#54120)
* Fix broken link

* Update docs/sources/datasources/tempo.md

Co-authored-by: Ursula Kallio <ursula.kallio@grafana.com>

Co-authored-by: Ursula Kallio <ursula.kallio@grafana.com>
2022-08-24 16:58:45 -07:00
Ryan McKinley
b483ac322f Chore: replace React.FC<Props> with simple function component (#54123) 2022-08-24 16:54:34 -04:00
Michael Mandrus
277ea836b6 Secrets: Implement migration of secrets from plugin back to unified secrets (#53561)
* initial cut at migration from plugin

* create new migration from plugin

* only migrate to or from, not both

* remove cfg check from plugin migration itself

* update comments, clean up secret after migration

* add better error handling

* hook up REST API with migrations

* Minor fixes

* fix wire injection issue

* modify migrator to access plugin calls directly. create unit tests

* change pre-migration checks in admin api

* stop plugin after migrating from it

* fix compile issues after merge

* add comment about migration

* fix linting issue

* bleh, fix unit test

* fix another unit test

* update plugin error fatal flag after a migration from the plugin

* add extra logging to migration

* make linter happy

Co-authored-by: Leandro Deveikis <leandro.deveikis@gmail.com>
2022-08-24 16:24:50 -04:00
lean.dev
c8f2cd2599 Fixing swagger meta preventing spec generation (#54181) 2022-08-24 16:56:28 -03:00
Yuriy Tseretyan
41bd36eb97 Alerting: Update rules delete endpoint to handle rules in group (#53790)
* update RouteDeleteAlertRules rules to update as a group
* remove expecter from scheduler mock to support variadic function
* create function to check for provisioning status + tests

Co-authored-by: Alexander Weaver <weaver.alex.d@gmail.com>
2022-08-24 15:33:33 -04:00
Santiago
4fad827acd Alerting: log external alertmanager URLs #54127 2022-08-24 13:52:39 -04:00
Andre Pereira
c8f2148f75 Tempo: Basic PoC of the upcoming TraceQL editor in Explore (#54028)
* First working version of the TraceQL editor with syntax highlighting and autocomplete

* Add feature flag around the new editor option

* Fix tests and cleanup

* Fix misspelling
2022-08-24 17:57:59 +01:00
Ryan McKinley
94b4f6f459 Search: Show all dashboards in the folder view (#54163) 2022-08-24 12:10:34 -04:00
Torkel Ödegaard
264645eecd TopNav: Dashboard settings (#52682)
* Scenes: Support new top nav

* Page: Make Page component support new and old dashboard page layouts

* Pass scrollbar props

* Fixing flex layout for dashboard

* Progress on dashboard settings working with topnav

* Updated

* Annotations working

* Starting to work fully

* Fix merge issue

* Fixed tests

* Added buttons to annotations editor

* Updating tests

* Move Page component to each page

* fixed general settings page

* Fixed versions

* Fixed annotation item page

* Variables section working

* Fixed tests

* Minor fixes to versions

* Update

* Fixing unit tests

* Adding add variable button

* Restore annotations edit form so it's the same as before

* Fixed semicolon in dashboard permissions

* Fixing unit tests

* Fixing tests

* Minor test update

* Fixing unit test

* Fixing e2e tests

* fix for e2e test

* fix a11y issues

* Changing places Settings -> General

* Trying to fix a11y

* I hope this fixes the e2e test

* Fixing merge issue

* tweak
2022-08-24 18:05:12 +02:00
Ryan McKinley
fe61a97c9d TextPanel: Support code formats (#53850) 2022-08-24 08:13:00 -07:00
ying-jeanne
4d4ecd7fec fix the event attributes (#54117) 2022-08-24 09:59:06 -05:00
Dimitris Sotirakis
9be8b0564a Update whatsNewUrl (#54154) 2022-08-24 09:57:03 -05:00
Jeff Levin
f5b99e5ca7 add tests for api urls (#54116)
Create function for generating api urls and add tests
2022-08-24 08:51:35 -06:00
Yuriy Tseretyan
736d035c65 Chore: Add context util that allow to provide cause of cancellation (#53918) 2022-08-24 10:24:41 -04:00
Armand Grillet
6804a8c9cc Add GH action to automatically add issue labeled to GH board (#54151) 2022-08-24 16:20:10 +02:00
Andreas Christou
e8b13f8122 Bump code coverage workflow version (#54138) 2022-08-24 14:40:47 +01:00
Laura Benz
95ec6f6c0f Explore: Improve a11y of query row collapse button (#53827)
* refactor: convert to IconButton

* refactor: adjust attributes
2022-08-24 15:38:16 +02:00
Dimitris Sotirakis
50d0581000 Trigger backend tests on devenv changes (#54137) 2022-08-24 14:54:11 +03:00
Valério Valério
b5142832fa Alerting: Fix saving of screenshots uploaded with a signed url (#53933)
The URL of screenshots uploaded to external image storages can be optionally signed, resulting in a long string (800+ chars).
2022-08-24 12:40:50 +01:00
Karl Persson
55c7b8add2 RBAC: Split up service into several components (#54002)
* RBAC: Rename interface to Store

* RBAC: Move ranme scopeInjector

* RBAC: Rename files to service

* RBAC: Rename to service

* RBAC: Split up accesscontrol into two components

* RBAC: Add DeclareFixedRoles to AccessControl interface

* Wire: Fix wire bindings

* RBAC: Move resolvers to root

* RBAC: Remove invalid test

* RBAC: Inject access control service

* RBAC: Implement the RoleRegistry interface in fake
2022-08-24 13:29:17 +02:00
Ashley Harrison
211c9991c5 Navigation: Add responsive behaviour to ToolbarButtonRow (#53739)
* hacky first attempt

* slightly cleaner...

* behaviour mostly working...

* remove unnecessary wrapper

* css tweaks

* much cleaner implementation with intersectionobserver

* set style props directly on children

* separate story, integrate when toggle is off

* improve story, integrate when toggle is on

* remove styles from DashNavTimeControls

* mock IntersectionObserver for all unit tests

* prettier

* don't use dropdown anymore

* add some basic documentation

* add right alignment to scenes toolbarbuttonrow

* just use the react children api to prevent duplicating children
2022-08-24 11:19:36 +01:00
renovate[bot]
b51167e89a Update dependency @betterer/regexp to v5.4.0 (#54051)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-24 11:04:51 +01:00
Marcus Efraimsson
cd5f27a25d Plugins: Propagate distributed tracing headers to backend plugins (#54107) 2022-08-24 11:55:49 +02:00
sam boyer
1cfb3c1627 devenv: run stripnulls.sh (#54124) 2022-08-24 12:26:20 +03:00
renovate[bot]
caf3077ebb Update dependency @betterer/eslint to v5.4.0 (#54046)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-24 09:29:17 +01:00
Matias Chomicki
1642716978 Chore(loki): remove any from DerivedFields test (#53547) 2022-08-24 10:06:28 +02:00
Kevin Minehart
95ec3e8c09 Chore: update latest.json to 9.1.1 (#54108) 2022-08-24 08:34:41 +01:00
Torkel Ödegaard
8880cbd7f6 AngularPanels: Fixing changing angular panel options not taking having affect when coming back from panel edit (#54087) 2022-08-24 08:35:44 +02:00
ying-jeanne
4dbe0b4f02 Chore: Move updateorg out of sqlstore (#54111)
* Chore: move updateorg out of sqlstore

* fix api test
2022-08-23 12:26:21 -05:00
Kristina
5f57edd08a Allow for clickable link (#54067) 2022-08-23 12:17:58 -05:00
Ryan McKinley
1d4e01f8ba Transformers: Support inner vs outer join (#53913) 2022-08-23 10:14:03 -07:00
eledobleefe
1766ea9fdf Navigation: Use new page layout in Server Admin > Orgs pages (#54018) 2022-08-23 18:38:46 +02:00
Grot (@grafanabot)
2eec035c13 ReleaseNotes: Updated changelog and release notes for 9.1.1 (#54103) 2022-08-23 11:56:04 -04:00
Isabella Siu
4f2b66ac1d CloudWatch: Log group variable should get all log groups (#54062) 2022-08-23 11:43:30 -04:00
Andreas Christou
1f17e9a044 Update effects to avoid retrieving metrics descriptors except on project name update (#54091) 2022-08-23 16:42:59 +01:00
Guilherme Caulada
d90600c454 Secrets: Add fallback to secrets kvstore plugin (#54056)
* Add fallback to secrets kvstore plugin

* Fix linter issues

* Fix linter issues

* Add deletion error to bool to fake secrets kvstore

* Add fallback to fake secrets kvstore

* Fix fake secrets kvstore fallback setter

* Use Key on Item message for secrets manager protobuf

* Add clarifying comment about fallback
2022-08-23 12:21:54 -03:00
ying-jeanne
ebcdf402b2 Chore: move from xorm to sqlx apikey store (#53434)
* migrate from xorm to sqlx

* fix tests

* fix comments

* fix some comments on the PR

* fix CI

* fix the comments
2022-08-23 11:01:35 -04:00
Kim Nylander
45b65cc6c9 [DOC] Add APM changes and fix links (#53986)
* Add APM changes and fix links

* Apply suggestions from code review

* Update docs/sources/datasources/tempo.md

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

* Update docs/sources/explore/trace-integration.md

* Prettier update

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>
2022-08-23 07:46:23 -07:00
Giordano Ricci
fe8a4e926d Chore: cleanup datasources devenv (#54092) 2022-08-23 15:10:13 +01:00
Ryan McKinley
dfda3e2b03 Dependencies: Update monaco-editor (#54068)
Co-authored-by: Gábor Farkas <gabor.farkas@gmail.com>
2022-08-23 06:58:58 -07:00
Esteban Beltran
6fe7a1f034 Icons: Move unicons icons to the repository and generate the iconsBundle.js with nodejs (#53766) 2022-08-23 15:47:14 +02:00
Karl Persson
c9661a5be1 RBAC: Only display unique permissions in list (#54074)
* PermissionList: Only display one row for each user, team or builtin role
2022-08-23 15:34:31 +02:00
Jo
5c1f614d3c Service Accounts: Separate metrics logic from store (#54085)
* separate stats logic from store

* remove in_teams unused stat

* use init instead
2022-08-23 08:24:55 -04:00
Hamas Shafiq
afa7e8d8de Tempo: Make TempoQuery.search & SearchQueryParams.tags optional (#54052) 2022-08-23 12:27:19 +01:00
Marcus Efraimsson
e6857bf17d Plugins: Handle app plugin proxy routes per request (#51835)
Fixes #47530
2022-08-23 13:05:31 +02:00
Hamas Shafiq
5f80bf5297 Tempo: Remove unused functions in datasource.ts (#54081) 2022-08-23 12:02:43 +01:00
Will Browne
26dfdd5af3 Plugins: Refactor plugin download/installation (#43046)
* installer -> repo

* add semver format checking

* add plugin callbacks in test

* remove newline

* post install only scans new directories

* remove unused stuff

* everything in own package

* add missing cli params

* make grafana version part of the API

* resolve conflicts

* tidy up logger

* fix cli and tidy log statements

* rename log package

* update struct name

* fix linter issue

* fs -> filestore

* reorder imports

* alias import

* fix test

* fix test

* inline var

* revert jsonc file

* make repo dep of manager

* actually inject the thing

* accept all args for compatability checks

* accept compat from store

* pass os + arch vals

* don't inject fs

* tidy up

* tidy up

* merge with main and tidy fs storage

* fix test

* fix packages

* fix comment + field name

* update fs naming

* fixed wire

* remove unused func

* fix mocks

* fix storage test

* renaming

* fix log line

* fix test

* re-order field

* tidying

* add test for update with same version

* fix wire for CLI

* remove use of ioutil

* don't pass field

* small tidy

* ignore code scanning warn

* fix testdata link

* update lgtm code
2022-08-23 11:50:50 +02:00
Karl Persson
cc78486535 RBAC: Display indicator if a permission is inherited (#54080)
* RBAC: Add IsInherited property

* PermissionList: Display inherited indicator
2022-08-23 05:34:19 -04:00
Will Browne
eb4266a85e Plugins: Interpolate plugin type as part of plugin ID schema (#54030)
* do it

* undo
2022-08-23 05:14:23 -04:00
Leon Sorokin
530dd63ac6 TimeSeries: Fix crash when min >= max in config (#54069)
* TimeSeries: fix crash when min === max in config

* stat sparkline, too

* better types
2022-08-23 01:00:42 -07:00
Christopher Moyer
c29a2c37c1 docs: corrects broken relrefs (#54061)
* corrects broken relrefs

* Apply suggestions from code review

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>

Co-authored-by: Eve Meelan <81647476+Eve832@users.noreply.github.com>
2022-08-22 17:03:58 -05:00
Ryan McKinley
13aacf3590 Geomap: Fix geohash editor settings #54058 2022-08-22 14:12:21 -07:00
Christopher Moyer
657e1683d2 docs: refactors field value overrides topics (#53849)
* refactors field value overrides topics

* Update docs/sources/panels/configure-overrides/index.md

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

* Update docs/sources/panels/configure-overrides/index.md

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

* Update docs/sources/panels/configure-overrides/index.md

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

* Update docs/sources/panels/configure-overrides/index.md

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

* Update docs/sources/panels/configure-overrides/index.md

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

* Update docs/sources/panels/configure-overrides/index.md

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

* Update docs/sources/panels/configure-overrides/index.md

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

* makes prettier

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-08-22 15:37:29 -05:00
Ryan McKinley
dcdf232882 Heatmap: update heatmap documentation (#52756)
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
2022-08-22 12:50:34 -05:00
ceh
ad501e770f Docs: Fix minor typo (#53590) 2022-08-22 18:26:52 +02:00
sam boyer
4d433084a5 plugins: New static scanner and validator, with Thema slot support (#53754)
* coremodels: Convert plugin-metadata schema to a coremodel

* Newer cuetsy; try quoting field name

* Add slot definitions

* Start sketching out pfs package

* Rerun codegen with fixes, new cuetsy

* Catch up dashboard with new cuetsy

* Update to go1.18

* Use new vmuxers in thema

* Add slot system in Go

* Draft finished implementation of pfs

* Collapse slot pkg into coremodel dir; add PluginInfo

* Add the mux type on top of kernel

* Refactor plugin generator for extensibility

* Change models.cue package, numerous debugs

* Bring new output to parity with old

* Remove old plugin generation logic

* Misc tweaking

* Reintroduce generation of shared schemas

* Drop back to go1.17

* Add globbing to tsconfig exclude

* Introduce pfs test on existing testdata

* Make most existing testdata tests pass with pfs

* coremodels: Convert plugin-metadata schema to a coremodel

* Newer cuetsy; try quoting field name

* Add APIType control concept, regen pluginmeta

* Use proper numeric types for schema fields

* Make pluginmeta schema follow Go type breakdown

* More decomposition into distinct types

* Add test case for no plugin.json file

* Fix missing ref to #Dependencies

* Remove generated TS for pluginmeta

* Update dependencies, rearrange go.mod

* Regenerate without Model prefix

* Use updated thema loader; this is now runnable

* Skip app plugin with weird include

* Make plugin tree extractor reusable

* Split out slot lineage load/validate logic

* Add myriad tests for new plugin validation failures

* Add test for zip fixtures

* One last run of codegen

* Proper delinting

* Ensure validation order is deterministic

* Let there actually be sorting

* Undo reliance on builtIn field (#54009)

* undo builtIn reliance

* fix tests

Co-authored-by: Will Browne <wbrowne@users.noreply.github.com>
2022-08-22 12:11:45 -04:00
renovate[bot]
828497447a Update dependency @betterer/cli to v5.4.0 (#54041)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-22 16:59:45 +01:00
Ashley Harrison
3cf95d7eee Chore: fix some anys pt.2 (#53928)
* correctly type some more any's

* undo this change for now...
2022-08-22 16:51:33 +01:00
Josh Hunt
2b17e5354a Chore: Remove needless eslint ignore comment from variable utils (#54050) 2022-08-22 16:50:24 +01:00
Vadim Beskrovnov
7caba545ec A11y: Fix a11y for toolbar buttons in PanelEditor (#53864)
Co-authored-by: Vadim Beskrovnov <vbeskrovnov@fb.com>
2022-08-22 17:08:22 +02:00
Christopher Moyer
666f84be57 refactors transformation topics (#53984) 2022-08-22 10:04:59 -05:00
George Robinson
e163a976fa Alerting: Fix width of Adapative Cards in Teams notifications (#53996) 2022-08-22 16:04:22 +01:00
Alex Khomenko
2caaa7fba2 ColorInputPicker: Fix popover in disabled state (#54000) 2022-08-22 18:01:33 +03:00
renovate[bot]
38017fd3f5 Update dependency @betterer/betterer to v5.4.0 (#54031)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-22 15:50:51 +01:00
Guilherme Caulada
2e9edf4592 Secrets: Refactor code duplicity on secrets sql kvstore (#54032) 2022-08-22 11:48:57 -03:00
renovate[bot]
013dda7bb8 Remove dependency jest-mock-console (#52872)
* Update dependency jest-mock-console to v2

* let's remove jest-mock-console

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-08-22 15:47:45 +01:00
Christopher Moyer
1da4aa25a8 docs: refactors value mappings topics (#53616)
* starts copy edit

* completes refactor and copy edit
2022-08-22 09:26:53 -05:00
Gábor Farkas
35253a909d Elasticsearch: remove already-disabled code (#52932)
* elastic: removed unused code from go-part

* elastic: removed unused code from js-part
2022-08-22 16:25:20 +02:00
Josh Hunt
9db9ebce02 Typed variables pt6: Clean up and test variable type guards (take 2) (#54025)
* Add fixture-factories for all variable types

* clean up variable guards

* add tests for isMulti, hasCurrent, and hasOptions variable type guards

* create VariableSupport type to try and work around ts wonkiness
2022-08-22 14:45:40 +01:00
renovate[bot]
4c8ea0bb89 Update dependency @lezer/common to v1 (#50866)
* Update dependency @lezer/common to v1

* Bump lezer/lr as well

* Fix broken code

* Add new lezer-promql and update lezer-logql

* Change to prometheus lezer-promql, fix lezer-logql code

* Update tests for Loki

* fix typeErrors

* fix tests by adding new error node to expected objects

* refactor usages of node references to differentiate usage from node object

Co-authored-by: Renovate Bot <bot@renovateapp.com>
Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
Co-authored-by: Ivana Huckova <ivana.huckova@gmail.com>
Co-authored-by: gtk-grafana <galen.kistler@grafana.com>
2022-08-22 08:45:29 -05:00
Dimitris Sotirakis
ceb32a7506 Add GCP_KEY secret to the artifacts-page pipeline (#54013) 2022-08-22 08:44:43 -05:00
Gilles De Mey
0923d2455c Alerting: Show alerting enabled for Alertmanager data sources (#54023) 2022-08-22 14:34:55 +02:00
Ashley Harrison
0f4b8c5e54 convert AzureCredentialsForm test to RTL (#53959) 2022-08-22 13:22:19 +01:00
Karl Persson
ef25d297d6 RBAC: Display groups for custom roles (#54020)
* RolePicker: Default to "Other" for roles without group

* RolePicker: Add GroupType enum and calculate group options based on
group type

* RolePicker: Display groups for custom roles

* RolePicker: Remove unused code

* RolePicker: Restructure

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
2022-08-22 14:21:12 +02:00
Ashley Harrison
f91f05f32c Chore: convert DebugSection test to RTL (#53965)
* convert DebugSection test to RTL

* remove unused import
2022-08-22 13:19:46 +01:00
Gábor Farkas
395e443932 loki: Fix adding refId to rowId (#53932) 2022-08-22 13:09:33 +02:00
Hamas Shafiq
895616a231 Tempo: Remove spanName from the query object if undefined (#53945) 2022-08-22 11:52:36 +01:00
Victor Marin
cbe4fb4dab TablePanel: Fix vertical scrollbar (#53457)
* TablePanel: Fix vertical scroll

* Fix vertical scrollbar with virtualized rendering

* betterer

* Refactor prop
2022-08-22 13:41:05 +03:00
George Robinson
c960301aa8 Alerting: Fix links in Microsoft Teams notifications (#54003) 2022-08-22 12:08:38 +02:00
Joao Silva
ee58d4ce4b TimePicker: Fixes relative timerange of less than a day not displaying 2022-08-22 10:37:27 +01:00
eledobleefe
8cdfedc559 A11y: Update buttons in Explore page to not use HTML Title for tooltip (#53894) 2022-08-22 11:19:22 +02:00
Polina Boneva
51d173711f A11y: do not change the focus when switching between Viz/Suggestions/Library Panels views (#53814) 2022-08-22 12:12:39 +03:00
Emil Tullstedt
ce7593686d Errors: Allow using Base as an error type (#53824) 2022-08-22 11:07:33 +02:00
Takuya Kosugiyama
2ff007b266 Cloud Monitoring: Support SLO burn rate (#53710) 2022-08-22 10:11:54 +02:00
Leon Sorokin
d5cc1bfff2 TimeSeries: fix regression with hardMin + hardMax ranging (#53922) 2022-08-19 12:20:21 -05:00
Alexander Weaver
c7b93ec331 Make channels_config no longer depend on legacy alerting (#53799) 2022-08-19 11:21:02 -05:00
Ashley Harrison
0b322a0f5d fix some anys (#53789) 2022-08-19 16:46:58 +01:00
Ryan McKinley
7cbf6015db StructureRev: use deep equals for structure revision change detection (#53920) 2022-08-19 08:29:23 -07:00
Esteban Beltran
88419aa8fe Grafana/schema: Fix plugins API regression. Add back "hidden" in LegendDisplayMode (#53925) 2022-08-19 17:06:33 +02:00
Esteban Beltran
edb54fc8d3 Fix: Rename timezones prop to timezone for plugins compatibility (#53926) 2022-08-19 16:59:56 +02:00
Joao Silva
4f2d30b153 Decimals: Fixes auto decimals to behave the same for positive and negative values (#53960) 2022-08-19 15:42:34 +01:00
Ashley Harrison
b6835ef87d convert TestRuleResult to RTL (#53953) 2022-08-19 15:00:53 +01:00
Timur Olzhabayev
4ca845e479 Chore/extend plugin schema json (#53950)
* Allowing additional parameters in tokenAuth and jwtTokenAuth
2022-08-19 08:58:32 -04:00
Ashley Harrison
0550808126 use navId over navModel, add page descriptions + create pageNav for child pages (#53936) 2022-08-19 13:32:43 +01:00
sam boyer
a87c685345 coremodels: Convert plugin-metadata schema to a coremodel (#52121)
* coremodels: Convert plugin-metadata schema to a coremodel

* Newer cuetsy; try quoting field name

* Add APIType control concept, regen pluginmeta

* Use proper numeric types for schema fields
2022-08-19 12:11:13 +02:00
Joao Silva
25538c528d Grafana-UI: Changes ClipboardButton to always allow copy of multi line content (#53903) 2022-08-19 09:57:56 +01:00
Hamas Shafiq
6b1804b6c0 Tempo: Set the default query type even if queryType was set to 'clear' (#53887) 2022-08-19 09:41:39 +01:00
eledobleefe
f926020c1b Chore: Improve FolderSettingsPage test (#53601) 2022-08-19 10:25:33 +02:00
Ashley Harrison
78995e252a implement responsive breadcrumb behaviour (#53764) 2022-08-19 09:17:52 +01:00
Ryan McKinley
7755f4c4ba Inspect: show DataFrame JSON *before* transformation and field config are applied (#53867) 2022-08-18 15:06:33 -07:00
Alex Karacaoglu
9be73e758d Transforms: Allow for clearing of select fields for outer join and grouping to matrix transformations (#53916) 2022-08-18 14:19:59 -07:00
Carl Bergquist
a74681036e prometheus: upgrades http client to 1.30 (#53901)
Signed-off-by: bergquist <carl.bergquist@gmail.com>
2022-08-18 18:44:31 +01:00
Alex Karacaoglu
a3c1cd836e Transformations: Add support for an inner join transformation (#53865) 2022-08-18 10:22:45 -07:00
owensmallwood
fb40b80141 shows example of how and where to enable public dashboards in config.ini (#53904) 2022-08-18 11:13:48 -06:00
Laura Benz
f5f93ccd96 A11y: Make tabs in query history + inspector accessible in Explore (#53773)
* refactor: make tabs accesible

* refactor: make content after slider accessible

* refactor: add a comment with todo
2022-08-18 17:16:37 +02:00
Jo
4a9137ac40 API Keys: Add revocation for SATs (#53896)
* add apikey is_revoked field

* add token store tests

* Apply suggestions from code review

* remove unused fields
2022-08-18 16:54:39 +02:00
Galen Kistler
8b18530cb8 Prometheus: properly de-accumulate multi-heatmap responses (#53688)
* Implement workaround to #3373, grouping heatmaps by query before sorting prevents bug when calculating a heatmap with multiple values for the same label on the x-axis

* Group heatmap frames prior to sort by the concatenation of their values, excluding quantile (le)

* add unit tests for multiple query and multi-dimensional query

* replace final le value with more apt quartile label

* unify quantile labels

Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
2022-08-18 09:54:09 -05:00
Andreas Gerstmayr
8b22481aec User management: Use HMAC-SHA256 to generate time limit codes (password reset tokens) (#42334)
Signed-off-by: bergquist <carl.bergquist@gmail.com>
Co-authored-by: bergquist <carl.bergquist@gmail.com>
2022-08-18 16:01:09 +02:00
Yuriy Tseretyan
9f90a7b54d Alerting: State manager to use InstanceStore (#53852)
* move saving the state to state manager when scheduler stops
* move saving state to ProcessEvalResults

* add GetRuleKey to State
* add LogContext to AlertRuleKey
2022-08-18 09:40:33 -04:00
Zoltán Bedi
86de94cbfa TimeSeries: Don't show y axis when visualisation is hidden (#53671)
* TimeSeries: Don't show y axis when visualisation is hidden

* Update snapshot

* make scale ranger return nulls for minMax when no visible data exists on scale

* drop unneeded change

* remove explicit axis.show

Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
2022-08-18 09:26:40 -04:00
Jo
10e6eac632 Auth: Reduce lookup cookie error to warning and invalidate cookie (#53881)
* Reduce lookup cookie error to warning. Delete invalid cookie to avoid continuous refresh

* debug log branch
2022-08-18 09:24:31 -04:00
Victor Marin
ae69b1d99c HistogramPanel: Generate .cue model (#53826)
* Generate .cue model for histogram panel

* Docs

* Refactor PR
2022-08-18 16:19:11 +03:00
Jan Garaj
6ca7009b6c CloudWatch: Add missing AWS/Lambda metrics (#53866)
Missing metrics/dimensions for AWS/Lambda. Removed Alias dimension - it isn't mentioned by doc and I don't see that dimension in my CloudWatch. Doc: https://docs.aws.amazon.com/lambda/latest/dg/monitoring-metrics.html
2022-08-18 09:18:40 -04:00
Zoltán Bedi
ea5e58a051 BarChart/PieChart: create/update models.cue (#52988)
* Reverse engineering barchart models.cue from models.gen.ts

* Barchart models.cue and import fixes

* Add models.cue for piechart

* Use single-item syntax to dodge cuetsy bug

* Add some docs

Co-authored-by: sam boyer <sdboyer@grafana.com>
2022-08-18 14:46:36 +02:00
Leon Sorokin
329aab7395 TimeSeries: Fix memory leak on viz re-init caused by KeyboardPlugin 2022-08-18 07:09:37 -05:00
Mihály Gyöngyösi
a915977002 Teams: Add TeamRolePicker to the Create and Edit Team pages (#53775)
* Add TeamRolePicker to CreateTeam and TeamSettings pages

* Align tests to the changes

* Change TeamRolePicker

* Add useRoleOptions hook

* Clean up

* Requested changes by reviewers

* Fixes

* Fixes
2022-08-18 13:21:06 +02:00
Oscar Kilhed
eedc7f1831 Update betterer results because of #53806 (#53884) 2022-08-18 06:36:12 -04:00
linoman
52904151f1 Update open ldap for macos (#53819)
* Add new OpenLDAP Docker block for macOS

* Add preconfigured users, groups and modules

* Add README
2022-08-18 12:31:19 +02:00
Karl Persson
4ff4aaab23 RBAC: Remove builtin role code (#53767)
* remove rbacBuiltInRoleAssignmentEnabled from frontendsettings

* RBAC: Remove RBACBuiltInRoleAssignmentEnabled

* RBAC: Remove code for builtin role

* RolePicker: Remove unused prop

* RolePicker: Rename builtinRole to basicRole

* RolePicker: Rename onBuiltinRoleChange to onBasicRoleChange

* RolePicker: Rename properties
2022-08-18 12:25:37 +02:00
Phil Z
8145caf554 Fix file extension (#53838) 2022-08-18 11:21:38 +02:00
Hamas Shafiq
a6ff6cd0c1 Tempo: Remove unused theme param in getStyles (#53823) 2022-08-18 09:55:24 +01:00
Jan Garaj
fdaf6b5e8d CloudWatch: Add missing AWS/ApiGateway metrics (#53839)
Missing metrics/dimensions for WebSocket API. Doc: https://docs.aws.amazon.com/apigateway/latest/developerguide/apigateway-websocket-api-logging.html
2022-08-18 09:52:14 +02:00
Karl Persson
1b933ff3ed RBAC: Move resource permissions store to service package (#53815)
* Rename file to store

* Move resource permission specific database functions to
resourcepermissions package

* Wire: Remove interface bind

* RBAC: Remove injection of resourcepermission Store

* RBAC: Export store constructor

* Tests: Use resource permission package to initiate store used in tests

* RBAC: Remove internal types package and move to resourcepermissions
package

* RBAC: Run database tests as itegration tests
2022-08-18 09:43:45 +02:00
Jan Garaj
83f8da2e02 Update of AWS/Events (#53831)
Added missing metrics: Events, IngestionToInvocationStartLatency. Doc: https://docs.aws.amazon.com/eventbridge/latest/userguide/eb-monitoring.html
2022-08-18 08:48:01 +02:00
Oscar Kilhed
e877c1da90 Revert "BarchartPanel: Fix color from thresholds show incorrectly (#52038)" (#53806)
This reverts commit 11c79cd6da.
2022-08-18 08:47:17 +02:00
ying-jeanne
82b63688d2 Chore: remove xorm from preference (#53803)
* Chore: remove xorm from preference

* separte feature toggle

* fix comments

* fix comments

* remove the dublicated namedexec
2022-08-17 22:07:20 -04:00
Ryan McKinley
4ac87a3b3b Geomap: update the layer order in docs (#53749) 2022-08-17 15:57:52 -07:00
Artur Wierzbicki
2a0ae74f96 Live: fix StreamingDataFrame length on replace action and schema change (#53796)
* streaming-data-frame

* add more expect.length in tests
2022-08-18 00:58:38 +04:00
Christopher Moyer
070393075a updates broken relrefs (#53857) 2022-08-17 15:26:29 -05:00
Eve Meelan
59e638acb9 Legal: CLA formatting update (#53853)
* Formatting

* linter
2022-08-17 14:37:25 -05:00
Christopher Moyer
5cbc579955 fixes time-series relrefs (#53851) 2022-08-17 14:22:52 -05:00
Brendan O'Handley
085258c035 Influxdb Datasource: Remove angular dependencies for Influxdb influxql annotations (#52546)
* migrate influxQL annotations to react and build new annotation editor

* use es-lint ignore for any type in migration

* changes for PR comments

* handle annotation editor on load error without query

* correct label for ann editor query

* add null coalesce operator and remove comment

* fix tooltip
2022-08-17 13:20:46 -04:00
Jean-Philippe Quéméner
2fef8e6f2c Alerting: add docs for file provisioning (#53101) 2022-08-17 18:53:36 +02:00
ying-jeanne
c7212643c2 add sqlx_store into star service (#53430) 2022-08-17 11:17:23 -05:00
George Robinson
6d69d7acb8 Alerting: Fix notifications for Microsoft Teams (#53810)
This commit fixes notifications for Microsoft Teams where notifications
would just contain "Card" rather than the title.
2022-08-17 16:46:46 +01:00
Karl Persson
57d87389e0 RBAC: Remove user permissions in org when user is removed (#53782)
* RBAC: Add orgID to DeleteUserPermissions

* RBAC: Refactor query to delete all permissions in specified org, 0
deletes all permissions

* Delete user permission in org when user is removed

* Remove call to delete permissions in frontend

* Remove user permissions if removed orgs is detected during oauth sync

Co-authored-by: Jo <joao.guerreiro@grafana.com>
2022-08-17 16:32:02 +02:00
Gábor Farkas
6fe2d4724a devenv: elastic: update to new version (#53825) 2022-08-17 15:02:00 +02:00
Beto Muniz
d4a63aca64 InfluxDB: Remove browser ('direct' access) mode. (#53529)
* Remove InfluxDB browser ('direct' access) mode.

* Improve text usage and clarity
2022-08-17 09:40:21 -03:00
Andrej Ocenas
f30795b088 Prometheus: Throw error on direct access (#50162)
* Disable direct access

* Hide access select if Server mode is already selected

* Update docs

* Add more tests

Co-authored-by: Beto Muniz <contato@betomuniz.com>
2022-08-17 09:37:29 -03:00
Victor Marin
b5cb7738da TimeRangePicker: Absolute timeranges with timezone (#53763) 2022-08-17 13:52:21 +03:00
Victor Marin
2d391c98d2 Histogram: Fix panel hide when clicking on legend (#53651) 2022-08-17 13:40:38 +03:00
Gilles De Mey
0523eba2a9 Alerting: Read group details before saving (#53586) 2022-08-17 11:56:54 +02:00
Gilles De Mey
68f6ae5de1 Alerting: Hide "no rules" message when we are fetching from data sources (#53778) 2022-08-17 11:54:51 +02:00
sam boyer
8ef6820f06 coremodels: Remove "Model" prefix from Go types (#53801)
Using the prefix "Model" on all generated types was adding more
verbosity to already lengthy generated types. This removed that prefix,
only replacing the base generated struct with the literal "Model" to
avoid a redundant name, e.g. dashboard.Dashboard.
2022-08-17 05:42:41 -04:00
Esteban Beltran
81957732ab Chore: Replace react-inlinesvg usage for the Icon component (#53736) 2022-08-17 09:09:58 +02:00
Kat Yang
7c5ddaea58 Chore: Add loginattempt service (#53687)
* Chore: Add loginattempt service

* Inject loginattemptservice into httpserver
2022-08-17 08:34:23 +02:00
sam boyer
c23a9d78ab Actually enforce dashboard schema on devenv (#53797)
* Relocate dashboards test so it runs

* Cover newer schema versions in stripnulls

* Strip nulls and remove iteration fields

* Fix fiscalYearStartMonth bounds

* Fix up and format dashboard schema

* Update thema, tidy Go dependencies
2022-08-16 22:07:57 -04:00
ying-jeanne
25de383540 Chore: Replace xorm with sqlx (#52575)
* Change of sqlstore to use sqlx

* Use sqlx in the playlist store

* Refectory of the interface

* update playlist service

* go mod tidy

* some refectory on interface

* fix kyle
2022-08-16 13:17:14 -05:00
Hamas Shafiq
860fd83ab4 Jaeger: Remove advanced options toggle & show advanced options by default (#53774)
Jaeger: Remove advanced options toggle & show advanced options by default
Jaeger: Make the width of all labels in the search form the same
Jaeger: Fix typo in the tooltip for the "Limit" field
Chore: Re-add durationPlaceholder constant
2022-08-16 19:27:43 +02:00
idafurjes
e3501dfa4d Chore: Add Get User Profile to user and Get User Org List to org service (#53788)
* Remove delete suer from store interface

* Remove get signed in user with cache ctx from store interface

* Support options when setting up access control tests

* Fix broken tests

* Fix lint

* Add user fake to middleware

* Fix middleware tests, remove usertest being initialised twice

* Chore: Add Get User Profile to user and Get User Org List to org service

Co-authored-by: Karl Persson <kalle.persson@grafana.com>
2022-08-16 17:50:45 +02:00
Karl Persson
d1df896962 Remove unsued dep (#53785) 2022-08-16 17:33:24 +02:00
Daniel Lee
ca017e0209 Chore: update latest.json to 9.1.0 (#53786) 2022-08-16 17:07:02 +02:00
Ashley Harrison
7eab08364e Navigation: Improve responsiveness of TopSearchBar (#53777)
* remove some magic numbers + used grid for better responsiveness

* remove old responsive styles
2022-08-16 15:09:22 +01:00
idafurjes
fa2e74cd6e Chore: Remove GetSignedInUserWithCacheCtx from store interface (#53734)
* Remove delete suer from store interface

* Remove get signed in user with cache ctx from store interface

* Support options when setting up access control tests

* Fix broken tests

* Fix lint

* Add user fake to middleware

* Fix middleware tests, remove usertest being initialised twice

Co-authored-by: Karl Persson <kalle.persson@grafana.com>
2022-08-16 16:08:59 +02:00
Konrad Lalik
f3085b1cac Alerting: Improve Mimir AM interoperability with Grafana (#53396) 2022-08-16 16:01:57 +02:00
Grot (@grafanabot)
932d1b6650 ReleaseNotes: Updated changelog and release notes for 9.1.0 (#53780) 2022-08-16 15:54:14 +02:00
Gilles De Mey
fb93b60fcc Alerting: Support for re-ordering alert rules in a group (#53318)
Co-authored-by: Peter Holmberg <peterholmberg@users.noreply.github.com>
2022-08-16 14:42:02 +02:00
idafurjes
1f442b419b Chore: Remove disable user, disable batch users and searchusers methods from store interface (#53717)
* Chore: Remove disable user and searchusers methods from store interface

* Remove disable batch user from sqlstore interface

* Remove sqlstore from search store

* Fix lint
2022-08-16 14:24:57 +02:00
Gábor Farkas
549f963366 codeowners: adjust logs ownership (#53771) 2022-08-16 07:29:30 -04:00
Hamas Shafiq
3e209c06f3 Tempo: Fix typo in the tooltip for 'Limit' (#53750) 2022-08-16 06:52:44 -04:00
Ivan Ortega Alba
38c690ecb0 Revert "Analytics: Use Fullstory to get behavioral data (#53732)" (#53762)
This reverts commit 961479b111.
2022-08-16 12:45:14 +02:00
Selene
6988dcd7f5 Release Notes: Add missing report bug fixes (#53597)
* Add missing report bug fixes

* Update docs/sources/release-notes/release-notes-9-0-7.md

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>

Co-authored-by: Alex Khomenko <Clarity-89@users.noreply.github.com>
2022-08-16 06:42:33 -04:00
sh0rez
635571db8a pkg/web: remove Router and Logger from Context (#53765)
web.Context previously held references to the current *web.Router albeit
not using it.

It also had a log.Logger only being used once internally
2022-08-16 12:25:27 +02:00
Garrett Guillotte
47364ae11f fix configuration secret_key relref link (#52742)
Co-authored-by: Fabio Michelini <fabio.michelini@protonmail.com>
2022-08-16 10:57:08 +02:00
Garrett Guillotte
25e546ad21 Docs: Fix link in What's New in 9.1 (#53259) 2022-08-16 10:54:33 +02:00
Garrett Guillotte
1f692d4020 Docs: Add 9.1 to What's New index (#53545)
* Docs: Add 9.1 to What's New index

* Docs: Update docs index What's New link
2022-08-16 10:45:05 +02:00
Ivan Ortega Alba
961479b111 Analytics: Use Fullstory to get behavioral data (#53732) 2022-08-16 10:32:00 +02:00
renovate[bot]
a7dd095231 Update dependency eslint to v8.22.0 (#52723)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2022-08-16 08:44:24 +01:00
Torkel Ödegaard
c8fc840865 Fix initDashboard bug (#53722)
Co-authored-by: Erik Sundell <erik.sundell87@gmail.com>
2022-08-16 03:24:04 -04:00
sam boyer
4a5afe4fb6 openapi: Use indentations for human-readable JSON (#53707) 2022-08-15 15:39:18 -04:00
malcolmholmes
a19d82124b Build: upgrade Alpine images (#53743) 2022-08-15 18:17:55 +02:00
Zoltán Bedi
835562bb68 GeoMap: Fix tooltip not showing values (#53738) 2022-08-15 16:39:00 +02:00
Timur Olzhabayev
12381c74f4 Adding urlparams to the routes schema (#53735) 2022-08-15 15:39:50 +02:00
Isabella Siu
f39f9eb053 Cloudwatch: update redis metrics (#53618) 2022-08-15 09:09:27 -04:00
Vardan Torosyan
962bf8a906 RBAC: Remove the flag from the config which states that you can disable RBAC (#53730) 2022-08-15 14:22:04 +02:00
idafurjes
dfc75b1114 Remove delete suer from store interface (#53726) 2022-08-15 13:56:16 +02:00
Mihály Gyöngyösi
1c0ab501aa UsersTable: Display Disabled flag in Organizations' Users table (#53656)
* Add disabled column to Org's Users table

* fix typo

* Change column order

* Add test for testing whether GetOrgUsers populates the DTO correctly
* Remove type assertion
2022-08-15 10:58:58 +02:00
Karl Persson
4069fe1c39 RBAC: Update permission query to not join on team table (#53677)
* RBAC: Add teamIDs to get permission query

* RBAC: Remove join on team table and use team ids

* RBAC: Pass team ids
2022-08-15 09:41:20 +02:00
Nathan Marrs
97eec9c220 Geomap: Minor 9.1 doc fixes (#53704) 2022-08-12 20:45:33 -07:00
Drew Slobodnjak
e9e5c97807 Geomap: Update language to match documentation and remove beta (#53703)
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2022-08-12 21:33:30 -04:00
Nathan Marrs
0362ab131e Geomap: Update whats new docs for 9.1 (#53634)
Co-authored-by: Garrett Guillotte <100453168+gguillotte-grafana@users.noreply.github.com>
2022-08-12 15:58:01 -07:00
Drew Slobodnjak
ef24453b9b Geomap: Update Documentation (#53552)
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
Co-authored-by: Christopher Moyer <35463610+chri2547@users.noreply.github.com>
Co-authored-by: Nathan Marrs  <nathanielmarrs@gmail.com>
2022-08-12 15:37:10 -07:00
Alexander Weaver
f093c249ac Alerting: Fix incorrect embedded DTO being returned when handling rule groups (#53701)
* Fix DTO embedding when getting/putting alert rule groups

* Drop usage of word 'Domain'

* Rename var as well
2022-08-12 16:36:50 -05:00
Nathan Marrs
a19b3136c9 Geomap: Add devenv dashboard for v9.1 of geomap (#53638) 2022-08-12 14:30:55 -07:00
Eve Meelan
a0cbe548fe replace relrefs with URLs (#53686) 2022-08-12 13:10:07 -07:00
Alexander Weaver
ccd41df603 Fix order-of-magnitude bug in DTO conversion (#53690) 2022-08-12 15:02:40 -05:00
Kat Yang
943cdea855 Chore: Add tempuser service (#53325)
* Chore: Add tempuser service

* Add implementation

* Fix linter; Inject tempUser into wire and HTTPServer

* Fix errors
2022-08-12 12:13:23 -04:00
Kim Nylander
101c087fc7 [Doc] Added link to APM dashboard doc for Service graph Tempo data source doc (#53491)
* Added link to APM dashboard doc

* Apply suggestions from code review
2022-08-12 08:46:28 -07:00
Leo
0ce89dbcb6 use dash-db type when searching for dashboard (#53607) 2022-08-12 16:14:04 +02:00
Eric Leijonmarck
dc8eb0b777 Print package error message for deprecated io/ioutil (#53665)
* Add: package error message for io/util

* added a ioutil for testing ci

* Revert "added a ioutil for testing ci"

This reverts commit 8c324ccf8a.

* removed spaces
2022-08-12 09:57:42 -04:00
Yuriy Tseretyan
d8d97d15ba Alerting: AlertingProxy to elevate permissions for request forwarded to data proxy when RBAC enabled (#53620) 2022-08-12 09:56:18 -04:00
Andreas Christou
d6a0a5c9ed Set projectName in componentDidMount to ensure GCE project is set (#53652)
- Update componentDidMount to call ensureGCEDefaultProject to correctly set project name for GCE Service Account auth
- Set state appropriately
- Update test
2022-08-12 14:54:19 +01:00
Andreas Christou
cace6f06d1 Fix webpack issue (#53666) 2022-08-12 13:53:35 +00:00
Eric Leijonmarck
cac3833b8e Auth: Add cli command users-manager for conflict resolution (#52344)
* add users-manager command

* add users-manager command

* rename files

* refactor: imports and renaming

* Command: add conflict merge user command

- MergeUser will
	- replace all user_ids from conflicting users to the chosen userId
	- delete users whose user_ids are not the chosen user
- SameIdentification will
	- update chosen user with chosen email,login details
	- delete users whose user_ids are not the chosen user

* refactor: clean up

* refactor: create structure for read, validate, ingest

* feat: ls and generate-file for conflicting users

* remove usagestats

* added back pkg/services/login/authinfoservice/database/stats.go

* Revert "added back pkg/services/login/authinfoservice/database/stats.go"

This reverts commit 2ba6e3c4d6.

* Revert "remove usagestats"

This reverts commit 1e3fa97810.

* cherry pick

* Revert "cherry pick"

This reverts commit 461626c306.

* fix test

* make lint

* make test run

* clean up and refactored to align with downstream refactoring

* formatting

* refactor: name list instead of ls

* fix: static lint error use trimprefix

* fix: remove unused functions in sqlstore

* fix: remove unused function

* handling of multiple users and resolve discarded users

* fix tests

* fix: bug that did not exclude the blocks

* ioutil is blacklisted

* should not run tests for mysql

* fix tests
2022-08-12 14:47:31 +01:00
Emil Tullstedt
cc777e175e Chore: Panic! in the Logs (#53664) 2022-08-12 13:43:16 +00:00
Sonia Aguilar
f416651842 Show alerting availability in data source details (#53391)
* Show alerting availability in data source details

* Show tooltip info in data source dropdown when creating an alert

* return earlier in HeaderExtras component

* Use getDataSourceSrv().getInstanceSettings instead of getDataSourceSrv().get to simplify

* Make information icon clickable and open a new window with documentation url
2022-08-12 15:32:07 +02:00
Ivana Huckova
fde5147d71 Loki, Prometheus: Fix passing of query with defaults to code mode (#53646) 2022-08-12 15:00:55 +02:00
Ivana Huckova
f34a03b2f1 Loki: Rename Labels to Label filter and update placeholders (#53446)
* Loki: Rename Labels to Label filter and update placeholders

* Update label

* Replace Label filter with Label filters based on suggestion
2022-08-12 07:38:34 -04:00
Karl Persson
91ef08de68 RBAC: Remove unused code (#53649) 2022-08-12 13:02:24 +02:00
idafurjes
0a2a8bc919 Chore: Add user methods to service (#53595) 2022-08-12 12:13:26 +02:00
Alex Khomenko
7944f3a692 ColorPickerInput: Enable input clearing (#53587)
* ColorPickerInput: Enable removing selected color

* ColorPickerInput: Add tests

* ColorInput: Add isClearable prop
2022-08-12 13:07:24 +03:00
Andreas Christou
d4f382892d CloudMonitor: Fix to hide queries when used in conjunction with Expressions (#53537)
* Correctly pass all original query parameters on interpolation

* Add datasource tests

- Update props on mock query
- Add mock instance settings
- Add util function to generate template variables
- Add datasource test file
- Correct setting of templateSrv
- Update betterer results

* Simplify test and pass templateSrv appropriately

* Fix lint issue

* Simplify test and add type that supports parital nested objects

* Update test and remove unneeded util function

* Rename to avoid duplicate mock
2022-08-12 11:02:56 +01:00
Maria Alexandra
2b5d12310a Docs: Fix missing reference update on dashboard page (#53641) 2022-08-12 09:49:46 +02:00
Mihály Gyöngyösi
57a46767cd AccessControl: Move GetCacheKey to SignedInUser (#53591)
* Add HasUniqueId and IsApiKeyUser to SignedInUser

* Improve GetCacheKey by explicit checks and error branch

* Align SignedInUser to merged changes

* change comparison method

Co-authored-by: jguer <joao.guerreiro@grafana.com>
2022-08-12 09:47:47 +02:00
Karl Persson
7e16d5b4b4 RBAC: Fix various ui issues for role picker (#53589)
* RolePicker: Check if user has permissions to delegate roles

* UserRolePicker: Require both UserRolsAdd and UserRolesRemove for chaning
roles

* RolePicker: Add option for controlling if roles can be updated to
RolePicker

* UserOrgs: Dont try to fetch roles with wrong permission

* RolePicker: make usage consistent with allowed actions

* RolePickerMenu: Remove unused property

* UserOrgs: Check for correct permission

* UserRolePicker: add apply to controll apply behaviour instand of
updateDisabled

* UserOrgs: Check for correct permission when trying to update roles

* RolePicker: Disable button if no roles or org role can be updated

* RolePicker: Always close on update

* RolePicker: Fix issue with updating immutable value

* ServiceAccountsListItem: Pass correct value to RolePicker

* ServiceAccountCreatePage: Pass correct value
2022-08-12 09:16:16 +02:00
Christopher Moyer
01bb83853c docs: refactor work, combines time-series topics (#53530)
* combines time-series topics

* makes prettier

* Progress on new time series docs

* Move annotation docs to dashboard annotation topic, simplify and update text for axis docs and color scheme docs

* Minor tweaks

* Move titles from shared files into the topic and add some intro paragraphs

* Fix double axis headings

* Test new image

* starts copyedit

* copy edit

* Update docs/sources/visualizations/time-series/index.md

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

* Update docs/sources/visualizations/time-series/index.md

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

* fixes typos

* adjust path to images

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
2022-08-12 08:20:23 +02:00
Jean-Philippe Quéméner
7f0002448d Alerting: use duration model for alert rule provisioning api (#53196) 2022-08-12 00:58:02 +02:00
Jean-Philippe Quéméner
e14c91d5d4 Alerting: fetch interval from stored namespace UID (#53195) 2022-08-12 00:54:57 +02:00
Jean-Philippe Quéméner
8c5f5e7a32 Alerting: create provisioning dir in docker image (#53594) 2022-08-12 00:16:02 +02:00
Yuriy Tseretyan
e3da9da51d update alertmanager to 0.24 (#53555) 2022-08-11 17:54:32 -04:00
Adela Almasan
1f93216f1d Layers check (#53611) 2022-08-11 17:39:18 -04:00
Giordano Ricci
6b84dddee8 Fix build error (#53615) 2022-08-11 15:21:37 -04:00
Gilles De Mey
e9980a9bb8 Alerting: Adds interval and For to alert rule details (#53211) 2022-08-11 18:49:21 +02:00
Andre Pereira
1216e70b08 Fix devenv tempo port (#53605) 2022-08-11 17:17:21 +01:00
Matias Chomicki
8d69acb9f8 Chore(loki): remove any from LokiQueryField test (#53548) 2022-08-11 18:08:23 +02:00
Matias Chomicki
df8d1de94f Chore(loki): remove any from config editor test (#53475) 2022-08-11 18:08:05 +02:00
Giordano Ricci
c1b30c56c9 Correlations: Add GetCorrelation(s) HTTP APIs (#52517)
* Correlations: Get Single correlations

* Correlations: Get all correlations for given source ds

* Correlations: Get all correlations

* add tests

* add DB indices

* fix lint errors

* remove skip from tests

* use DatasourceService in test
2022-08-11 16:58:11 +01:00
Ivana Huckova
8813cbfb62 Loki: Update copy for missing label filter error message (#53449)
* Loki: Update copy for missing label filter

* Update
2022-08-11 17:57:10 +02:00
Hamas Shafiq
6592b03f12 Jaeger: Extract inline CSS into getStyles 2022-08-11 16:41:59 +01:00
Ashley Harrison
6cdeeeda3c remove UseState from last 2 stories (#53596) 2022-08-11 16:28:22 +01:00
Hamas Shafiq
20caed026f Jaeger: Improve JSON file upload error msg 2022-08-11 16:23:19 +01:00
Maria Alexandra
6ec5e7b998 Docs: Update dashboard documentation, including new search (#53050)
Co-authored-by: Chris Moyer <chris.moyer@grafana.com>
2022-08-11 17:18:52 +02:00
malcolmholmes
0ac85c8169 Build: fix shellcheck (#53602) 2022-08-11 16:13:41 +01:00
Andres Martinez Gotor
a31d96d20a Prometheus: Promote Azure auth flag to configuration (#53447) 2022-08-11 16:12:57 +02:00
zhichli
806fb8ab7a Tracing: Fix OpenTelemetry Jaeger context propagation (#53269)
* fix otel jaeger context propagation

* add back launch.json

* add back launch.json
2022-08-11 16:11:34 +02:00
Josh Hunt
44ea98b24f Chore: Ignore type assertions in __mocks__ (#53593) 2022-08-11 14:06:15 +00:00
timkendrickmw
85dbacafdb GrafanaUI: improve Prometheus getQueryHints performance (#52148) 2022-08-11 15:47:07 +02:00
Karl Persson
c08fe3a53c RBAC: Enable rbac when creating new settings (#53531)
* Settings: Set RBACEnabled to true by default

* Remove accessControlEnabledFlag and explicitly set to false when needed

* Disable rbac for tests
2022-08-11 15:37:31 +02:00
Jack Westbrook
b1ce721cf1 Levitate: Update workflow to find type declaration via package.json (#53539)
* refactor(breaking-changes): make sure to pack and zip tarballed packages before artifact upload

* feat(check-breaking-changes): support extracting npm package tarballs before comparing packages

* chore(breaking-changes): fix typo preventing upload of pr_built_packages.zip
2022-08-11 15:17:51 +02:00
idafurjes
da72a4ed2e Chore move Filter to user service (#53588) 2022-08-11 14:45:29 +02:00
idafurjes
a14621fff6 Chore: Add user service method SetUsingOrg and GetSignedInUserWithCacheCtx (#53343)
* Chore: Add user service method SetUsingOrg

* Chore: Add user service method GetSignedInUserWithCacheCtx

* Use method GetSignedInUserWithCacheCtx from user service

* Fix lint after rebase

* Fix lint

* Fix lint error

* roll back some changes

* Roll back changes in api and middleware

* Add xorm tags to SignedInUser ID fields
2022-08-11 13:28:55 +02:00
Jo
ca72cd570e Remove ioutil.ReadDir from usage (#53550)
* add depguard rule for ioutil

* replace ioutil.ReadDir with os.ReadDir

* use legacy option in depguard supported in golangci-lint v1.40

* replace ioutil.ReadDir with os.ReadDir

* return error for file info
2022-08-11 07:21:12 -04:00
Alex Khomenko
b42f3e2c4c A11y: Create Minimal Styleguide (#46948)
* First draft of the guide

* Fix Select part

* Move a11y PR guidelines

* Update contribute/create-pull-request.md

Co-authored-by: Maria Alexandra <239999+axelavargas@users.noreply.github.com>

Co-authored-by: Maria Alexandra <239999+axelavargas@users.noreply.github.com>
2022-08-11 14:00:38 +03:00
Dimitris Sotirakis
332bc3aa63 CI: Split store-packages step (#53516)
* Remove unused def

* Add grafanacom step
2022-08-11 05:31:35 -04:00
Dimitris Sotirakis
fa4abdcce1 Grafana Build: Sync Grafana versioning changes from build-pipeline (#53522)
* Sync version changes

(cherry picked from commit fb449ba0376cd7d86928e8b08ef77a851488604b)

Sync version refactoring changes

* Update grabpl
2022-08-11 11:44:59 +03:00
Ivan Ortega Alba
6423485061 Preferences: Use search endpoint to get missing dashboard (#53540) 2022-08-11 10:34:01 +02:00
Serge Zaitsev
72367f99cf Chore: Move plugin settings store code into a dedicated service (#53560) 2022-08-11 09:50:53 +02:00
Zoltán Bedi
818bc88242 MSSQL: Don't inject angular dependency (#53546) 2022-08-11 09:43:20 +02:00
Yaelle Chaudy
dfe33a63fb Datasources: Emit event on dashboard load with queries info (#52052)
Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>
Co-authored-by: Andres Martinez <andres.martinez@grafana.com>
2022-08-11 09:30:14 +02:00
Levente Balogh
d7556bd189 fix: use type instead of uid to get datasource metadata (#53543) 2022-08-11 07:24:39 +02:00
Guilherme Caulada
7554322327 Fix middleware tests for public dashboards (#53557) 2022-08-10 17:12:25 -04:00
Guilherme Caulada
7924d3b3b5 Secrets: Move license check to secret store plugin (#53185)
* Move license check to secret store plugin

* Use shouldUseRemoteSecretsPlugin for migration

* Encapsulate plugin startup logic in sync.Once

* Remove global logger from startup functions

* Fix issues with wire and secrets plugin check

* Remove todo for plugin fatal error

* Rename fatalErr variable to be less confusing

* Fix merge conflicts

* Fix issue with grafana-cli wire and opentsdb

* Remove duplicated import on remote plugin

* Rename plugin check in favor of error return value

* Remove unnecessary import on grafana-cli wireexts_oss

* Remove unnecessary import on grafana wireexts_oss

* Reset sync.Once during test setup

* Remove unrelated opentsdb change on grafana-cli wire

* Readd opentsdb change on grafana-cli wire
2022-08-10 16:47:03 -03:00
lean.dev
92d0420a45 Adding logs during migration of secrets to plugin (#53426) 2022-08-10 16:23:55 -03:00
George Robinson
5e1d628f21 Alerting: Use Adaptive Cards in Teams notifications (#53532)
This commit changes the cards in Teams notifications from Office 365
Connector cards to Adaptive Cards to fix an issue where images were not
shown in Teams for desktop and web. Since Office 365 Connector cards
are deprecated, it made sense to move to Adapative Cards and fix this
bug at the same time.

The Adaptive Card messages maintain the design of the Office 365
Connector Card with a number of minor differences:

- In Adaptive Card messages the color of the title is red or green
  depending on the status of the alerts, where as with Office 365
  connector cards there was a colored border at the top of the title

- In Adaptive Card messages the title is bold to make it easier to read
  when the color is red or green

- In Adaptive Card messages the thumbnails for images are medium size
  if there are more than two images, otherwise large size
2022-08-10 19:51:20 +01:00
Alexander Weaver
b198559225 Alerting: Extend PUT rule-group route to write the entire rule group rather than top-level fields only (#53078)
* Wire up to full alert rule struct

* Extract group change detection logic to dedicated file

* GroupDiff -> GroupDelta for consistency

* Calculate deltas and handle backwards compatible requests

* Separate changes and insert/update/delete as needed

* Regenerate files

* Don't touch the DB if there are no changes

* Quota checking, delete unused file

* Mark modified records as provisioned

* Validation + a couple API layer tests

* Address linter errors

* Fix issue with UID assignment and rule creation

* Propagate top level group fields to all rules

* Tests for repeated updates and versioning

* Tests for quota and provenance checks

* Fix linter errors

* Regenerate

* Factor out some shared logic

* Drop unnecessary multiple nilchecks

* Use alternative strategy for rolling UIDs on inserted rules

* Fix tests, add back nilcheck, refresh UIDs during test

* Address feedback

* Add missing nil-check
2022-08-10 12:33:41 -05:00
owensmallwood
dc23643bee Public Dashboards: Usage Insights (#52768) 2022-08-10 14:14:48 -03:00
Christopher Moyer
5e4d5eb14b updates whats new version number and link (#53541) 2022-08-10 10:22:01 -05:00
Christopher Moyer
f96a72d3ec Docs/refactors configure panels (#53485)
* updates prose

* updates prose and relrefs

* incorporates feedback

* moves repeating rows to add and organize panels; fixes relrefs
2022-08-10 10:18:04 -05:00
Josh Hunt
081d6e9d3e Typed variables pt5: Remove generics from getInstanceState (#53018)
* wip

* make diff easier to read

* Update template_srv getVariables to return new TypedVariableModel

* update VariableType to use the type from TypedVariableModel

* tidy things up

* Chore: Use type-accurate mock variables in tests

* Chore: Type VariableState to use TypedVariableModel

* fix typo

* remove type assertion from template_srv.getVariables

* use typescript/no-redeclare for compatibility with ts overloads

* remove generics from getVariable() and overload it to only return undefined based on arguments

* update usages of getVariable()

* Remove generic from getInstanceState

* update usages of getInstanceState

* fix lint
2022-08-10 16:06:49 +01:00
Ashley Harrison
f32c0058a1 remove UseState from legacy Select story (#53519) 2022-08-10 15:30:02 +01:00
Kevin Minehart
d117689aea CI: move grabpl build-frontend from grabpl to grafana (#53073)
* move grabpl build-frontend
2022-08-10 10:29:51 -04:00
ismail simsek
435aaf81d2 Chore: update latest.json to 9.0.7 (#53533) 2022-08-10 14:28:41 +00:00
Josiah (Jay) Goodson
7d7890e23c Transform: Add a limit transform (#49291)
* Add a limit transform

* Add a limit transform

* Simplify filter code

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
2022-08-10 07:21:11 -07:00
Jo
062d255124 Handle ioutil deprecations (#53526)
* replace ioutil.ReadFile -> os.ReadFile

* replace ioutil.ReadAll -> io.ReadAll

* replace ioutil.TempFile -> os.CreateTemp

* replace ioutil.NopCloser -> io.NopCloser

* replace ioutil.WriteFile -> os.WriteFile

* replace ioutil.TempDir -> os.MkdirTemp

* replace ioutil.Discard -> io.Discard
2022-08-10 15:37:51 +02:00
Leo
4926767737 Dashboard: Reverted the changes of hiding multi-select and all variable in the datasource picker (#53521)
* REVERT PanelEdit: Hide multi-/all-select datasource variables in datasource picker, PR 52142

* user essentials mob! 🔱

lastFile:public/app/features/dashboard/dashgrid/PanelChrome.tsx

* user essentials mob! 🔱

lastFile:public/app/features/dashboard/dashgrid/PanelChrome.tsx

* removed todo comments

Co-authored-by: polinaboneva <polina.boneva@grafana.com>
Co-authored-by: Joao Silva <joao.silva@grafana.com>
Co-authored-by: eledobleefe <laura.fernandez@grafana.com>
2022-08-10 15:30:00 +02:00
lean.dev
07681a737d Add LockExecuteAndRelease method to ServerLockService (#53417) 2022-08-10 10:28:25 -03:00
Serge Zaitsev
6e4b537ba6 Chore: Remove datasources from the Store interface (#53515) 2022-08-10 15:04:51 +02:00
Grot (@grafanabot)
86030493a8 ReleaseNotes: Updated changelog and release notes for 9.0.7 (#53524) 2022-08-10 08:57:57 -04:00
Ashley Harrison
26e81cad21 Add tests for Breadcrumbs (#53514) 2022-08-10 12:56:25 +01:00
Ashley Harrison
e51c80f8dd Storybook: remove UseState from ButtonSelect story (#53509)
* remove UseState from ButtonSelect story

* leave this type assertion for now
2022-08-10 07:00:19 -04:00
Ashley Harrison
aaccb592cc remove UseState from Drawer story (#53503) 2022-08-10 11:40:33 +01:00
Dimitris Sotirakis
e9fe9a25dc Run docs pipeline on *.md changes only, in the packages dir (#53517) 2022-08-10 13:39:56 +03:00
idafurjes
6afad51761 Move SignedInUser to user service and RoleType and Roles to org (#53445)
* Move SignedInUser to user service and RoleType and Roles to org

* Use go naming convention for roles

* Fix some imports and leftovers

* Fix ldap debug test

* Fix lint

* Fix lint 2

* Fix lint 3

* Fix type and not needed conversion

* Clean up messages in api tests

* Clean up api tests 2
2022-08-10 11:56:48 +02:00
Kirchen99
46004037e2 Dashboard: Support Variables in "Filter by Name" Transformation (#51804) 2022-08-10 10:54:40 +01:00
Matias Chomicki
9b1e1d67cc Chore(devenv): remove unsupported elasticsearch versions (#53470) 2022-08-10 11:13:39 +02:00
Selene
119ce90234 Allow empty value in kv_store (#53416) 2022-08-10 10:48:14 +02:00
Leo
c4984854b6 added dashboard uid when tracing header in browsermode (#53232) 2022-08-10 10:36:19 +02:00
Karl Persson
aa484a60c9 RBAC: Fix dashboard filter in SQLBuilder (#53379)
* Reuse DasbhoardPermissionFilter

*  Use rbac dashboard filter if enabled
2022-08-10 10:32:03 +02:00
Ashley Harrison
6d495a6a8e Navigation: Improve breadcrumb accessibility (#53471)
* refactor breadcrumbs into their own folder, add appropriate accessibility

* rename Breadcrumb to BreadcrumbItem
2022-08-10 09:24:21 +01:00
Jo
1f8b1eef75 SAML: Do not SAML SLO if user is not SAML authenticated (#53418)
* Only SLO user if the user is using SAML

* only one source of truth for auth module info

* ensure SAML is also enabled and not only SLO

* move auth module naming to auth module login package

* use constants in other previously unused spots
2022-08-10 10:21:33 +02:00
Jo
09c95bc31f TeamSync: Fix team syncing out of orgs mapped by auth method (#53257) 2022-08-10 10:20:23 +02:00
Matej Kubinec
bca8a5d153 Grafana UI: Add implicit submit to TimeRangeForm for A11y (#52647) 2022-08-10 10:00:02 +02:00
Ashley Harrison
d38e86f3a6 Storybook: add controls support + remove UseState from RelativeTimeRangePicker story (#53459)
* add controls support + remove UseState from RelativeTimeRangePicker story

* don't need this displayName

* exclude onChange
2022-08-10 08:55:22 +01:00
Ivan Ortega Alba
742686bab1 Library Panels: Use UIDs to list Dashboards using a panel (#53477) 2022-08-10 03:43:09 -04:00
Kian Eliasi
e3c50f0cd6 Chore: Remove any from public/app/plugins/datasource/elasticsearch/hooks/useNextId.test.tsx (#53427)
* Remove any from public/app/plugins/datasource/elasticsearch/hooks/useNextId.test.tsx

* Fix lint and update betterer results
2022-08-10 09:25:35 +02:00
Joey Tawadrous
9fbebc7550 Update codeowners (#53381) 2022-08-10 08:04:37 +01:00
Joey Tawadrous
f9576ad137 Update add to project urls (#53384) 2022-08-10 08:03:48 +01:00
Adela Almasan
45750da667 Geomap: Set markers color based on selected color field #53493 2022-08-09 15:42:37 -07:00
Christopher Moyer
ffb4aba214 updates aliases (#53488) 2022-08-09 14:59:05 -05:00
Christopher Moyer
acae736796 moves legend to visualizations, adds links (#53486) 2022-08-09 14:41:41 -05:00
linoman
9f749eead7 Fix cloak typo (#53474) 2022-08-09 17:38:49 +02:00
Mihály Gyöngyösi
3ac4415d6d Devenv: Universal jwt_proxy environment (#53377)
* change hostname to env.grafana.local to not collide with any custom host.docker.internal settings
* add WSL2 documentation
* update general documentation
* cleanup
2022-08-09 17:02:36 +02:00
Ashley Harrison
e73e3cac11 add controls support + remove UseState from WeekStartPicker.story.tsx (#53455) 2022-08-09 16:00:39 +01:00
Peter Holmberg
509e34cfe7 Alert list panel: Add view mode "Stat" (#53281)
* add stat mode

* remove unused import
2022-08-09 16:37:09 +02:00
George Robinson
196b781c70 Alerting: Delete expired images from the database (#53236)
This commit adds a DeleteExpiredService that deletes expired images from the database. It is run in the periodic collector service.
2022-08-09 15:28:36 +01:00
sh0rez
adbb789877 pkg/web: detect Hijack() as chain write (#53466) 2022-08-09 16:04:21 +02:00
kay delaney
96403236cb Chore: Further reduce usage of v1 theme (#53423) 2022-08-09 14:58:32 +01:00
kay delaney
f4a5e034b3 LibraryPanels: Rewrite invalid connection deletion query to be MySQL-friendly (#53460)
Closes #53456
2022-08-09 14:55:36 +01:00
Karl Persson
e4c45c4f98 RBAC: Remove sort and unique values when fetching permissions (#53461)
* RBAC: remove sort and unique values for fetching permissions
2022-08-09 15:52:14 +02:00
Matias Chomicki
27e2953951 Loki: Rewrite getHighlighterExpressionsFromQuery to use Loki parser (#53316)
* refactor(loki): use Loki parser in getHighlighterExpressionsFromQuery

* fix(highlighter): update regex to properly identify term quotes

* refactor(highlighter): determine quote type by string comparison

* Chore: remove empty line
2022-08-09 15:23:14 +02:00
Dimitris Sotirakis
d638cd4fd7 Trigger test release on pkg/cmd/** changes (#53448) 2022-08-09 08:21:09 -05:00
Ivana Huckova
ab739bf0e6 Collapse: Fix miss-aligned arrow icon (#53452) 2022-08-09 15:05:10 +02:00
sh0rez
534ece064b pkg/web: closure-style middlewares (#51238)
* pkg/web: closure-style middlewares

Switches the middleware execution model from web.Handlers in a slice to
web.Middleware.
Middlewares are temporarily kept in a slice to preserve ordering, but
prior to execution they are applied, forming a giant call-stack, giving
granular control over the execution flow.

* pkg/middleware: adapt to web.Middleware

* pkg/middleware/recovery: use c.Req over req

c.Req gets updated by future handlers, while req stays static.

The current recovery implementation needs this newer information

* pkg/web: correct middleware ordering

* pkg/webtest: adapt middleware

* pkg/web/hack: set w and r onto web.Context

By adopting std middlewares, it may happen they invoke next(w,r) without
putting their modified w,r into the web.Context, leading old-style
handlers to operate on outdated fields.

pkg/web now takes care of this

* pkg/middleware: selectively use future context

* pkg/web: accept closure-style on Use()

* webtest: Middleware testing

adds a utility function to web/webtest to obtain a http.ResponseWriter,
http.Request and http.Handler the same as a middleware that runs would receive

* *: cleanup

* pkg/web: don't wrap Middleware from Router

* pkg/web: require chain to write response

* *: remove temp files

* webtest: don't require chain write

* *: cleanup
2022-08-09 14:58:50 +02:00
Victor Marin
3893c46976 Histogram: Send proper dataframe to PlotLegend (#53284)
* Send proper dataframe to PlotLegend

* Update dataFrameFieldIndex for multiple frames
2022-08-09 15:39:42 +03:00
Ashley Harrison
8185b6fdf7 refactor component to be more dumb, use LinkButton for icons and fix alignment (#53383) 2022-08-09 11:46:27 +01:00
Ashley Harrison
25c7dc9151 Add controls support + remove UseState from TimeRangePicker.story.tsx (#53376) 2022-08-09 11:20:03 +01:00
Andrew Grangaard
109f821abf Query Builder: Fix spelling of "lose" in user visible message (#53435)
* Fix spelling of "lose" in user visible message

* Fix spelling of "lose"
2022-08-09 10:59:17 +02:00
lai
8f9a372ce2 Access Control: optimize GetUserPermissions sql (#53279)
* Access Control: optimize GetUserPermissions sql
2022-08-09 10:40:22 +02:00
Dimitris Sotirakis
bf30976200 Change from arm to armv7 (#53437) 2022-08-09 04:20:45 -04:00
Alex Ratner
fecf4c41ad Dashboard: Spelling corrections in end-user visible dialogs (#53340) 2022-08-09 10:19:30 +02:00
Karl Persson
592d31e617 RBAC: Handle case when folder id is negative (#53438) 2022-08-09 04:14:08 -04:00
Kevin Minehart
59ce564d49 CI: move grabpl build-docker from grabpl to grafana (#53077)
* add grabpl build-docker
2022-08-09 09:43:28 +03:00
linoman
ed5dac7a75 Fix groups and useres indentation (#53414) 2022-08-09 08:05:15 +02:00
Brendan O'Handley
7aeb8b4cdf Prometheus: Remove metadata endpoint (#53428)
* remove prom metadata endpoint until we have a fix for detecting versions and implementations

* fix linting issue
2022-08-08 18:37:12 -04:00
sam boyer
e6903582d0 coremodels: Include nested optional fields in output (#53355) 2022-08-08 21:48:21 +00:00
Seth Falco
a8666370be fix: add promql placeholder text (#53321) 2022-08-08 19:11:45 +02:00
Dimitris Sotirakis
499cac44e3 Remove packages-bucket arg (#53421) 2022-08-08 13:05:26 -04:00
matt abrams
d69457d5e5 revise to match docs (#53354) 2022-08-08 18:49:54 +02:00
Dimitris Sotirakis
c472726083 Change base image for npm storage (#53419) 2022-08-08 12:43:44 -04:00
Brendan O'Handley
85db523dd5 Graphite Plugin: fix annotation migration regression with ref-ids (#53361)
* fix regression with ref-ids

* remove duplicate check for annotations in fix
2022-08-08 12:32:35 -04:00
ying-jeanne
ba89471598 Chore: Enable ANSI_QUOTES for Mysql Database (#53277)
* remove the quote dialect

* add environment variable
2022-08-08 12:14:17 -04:00
Dimitris Sotirakis
732c22ed02 CI: Update grabpl to v3.0.1 (#53369)
* Update grabpl to v3.0.0

* Update to v3.0.1
2022-08-08 12:08:55 -04:00
ying-jeanne
af09638a0d remove the sqlstore playlist methods (#53415) 2022-08-08 11:06:06 -05:00
eledobleefe
9930fd522d Chore: convert DashboardGrid test to RTL (#53405) 2022-08-08 17:43:35 +02:00
kay delaney
1772bd4238 Chore: Reduce usage of v1 theme (#53245) 2022-08-08 16:37:06 +01:00
Kevin Minehart
d1d237f30a CI: move grabpl shellcheck from grabpl to grafana (#53076)
* add grabpl shellcheck

* grabpl shellcheck -> ./bin/build shellcheck
2022-08-08 10:36:13 -05:00
Ezequiel Victorero
7f43839813 Chore: disable flaky e2e test (#53408)
* Chore: disable flaky e2e test
2022-08-08 11:34:59 -04:00
linoman
82d35b7d72 Change LDAP configuration to secure connections (#53404) 2022-08-08 17:27:22 +02:00
Gilles De Mey
f0594ebace Alerting: Fix alert detail layout issue (#53256) 2022-08-08 16:57:34 +02:00
kay delaney
c2d3b45bf4 Chore: Make "why-did-you-render" a dynamic import (#53121) 2022-08-08 15:33:49 +01:00
Ashley Harrison
f1295e4bd0 Chore: Update version of @grafana/eslint-config (#53403)
* use let/const over var

* use new version of @grafana/eslint-config
2022-08-08 15:19:15 +01:00
Grot (@grafanabot)
ff8d96602a ReleaseNotes: Updated changelog and release notes for 8.5.10 (#53395) 2022-08-08 15:16:29 +02:00
Ivana Huckova
84b2498150 Loki: Fix showing of unusable labels field in detected fields (#53319)
* Loki: Fix showing of labels field in detected fields

* Create reusable createlogRow mock
2022-08-08 14:27:33 +02:00
Dimitris Sotirakis
ee8966344d Replace with anonymoud functions (#53386) 2022-08-08 08:09:52 -04:00
Josh Hunt
aee2856907 Fix: correct bold, italics, and code color in Panel tooltips (#53380) 2022-08-08 07:10:42 -04:00
Matias Chomicki
6f01930e9d Chore: remove any from test (#53260) 2022-08-08 11:26:12 +02:00
Leo
64967325b2 Search: Migrated impressions to use dashboardUID (#53090)
* used dashboarduid in impressions

* handle scenario to convert all ids saved in storage to uids
2022-08-08 11:13:19 +02:00
Jo
beb3cb9abe Oauth: Reduce error scope on upsert (#53242) 2022-08-08 10:58:10 +02:00
ismail simsek
a40c1e227c Prometheus: Use lezer-promql types instead of hardcoded strings (#53287)
* Prometheus: Use lezer-promql types instead of hardcoded strings

* Update comment line

* Removing more hardcoded values
2022-08-08 10:14:12 +02:00
Ashley Harrison
2fea3f0d9a BarGauge: Show empty bar when value, minValue and maxValue are all equal (#53314)
* prevent returning NaN from getValuePercent

* return 0 instead of NaN always
2022-08-08 09:11:46 +01:00
Teddy Lin
42f9a6e67b Azure Monitor: Add Network Insights Dashboard (#50362) 2022-08-08 09:38:23 +02:00
Josh Hunt
fbc48d68f1 E2E: Make Cypress recordings higher res + quality (#53342) 2022-08-08 09:54:00 +03:00
Krzysztof Dąbrowski
2dab7ad890 Login: allow basic users to reset password when LDAP or Auth Proxy is enabled (#52331) 2022-08-08 05:12:39 +00:00
Kat Yang
62b4dbf52f Chore: Remove pluginsettings methods from store and mockstore (#53347) 2022-08-05 12:26:39 -04:00
Josh Hunt
4b4d546e32 Typed variables pt4: Remove generics from getVariable (#53017)
* wip

* make diff easier to read

* Update template_srv getVariables to return new TypedVariableModel

* update VariableType to use the type from TypedVariableModel

* tidy things up

* Chore: Use type-accurate mock variables in tests

* Chore: Type VariableState to use TypedVariableModel

* fix typo

* remove type assertion from template_srv.getVariables

* use typescript/no-redeclare for compatibility with ts overloads

* remove generics from getVariable() and overload it to only return undefined based on arguments

* update usages of getVariable()

* Fix Interval variable options picker not working
2022-08-05 13:44:52 +01:00
Yuriy Tseretyan
4090e122f8 Alerting: Remove mention of host name from Alerting HA docs (#53178) 2022-08-05 08:41:37 -04:00
Ieva
b590c1c60f Access Control: Set permissions for Grafana's test data source (#53247)
* set permissions for Grafana's test data source

* linting
2022-08-05 10:19:50 +03:00
Drew Slobodnjak
64721bfa94 Geomap: Do not show markers with empty coordinates (#53330)
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2022-08-04 21:17:32 -04:00
Timur Olzhabayev
2107652c3f Docs: Adding hint about healthcheck not being mandatory (#53308) 2022-08-04 18:51:52 +02:00
lean.dev
e8e7b59bb0 Implementing OpenApi 3 specs (converted from Swagger 2) (#53243)
* Adding OpenApi target to makefile, to covert swagger spec into OpenAPI 3
* Adding endpoint to server swaggerui with new openapi3 specs
* Passing output file as parameter for OpenApi3 specs
* Implement workaround for missing host and prefix domain
2022-08-04 13:51:12 -03:00
Kevin Minehart
138f03aad1 CI: move grabpl build-plugins from grabpl to grafana (#53071)
* add grabpl command to build internal plugins

* grabpl build-plugins -> ./bin/build build-plugins
2022-08-04 11:39:36 -05:00
Ivana Huckova
bf3fa4a445 Loki: Fix producing correct log volume query for query with comments (#53254)
* Loki: Remove comments from log volume query

* Update, add more tests

* Update based on suggestions

* Update

* Update tests to use it.each
2022-08-04 17:58:39 +02:00
Joao Silva
a84873a52b i18n: Translates the Share Panel modal (#53297) 2022-08-04 16:43:49 +01:00
Gilles De Mey
ca2b97b095 Alerting: Adds support for editing group details for Grafana managed rules (#53120) 2022-08-04 11:39:28 -04:00
eledobleefe
c65b4c732f Chore: Convert FolderSettingsPage.test.tsx to RTL (#53307) 2022-08-04 16:00:04 +02:00
idafurjes
0c5b71694f Chore: Add user service method UpdateLastSeenAt (#53309)
* Chore: Add user service method UpdateLastSeenAt

* Fix lint
2022-08-04 15:44:14 +02:00
idafurjes
20f4191e56 Chore: Add user service method ChangePassword (#53303)
* Chore: Add user service method ChangePassword

* Fix lint
2022-08-04 15:05:05 +02:00
idafurjes
6fdb6ea6f6 Chore: Add user service method Update (#53300)
* Chore: Add user service method Update

* Remove UpdateUser from store interface
2022-08-04 14:22:44 +02:00
Serge Zaitsev
191ab3bb01 Chore: Move api key models into apikey service package (#53241)
* Chore: move api key models into apikey service package

* force table name for api key
2022-08-04 14:19:09 +02:00
idafurjes
af83a09a92 Chore: Add user service method GetByEmail (#53298) 2022-08-04 13:47:30 +02:00
idafurjes
1ecbe22751 Chore: Add user service method GetByLogin (#53204)
* Add wrapper around sqlstore method GetUserByLogin

* Use new method from user service

* Fix lint

* Fix lint 2

* fix middleware basic auth test

* Fix grafana login returning a user by login

* Remove GetUserByLogin from store interface

* Merge commit
2022-08-04 13:22:43 +02:00
Giordano Ricci
1ec9007fe0 GrafanaUI: Render PageToolbar's leftItems regardless of title's presence (#53285)
* Grafana-UI: make PageToolbar render leftItems regardless of title's presence

* simplify test
2022-08-04 11:59:20 +01:00
idafurjes
66fd516c44 Remove GetUserById from store interface (#53226) 2022-08-04 10:34:05 +02:00
Esteban Beltran
112f69177b Build: Replace the file-loader loader with asset module in webpack config (#53088) 2022-08-04 10:29:42 +02:00
Joan López de la Franca Beltran
6b8316d510 Encryption: Fall back to AES-CFB on empty algorithm metadata (#53266) 2022-08-04 09:37:53 +02:00
Levente Balogh
2bf37a0d35 Data Connections: Remove the placeholder for Recorded Queries (#53230)
* feat(Data Connections): remove the Recorded Queries tab

* chore: remove the Recorded Queries from the nav
2022-08-04 06:39:06 +00:00
Drew Slobodnjak
fe0f193189 Geomap: Add measuring tools (#51608)
* Geomap: add measuring tools

* Add measure type selection

* Add controls and state to measure overlay

* Override tooltip mouse events when menu active

* Move measure tools to top right

* Lay groundwork for units and consolidate measuring

* Create measure vector layer class

* Improve styling to match other overlay controls

* Consolidate styling and use theme2

* Update unit language and add km2

Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2022-08-03 16:19:30 -07:00
Adela Almasan
6c58ea66a9 Canvas: Fix inconsistent border behavior (#53262) 2022-08-03 16:23:08 -05:00
sam boyer
b11f66b4bb coremodels: Combine static and generic registries (#53246)
* Stop generating non-dynamic registry code

* Remove generic, errors, s/static/base/

* Sort during codegen, not runtime

* Not a method call

* Precisiate a comment

* Remove generic registry, fix assignability test
2022-08-04 00:04:54 +04:00
Adela Almasan
d54e55ea9a Canvas: Fix duplicated option editors functionality (#53184)
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
2022-08-03 12:49:35 -07:00
Beto Muniz
4c02d072e3 Ensure that tooltip and legend have same parameters to calculate and display label equally (#53176) 2022-08-03 14:47:22 -03:00
Sofia Papagiannaki
ae101bf935 Alerting: Fix migration (#53253) 2022-08-03 11:41:18 -04:00
Ashley Harrison
202f5d38c8 Add missing package to @grafana/schema (#53252) 2022-08-03 11:28:01 -04:00
Ashley Harrison
9d6faa7e9a Storybook: remove UseState + add controls support to TimeZonePicker story (#53219)
* remove UseState + add controls support to TimeZonePicker story

* remove redundant check
2022-08-03 16:17:42 +01:00
Kyle Brandt
643d2bc890 Chore: Sql store split for legacy alerting (#52901)
Moves ~20 sqlstore methods for legacy alerting out of sqlstore (sqlstore.Store interface) and into alerting.
2022-08-03 11:17:26 -04:00
Will Browne
46b7ca12e1 add missing check for root URLs length (#53239) 2022-08-03 17:13:45 +02:00
gtk-grafana
f8d6730134 Metrics: Refactor use of lezer nodes to reference ID instead of name (parsing.ts) (#53177)
* Update public/app/plugins/datasource/prometheus/querybuilder/shared/parsingUtils.ts

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

* Since loki is still passing in node type strings, update the getAllByType shared function to allow string or number types

* add todo to remove string type when last datasource has migrated

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2022-08-03 09:57:29 -05:00
gtk-grafana
7f165729b0 remove string constant and use ids provided in lezer-promql library (#53180) 2022-08-03 09:56:32 -05:00
Sofia Papagiannaki
5fec6cc4f5 API: Fix snapshot responses (#52998)
* API: Fix response status when snapshots are not found

* API: Fix response status when snapshot key is empty

* Apply suggestions from code review
2022-08-03 10:31:23 -04:00
Jean-Philippe Quéméner
54217a2037 Alerting: set dashboard and panel id using annotations in provisioning api (#53221) 2022-08-03 16:05:32 +02:00
Matias Chomicki
97ce40577b Loki: Fix types in querybuilder state test (#53223)
* Chore: add missing refId property to LokiQuery type

* Chore: fix types in Loki querybuilder state test

* Chore: remove unnecessary added property to LokiQuery
2022-08-03 15:59:33 +02:00
Ivana Huckova
3877964470 Loki: Remove some of any assertions from tests (#53114)
* Loki: Remove some of any assertions from tests

* Remove unnecessary as assertions
2022-08-03 15:57:38 +02:00
Grafana I18n Bot
1c1f72b1aa I18n: Crowdin sync (#53222)
* New translations messages.po (French)

* New translations messages.po (French)
2022-08-03 09:49:53 -04:00
ismail simsek
87af08129c Prometheus: Add tests for new explain section (#53182)
* Prometheus: Add tests for new explain section

* Update public/app/plugins/datasource/prometheus/querybuilder/components/PromQueryBuilder.test.tsx

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

* Mock MonacoQueryFieldWrapper

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2022-08-03 15:48:16 +02:00
Jack Westbrook
d87bf30e9e Build: Introduce ESM and Treeshaking to NPM package builds (#51517)
* Revert "Chore: Bump terser to fix security vulnerability (#53052)"

This reverts commit 7ae74d2a18.

* feat: use tsc and rollup directly with esbuild and publishConfig, files props

* refactor(grafana-data): fix isolatedModules re-export type error

* refactor(grafana-data): import paths from src not package name

* refactor(rollup): fix dts output.file

* chore(grafana-schema): delete dashboard_experimental.gen.ts - cannot work with isolatedModules

* refactor(grafana-e2e-selectors): fix export types isolatedModules error

* refactor(grafana-runtime): fix isolatedModules re-export type error

* refactor(grafana-ui): fix isolatedModules re-export type error

* feat(grafana-ui): use named imports for treeshaking

* refactor(grafana-ui): use named imports for treeshaking

* feat: react and react-dom as peerDeps for packages

* feat(grafana-ui): emotion packages as peerDeps

* feat(grafana-e2e): use tsc, rollup, esbuild for bundling

* chore(packages): clean up redundant dependencies

* chore(toolkit): deprecate unused package:build task

* chore(schema): put back dashboard_experimental and exclude to prevent isolatedModules error

* docs(packages): update readme

* chore(storybook): disable isolatedModules for builds

* chore: relax peerDeps for emotion and react

* revert(grafana-ui): put @emotion dependencies back

* refactor: replace relative package imports with package name

* build(packages): set emitDeclaration false for typecheck scripts to work

* test(publicdashboarddatasource): move test next to implementation. try to appease the betterer gods

* chore(storybook): override ts-node config for storybook compilation

* refactor(grafana-data): use ternary so babel doesnt complain about expecting flow types

* chore(toolkit): prefer files and publishConfig package.json props over copying

* build(npm): remove --contents dist arg from publishing commands

* chore(packages): introduce sideEffects prop to package.json to hint package can be treeshaken

* chore(packages): remove redundant index.js files

* feat(packages): set publishConfig.access to public

* feat(packages): use yarn berry and npm for packaging and publishing

* refactor(packages): simplify rollup configs

* chore(schema): add comment explaining need to exclude dashboard_experimental

* revert(toolkit): put back clean to prevent cli failures

* ci(packages): run packages:pack before a canary publish

* chore(gitignore): add npm-artifacts directory to ignore list

* test(publicdashboarddatasource): fix module mocking

* chore(packages): delete package.tgz when running clean

* chore(grafana-data): move dependencies from devDeps to prevent build resolution errors
2022-08-03 15:47:09 +02:00
Ieva
610abc2af0 Access Control: Fix permission error during dashboard creation flow (#53214)
* remove permission check

* remove unneeded function
2022-08-03 16:39:20 +03:00
Will Browne
5523c00b01 check not empty root urls before setting field (#53135) 2022-08-03 15:25:59 +02:00
Giordano Ricci
09c4dbdb9f Correlations: Add UpdateCorrelation HTTP API (#52444)
* Correlations: add UpdateCorrelation HTTP API

* handle correlation not found

* add tests

* fix lint errors

* add bad request to API spec

* change casing

* fix casing in docs

* fix tests

* update spec
2022-08-03 14:18:51 +01:00
Artur Wierzbicki
f61a97a0ab Search: rename remove search constraints (#53190) 2022-08-03 16:44:51 +04:00
Mihály Gyöngyösi
dc775c7577 RolePicker: Fix RolePicker menu positioning (#53201)
Fixes #52800
2022-08-03 14:35:51 +02:00
Dimitris Sotirakis
1d1fb07124 Make retrieve and release npm packages allowed to fail (#53191) 2022-08-03 08:24:32 -04:00
Serge Zaitsev
8d36f71673 Chore: Remove apikey store methods from sqlstore (#53197)
* Chore: remove apikey store methods from sqlstore

* remove GetAPIKeys

* remove GetAllAPIKeys

* remove the rest of apikey from sqlstore
2022-08-03 08:13:05 -04:00
Dimitris Sotirakis
5d014f0c37 CI: Run main-docs pipeline only, when a docs PR is merged (#53026)
* Trigger docs pipeline on main, on docs only changes

* Export docs inclusion paths in variable
2022-08-03 08:08:43 -04:00
Julien Duchesne
157303d8ba Drone: Add retries for pipelines (#53171)
* Drone: Add retries for pipelines
Self-explanatory, this should reduce flakiness for the clone step

* Oops remove extra file
2022-08-03 14:51:29 +03:00
Victor Marin
34b7c38314 Change var keyword to const (#53206) 2022-08-03 11:41:39 +00:00
Josh Hunt
c7d3fec515 Typed variables pt3: Type VariableState with TypedVariableModel (#53015)
* wip

* make diff easier to read

* Update template_srv getVariables to return new TypedVariableModel

* update VariableType to use the type from TypedVariableModel

* tidy things up

* Chore: Use type-accurate mock variables in tests

* Chore: Type VariableState to use TypedVariableModel

* fix typo

* remove type assertion from template_srv.getVariables

* undo whatever changes i did to swagger spec
2022-08-03 12:38:59 +01:00
Josh Hunt
8f81c4d2ce Chore: reformat swagger specs, again (#53205) 2022-08-03 12:18:52 +01:00
Andrey Smirnov
fc9577b76d MegaMenu: Fix broken hamburger toggle (#52770)
* MegaMenu: Fix broken hamburger toggle

* oops

* MegaMenu: move NavBarToggle to FocusScope
2022-08-03 12:08:39 +01:00
Matias Chomicki
7cf2b68e0a Loki: Remove hardcoded values for LokiOperationId (#53168) 2022-08-03 12:50:43 +02:00
Josh Hunt
805203dba9 Chore: Prettier ignore api-merged & api-spec swagger api specs (#53170)
* Prettier ignore api-merged & api-spec swagger api specs

* add enterprise
2022-08-03 11:41:31 +01:00
user10x
fb00a11b5f rename table_model.ts => TableModel.ts (#51659)
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
2022-08-03 10:33:13 +00:00
Joey Tawadrous
1592ea45b0 Tempo: Devenv update to support all features (#52728)
* Tempo devenv

* Add logging to tempo devenv

* Update readme

* Formatting

* Update loki image

* Update tempo image
2022-08-03 11:24:50 +01:00
Gabriel MABILLE
00ff61cb9e RBAC: Add an additional check on UserID before fetching the permissions (#53002)
* RBAC: add an additional check before fetching permissions

* Nit.

* Readd removed test

* change message
2022-08-03 11:06:06 +02:00
J-Loup
2054414d37 Frontend: Make datalinks work with status history and state timeline (#50226)
* fix datalinks for state and status panels

* Add close button on tooltip

* fix links from all series displayed in tooltip

* Allow annotations creation, tweak UI

* Nits

* Remove unused property

* fix returns made from review

* setupUPlotConfig renamed to addTooltipSupport

Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
Co-authored-by: Victor Marin <victor.marin@grafana.com>
2022-08-03 11:58:01 +03:00
Harry Tennent
c56aae6f63 Docs: update annotations API docs to include required field (#52644)
* Update annotations.md

A minor change to include the required fields when creating a new annotation via the annotations API. The error message when fields are missing is not descriptive and there is no indication in the current documentation (that I can see anyway) that would indicate these fields are required.

* Update annotations.md

Update required json body fields to only include fields that are actually required.

* Add required field in Swagger

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>
2022-08-03 08:01:25 +00:00
ismail simsek
920ee16b54 Update LokiQueryCodeEditor test title (#53181)
* Update LokiQueryCodeEditor test title

* Update public/app/plugins/datasource/loki/querybuilder/components/LokiQueryCodeEditor.test.tsx
2022-08-03 09:59:02 +02:00
Armand Grillet
edbaaf495b Docs: update Alerting configuration (#53169) 2022-08-03 09:52:38 +02:00
Gilles De Mey
b7e11358cf Alerting: Fix crash when viewing alert group without interval (#53166) 2022-08-03 08:22:52 +02:00
Garrett Guillotte
e1bb23a2d7 Docs: Add What's New in v9.1 (#53066)
* Docs: Add What's New in v9.1

* Update docs/sources/whatsnew/whats-new-in-v9-1.md

Co-authored-by: Fiona Artiaga <89225282+GrafanaWriter@users.noreply.github.com>

* Docs: Pass CI

* Update docs/sources/whatsnew/whats-new-in-v9-1.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/whatsnew/whats-new-in-v9-1.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/whatsnew/whats-new-in-v9-1.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/whatsnew/whats-new-in-v9-1.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/whatsnew/whats-new-in-v9-1.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/whatsnew/whats-new-in-v9-1.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Update docs/sources/whatsnew/whats-new-in-v9-1.md

Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>

* Docs: Apply style and semantic linebreak suggestions to 9.1 what's new

* Docs: Pass CI

* Removed reference to AWS SM project that has been pulled from announcement

* Docs: Pass CI

* Docs: Pass CI

Co-authored-by: Fiona Artiaga <89225282+GrafanaWriter@users.noreply.github.com>
Co-authored-by: Kim Nylander <104772500+knylander-grafana@users.noreply.github.com>
Co-authored-by: Tim Levett <tim.levett@grafana.com>
2022-08-02 11:07:36 -07:00
Sofia Papagiannaki
3713a193d8 Chore: Fix Makefile target dependency (#53165) 2022-08-02 19:42:48 +03:00
Ieva
67d817ff48 update versions (#53167) 2022-08-02 11:55:46 -04:00
Scott Lepper
fe7add0bc6 ref experimental query editor (#53061)
* ref experimental query editor
2022-08-02 11:44:06 -04:00
Ieva
904d21dc93 update latest.json testing version (#53157) 2022-08-02 15:35:04 +00:00
Ivana Huckova
c4ed5c4d4b Docs: Update explain section in Loki docs (#53107) 2022-08-02 17:21:09 +02:00
Ivana Huckova
5009c330ca Loki: Add tests for explain section in builder and code editor (#53113)
* Loki: Add tests for new explain section

* Update any assertions
2022-08-02 17:20:22 +02:00
Grot (@grafanabot)
8a1dc85e2c ReleaseNotes: Updated changelog and release notes for 9.1.0-beta1 (#53155) 2022-08-02 11:07:36 -04:00
idafurjes
fab6c38c95 Chore: Split get user by ID (#52442)
* Remove user from preferences, stars, orguser, team member

* Fix lint

* Add Delete user from org and dashboard acl

* Delete user from user auth

* Add DeleteUser to quota

* Add test files and adjust user auth store

* Rename package in wire for user auth

* Import Quota Service interface in other services

* do the same in tests

* fix lint tests

* Fix tests

* Add some tests

* Rename InsertUser and DeleteUser to InsertOrgUser and DeleteOrgUser

* Rename DeleteUser to DeleteByUser in quota

* changing a method name in few additional places

* Fix in other places

* Fix lint

* Fix tests

* Chore: Split Delete User method

* Add fakes for userauth

* Add mock for access control Delete User permossion, use interface

* Use interface for ream guardian

* Add simple fake for dashboard acl

* Add go routines, clean up, use interfaces

* fix lint

* Update pkg/services/user/userimpl/user_test.go

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>

* Update pkg/services/user/userimpl/user_test.go

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>

* Update pkg/services/user/userimpl/user_test.go

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>

* Split get user by ID

* Use new method in api

* Add tests

* Aplly emthod in auth info service

* Fix lint and some tests

* Fix get user by ID

* Fix lint
Remove unused fakes

* Use split get user id in admin users

* Use GetbyID in cli commands

* Clean up after merge

* Remove commented out code

* Clena up imports

* add back )

* Fix wire generation for runner after merge with main

Co-authored-by: Sofia Papagiannaki <1632407+papagian@users.noreply.github.com>
2022-08-02 16:58:05 +02:00
Serge Zaitsev
64488f6b90 Chore: split APIKey store (#52781)
* move apikey store into a separate service

* add apikey service to wire graph

* fix linter

* switch api to use apikey service

* fix provideservice in tests

* add apikey service test double

* try different sql syntax

* rolling back the dialect

* trigger drone

* trigger drone
2022-08-02 16:55:19 +02:00
Andres Martinez Gotor
43955bdebd Azure Monitor: Early error if the client secret is not set (#53106) 2022-08-02 16:53:05 +02:00
Andres Martinez Gotor
245af46798 Docs: Remove limitation for Azure Monitor template variables (#52983) 2022-08-02 16:52:28 +02:00
kay delaney
b9598a08a4 Chore: Enable React strict mode (#53126) 2022-08-02 15:27:49 +01:00
Andres Martinez Gotor
194d0fe33b Azure Monitor: Clarify removed query methods (#52986) 2022-08-02 16:02:26 +02:00
Josh Hunt
1a683e53c5 Typed variables pt2: Use type-accurate mock variables in tests (#52987)
* wip

* make diff easier to read

* Update template_srv getVariables to return new TypedVariableModel

* update VariableType to use the type from TypedVariableModel

* tidy things up

* Chore: Use type-accurate mock variables in tests

* make createBaseVariableModel take the variable type
2022-08-02 14:47:41 +01:00
Yuriy Tseretyan
718620c197 Alerting: Update forking request handlers to use the same errors (#52965)
* generalize error handling in forking request handlers
* remove MatchesBackend and change test to test Can
* add 404 to route specs
* change backendTypeByUID to getDatasourceByUID of expected type
* use common errors in api testing
* handle 401 in errorToResponse
* replace backend type error with "unexpected datasource type"
* update swagger spec
2022-08-02 09:33:59 -04:00
Joan López de la Franca Beltran
28e27e1365 Encryption: De-duplicate encryption code with extensible service (#52472)
* Encryption: De-duplicate encryption code with extensible service

* Fix Wire injections

* Fix tests

* Register reload handler
2022-08-02 15:08:09 +02:00
Ashley Harrison
9c6aab3bc9 Chore: remove UseState + add support for controls in TimeOfDayPicker/TimeRangeInput story (#53040)
* remove UseState + add support for controls in TimeOfDayPicker story

* remove UseState + add controls support in TimeRangeInput story

* Add documentation + fix error when clearing

* properly type range
2022-08-02 13:33:59 +01:00
Grafana I18n Bot
db08ece3db I18n: Crowdin sync (#53104)
* New translations messages.po (French)

* New translations messages.po (Spanish)
2022-08-02 12:14:07 +01:00
Josh Hunt
4323e12588 I18n: Add X-Crowdin-SourceKey to messages.po files (#53102)
* add X-Crowdin-SourceKey to messages.po files

* remove previous fake translation
2022-08-02 06:54:24 -04:00
Josh Hunt
1cadccf137 Add crowdin config (#53096) 2022-08-02 05:15:37 -04:00
Josh Hunt
eaf6aea98f Typed variables pt1: Use discriminated union for variable model (#52981)
* wip

* make diff easier to read

* Update template_srv getVariables to return new TypedVariableModel

* update VariableType to use the type from TypedVariableModel

* tidy things up
2022-08-02 10:15:25 +01:00
Ashley Harrison
4d47d7085b don't show dashboards or starred items in navbar when unauthenticated (#53051) 2022-08-02 09:57:32 +01:00
Eric Leijonmarck
f6985835aa Chore: update latest.json to 9.0.6 (#53095) 2022-08-02 04:45:52 -04:00
ismail simsek
3701c9a8f5 Update prometheus docs (#53062) 2022-08-02 10:38:22 +02:00
Grot (@grafanabot)
47a7f84c86 ReleaseNotes: Updated changelog and release notes for 9.0.6 (#53092) 2022-08-02 10:18:46 +02:00
Jack Westbrook
7ae74d2a18 Chore: Bump terser to fix security vulnerability (#53052) 2022-08-02 09:08:10 +02:00
9110 changed files with 617862 additions and 255897 deletions

File diff suppressed because it is too large Load Diff

View File

@@ -1,10 +1,10 @@
import { regexp } from '@betterer/regexp';
import { BettererFileTest } from '@betterer/betterer';
import { ESLint, Linter } from 'eslint';
import { existsSync } from 'fs';
import path from 'path';
import glob from 'glob';
export default {
'no enzyme tests': () => regexp(/from 'enzyme'/g).include('**/*.test.*'),
'better eslint': () => countEslintErrors().include('**/*.{ts,tsx}'),
'no undocumented stories': () => countUndocumentedStories().include('**/*.story.tsx'),
};
@@ -22,51 +22,80 @@ function countUndocumentedStories() {
});
}
async function findEslintConfigFiles(): Promise<string[]> {
return new Promise((resolve, reject) => {
glob('**/.eslintrc', (err, files) => {
if (err) {
reject(err);
}
resolve(files);
});
});
}
function countEslintErrors() {
return new BettererFileTest(async (filePaths, fileTestResult, resolver) => {
const { baseDirectory } = resolver;
const cli = new ESLint({ cwd: baseDirectory });
await Promise.all(
filePaths.map(async (filePath) => {
const linterOptions = (await cli.calculateConfigForFile(filePath)) as Linter.Config;
const eslintConfigFiles = await findEslintConfigFiles();
const eslintConfigMainPaths = eslintConfigFiles.map((file) => path.resolve(path.dirname(file)));
const rules: Partial<Linter.RulesRecord> = {
'@typescript-eslint/no-explicit-any': 'error',
};
const baseRules: Partial<Linter.RulesRecord> = {
'@typescript-eslint/no-explicit-any': 'error',
'@grafana/no-aria-label-selectors': 'error',
};
const isTestFile =
filePath.endsWith('.test.tsx') || filePath.endsWith('.test.ts') || filePath.includes('__mocks__');
const nonTestFilesRules: Partial<Linter.RulesRecord> = {
...baseRules,
'@typescript-eslint/consistent-type-assertions': ['error', { assertionStyle: 'never' }],
};
if (!isTestFile) {
rules['@typescript-eslint/consistent-type-assertions'] = [
'error',
{
assertionStyle: 'never',
},
];
}
// group files by eslint config file
// this will create two file groups for each eslint config file
// one for test files and one for non-test files
const fileGroups: Record<string, string[]> = {};
const runner = new ESLint({
baseConfig: {
...linterOptions,
rules,
},
useEslintrc: false,
cwd: baseDirectory,
});
for (const filePath of filePaths) {
let configPath = eslintConfigMainPaths.find((configPath) => filePath.startsWith(configPath)) ?? '';
const isTestFile =
filePath.endsWith('.test.tsx') ||
filePath.endsWith('.test.ts') ||
filePath.includes('__mocks__') ||
filePath.includes('public/test/');
const lintResults = await runner.lintFiles([filePath]);
lintResults
.filter((lintResult) => lintResult.source)
.forEach((lintResult) => {
const { messages } = lintResult;
const file = fileTestResult.addFile(filePath, '');
messages.forEach((message, index) => {
file.addIssue(0, 0, message.message, `${index}`);
});
if (isTestFile) {
configPath += '-test';
}
if (!fileGroups[configPath]) {
fileGroups[configPath] = [];
}
fileGroups[configPath].push(filePath);
}
for (const configPath of Object.keys(fileGroups)) {
const rules = configPath.endsWith('-test') ? baseRules : nonTestFilesRules;
// this is by far the slowest part of this code. It takes eslint about 2 seconds just to find the config
const linterOptions = (await cli.calculateConfigForFile(fileGroups[configPath][0])) as Linter.Config;
const runner = new ESLint({
baseConfig: {
...linterOptions,
rules: rules,
},
useEslintrc: false,
cwd: baseDirectory,
});
const lintResults = await runner.lintFiles(fileGroups[configPath]);
lintResults
.filter((lintResult) => lintResult.source)
.forEach((lintResult) => {
const { messages } = lintResult;
const filePath = lintResult.filePath;
const file = fileTestResult.addFile(filePath, '');
messages.forEach((message, index) => {
file.addIssue(0, 0, message.message, `${index}`);
});
})
);
});
}
});
}

View File

@@ -1,4 +1,4 @@
# Auto generated binary variables helper managed by https://github.com/bwplotka/bingo v0.6. DO NOT EDIT.
# Auto generated binary variables helper managed by https://github.com/bwplotka/bingo v0.8. DO NOT EDIT.
# All tools are designed to be build inside $GOBIN.
BINGO_DIR := $(dir $(lastword $(MAKEFILE_LIST)))
GOPATH ?= $(shell go env GOPATH)
@@ -21,29 +21,41 @@ BRA := $(GOBIN)/bra-v0.0.0-20200517080246-1e3013ecaff8
$(BRA): $(BINGO_DIR)/bra.mod
@# Install binary/ries using Go 1.14+ build command. This is using bwplotka/bingo-controlled, separate go module with pinned dependencies.
@echo "(re)installing $(GOBIN)/bra-v0.0.0-20200517080246-1e3013ecaff8"
@cd $(BINGO_DIR) && $(GO) build -mod=mod -modfile=bra.mod -o=$(GOBIN)/bra-v0.0.0-20200517080246-1e3013ecaff8 "github.com/unknwon/bra"
@cd $(BINGO_DIR) && GOWORK=off $(GO) build -mod=mod -modfile=bra.mod -o=$(GOBIN)/bra-v0.0.0-20200517080246-1e3013ecaff8 "github.com/unknwon/bra"
CUE := $(GOBIN)/cue-v0.5.0-beta.2
$(CUE): $(BINGO_DIR)/cue.mod
@# Install binary/ries using Go 1.14+ build command. This is using bwplotka/bingo-controlled, separate go module with pinned dependencies.
@echo "(re)installing $(GOBIN)/cue-v0.5.0-beta.2"
@cd $(BINGO_DIR) && GOWORK=off $(GO) build -mod=mod -modfile=cue.mod -o=$(GOBIN)/cue-v0.5.0-beta.2 "cuelang.org/go/cmd/cue"
DRONE := $(GOBIN)/drone-v1.5.0
$(DRONE): $(BINGO_DIR)/drone.mod
@# Install binary/ries using Go 1.14+ build command. This is using bwplotka/bingo-controlled, separate go module with pinned dependencies.
@echo "(re)installing $(GOBIN)/drone-v1.5.0"
@cd $(BINGO_DIR) && $(GO) build -mod=mod -modfile=drone.mod -o=$(GOBIN)/drone-v1.5.0 "github.com/drone/drone-cli/drone"
@cd $(BINGO_DIR) && GOWORK=off $(GO) build -mod=mod -modfile=drone.mod -o=$(GOBIN)/drone-v1.5.0 "github.com/drone/drone-cli/drone"
GOLANGCI_LINT := $(GOBIN)/golangci-lint-v1.49.0
GOLANGCI_LINT := $(GOBIN)/golangci-lint-v1.51.2
$(GOLANGCI_LINT): $(BINGO_DIR)/golangci-lint.mod
@# Install binary/ries using Go 1.14+ build command. This is using bwplotka/bingo-controlled, separate go module with pinned dependencies.
@echo "(re)installing $(GOBIN)/golangci-lint-v1.49.0"
@cd $(BINGO_DIR) && $(GO) build -mod=mod -modfile=golangci-lint.mod -o=$(GOBIN)/golangci-lint-v1.49.0 "github.com/golangci/golangci-lint/cmd/golangci-lint"
@echo "(re)installing $(GOBIN)/golangci-lint-v1.51.2"
@cd $(BINGO_DIR) && GOWORK=off $(GO) build -mod=mod -modfile=golangci-lint.mod -o=$(GOBIN)/golangci-lint-v1.51.2 "github.com/golangci/golangci-lint/cmd/golangci-lint"
JB := $(GOBIN)/jb-v0.5.1
$(JB): $(BINGO_DIR)/jb.mod
@# Install binary/ries using Go 1.14+ build command. This is using bwplotka/bingo-controlled, separate go module with pinned dependencies.
@echo "(re)installing $(GOBIN)/jb-v0.5.1"
@cd $(BINGO_DIR) && GOWORK=off $(GO) build -mod=mod -modfile=jb.mod -o=$(GOBIN)/jb-v0.5.1 "github.com/jsonnet-bundler/jsonnet-bundler/cmd/jb"
SWAGGER := $(GOBIN)/swagger-v0.30.2
$(SWAGGER): $(BINGO_DIR)/swagger.mod
@# Install binary/ries using Go 1.14+ build command. This is using bwplotka/bingo-controlled, separate go module with pinned dependencies.
@echo "(re)installing $(GOBIN)/swagger-v0.30.2"
@cd $(BINGO_DIR) && $(GO) build -mod=mod -modfile=swagger.mod -o=$(GOBIN)/swagger-v0.30.2 "github.com/go-swagger/go-swagger/cmd/swagger"
@cd $(BINGO_DIR) && GOWORK=off $(GO) build -mod=mod -modfile=swagger.mod -o=$(GOBIN)/swagger-v0.30.2 "github.com/go-swagger/go-swagger/cmd/swagger"
WIRE := $(GOBIN)/wire-v0.5.0
$(WIRE): $(BINGO_DIR)/wire.mod
@# Install binary/ries using Go 1.14+ build command. This is using bwplotka/bingo-controlled, separate go module with pinned dependencies.
@echo "(re)installing $(GOBIN)/wire-v0.5.0"
@cd $(BINGO_DIR) && $(GO) build -mod=mod -modfile=wire.mod -o=$(GOBIN)/wire-v0.5.0 "github.com/google/wire/cmd/wire"
@cd $(BINGO_DIR) && GOWORK=off $(GO) build -mod=mod -modfile=wire.mod -o=$(GOBIN)/wire-v0.5.0 "github.com/google/wire/cmd/wire"

View File

@@ -2,6 +2,6 @@ module _ // Auto generated by https://github.com/bwplotka/bingo. DO NOT EDIT
go 1.17
require github.com/unknwon/bra v0.0.0-20200517080246-1e3013ecaff8
replace golang.org/x/sys => golang.org/x/sys v0.0.0-20220615213510-4f61da869c0c
replace golang.org/x/sys => golang.org/x/sys v0.0.0-20220615213510-4f61da869c0c
require github.com/unknwon/bra v0.0.0-20200517080246-1e3013ecaff8

5
.bingo/cue.mod Normal file
View File

@@ -0,0 +1,5 @@
module _ // Auto generated by https://github.com/bwplotka/bingo. DO NOT EDIT
go 1.19
require cuelang.org/go v0.5.0-beta.2 // cmd/cue

30
.bingo/cue.sum Normal file
View File

@@ -0,0 +1,30 @@
cuelang.org/go v0.4.3 h1:W3oBBjDTm7+IZfCKZAmC8uDG0eYfJL4Pp/xbbCMKaVo=
cuelang.org/go v0.4.3/go.mod h1:7805vR9H+VoBNdWFdI7jyDR3QLUPp4+naHfbcgp55HI=
cuelang.org/go v0.5.0-beta.2 h1:am5M7jGvNTJ0rnjrFNyvE7fucL/wRqb0emK4XxdThQI=
cuelang.org/go v0.5.0-beta.2/go.mod h1:okjJBHFQFer+a41sAe2SaGm1glWS8oEb6CmJvn5Zdws=
github.com/cockroachdb/apd v1.1.0 h1:3LFP3629v+1aKXU5Q37mxmRxX/pIu1nijXydLShEq5I=
github.com/cockroachdb/apd/v2 v2.0.1 h1:y1Rh3tEU89D+7Tgbw+lp52T6p/GJLpDmNvr10UWqLTE=
github.com/cockroachdb/apd/v2 v2.0.2 h1:weh8u7Cneje73dDh+2tEVLUvyBc89iwepWCD8b8034E=
github.com/emicklei/proto v1.6.15 h1:XbpwxmuOPrdES97FrSfpyy67SSCV/wBIKXqgJzh6hNw=
github.com/emicklei/proto v1.10.0 h1:pDGyFRVV5RvV+nkBK9iy3q67FBy9Xa7vwrOTE+g5aGw=
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b h1:VKtxabqXZkF25pY9ekfRL6a582T4P37/31XEstQ5p58=
github.com/google/uuid v1.2.0 h1:qJYtXnJRWmpe7m/3XlyhrsLrEURqHRM2kxzoxXqyUDs=
github.com/mitchellh/go-wordwrap v1.0.1 h1:TLuKupo69TCn6TQSyGxwI1EblZZEsQ0vMlAFQflz0v0=
github.com/mpvl/unique v0.0.0-20150818121801-cbe035fff7de h1:D5x39vF5KCwKQaw+OC9ZPiLVHXz3UFw2+psEX+gYcto=
github.com/pkg/errors v0.8.1 h1:iURUrRGxPUNPdy5/HRSm+Yj6okJ6UtLINN0Q9M4+h3I=
github.com/protocolbuffers/txtpbfmt v0.0.0-20201118171849-f6a6b3f636fc h1:gSVONBi2HWMFXCa9jFdYvYk7IwW/mTLxWOF7rXS4LO0=
github.com/protocolbuffers/txtpbfmt v0.0.0-20220428173112-74888fd59c2b h1:zd/2RNzIRkoGGMjE+YIsZ85CnDIz672JK2F3Zl4vux4=
github.com/spf13/cobra v1.4.0 h1:y+wJpx64xcgO1V+RcnwW0LEHxTKRi2ZDPSBjWnrg88Q=
github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA=
golang.org/x/mod v0.3.1-0.20200828183125-ce943fd02449 h1:xUIPaMhvROX9dhPvRCenIJtU78+lbEenGbgqB5hfHCQ=
golang.org/x/mod v0.6.0-dev.0.20220818022119-ed83ed61efb9 h1:VtCrPQXM5Wo9l7XN64SjBMczl48j8mkP+2e3OhYlz+0=
golang.org/x/net v0.0.0-20200226121028-0de0cce0169b h1:0mm1VjtFUOIlE1SbDlwjYaDxZVDP2S5ou6y0gSgXHu8=
golang.org/x/net v0.0.0-20220722155237-a158d28d115b h1:PxfKdU9lEEDYjdIzOtC4qFWgkU2rGHdKlKowJSMN9h0=
golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f h1:v4INt8xihDGvnrfjMDVXGxw9wrfxYyCjk0KbXjhR55s=
golang.org/x/text v0.3.7 h1:olpwvP2KacW1ZWvsR7uQhoyTYvKAupfQrRGBFM352Gk=
golang.org/x/text v0.3.8 h1:nAL+RVCQ9uMn3vJZbV+MRnydTJFPf8qqY42YiA6MrqY=
golang.org/x/tools v0.0.0-20200612220849-54c614fe050c h1:g6oFfz6Cmw68izP3xsdud3Oxu145IPkeFzyRg58AKHM=
golang.org/x/tools v0.1.12 h1:VveCTK38A2rkS8ZqFY25HIDFscX5X9OoEhJd3quQmXU=
golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543 h1:E7g+9GITq07hpfrRu66IVDexMakfv52eLZ2CXBWiKr4=
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b h1:h8qDotaEPuJATrMmW04NCwg7v22aHH28wwpauUhK9Oo=
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=

View File

@@ -2,173 +2,4 @@ module _ // Auto generated by https://github.com/bwplotka/bingo. DO NOT EDIT
go 1.19
require github.com/golangci/golangci-lint v1.49.0 // cmd/golangci-lint
require (
4d63.com/gochecknoglobals v0.1.0 // indirect
github.com/Antonboom/errname v0.1.7 // indirect
github.com/Antonboom/nilnil v0.1.1 // indirect
github.com/BurntSushi/toml v1.2.0 // indirect
github.com/Djarvur/go-err113 v0.0.0-20210108212216-aea10b59be24 // indirect
github.com/GaijinEntertainment/go-exhaustruct/v2 v2.3.0 // indirect
github.com/Masterminds/semver v1.5.0 // indirect
github.com/OpenPeeDeeP/depguard v1.1.0 // indirect
github.com/alexkohler/prealloc v1.0.0 // indirect
github.com/alingse/asasalint v0.0.11 // indirect
github.com/ashanbrown/forbidigo v1.3.0 // indirect
github.com/ashanbrown/makezero v1.1.1 // indirect
github.com/beorn7/perks v1.0.1 // indirect
github.com/bkielbasa/cyclop v1.2.0 // indirect
github.com/blizzy78/varnamelen v0.8.0 // indirect
github.com/bombsimon/wsl/v3 v3.3.0 // indirect
github.com/breml/bidichk v0.2.3 // indirect
github.com/breml/errchkjson v0.3.0 // indirect
github.com/butuzov/ireturn v0.1.1 // indirect
github.com/cespare/xxhash/v2 v2.1.2 // indirect
github.com/charithe/durationcheck v0.0.9 // indirect
github.com/chavacava/garif v0.0.0-20220630083739-93517212f375 // indirect
github.com/curioswitch/go-reassign v0.1.2 // indirect
github.com/daixiang0/gci v0.6.3 // indirect
github.com/davecgh/go-spew v1.1.1 // indirect
github.com/denis-tingaikin/go-header v0.4.3 // indirect
github.com/esimonov/ifshort v1.0.4 // indirect
github.com/ettle/strcase v0.1.1 // indirect
github.com/fatih/color v1.13.0 // indirect
github.com/fatih/structtag v1.2.0 // indirect
github.com/firefart/nonamedreturns v1.0.4 // indirect
github.com/fsnotify/fsnotify v1.5.4 // indirect
github.com/fzipp/gocyclo v0.6.0 // indirect
github.com/go-critic/go-critic v0.6.4 // indirect
github.com/go-toolsmith/astcast v1.0.0 // indirect
github.com/go-toolsmith/astcopy v1.0.1 // indirect
github.com/go-toolsmith/astequal v1.0.2 // indirect
github.com/go-toolsmith/astfmt v1.0.0 // indirect
github.com/go-toolsmith/astp v1.0.0 // indirect
github.com/go-toolsmith/strparse v1.0.0 // indirect
github.com/go-toolsmith/typep v1.0.2 // indirect
github.com/go-xmlfmt/xmlfmt v0.0.0-20191208150333-d5b6f63a941b // indirect
github.com/gobwas/glob v0.2.3 // indirect
github.com/gofrs/flock v0.8.1 // indirect
github.com/golang/protobuf v1.5.2 // indirect
github.com/golangci/check v0.0.0-20180506172741-cfe4005ccda2 // indirect
github.com/golangci/dupl v0.0.0-20180902072040-3e9179ac440a // indirect
github.com/golangci/go-misc v0.0.0-20220329215616-d24fe342adfe // indirect
github.com/golangci/gofmt v0.0.0-20190930125516-244bba706f1a // indirect
github.com/golangci/lint-1 v0.0.0-20191013205115-297bf364a8e0 // indirect
github.com/golangci/maligned v0.0.0-20180506175553-b1d89398deca // indirect
github.com/golangci/misspell v0.3.5 // indirect
github.com/golangci/revgrep v0.0.0-20220804021717-745bb2f7c2e6 // indirect
github.com/golangci/unconvert v0.0.0-20180507085042-28b1c447d1f4 // indirect
github.com/google/go-cmp v0.5.8 // indirect
github.com/gordonklaus/ineffassign v0.0.0-20210914165742-4cc7213b9bc8 // indirect
github.com/gostaticanalysis/analysisutil v0.7.1 // indirect
github.com/gostaticanalysis/comment v1.4.2 // indirect
github.com/gostaticanalysis/forcetypeassert v0.1.0 // indirect
github.com/gostaticanalysis/nilerr v0.1.1 // indirect
github.com/hashicorp/errwrap v1.0.0 // indirect
github.com/hashicorp/go-multierror v1.1.1 // indirect
github.com/hashicorp/go-version v1.6.0 // indirect
github.com/hashicorp/hcl v1.0.0 // indirect
github.com/hexops/gotextdiff v1.0.3 // indirect
github.com/inconshreveable/mousetrap v1.0.0 // indirect
github.com/jgautheron/goconst v1.5.1 // indirect
github.com/jingyugao/rowserrcheck v1.1.1 // indirect
github.com/jirfag/go-printf-func-name v0.0.0-20200119135958-7558a9eaa5af // indirect
github.com/julz/importas v0.1.0 // indirect
github.com/kisielk/errcheck v1.6.2 // indirect
github.com/kisielk/gotool v1.0.0 // indirect
github.com/kulti/thelper v0.6.3 // indirect
github.com/kunwardeep/paralleltest v1.0.6 // indirect
github.com/kyoh86/exportloopref v0.1.8 // indirect
github.com/ldez/gomoddirectives v0.2.3 // indirect
github.com/ldez/tagliatelle v0.3.1 // indirect
github.com/leonklingele/grouper v1.1.0 // indirect
github.com/lufeee/execinquery v1.2.1 // indirect
github.com/magiconair/properties v1.8.6 // indirect
github.com/maratori/testpackage v1.1.0 // indirect
github.com/matoous/godox v0.0.0-20210227103229-6504466cf951 // indirect
github.com/mattn/go-colorable v0.1.13 // indirect
github.com/mattn/go-isatty v0.0.16 // indirect
github.com/mattn/go-runewidth v0.0.9 // indirect
github.com/matttproud/golang_protobuf_extensions v1.0.1 // indirect
github.com/mbilski/exhaustivestruct v1.2.0 // indirect
github.com/mgechev/revive v1.2.3 // indirect
github.com/mitchellh/go-homedir v1.1.0 // indirect
github.com/mitchellh/mapstructure v1.5.0 // indirect
github.com/moricho/tparallel v0.2.1 // indirect
github.com/nakabonne/nestif v0.3.1 // indirect
github.com/nbutton23/zxcvbn-go v0.0.0-20210217022336-fa2cb2858354 // indirect
github.com/nishanths/exhaustive v0.8.1 // indirect
github.com/nishanths/predeclared v0.2.2 // indirect
github.com/olekukonko/tablewriter v0.0.5 // indirect
github.com/pelletier/go-toml v1.9.5 // indirect
github.com/pelletier/go-toml/v2 v2.0.2 // indirect
github.com/phayes/checkstyle v0.0.0-20170904204023-bfd46e6a821d // indirect
github.com/pkg/errors v0.9.1 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/polyfloyd/go-errorlint v1.0.2 // indirect
github.com/prometheus/client_golang v1.12.1 // indirect
github.com/prometheus/client_model v0.2.0 // indirect
github.com/prometheus/common v0.32.1 // indirect
github.com/prometheus/procfs v0.7.3 // indirect
github.com/quasilyte/go-ruleguard v0.3.17 // indirect
github.com/quasilyte/gogrep v0.0.0-20220120141003-628d8b3623b5 // indirect
github.com/quasilyte/regex/syntax v0.0.0-20200407221936-30656e2c4a95 // indirect
github.com/quasilyte/stdinfo v0.0.0-20220114132959-f7386bf02567 // indirect
github.com/ryancurrah/gomodguard v1.2.4 // indirect
github.com/ryanrolds/sqlclosecheck v0.3.0 // indirect
github.com/sanposhiho/wastedassign/v2 v2.0.6 // indirect
github.com/sashamelentyev/interfacebloat v1.1.0 // indirect
github.com/sashamelentyev/usestdlibvars v1.13.0 // indirect
github.com/securego/gosec/v2 v2.13.1 // indirect
github.com/shazow/go-diff v0.0.0-20160112020656-b6b7b6733b8c // indirect
github.com/sirupsen/logrus v1.9.0 // indirect
github.com/sivchari/containedctx v1.0.2 // indirect
github.com/sivchari/nosnakecase v1.7.0 // indirect
github.com/sivchari/tenv v1.7.0 // indirect
github.com/sonatard/noctx v0.0.1 // indirect
github.com/sourcegraph/go-diff v0.6.1 // indirect
github.com/spf13/afero v1.8.2 // indirect
github.com/spf13/cast v1.5.0 // indirect
github.com/spf13/cobra v1.5.0 // indirect
github.com/spf13/jwalterweatherman v1.1.0 // indirect
github.com/spf13/pflag v1.0.5 // indirect
github.com/spf13/viper v1.12.0 // indirect
github.com/ssgreg/nlreturn/v2 v2.2.1 // indirect
github.com/stbenjam/no-sprintf-host-port v0.1.1 // indirect
github.com/stretchr/objx v0.4.0 // indirect
github.com/stretchr/testify v1.8.0 // indirect
github.com/subosito/gotenv v1.4.0 // indirect
github.com/sylvia7788/contextcheck v1.0.6 // indirect
github.com/tdakkota/asciicheck v0.1.1 // indirect
github.com/tetafro/godot v1.4.11 // indirect
github.com/timakin/bodyclose v0.0.0-20210704033933-f49887972144 // indirect
github.com/timonwong/logrlint v0.1.0 // indirect
github.com/tomarrell/wrapcheck/v2 v2.6.2 // indirect
github.com/tommy-muehle/go-mnd/v2 v2.5.0 // indirect
github.com/ultraware/funlen v0.0.3 // indirect
github.com/ultraware/whitespace v0.0.5 // indirect
github.com/uudashr/gocognit v1.0.6 // indirect
github.com/yagipy/maintidx v1.0.0 // indirect
github.com/yeya24/promlinter v0.2.0 // indirect
gitlab.com/bosi/decorder v0.2.3 // indirect
go.uber.org/atomic v1.7.0 // indirect
go.uber.org/multierr v1.6.0 // indirect
go.uber.org/zap v1.17.0 // indirect
golang.org/x/exp v0.0.0-20220722155223-a9213eeb770e // indirect
golang.org/x/exp/typeparams v0.0.0-20220613132600-b0d781184e0d // indirect
golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4 // indirect
golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4 // indirect
golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab // indirect
golang.org/x/text v0.3.7 // indirect
golang.org/x/tools v0.1.12 // indirect
google.golang.org/protobuf v1.28.0 // indirect
gopkg.in/ini.v1 v1.66.6 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
honnef.co/go/tools v0.3.3 // indirect
mvdan.cc/gofumpt v0.3.1 // indirect
mvdan.cc/interfacer v0.0.0-20180901003855-c20040233aed // indirect
mvdan.cc/lint v0.0.0-20170908181259-adc824a0674b // indirect
mvdan.cc/unparam v0.0.0-20220706161116-678bad134442 // indirect
)
require github.com/golangci/golangci-lint v1.51.2 // cmd/golangci-lint

File diff suppressed because it is too large Load Diff

5
.bingo/jb.mod Normal file
View File

@@ -0,0 +1,5 @@
module _ // Auto generated by https://github.com/bwplotka/bingo. DO NOT EDIT
go 1.18
require github.com/jsonnet-bundler/jsonnet-bundler v0.5.1 // cmd/jb

50
.bingo/jb.sum Normal file
View File

@@ -0,0 +1,50 @@
github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751 h1:JYp7IbQjafoB+tBA3gMyHYHrpOtNuDiK/uB5uXxq5wM=
github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc=
github.com/alecthomas/units v0.0.0-20211218093645-b94a6e3cc137 h1:s6gZFSlWYmbqAuRjVTiNNhvNRfY2Wxp9nhfyel4rklc=
github.com/alecthomas/units v0.0.0-20211218093645-b94a6e3cc137/go.mod h1:OMCwj8VM1Kc9e19TLln2VL61YJF0x1XFtfdL4JdbSyE=
github.com/campoy/embedmd v1.0.0/go.mod h1:oxyr9RCiSXg0M3VJ3ks0UGfp98BpSSGr0kpiX3MzVl8=
github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E=
github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
github.com/fatih/color v1.13.0 h1:8LOYc1KYPPmyKMuN8QV2DNRWNbLo6LZ0iLs8+mlH53w=
github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk=
github.com/jsonnet-bundler/jsonnet-bundler v0.5.1 h1:eUd6EA1Qzz73Q4NLNLOrNkMb96+6NTTERbX9lqaxVwk=
github.com/jsonnet-bundler/jsonnet-bundler v0.5.1/go.mod h1:Qrdw/7mOFS2SKCOALKFfEH8gdvXJi8XZjw9g5ilpf4I=
github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo=
github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI=
github.com/kr/pretty v0.3.0/go.mod h1:640gp4NfQd8pI5XOwp5fnNeVWj67G7CFk/SaSQn7NBk=
github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ=
github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI=
github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE=
github.com/mattn/go-colorable v0.1.9/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc=
github.com/mattn/go-colorable v0.1.12 h1:jF+Du6AlPIjs2BiUiQlKOX0rt3SujHxPnksPKZbaA40=
github.com/mattn/go-colorable v0.1.12/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4=
github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU=
github.com/mattn/go-isatty v0.0.14 h1:yVuAays6BHfxijgZPzw+3Zlu5yQgKGP2/hcQbHb7S9Y=
github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94=
github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e/go.mod h1:pJLUxLENpZxwdsKMEsNbx1VGcRFpLqf3715MtcvvzbA=
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=
github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
github.com/rogpeppe/go-internal v1.6.1/go.mod h1:xXDCJY+GAPziupqXw64V24skbSoqbTEfhy4qGm1nDQc=
github.com/rogpeppe/go-internal v1.8.1/go.mod h1:JeRgkft04UBgHMgCIwADu4Pn6Mtm5d4nPKWu0nJ5d+o=
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw=
github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4=
github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
github.com/stretchr/testify v1.7.4/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU=
golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20200223170610-d5e6a3e2c0ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
golang.org/x/sys v0.0.0-20220615213510-4f61da869c0c h1:aFV+BgZ4svzjfabn8ERpuB4JI4N6/rdy1iusx77G3oU=
golang.org/x/sys v0.0.0-20220615213510-4f61da869c0c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg=
gopkg.in/alecthomas/kingpin.v2 v2.2.6 h1:jMFz6MfLP0/4fUyZle81rXUoxOBFi19VUFKVDOQfozc=
gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw=
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q=
gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI=
gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=
gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=
gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=

View File

@@ -1,4 +1,4 @@
# Auto generated binary variables helper managed by https://github.com/bwplotka/bingo v0.6. DO NOT EDIT.
# Auto generated binary variables helper managed by https://github.com/bwplotka/bingo v0.8. DO NOT EDIT.
# All tools are designed to be build inside $GOBIN.
# Those variables will work only until 'bingo get' was invoked, or if tools were installed via Makefile's Variables.mk.
GOBIN=${GOBIN:=$(go env GOBIN)}
@@ -10,9 +10,13 @@ fi
BRA="${GOBIN}/bra-v0.0.0-20200517080246-1e3013ecaff8"
CUE="${GOBIN}/cue-v0.5.0-beta.2"
DRONE="${GOBIN}/drone-v1.5.0"
GOLANGCI_LINT="${GOBIN}/golangci-lint-v1.49.0"
GOLANGCI_LINT="${GOBIN}/golangci-lint-v1.51.2"
JB="${GOBIN}/jb-v0.5.1"
SWAGGER="${GOBIN}/swagger-v0.30.2"

View File

@@ -1,9 +1,9 @@
[run]
init_cmds = [
["make", "gen-go"],
["GO_BUILD_DEV=1", "make", "build-cli"],
["GO_BUILD_DEV=1", "make", "build-server"],
["./bin/grafana-server", "-packaging=dev", "cfg:app_mode=development"]
["make", "gen-jsonnet"],
["GO_BUILD_DEV=1", "make", "build-go"],
["./bin/grafana", "server", "-packaging=dev", "cfg:app_mode=development"]
]
watch_all = true
follow_symlinks = true
@@ -11,12 +11,14 @@ watch_dirs = [
"$WORKDIR/pkg",
"$WORKDIR/public/views",
"$WORKDIR/conf",
"$WORKDIR/devenv/dev-dashboards",
]
watch_exts = [".go", ".ini", ".toml", ".template.html"]
ignore_files = [".*_gen.go"]
build_delay = 1500
cmds = [
["make", "gen-go"],
["GO_BUILD_DEV=1", "make", "build-server"],
["./bin/grafana-server", "-packaging=dev", "cfg:app_mode=development"]
["make", "gen-jsonnet"],
["GO_BUILD_DEV=1", "make", "build-go"],
["./bin/grafana", "server", "-packaging=dev", "cfg:app_mode=development"]
]

View File

@@ -2,7 +2,6 @@
.dockerignore
.git
.gitignore
.github
.vscode
bin
data*

View File

@@ -3,19 +3,57 @@
# 2. Login to drone and export the env variables (token and server) shown here: https://drone.grafana.net/account
# 3. Run `make drone`
# More information about this process here: https://github.com/grafana/deployment_tools/blob/master/docs/infrastructure/drone/signing.md
"""
This module returns a Drone configuration including pipelines and secrets.
"""
load('scripts/drone/events/pr.star', 'pr_pipelines')
load('scripts/drone/events/main.star', 'main_pipelines')
load('scripts/drone/pipelines/docs.star', 'docs_pipelines')
load('scripts/drone/events/release.star', 'release_pipelines', 'publish_image_pipelines', 'publish_artifacts_pipelines', 'publish_npm_pipelines', 'publish_packages_pipeline', 'artifacts_page_pipeline')
load('scripts/drone/version.star', 'version_branch_pipelines')
load('scripts/drone/events/cron.star', 'cronjobs')
load('scripts/drone/vault.star', 'secrets')
load("scripts/drone/events/pr.star", "pr_pipelines")
load("scripts/drone/events/main.star", "main_pipelines")
load(
"scripts/drone/events/release.star",
"integration_test_pipelines",
"publish_artifacts_pipelines",
"publish_npm_pipelines",
"publish_packages_pipeline",
)
load(
"scripts/drone/rgm.star",
"rgm",
)
load(
"scripts/drone/pipelines/publish_images.star",
"publish_image_pipelines_public",
)
load(
"scripts/drone/pipelines/ci_images.star",
"publish_ci_build_container_image_pipeline",
"publish_ci_windows_test_image_pipeline",
)
load(
"scripts/drone/pipelines/windows.star",
"windows_test_backend",
)
load("scripts/drone/version.star", "version_branch_pipelines")
load("scripts/drone/events/cron.star", "cronjobs")
load("scripts/drone/vault.star", "secrets")
def main(ctx):
edition = 'oss'
return pr_pipelines(edition=edition) + main_pipelines(edition=edition) + release_pipelines() + \
publish_image_pipelines('public') + publish_image_pipelines('security') + \
publish_artifacts_pipelines('security') + publish_artifacts_pipelines('public') + \
publish_npm_pipelines('public') + publish_packages_pipeline() + artifacts_page_pipeline() + \
version_branch_pipelines() + cronjobs(edition=edition) + secrets()
def main(_ctx):
return (
pr_pipelines() +
main_pipelines() +
publish_image_pipelines_public() +
publish_artifacts_pipelines("public") +
publish_npm_pipelines() +
publish_packages_pipeline() +
rgm() +
[windows_test_backend({
"event": ["promote"],
"target": ["test-windows"],
}, "oss", "testing")] +
version_branch_pipelines() +
integration_test_pipelines() +
publish_ci_windows_test_image_pipeline() +
publish_ci_build_container_image_pipeline() +
cronjobs() +
secrets()
)

5088
.drone.yml

File diff suppressed because it is too large Load Diff

View File

@@ -1,13 +1,15 @@
{
"extends": ["@grafana/eslint-config"],
"root": true,
"plugins": ["@emotion", "lodash", "jest", "import"],
"plugins": ["@emotion", "lodash", "jest", "import", "jsx-a11y", "@grafana"],
"settings": {
"import/internal-regex": "^(app/)|(@grafana)",
"import/external-module-folders": ["node_modules", ".yarn"]
},
"rules": {
"react/prop-types": "off",
// need to ignore emotion's `css` prop, see https://github.com/jsx-eslint/eslint-plugin-react/blob/master/docs/rules/no-unknown-property.md#rule-options
"react/no-unknown-property": ["error", { "ignore": ["css"] }],
"@emotion/jsx-import": "error",
"lodash/import-scope": [2, "member"],
"jest/no-focused-tests": "error",
@@ -18,9 +20,36 @@
"newlines-between": "always",
"alphabetize": { "order": "asc" }
}
]
],
"no-restricted-imports": [
"error",
{
"paths": [
{
"name": "react-redux",
"importNames": ["useDispatch", "useSelector"],
"message": "Please import from app/types instead."
},
{
"name": "react-i18next",
"importNames": ["Trans", "t"],
"message": "Please import from app/core/internationalization instead"
}
]
}
],
// Use typescript's no-redeclare for compatibility with overrides
"no-redeclare": "off",
"@typescript-eslint/no-redeclare": ["error"]
},
"overrides": [
{
"files": ["public/app/features/scenes/**/*.{ts,tsx}"],
"rules": {
"@typescript-eslint/explicit-member-accessibility": ["error", { "accessibility": "explicit" }]
}
},
{
"files": ["packages/grafana-ui/src/components/uPlot/**/*.{ts,tsx}"],
"rules": {
@@ -35,6 +64,38 @@
"react/jsx-uses-react": "off",
"react/react-in-jsx-scope": "off"
}
},
{
"files": ["public/dashboards/scripted*.js"],
"rules": {
"no-redeclare": "error",
"@typescript-eslint/no-redeclare": "off"
}
},
{
"extends": ["plugin:jsx-a11y/recommended"],
"files": ["**/*"],
"excludedFiles": ["**/*.{spec,test}.{ts,tsx}"],
"rules": {
// rules marked "off" are those left in the recommended preset we need to fix
// we should remove the corresponding line and fix them one by one
// any marked "error" contain specific overrides we'll need to keep
"jsx-a11y/click-events-have-key-events": "off",
"jsx-a11y/no-autofocus": [
"error",
{
"ignoreNonDOM": true
}
],
"jsx-a11y/no-static-element-interactions": "off",
"jsx-a11y/label-has-associated-control": [
"error",
{
"controlComponents": ["NumberInput"],
"depth": 2
}
]
}
}
]
}

704
.github/CODEOWNERS vendored
View File

@@ -11,175 +11,615 @@
# In each subsection folders are ordered first by depth, then alphabetically.
# This should make it easy to add new rules without breaking existing ones.
# Documentation owner: Jita Chatterjee
/docs/ @grafana/docs-squad
/contribute/ @marcusolsson @grafana/docs-squad
/docs/sources/developers/plugins/ @marcusolsson @grafana/docs-squad @grafana/plugins-platform-frontend @grafana/plugins-platform-backend
/docs/sources/developers/plugins/backend @marcusolsson @grafana/docs-squad @grafana/plugins-platform-backend
/docs/sources/enterprise/ @osg-grafana @grafana/docs-squad
# Documentation
/docs/ @grafana/docs-grafana
/contribute/ @grafana/docs-grafana
/docs/sources/developers/plugins/ @grafana/docs-grafana @grafana/plugins-platform-frontend @grafana/plugins-platform-backend
/docs/sources/developers/plugins/backend/ @grafana/docs-grafana @grafana/plugins-platform-backend
/.changelog-archive @grafana/docs-grafana
CHANGELOG.md @grafana/docs-grafana
CODE_OF_CONDUCT.md @grafana/docs-grafana
CONTRIBUTING.md @grafana/docs-grafana
GOVERNANCE.md @RichiH
HALL_OF_FAME.md @grafana/docs-grafana
ISSUE_TRIAGE.md @grafana/grafana-community-support
LICENSE @torkelo
LICENSING.md @torkelo
MAINTAINERS.md @RichiH
NOTICE.md @torkelo
README.md @grafana/docs-grafana
ROADMAP.md @torkelo
SECURITY.md @grafana/security-team
SUPPORT.md @torkelo
UPGRADING_DEPENDENCIES.md @grafana/docs-grafana
WORKFLOW.md @torkelo
# Technical documentation
/docs/ @Eve832 @jdbaldry
/docs/sources/ @Eve832
/docs/sources/administration/ @Eve832 @GrafanaWriter
/docs/sources/alerting/ @brendamuir
/docs/sources/dashboards/ @imatwawana
/docs/sources/datasources/ @Eve832 @GrafanaWriter
/docs/sources/explore/ @Eve832 @GrafanaWriter
/docs/sources/fundamentals @chri2547
/docs/sources/getting-started/ @chri2547
/docs/sources/introduction/ @chri2547
/docs/sources/old-alerting/ @brendamuir
/docs/sources/panels-visualizations/ @imatwawana
/docs/sources/release-notes/ @Eve832 @GrafanaWriter
/docs/sources/setup-grafana/ @chri2547
/docs/sources/upgrade-guide/ @chri2547 @imatwawana
/docs/sources/whatsnew/ @chri2547 @imatwawana
/docs/sources/developers/plugins/ @Eve832 @josmperez @grafana/plugins-platform-frontend @grafana/plugins-platform-backend
/docs/sources/developers/plugins/backend/ @Eve832 @grafana/plugins-platform-backend
# Backend code
*.go @grafana/backend-platform
go.mod @grafana/backend-platform
go.sum @grafana/backend-platform
/.bingo @grafana/backend-platform
/go.mod @grafana/backend-platform
/go.sum @grafana/backend-platform
/.bingo/ @grafana/backend-platform
/pkg/README.md @grafana/backend-platform
/pkg/ruleguard.rules.go @grafana/backend-platform
/.bra.toml @grafana/backend-platform
/.golangci.toml @grafana/backend-platform
/build.go @grafana/backend-platform
/pkg/api/ @grafana/backend-platform
/pkg/bus/ @grafana/backend-platform
/pkg/cmd/ @grafana/backend-platform
/pkg/components/apikeygen/ @grafana/grafana-authnz-team
/pkg/components/apikeygenprefixed/ @grafana/grafana-authnz-team
/pkg/components/dashdiffs/ @grafana/backend-platform
/pkg/components/imguploader/ @grafana/backend-platform
/pkg/components/loki/ @grafana/backend-platform
/pkg/components/null/ @grafana/backend-platform
/pkg/components/simplejson/ @grafana/backend-platform
/pkg/events/ @grafana/backend-platform
/pkg/extensions/ @grafana/backend-platform
/pkg/ifaces/ @grafana/backend-platform
/pkg/infra/appcontext/ @grafana/backend-platform
/pkg/infra/db/ @grafana/backend-platform
/pkg/infra/grn/ @grafana/backend-platform
/pkg/infra/localcache/ @grafana/backend-platform
/pkg/infra/log/ @grafana/backend-platform
/pkg/infra/metrics/ @grafana/backend-platform
/pkg/infra/network/ @grafana/backend-platform
/pkg/infra/process/ @grafana/backend-platform
/pkg/infra/remotecache/ @grafana/backend-platform
/pkg/infra/serverlock/ @grafana/backend-platform
/pkg/infra/slugify/ @grafana/backend-platform
/pkg/infra/tracing/ @grafana/backend-platform
/pkg/infra/usagestats/ @grafana/backend-platform
/pkg/middleware/ @grafana/backend-platform
/pkg/mocks/ @grafana/backend-platform
/pkg/models/ @grafana/backend-platform
/pkg/server/ @grafana/backend-platform
/pkg/services/annotations/ @grafana/backend-platform
/pkg/services/apikey/ @grafana/backend-platform
/pkg/services/cleanup/ @grafana/backend-platform
/pkg/services/comments/ @grafana/backend-platform
/pkg/services/contexthandler/ @grafana/backend-platform
/pkg/services/correlations/ @grafana/backend-platform
/pkg/services/dashboardimport/ @grafana/backend-platform
/pkg/services/dashboards/ @grafana/backend-platform
/pkg/services/dashboardsnapshots/ @grafana/backend-platform
/pkg/services/dashboardversion/ @grafana/backend-platform
/pkg/services/encryption/ @grafana/backend-platform
/pkg/services/featuremgmt/ @grafana/backend-platform
/pkg/services/folder/ @grafana/backend-platform
/pkg/services/hooks/ @grafana/backend-platform
/pkg/services/kmsproviders/ @grafana/backend-platform
/pkg/services/licensing/ @grafana/backend-platform
/pkg/services/navtree/ @grafana/backend-platform
/pkg/services/notifications/ @grafana/backend-platform
/pkg/services/org/ @grafana/backend-platform
/pkg/services/playlist/ @grafana/backend-platform
/pkg/services/plugindashboards/ @grafana/backend-platform
/pkg/services/pluginsettings/ @grafana/backend-platform
/pkg/services/preference/ @grafana/backend-platform
/pkg/services/provisioning/ @grafana/backend-platform
/pkg/services/publicdashboards/ @grafana/dashboards-squad
/pkg/services/query/ @grafana/backend-platform
/pkg/services/queryhistory/ @grafana/backend-platform
/pkg/services/quota/ @grafana/backend-platform
/pkg/services/rendering/ @grafana/backend-platform
/pkg/services/screenshot/ @grafana/backend-platform
/pkg/services/search/ @grafana/backend-platform
/pkg/services/searchusers/ @grafana/backend-platform
/pkg/services/secrets/ @grafana/backend-platform
/pkg/services/shorturls/ @grafana/backend-platform
/pkg/services/sqlstore/ @grafana/backend-platform
/pkg/services/star/ @grafana/backend-platform
/pkg/services/stats/ @grafana/backend-platform
/pkg/services/tag/ @grafana/backend-platform
/pkg/services/team/ @grafana/grafana-authnz-team
/pkg/services/temp_user/ @grafana/backend-platform
/pkg/services/updatechecker/ @grafana/backend-platform
/pkg/services/user/ @grafana/backend-platform
/pkg/services/validations/ @grafana/backend-platform
/pkg/setting/ @grafana/backend-platform
/pkg/tests/ @grafana/backend-platform
/pkg/tests/api/correlations/ @grafana/explore-squad
/pkg/tsdb/grafanads/ @grafana/backend-platform
/pkg/tsdb/intervalv2/ @grafana/backend-platform
/pkg/tsdb/legacydata/ @grafana/backend-platform
/pkg/tsdb/opentsdb/ @grafana/backend-platform
/pkg/tsdb/sqleng/ @grafana/backend-platform
/pkg/util/ @grafana/backend-platform
/pkg/web/ @grafana/backend-platform
/pkg/services/grpcserver/ @grafana/backend-platform
/pkg/infra/kvstore/ @grafana/backend-platform
/pkg/infra/fs/ @grafana/backend-platform
/pkg/infra/x/ @grafana/backend-platform
# devenv
# Backend code, developers environment
/devenv/docker/blocks/auth/ @grafana/grafana-authnz-team
# Logs code, developers environment
/devenv/docker/blocks/loki* @grafana/observability-logs
/devenv/docker/blocks/elastic* @grafana/observability-logs
# Performance tests
/devenv/docker/loadtest-ts/ @grafana/multitenancy-squad
/devenv/bulk-dashboards/ @grafana/dashboards-squad
/devenv/bulk_alerting_dashboards/ @grafana/alerting-squad-backend
/devenv/create_docker_compose.sh @grafana/backend-platform
/devenv/dashboards.yaml @grafana/dashboards-squad
/devenv/datasources.yaml @grafana/backend-platform
/devenv/datasources_docker.yaml @grafana/backend-platform
/devenv/dev-dashboards-without-uid/ @grafana/dashboards-squad
/devenv/dev-dashboards/ @grafana/dashboards-squad
/devenv/docker/blocks/alert_webhook_listener/ @grafana/alerting-squad-backend
/devenv/docker/blocks/clickhouse/ @grafana/partner-plugins
/devenv/docker/blocks/collectd/ @grafana/observability-metrics
/devenv/docker/blocks/grafana/ @grafana/grafana-as-code
/devenv/docker/blocks/graphite/ @grafana/observability-metrics
/devenv/docker/blocks/graphite09/ @grafana/observability-metrics
/devenv/docker/blocks/graphite1/ @grafana/observability-metrics
/devenv/docker/blocks/influxdb/ @grafana/observability-metrics
/devenv/docker/blocks/influxdb1/ @grafana/observability-metrics
/devenv/docker/blocks/jaeger/ @grafana/observability-traces-and-profiling
/devenv/docker/blocks/maildev/ @grafana/alerting-squad-frontend
/devenv/docker/blocks/memcached/ @grafana/backend-platform
/devenv/docker/blocks/mssql/ @grafana/grafana-bi-squad
/devenv/docker/blocks/mssql_arm64/ @grafana/grafana-bi-squad
/devenv/docker/blocks/mssql_tests/ @grafana/grafana-bi-squad
/devenv/docker/blocks/mssql_tls/ @grafana/grafana-bi-squad
/devenv/docker/blocks/mysql/ @grafana/grafana-bi-squad
/devenv/docker/blocks/mysql_exporter/ @grafana/grafana-bi-squad
/devenv/docker/blocks/mysql_opendata/ @grafana/grafana-bi-squad
/devenv/docker/blocks/mysql_tests/ @grafana/grafana-bi-squad
/devenv/docker/blocks/opentsdb/ @grafana/observability-metrics
/devenv/docker/blocks/phlare/ @grafana/observability-traces-and-profiling
/devenv/docker/blocks/postgres/ @grafana/grafana-bi-squad
/devenv/docker/blocks/postgres_tests/ @grafana/grafana-bi-squad
/devenv/docker/blocks/prometheus/ @grafana/observability-metrics
/devenv/docker/blocks/prometheus_random_data/ @grafana/observability-metrics
/devenv/docker/blocks/redis/ @bergquist
/devenv/docker/blocks/sensugo/ @grafana/backend-platform
/devenv/docker/blocks/slow_proxy/ @bergquist
/devenv/docker/blocks/smtp/ @bergquist
/devenv/docker/blocks/tempo/ @grafana/observability-traces-and-profiling
/devenv/docker/blocks/traefik/ @mckn
/devenv/docker/blocks/zipkin/ @grafana/observability-traces-and-profiling
/devenv/docker/buildcontainer/ @bergquist
/devenv/docker/compose_header.yml @grafana/backend-platform
/devenv/docker/debtest/ @bergquist
/devenv/docker/ha-test-unified-alerting/ @grafana/alerting-squad-backend
/devenv/docker/ha_test/ @grafana/backend-platform
/devenv/docker/loadtest/ @grafana/backend-platform
/devenv/docker/rpmtest/ @grafana/backend-platform
/devenv/jsonnet/ @grafana/grafana-edge-squad
/devenv/local-npm/ @grafana/frontend-ops
/devenv/vscode/ @grafana/frontend-ops
/devenv/setup.sh @grafana/backend-platform
# Emails
/emails/ @grafana/alerting-squad-frontend
#Packaging
/packaging/ @DanCech
# Continuous Integration
.drone.yml @grafana/grafana-release-eng
.drone.star @grafana/grafana-release-eng
/scripts/drone/ @grafana/grafana-release-eng
/pkg/build/ @grafana/grafana-release-eng
.drone.yml @grafana/grafana-delivery
.drone.star @grafana/grafana-delivery
/scripts/drone/ @grafana/grafana-delivery
/pkg/build/ @grafana/grafana-delivery
/.dockerignore @grafana/grafana-delivery
/Dockerfile @grafana/grafana-delivery
/Makefile @grafana/grafana-delivery
/scripts/build/ @grafana/grafana-delivery
/scripts/list-release-artifacts.sh @grafana/grafana-delivery
# Cloud Datasources backend code
/pkg/tsdb/cloudwatch @grafana/aws-plugins
/pkg/tsdb/azuremonitor @grafana/cloud-provider-plugins
/pkg/tsdb/cloudmonitoring @grafana/cloud-provider-plugins
# OSS Plugin Partnerships backend code
/pkg/tsdb/cloudwatch/ @grafana/aws-plugins
/pkg/tsdb/azuremonitor/ @grafana/partner-plugins
/pkg/tsdb/cloudmonitoring/ @grafana/partner-plugins
# Observability backend code
/pkg/tsdb/prometheus @grafana/observability-metrics
/pkg/tsdb/influxdb @grafana/observability-metrics
/pkg/tsdb/elasticsearch @grafana/observability-logs
/pkg/tsdb/graphite @grafana/observability-metrics
/pkg/tsdb/jaeger @grafana/observability-logs-and-traces
/pkg/tsdb/loki @grafana/observability-logs
/pkg/tsdb/zipkin @grafana/observability-logs-and-traces
/pkg/tsdb/tempo @grafana/observability-logs-and-traces
/pkg/tsdb/prometheus/ @grafana/observability-metrics
/pkg/tsdb/influxdb/ @grafana/observability-metrics
/pkg/tsdb/elasticsearch/ @grafana/observability-logs
/pkg/tsdb/graphite/ @grafana/observability-metrics
/pkg/tsdb/loki/ @grafana/observability-logs
/pkg/tsdb/tempo/ @grafana/observability-traces-and-profiling
/pkg/tsdb/phlare/ @grafana/observability-traces-and-profiling
/pkg/tsdb/parca/ @grafana/observability-traces-and-profiling
# BI backend code
/pkg/tsdb/mysql @grafana/grafana-bi-squad
/pkg/tsdb/postgres @grafana/grafana-bi-squad
/pkg/tsdb/mssql @grafana/grafana-bi-squad
/pkg/tsdb/mysql/ @grafana/grafana-bi-squad
/pkg/tsdb/postgres/ @grafana/grafana-bi-squad
/pkg/tsdb/mssql/ @grafana/grafana-bi-squad
# Database migrations
/pkg/services/sqlstore/migrations @grafana/backend-platform @grafana/hosted-grafana-team
/pkg/services/sqlstore/migrations/ @grafana/backend-platform @grafana/hosted-grafana-team
*_mig.go @grafana/backend-platform @grafana/hosted-grafana-team
# Grafana edge
/pkg/services/live/ @grafana/grafana-edge-squad
/pkg/services/searchV2/ @grafana/grafana-edge-squad
/pkg/services/store/ @grafana/grafana-edge-squad
/pkg/services/export/ @grafana/grafana-edge-squad
/pkg/infra/filestore/ @grafana/grafana-edge-squad
pkg/tsdb/testdatasource/sims/ @grafana/grafana-edge-squad
# Grafana multitenancy
/pkg/services/live/ @grafana/multitenancy-squad
/pkg/services/searchV2/ @grafana/multitenancy-squad
/pkg/services/store/ @grafana/multitenancy-squad
/pkg/services/querylibrary/ @grafana/multitenancy-squad
/pkg/services/export/ @grafana/multitenancy-squad
/pkg/infra/filestorage/ @grafana/multitenancy-squad
/pkg/util/converter/ @grafana/multitenancy-squad
# Alerting
/pkg/services/ngalert @grafana/alerting-squad-backend
/pkg/services/sqlstore/migrations/ualert @grafana/alerting-squad-backend
/pkg/services/alerting @grafana/alerting-squad-backend
/pkg/tests/api/alerting @grafana/alerting-squad-backend
/public/app/features/alerting @grafana/alerting-squad-frontend
/pkg/services/ngalert/ @grafana/alerting-squad-backend
/pkg/services/sqlstore/migrations/ualert/ @grafana/alerting-squad-backend
/pkg/services/alerting/ @grafana/alerting-squad-backend
/pkg/tests/api/alerting/ @grafana/alerting-squad-backend
/public/app/features/alerting/ @grafana/alerting-squad-frontend
# Library Services
/pkg/services/libraryelements @grafana/user-essentials
/pkg/services/librarypanels @grafana/user-essentials
/pkg/services/libraryelements/ @grafana/user-essentials
/pkg/services/librarypanels/ @grafana/user-essentials
# Plugins
/pkg/api/pluginproxy @grafana/plugins-platform-backend
/pkg/plugins @grafana/plugins-platform-backend
/pkg/services/datasourceproxy @grafana/plugins-platform-backend
/pkg/services/datasources @grafana/plugins-platform-backend
/pkg/api/pluginproxy/ @grafana/plugins-platform-backend
/pkg/infra/httpclient/ @grafana/plugins-platform-backend
/pkg/plugins/ @grafana/plugins-platform-backend
/pkg/services/datasourceproxy/ @grafana/plugins-platform-backend
/pkg/services/datasources/ @grafana/plugins-platform-backend
/pkg/services/pluginsintegration/ @grafana/plugins-platform-backend
/pkg/plugins/pfs/ @grafana/plugins-platform-backend @grafana/grafana-as-code
/pkg/tsdb/testdatasource/ @grafana/plugins-platform-backend
# Dashboard previews / crawler (behind feature flag)
/pkg/services/thumbs @grafana/grafana-edge-squad
/pkg/services/thumbs/ @grafana/multitenancy-squad
# Backend code docs
/contribute/style-guides/backend.md @grafana/backend-platform
/contribute/architecture/backend @grafana/backend-platform
/contribute/engineering/backend @grafana/backend-platform
/contribute/backend/ @grafana/backend-platform
/e2e @grafana/user-essentials
/packages @grafana/user-essentials @grafana/plugins-platform-frontend @grafana/grafana-bi-squad
/packages/grafana-e2e-selectors @grafana/user-essentials
/packages/grafana-e2e @grafana/user-essentials
/packages/grafana-toolkit @grafana/plugins-platform-frontend
/packages/grafana-ui/.storybook @grafana/plugins-platform-frontend
/packages/grafana-ui/src/components/DateTimePickers @grafana/grafana-bi-squad
/packages/grafana-ui/src/components/GraphNG @grafana/grafana-bi-squad
/packages/grafana-ui/src/components/Table @grafana/grafana-bi-squad
/packages/grafana-ui/src/components/TimeSeries @grafana/grafana-bi-squad
/packages/grafana-ui/src/components/uPlot @grafana/grafana-bi-squad
/packages/grafana-ui/src/utils/storybook @grafana/plugins-platform-frontend
/packages/jaeger-ui-components/ @grafana/observability-logs-and-traces
/plugins-bundled @grafana/plugins-platform-frontend
# public folder
/public/app/core/components/TimePicker @grafana/grafana-bi-squad
/public/app/core/components/Layers @grafana/grafana-edge-squad
/public/app/features/canvas/ @grafana/grafana-edge-squad
/public/app/features/comments/ @grafana/grafana-edge-squad
/public/app/features/dimensions/ @grafana/grafana-edge-squad
/public/app/features/geo/ @grafana/grafana-edge-squad
/public/app/features/storage/ @grafana/grafana-edge-squad
/public/app/features/live/ @grafana/grafana-edge-squad
/public/app/features/explore/ @grafana/observability-experience-squad
/public/app/features/plugins @grafana/plugins-platform-frontend
/public/app/features/transformers/spatial @grafana/grafana-edge-squad
/public/app/plugins/panel/alertlist @grafana/alerting-squad-frontend
/public/app/plugins/panel/barchart @grafana/grafana-bi-squad
/public/app/plugins/panel/heatmap @grafana/grafana-bi-squad
/public/app/plugins/panel/histogram @grafana/grafana-bi-squad
/public/app/plugins/panel/logs @grafana/observability-logs
/public/app/plugins/panel/nodeGraph @grafana/observability-logs-and-traces
/public/app/plugins/panel/piechart @grafana/grafana-bi-squad
/public/app/plugins/panel/state-timeline @grafana/grafana-bi-squad
/public/app/plugins/panel/status-history @grafana/grafana-bi-squad
/public/app/plugins/panel/table @grafana/grafana-bi-squad
/public/app/plugins/panel/timeseries @grafana/grafana-bi-squad
/public/app/plugins/panel/geomap @grafana/grafana-edge-squad
/public/app/plugins/panel/canvas @grafana/grafana-edge-squad
/public/app/plugins/panel/candlestick @grafana/grafana-edge-squad
/public/app/plugins/panel/icon @grafana/grafana-edge-squad
/scripts/build/release-packages.sh @grafana/plugins-platform-frontend
/scripts/circle-release-next-packages.sh @grafana/plugins-platform-frontend
/scripts/ci-frontend-metrics.sh @grafana/user-essentials @grafana/plugins-platform-frontend @grafana/grafana-bi-squad
/scripts/ci-reference-docs-build.sh @grafana/plugins-platform-frontend
/scripts/ci-reference-docs-lint.sh @grafana/plugins-platform-frontend
/scripts/grunt @grafana/frontend-ops
/scripts/webpack @grafana/frontend-ops
/scripts/generate-a11y-report.sh @grafana/user-essentials
/crowdin.yml @grafana/user-essentials
/public/locales/ @grafana/user-essentials
/public/app/core/internationalization/ @grafana/user-essentials
/e2e/ @grafana/user-essentials
/e2e/cloud-plugins-suite/ @grafana/partner-plugins
/packages/ @grafana/user-essentials @grafana/plugins-platform-frontend @grafana/grafana-bi-squad
/packages/grafana-e2e-selectors/ @grafana/user-essentials
/packages/grafana-e2e/ @grafana/user-essentials
/packages/grafana-toolkit/ @grafana/plugins-platform-frontend
/packages/grafana-ui/.storybook/ @grafana/plugins-platform-frontend
/packages/grafana-ui/src/components/DateTimePickers/ @grafana/user-essentials
/packages/grafana-ui/src/components/GraphNG/ @grafana/grafana-bi-squad
/packages/grafana-ui/src/components/Logs/ @grafana/observability-logs
/packages/grafana-ui/src/components/Table/ @grafana/grafana-bi-squad
/packages/grafana-ui/src/components/TimeSeries/ @grafana/grafana-bi-squad
/packages/grafana-ui/src/components/uPlot/ @grafana/grafana-bi-squad
/packages/grafana-ui/src/utils/storybook/ @grafana/plugins-platform-frontend
/packages/grafana-data/src/**/*logs* @grafana/observability-logs
/plugins-bundled/ @grafana/plugins-platform-frontend
# root files, mostly frontend
.browserslistrc @grafana/frontend-ops
package.json @grafana/frontend-ops
tsconfig.json @grafana/frontend-ops
/.editorconfig @grafana/frontend-ops
/.eslintignore @grafana/frontend-ops
/.gitattributes @grafana/frontend-ops
/.gitignore @grafana/frontend-ops
/.husky/pre-commit @grafana/frontend-ops
/.nvmrc @grafana/frontend-ops
/.prettierignore @grafana/frontend-ops
/.yarn @grafana/frontend-ops
/.yarnrc.yml @grafana/frontend-ops
/yarn.lock @grafana/frontend-ops
/.linguirc @grafana/user-essentials
/babel.config.json @grafana/frontend-ops
lerna.json @grafana/frontend-ops
.babelrc @grafana/frontend-ops
.prettierrc.js @grafana/frontend-ops
.eslintrc @grafana/frontend-ops
/.prettierrc.js @grafana/frontend-ops
/.eslintrc @grafana/frontend-ops
/.vim @zoltanbedi
/jest.config.js @grafana/frontend-ops
/latest.json @grafana/frontend-ops
/metadata.md @grafana/plugins-platform
/stylelint.config.js @grafana/frontend-ops
/tools/ @grafana/frontend-ops
# public folder
/public/app/core/ @grafana/user-essentials
/public/app/core/components/TimePicker/ @grafana/user-essentials
/public/app/core/components/Layers/ @grafana/grafana-edge-squad
/public/app/features/all.ts @grafana/user-essentials
/public/app/features/admin/ @grafana/grafana-authnz-team
/public/app/features/annotations/ @grafana/user-essentials
/public/app/features/api-keys/ @grafana/user-essentials
/public/app/features/canvas/ @grafana/grafana-edge-squad
/public/app/features/commandPalette/ @grafana/user-essentials
/public/app/features/comments/ @grafana/grafana-edge-squad
/public/app/features/connections/ @grafana/plugins-platform-frontend
/public/app/features/correlations/ @grafana/explore-squad
/public/app/features/dashboard/ @grafana/dashboards-squad
/public/app/features/datasources/ @grafana/user-essentials
/public/app/features/dimensions/ @grafana/grafana-edge-squad
/public/app/features/explore/ @grafana/explore-squad
/public/app/features/expressions/ @grafana/observability-metrics
/public/app/features/folders/ @grafana/user-essentials
/public/app/features/inspector/ @grafana/user-essentials
/public/app/features/invites/ @grafana/user-essentials
/public/app/features/geo/ @grafana/grafana-edge-squad
/public/app/features/library-panels/ @grafana/user-essentials
/public/app/features/logs/ @grafana/observability-logs
/public/app/features/live/ @grafana/multitenancy-squad
/public/app/features/manage-dashboards/ @grafana/dashboards-squad
/public/app/features/notifications/ @grafana/user-essentials
/public/app/features/org/ @grafana/user-essentials
/public/app/features/panel/ @grafana/user-essentials
/public/app/features/playlist/ @grafana/dashboards-squad
/public/app/features/plugins/ @grafana/plugins-platform-frontend
/public/app/features/profile/ @grafana/user-essentials
/public/app/features/runtime/ @ryantxu
/public/app/features/query/ @grafana/dashboards-squad
/public/app/features/query-library/ @grafana/grafana-edge-squad
/public/app/features/sandbox/ @grafana/user-essentials
/public/app/features/scenes/ @grafana/dashboards-squad
/public/app/features/search/ @grafana/user-essentials
/public/app/features/serviceaccounts/ @grafana/grafana-authnz-team
/public/app/features/storage/ @grafana/multitenancy-squad
/public/app/features/teams/ @grafana/grafana-authnz-team
/public/app/features/templating/ @grafana/dashboards-squad
/public/app/features/transformers/ @grafana/grafana-edge-squad
/public/app/features/users/ @grafana/grafana-authnz-team
/public/app/features/variables/ @grafana/dashboards-squad
/public/app/plugins/panel/alertGroups/ @grafana/alerting-squad-frontend
/public/app/plugins/panel/alertlist/ @grafana/alerting-squad-frontend
/public/app/plugins/panel/annolist/ @grafana/user-essentials
/public/app/plugins/panel/barchart/ @grafana/grafana-bi-squad
/public/app/plugins/panel/bargauge/ @grafana/user-essentials
/public/app/plugins/panel/dashlist/ @grafana/user-essentials
/public/app/plugins/panel/debug/ @ryantxu
/public/app/plugins/panel/gauge/ @grafana/user-essentials
/public/app/plugins/panel/gettingstarted/ @grafana/user-essentials
/public/app/plugins/panel/graph/ @grafana/user-essentials
/public/app/plugins/panel/heatmap/ @grafana/grafana-bi-squad
/public/app/plugins/panel/histogram/ @grafana/grafana-bi-squad
/public/app/plugins/panel/logs/ @grafana/observability-logs
/public/app/plugins/panel/nodeGraph/ @grafana/observability-traces-and-profiling
/public/app/plugins/panel/traces/ @grafana/observability-traces-and-profiling
/public/app/plugins/panel/flamegraph/ @grafana/observability-traces-and-profiling
/public/app/plugins/panel/piechart/ @grafana/grafana-bi-squad
/public/app/plugins/panel/state-timeline/ @grafana/grafana-bi-squad
/public/app/plugins/panel/status-history/ @grafana/grafana-bi-squad
/public/app/plugins/panel/table/ @grafana/grafana-bi-squad
/public/app/plugins/panel/table-old/ @grafana/grafana-bi-squad
/public/app/plugins/panel/timeseries/ @grafana/grafana-bi-squad
/public/app/plugins/panel/geomap/ @grafana/grafana-edge-squad
/public/app/plugins/panel/canvas/ @grafana/grafana-edge-squad
/public/app/plugins/panel/candlestick/ @grafana/grafana-edge-squad
/public/app/plugins/panel/icon/ @grafana/grafana-edge-squad
/public/app/plugins/panel/live/ @grafana/multitenancy-squad
/public/app/plugins/panel/news/ @grafana/user-essentials
/public/app/plugins/panel/stat/ @grafana/user-essentials
/public/app/plugins/panel/text/ @grafana/user-essentials
/public/app/plugins/panel/welcome/ @grafana/user-essentials
/public/app/plugins/panel/xychart/ @grafana/grafana-bi-squad
/public/app/plugins/sdk.ts @grafana/plugins-platform-frontend
/public/app/polyfills/old-mediaquerylist.ts @grafana/user-essentials
/public/app/routes/ @grafana/user-essentials
/public/app/store/ @grafana/user-essentials
/public/app/types/ @grafana/user-essentials
/public/dashboards/ @grafana/dashboards-squad
/public/fonts/ @grafana/alerting-squad-frontend
/public/emails/ @grafana/user-essentials
/public/gazetteer/ @ryantxu
/public/img/ @grafana/user-essentials
/public/lib/ @grafana/user-essentials
/public/maps/ @ryantxu
/public/robots.txt @grafana/frontend-ops
/public/sass/ @grafana/user-essentials
/public/test/ @grafana/user-essentials
/public/testdata/ @grafana/user-essentials
/public/views/ @grafana/user-essentials
/public/app/features/explore/Logs.tsx @grafana/observability-logs
/public/app/features/explore/LogsContainer.tsx @grafana/observability-logs
/public/app/features/explore/TraceView/ @grafana/observability-traces-and-profiling
/public/api-merged.json @grafana/backend-platform
/public/api-spec.json @grafana/backend-platform
/public/openapi3.json @grafana/backend-platform
/public/app/angular/ @torkelo
/public/app/app.ts @grafana/frontend-ops
/public/app/dev.ts @grafana/frontend-ops
/public/app/index.ts @grafana/frontend-ops
/public/app/AppWrapper.tsx @grafana/frontend-ops
/public/app/partials/ @grafana/user-essentials
/scripts/benchmark-access-control.sh @grafana/grafana-authnz-team
/scripts/check-breaking-changes.sh @grafana/plugins-platform-frontend
/scripts/ci-* @grafana/grafana-delivery
/scripts/circle-* @grafana/grafana-delivery
/scripts/ci-frontend-metrics.sh @grafana/user-essentials @grafana/plugins-platform-frontend @grafana/grafana-bi-squad
/scripts/cli/ @grafana/user-essentials
/scripts/clean-git-or-error.sh @grafana/grafana-as-code
/scripts/grafana-server/ @grafana/user-essentials
/scripts/helpers/ @grafana/grafana-delivery
/scripts/import_many_dashboards.sh @torkelo
/scripts/mixin-check.sh @bergquist
/scripts/openapi3/ @grafana/grafana-partnerships-team
/scripts/prepare-packagejson.js @grafana/frontend-ops
/scripts/protobuf-check.sh @grafana/plugins-platform-backend
/scripts/stripnulls.sh @grafana/grafana-as-code
/scripts/tag_release.sh @grafana/grafana-delivery
/scripts/trigger_docker_build.sh @grafana/grafana-delivery
/scripts/trigger_grafana_packer.sh @grafana/grafana-delivery
/scripts/trigger_windows_build.sh @grafana/grafana-delivery
/scripts/validate-devenv-dashboards.sh @grafana/grafana-delivery
/scripts/verify-repo-update/ @grafana/grafana-delivery
/scripts/webpack/ @grafana/frontend-ops
/scripts/generate-a11y-report.sh @grafana/user-essentials
.pa11yci.conf.js @grafana/user-essentials
.pa11yci-pr.conf.js @grafana/user-essentials
.betterer.results @joshhunt
.betterer.ts @joshhunt
# @grafana/ui component documentation
*.mdx @marcusolsson @jessover9000 @grafana/plugins-platform-frontend
*.mdx @grafana/plugins-platform-frontend
# Design system
/public/img/icons/unicons/ @grafana/design-system
# Core datasources
/public/app/plugins/datasource/cloudwatch @grafana/aws-plugins
/public/app/plugins/datasource/elasticsearch @grafana/observability-logs
/public/app/plugins/datasource/grafana-azure-monitor-datasource @grafana/cloud-provider-plugins
/public/app/plugins/datasource/graphite @grafana/observability-metrics
/public/app/plugins/datasource/influxdb @grafana/observability-metrics
/public/app/plugins/datasource/jaeger @grafana/observability-logs-and-traces
/public/app/plugins/datasource/loki @grafana/observability-logs
/public/app/plugins/datasource/mssql @grafana/grafana-bi-squad
/public/app/plugins/datasource/mysql @grafana/grafana-bi-squad
/public/app/plugins/datasource/opentsdb @grafana/backend-platform
/public/app/plugins/datasource/postgres @grafana/grafana-bi-squad
/public/app/plugins/datasource/prometheus @grafana/observability-metrics
/public/app/plugins/datasource/cloud-monitoring @grafana/cloud-provider-plugins
/public/app/plugins/datasource/zipkin @grafana/observability-logs-and-traces
/public/app/plugins/datasource/tempo @grafana/observability-logs-and-traces
/public/app/plugins/datasource/alertmanager @grafana/alerting-squad
/public/app/plugins/datasource/dashboard/ @grafana/dashboards-squad
/public/app/plugins/datasource/cloudwatch/ @grafana/aws-plugins
/public/app/plugins/datasource/elasticsearch/ @grafana/observability-logs
/public/app/plugins/datasource/grafana/ @grafana/user-essentials
/public/app/plugins/datasource/testdata/ @grafana/plugins-platform-frontend
/public/app/plugins/datasource/grafana-azure-monitor-datasource/ @grafana/partner-plugins
/public/app/plugins/datasource/graphite/ @grafana/observability-metrics
/public/app/plugins/datasource/influxdb/ @grafana/observability-metrics
/public/app/plugins/datasource/jaeger/ @grafana/observability-traces-and-profiling
/public/app/plugins/datasource/loki/ @grafana/observability-logs
/public/app/plugins/datasource/mixed/ @grafana/dashboards-squad
/public/app/plugins/datasource/mssql/ @grafana/grafana-bi-squad
/public/app/plugins/datasource/mysql/ @grafana/grafana-bi-squad
/public/app/plugins/datasource/opentsdb/ @grafana/backend-platform
/public/app/plugins/datasource/postgres/ @grafana/grafana-bi-squad
/public/app/plugins/datasource/prometheus/ @grafana/observability-metrics
/public/app/plugins/datasource/cloud-monitoring/ @grafana/partner-plugins
/public/app/plugins/datasource/zipkin/ @grafana/observability-traces-and-profiling
/public/app/plugins/datasource/tempo/ @grafana/observability-traces-and-profiling
/public/app/plugins/datasource/phlare/ @grafana/observability-traces-and-profiling
/public/app/plugins/datasource/parca/ @grafana/observability-traces-and-profiling
/public/app/plugins/datasource/alertmanager/ @grafana/alerting-squad
# SSE - Server Side Expressions
/pkg/expr/ @grafana/observability-metrics
# Cloud middleware
/grafana-mixin/ @grafana/hosted-grafana-team
# Grafana authentication and authorization
/pkg/services/accesscontrol @grafana/grafana-authnz-team
/pkg/services/auth @grafana/grafana-authnz-team
/pkg/login/ @grafana/grafana-authnz-team
/pkg/services/accesscontrol/ @grafana/grafana-authnz-team
/pkg/services/anonymous/ @grafana/grafana-authnz-team
/pkg/services/auth/ @grafana/grafana-authnz-team
/pkg/services/authn/ @grafana/grafana-authnz-team
/pkg/services/dashboards/accesscontrol.go @grafana/grafana-authnz-team
/pkg/services/datasources/permissions @grafana/grafana-authnz-team
/pkg/services/datasources/permissions/accesscontrol.go @grafana/grafana-authnz-team
/pkg/services/guardian @grafana/grafana-authnz-team
/pkg/services/ldap @grafana/grafana-authnz-team
/pkg/services/login @grafana/grafana-authnz-team
/pkg/services/multildap @grafana/grafana-authnz-team
/pkg/services/oauthtoken @grafana/grafana-authnz-team
/pkg/services/teamguardian @grafana/grafana-authnz-team
/pkg/services/serviceaccounts @grafana/grafana-authnz-team
/pkg/services/datasources/permissions/ @grafana/grafana-authnz-team
/pkg/services/guardian/ @grafana/grafana-authnz-team
/pkg/services/ldap/ @grafana/grafana-authnz-team
/pkg/services/login/ @grafana/grafana-authnz-team
/pkg/services/multildap/ @grafana/grafana-authnz-team
/pkg/services/loginattempt/ @grafana/grafana-authnz-team
/pkg/services/oauthtoken/ @grafana/grafana-authnz-team
/pkg/services/serviceaccounts/ @grafana/grafana-authnz-team
/pkg/services/teamguardian/ @grafana/grafana-authnz-team
# Support bundles
/public/app/features/support-bundles/ @grafana/grafana-authnz-team
/pkg/services/supportbundles/ @grafana/grafana-authnz-team
# Grafana Partnerships Team
/pkg/infra/httpclient/httpclientprovider/sigv4_middleware.go @grafana/grafana-partnerships-team
/pkg/infra/httpclient/httpclientprovider/sigv4_middleware_test.go @grafana/grafana-partnerships-team
# Kind definitions
/kinds/dashboard @grafana/dashboards-squad
/kinds/ @grafana/grafana-as-code
# Kind system and code generation
embed.go @grafana/grafana-as-code
/pkg/kinds/ @grafana/grafana-as-code
/pkg/cuectx/ @grafana/grafana-as-code
/pkg/registry/ @grafana/grafana-as-code
/pkg/codegen/ @grafana/grafana-as-code
/pkg/kindsys/ @grafana/grafana-as-code
/pkg/kindsys/kindcat_custom.cue @grafana/apps-platform-core
/pkg/kinds/*/*_gen.go @grafana/grafana-as-code
/pkg/registry/corekind/ @grafana/grafana-as-code
/public/app/plugins/*gen.go @grafana/grafana-as-code
/cue.mod/ @grafana/grafana-as-code
# GitHub Workflows and Templates
/.github/CODEOWNERS @tolzhabayev
/.github/ISSUE_TEMPLATE/ @torkelo
/.github/PULL_REQUEST_TEMPLATE.md @torkelo
/.github/bot.md @torkelo
/.github/commands.json @torkelo
/.github/dependabot.yml @grafana/frontend-ops
/.github/metrics-collector.json @torkelo
/.github/pr-checks.json @marefr
/.github/pr-commands.json @marefr
/.github/renovate.json5 @grafana/frontend-ops
/.github/teams.yml @armandgrillet
/.github/workflows/auto-milestone.yml @grafana/grafana-delivery
/.github/workflows/backport.yml @grafana/grafana-delivery
/.github/workflows/bump-version.yml @grafana/grafana-delivery
/.github/workflows/close-milestone.yml @grafana/grafana-delivery
/.github/workflows/cloud-data-sources-code-coverage.yml @grafana/partner-plugins @grafana/aws-plugins
/.github/workflows/codeowners-validator.yml @tolzhabayev
/.github/workflows/codeql-analysis.yml @DanCech
/.github/workflows/commands.yml @torkelo
/.github/workflows/detect-breaking-changes-* @grafana/plugins-platform-frontend
/.github/workflows/doc-validator.yml @grafana/docs-grafana
/.github/workflows/enterprise-pr-check.yml @grafana/grafana-release-eng
/.github/workflows/epic-add-to-platform-ux-parent-project.yml @meanmina
/.github/workflows/github-release.yml @torkelo
/.github/workflows/issue-labeled.yml @armandgrillet
/.github/workflows/metrics-collector.yml @torkelo
/.github/workflows/milestone.yml @marefr
/.github/workflows/ox-code-coverage.yml @grafana/explore-squad
/.github/workflows/pr-checks.yml @marefr
/.github/workflows/pr-codeql-analysis-go.yml @DanCech
/.github/workflows/pr-codeql-analysis-javascript.yml @DanCech
/.github/workflows/pr-codeql-analysis-python.yml @DanCech
/.github/workflows/pr-commands-closed.yml @tolzhabayev
/.github/workflows/pr-commands.yml @marefr
/.github/workflows/pr-patch-check.yml @grafana/grafana-delivery
/.github/workflows/sync-mirror.yml @grafana/grafana-delivery
/.github/workflows/publish-technical-documentation-next.yml @grafana/docs-grafana
/.github/workflows/publish-technical-documentation-release.yml @grafana/docs-grafana
/.github/workflows/remove-milestone.yml @grafana/user-essentials
/.github/workflows/sbom-report.yml @grafana/security-team
/.github/workflows/scripts/json-file-to-job-output.js @grafana/plugins-platform-frontend
/.github/workflows/scripts/pr-get-job-link.js @grafana/plugins-platform-frontend
/.github/workflows/stale.yml @grafana/user-essentials
/.github/workflows/update-changelog.yml @grafana/grafana-delivery
/.github/workflows/snyk.yml @grafana/security-team
# Conf
/conf/defaults.ini @torkelo
/conf/sample.ini @torkelo
/conf/ldap.toml @grafana/grafana-authnz-team
/conf/ldap_multiple.toml @grafana/grafana-authnz-team
/conf/provisioning/access-control/ @grafana/grafana-authnz-team
/conf/provisioning/alerting/ @grafana/alerting-squad-backend
/conf/provisioning/dashboards/ @grafana/dashboards-squad
/conf/provisioning/datasources/ @grafana/plugins-platform-backend
/conf/provisioning/notifiers/ @bergquist
/conf/provisioning/plugins/ @grafana/plugins-platform-backend

View File

@@ -14,11 +14,23 @@ Thank you for sending a pull request! Here are some tips:
6. Name your PR as "<FeatureArea>: Describe your change", e.g. Alerting: Prevent race condition. If it's a fix or feature relevant for the changelog describe the user impact in the title. The PR title is used to auto-generate the changelog for issues marked with the "add to changelog" label.
7. If your PR content should be added to the What's New document for the next major or minor release, add the **add to what's new** label to your PR. Note that you should add this label to the main PR that introduces the feature; do not add this label to smaller PRs for the feature.
-->
**What this PR does / why we need it**:
**What is this feature?**
**Which issue(s) this PR fixes**:
[Add a brief description of what the feature or update does.]
**Why do we need this feature?**
[Add a description of the problem the feature is trying to solve.]
**Who is this feature for?**
[Add information on what kind of user the feature is for.]
**Which issue(s) does this PR fix?**:
<!--

31
.github/commands.json vendored
View File

@@ -41,6 +41,7 @@
"type":"label",
"name":"bot/no new info",
"action":"close",
"removeLabel":"needs more info",
"comment":"We've closed this issue since it needs more information and hasn't had any activity recently. We can re-open it after you you add more information. To avoid having your issue closed in the future, please read our [CONTRIBUTING](https://github.com/grafana/grafana/blob/main/CONTRIBUTING.md) guidelines.\n\nHappy graphing!"
},
{
@@ -151,7 +152,23 @@
"name":"datasource/Tempo",
"action":"addToProject",
"addToProject":{
"url":"https://github.com/orgs/grafana/projects/110"
"url":"https://github.com/orgs/grafana/projects/221"
}
},
{
"type":"label",
"name":"datasource/Phlare",
"action":"addToProject",
"addToProject":{
"url":"https://github.com/orgs/grafana/projects/221"
}
},
{
"type":"label",
"name":"datasource/Parca",
"action":"addToProject",
"addToProject":{
"url":"https://github.com/orgs/grafana/projects/221"
}
},
{
@@ -167,7 +184,7 @@
"name":"datasource/Jaeger",
"action":"addToProject",
"addToProject":{
"url":"https://github.com/orgs/grafana/projects/110"
"url":"https://github.com/orgs/grafana/projects/221"
}
},
{
@@ -175,7 +192,7 @@
"name":"datasource/Zipkin",
"action":"addToProject",
"addToProject":{
"url":"https://github.com/orgs/grafana/projects/110"
"url":"https://github.com/orgs/grafana/projects/221"
}
},
{
@@ -297,5 +314,13 @@
"addToProject": {
"url": "https://github.com/orgs/grafana/projects/86"
}
},
{
"type": "label",
"name": "area/internationalization",
"action": "addToProject",
"addToProject": {
"url": "https://github.com/orgs/grafana/projects/78"
}
}
]

View File

@@ -16,6 +16,10 @@
"name": "needs_more_info",
"query": "label:\"needs more info\" is:open"
},
{
"name": "triage_needs_confirmation",
"query": "label:\"triage/needs-confirmation\" is:open"
},
{
"name": "unlabeled",
"query": "is:open is:issue no:label"
@@ -23,10 +27,6 @@
{
"name": "open_prs",
"query": "is:open is:pr"
},
{
"name": "milestone_7_4_open",
"query": "is:open is:issue milestone:7.4"
}
]
}

View File

@@ -46,4 +46,4 @@
},
"targetUrl": "https://github.com/grafana/grafana/blob/main/contribute/merge-pull-request.md#include-in-changelog-and-release-notes"
}
]
]

View File

@@ -66,8 +66,7 @@
"scripts/build/**/*",
"scripts/*.sh",
"Makefile",
"Dockerfile",
"Dockerfile.ubuntu"
"Dockerfile"
],
"action": "updateLabel",
"addLabel": "type/build-packaging"

View File

@@ -5,22 +5,13 @@
"enabledManagers": ["npm"],
"ignoreDeps": [
"@types/systemjs",
"@types/d3-force", // we should bump this once we move to esm modules
"@types/d3-interpolate", // we should bump this once we move to esm modules
"@types/d3-scale-chromatic", // we should bump this once we move to esm modules
"@types/react-icons", // jaeger-ui-components is being refactored to use @grafana/ui icons instead
"commander", // we are planning to remove this, so no need to update it
"d3",
"d3-force", // we should bump this once we move to esm modules
"d3-interpolate", // we should bump this once we move to esm modules
"d3-scale-chromatic", // we should bump this once we move to esm modules
"execa", // we should bump this once we move to esm modules
"history", // we should bump this together with react-router-dom
"@mdx-js/react", // storybook peer-depends on it's 1.x version, we should upgrade this when we upgrade storybook
"@mdx-js/react", // storybook peer-depends on its 1.x version, we should upgrade this when we upgrade storybook
"monaco-editor", // due to us exposing this via @grafana/ui/CodeEditor's props bumping can break plugins
"node-fetch", // we should bump this once we move to esm modules
"react-hook-form", // due to us exposing these hooks via @grafana/ui form components bumping can break plugins
"react-icons", // jaeger-ui-components is being refactored to use @grafana/ui icons instead
"react-redux", // react-beautiful-dnd depends on react-redux 7.x, we need to update that one first
"react-router-dom", // we should bump this together with history
"systemjs",
@@ -28,6 +19,12 @@
"ts-loader", // we should remove ts-loader and use babel-loader instead
"ora", // we should bump this once we move to esm modules
// Sentry deprecated in favor of Grafana Faro for frontend logging.
// Major effort required to upgrade to latest Sentry, not worthwhile
"@sentry/browser",
"@sentry/types",
"@sentry/utils",
// dep updates blocked by React 18
"@testing-library/react",
"@types/react",
@@ -37,6 +34,7 @@
"react-dom",
"react-test-renderer"
],
"includePaths": ["package.json", "packages/**"],
"ignorePaths": ["packages/grafana-toolkit/package.json", "emails/**", "plugins-bundled/**", "**/mocks/**"],
"labels": ["area/frontend", "dependencies", "no-backport", "no-changelog"],
"packageRules": [
@@ -50,12 +48,49 @@
"matchPackagePatterns": ["@storybook"],
"extends": ["schedule:monthly"],
"groupName": "Storybook updates"
},
{
"groupName": "React Aria",
"matchPackagePrefixes": [
"@react-aria/",
"@react-stately/"
]
},
{
"groupName": "Moveable",
"matchPackageNames": [
"moveable",
"react-moveable"
]
},
{
"groupName": "Slate",
"matchPackageNames": [
"@types/slate",
"@types/slate-react",
"slate",
"slate-react"
]
},
{
"groupName": "d3",
"matchPackagePrefixes": [
"d3",
"@types/d3"
]
},
{
"groupName": "visx",
"matchPackagePrefixes": [
"@visx/"
]
}
],
"pin": {
"enabled": false
},
"prConcurrentLimit": 10,
"rebaseWhen": "conflicted",
"reviewers": ["team:grafana/frontend-ops"],
"separateMajorMinor": false,
"vulnerabilityAlerts": {

1
.github/teams.yml vendored
View File

@@ -7,4 +7,5 @@ test:
# Alerting team
area/alerting:
github-board: 52
channel-label: C02B9MXQE0J

24
.github/workflows/auto-milestone.yml vendored Normal file
View File

@@ -0,0 +1,24 @@
name: Auto-milestone
on:
pull_request:
types:
- opened
- reopened
- closed
jobs:
main:
runs-on: ubuntu-latest
steps:
- name: "Generate token"
id: generate_token
uses: tibdex/github-app-token@b62528385c34dbc9f38e5f4225ac829252d1ea92
with:
app_id: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_ID }}
private_key: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_PEM }}
- name: Run auto-milestone
uses: grafana/grafana-github-actions-go/auto-milestone@main
with:
pr: ${{ github.event.pull_request.number }}
token: ${{ steps.generate_token.outputs.token }}

View File

@@ -17,10 +17,16 @@ jobs:
ref: main
- name: Install Actions
run: npm install --production --prefix ./actions
- name: "Generate token"
id: generate_token
uses: tibdex/github-app-token@b62528385c34dbc9f38e5f4225ac829252d1ea92
with:
app_id: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_ID }}
private_key: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_PEM }}
- name: Run backport
uses: ./actions/backport
with:
metricsWriteAPIKey: ${{secrets.GRAFANA_MISC_STATS_API_KEY}}
token: ${{secrets.GH_BOT_ACCESS_TOKEN}}
token: ${{ steps.generate_token.outputs.token }}
labelsToAdd: "backport,no-changelog"
title: "[{{base}}] {{originalTitle}}"

View File

@@ -3,32 +3,21 @@ on:
workflow_dispatch:
inputs:
version:
description: 'Needs to match, exactly, the name of a milestone. The version to be released please respect: major.minor.patch or major.minor.patch-beta<number> format. example: 7.4.3 or 7.4.3-beta1'
required: true
default: '7.x.x'
workflow_call:
inputs:
version_call:
description: Needs to match, exactly, the name of a version
required: true
type: string
secrets:
token:
required: true
metricsWriteAPIKey:
required: true
env:
YARN_ENABLE_IMMUTABLE_INSTALLS: false
YARN_ENABLE_IMMUTABLE_INSTALLS: false
jobs:
main:
runs-on: ubuntu-latest
steps:
# This is a basic workflow to help you get started with Actions
# This is a basic workflow to help you get started with Actions
- uses: actions-ecosystem/action-regex-match@v2.0.2
if: ${{ github.event.inputs.version != '' }}
id: regex-match
with:
text: ${{ github.event.inputs.version }}
regex: '^(\d+.\d+).\d+(?:-beta.\d+)?$'
regex: '^(\d+.\d+).\d+(?:-beta\d+)?$'
- uses: actions-ecosystem/action-regex-match@v2.0.2
if: ${{ inputs.version_call != '' }}
id: regex-match-version-call
@@ -40,7 +29,7 @@ jobs:
run: |
echo "The input version format is not correct, please respect:\
major.minor.patch or major.minor.patch-beta.number format. \
example: 7.4.3 or 7.4.3-beta.1"
example: 7.4.3 or 7.4.3-beta1"
exit 1
- name: Validate input version call
if: ${{ inputs.version_call != '' && steps.regex-match-version-call.outputs.match == '' }}
@@ -55,10 +44,10 @@ jobs:
- name: Set intermedia variables
id: intermedia
run: |
echo "::set-output name=short_ref::${GITHUB_REF#refs/*/}"
echo "::set-output name=check_passed::false"
echo "::set-output name=branch_name::v${{steps.regex-match.outputs.group1}}"
echo "::set-output name=branch_exist::$(git ls-remote --heads https://github.com/grafana/grafana.git v${{ steps.regex-match.outputs.group1 }}.x | wc -l)"
echo "short_ref=${GITHUB_REF#refs/*/}" >> $GITHUB_OUTPUT
echo "check_passed=false" >> $GITHUB_OUTPUT
echo "branch_name=v${{steps.regex-match.outputs.group1}}" >> $GITHUB_OUTPUT
echo "branch_exist=$(git ls-remote --heads https://github.com/grafana/grafana.git v${{ steps.regex-match.outputs.group1 }}.x | wc -l)" >> $GITHUB_OUTPUT
- name: Check input version is aligned with branch(main)
if: ${{ github.event.inputs.version != '' && steps.intermedia.outputs.branch_exist == '0' && !contains(steps.intermedia.outputs.short_ref, 'main') }}
@@ -74,21 +63,19 @@ jobs:
repository: "grafana/grafana-github-actions"
path: ./actions
ref: main
- uses: actions/setup-node@v3.4.0
- uses: actions/setup-node@v3.5.1
with:
node-version: '16'
- name: Install Actions
run: npm install --production --prefix ./actions
- name: "Generate token"
id: generate_token
uses: tibdex/github-app-token@b62528385c34dbc9f38e5f4225ac829252d1ea92
with:
app_id: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_ID }}
private_key: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_PEM }}
- name: Run bump version (manually invoked)
if: ${{ github.event.inputs.version != '' }}
uses: ./actions/bump-version
with:
token: ${{ secrets.GH_BOT_ACCESS_TOKEN }}
token: ${{ steps.generate_token.outputs.token }}
metricsWriteAPIKey: ${{ secrets.GRAFANA_MISC_STATS_API_KEY }}
- name: Run bump version (workflow invoked)
if: ${{ inputs.version_call != '' }}
uses: ./actions/bump-version
with:
version_call: ${{ inputs.version_call }}
token: ${{ secrets.token }}
metricsWriteAPIKey: ${{ secrets.metricsWriteAPIKey }}

View File

@@ -11,9 +11,7 @@ on:
description: Needs to match, exactly, the name of a milestone
required: true
type: string
secrets:
token:
required: true
jobs:
main:
runs-on: ubuntu-latest
@@ -26,14 +24,20 @@ jobs:
ref: main
- name: Install Actions
run: npm install --production --prefix ./actions
- name: "Generate token"
id: generate_token
uses: tibdex/github-app-token@b62528385c34dbc9f38e5f4225ac829252d1ea92
with:
app_id: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_ID }}
private_key: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_PEM }}
- name: Close milestone (manually invoked)
if: ${{ github.event.inputs.version != '' }}
uses: ./actions/close-milestone
with:
token: ${{ secrets.GH_BOT_ACCESS_TOKEN }}
token: ${{ steps.generate_token.outputs.token }}
- name: Close milestone (workflow invoked)
if: ${{ inputs.version_call != '' }}
uses: ./actions/close-milestone
with:
version_call: ${{ inputs.version_call }}
token: ${{ secrets.token }}
token: ${{ steps.generate_token.outputs.token }}

View File

@@ -14,7 +14,7 @@ on:
jobs:
workflow-call:
uses: grafana/code-coverage/.github/workflows/code-coverage.yml@v0.1.6
uses: grafana/code-coverage/.github/workflows/code-coverage.yml@v0.1.18
with:
frontend-path-regexp: public\/app\/plugins\/datasource\/(grafana-azure-monitor-datasource|cloud-monitoring|cloudwatch)
backend-path-regexp: pkg\/tsdb\/(azuremonitor|cloudmonitoring|cloudwatch)

View File

@@ -0,0 +1,38 @@
name: "Codeowners Validator"
on:
pull_request:
branches: [ main ]
jobs:
codeowners-validator:
runs-on: ubuntu-latest
steps:
# Checks-out your repository, which is validated in the next step
- uses: actions/checkout@v2
- name: GitHub CODEOWNERS Validator
uses: mszostok/codeowners-validator@v0.7.4
# input parameters
with:
# ==== GitHub Auth ====
# "The list of checks that will be executed. By default, all checks are executed. Possible values: files,owners,duppatterns,syntax"
checks: "files,duppatterns,syntax"
# "The comma-separated list of experimental checks that should be executed. By default, all experimental checks are turned off. Possible values: notowned,avoid-shadowing"
experimental_checks: "notowned,avoid-shadowing"
# The repository path in which CODEOWNERS file should be validated."
repository_path: "."
# Defines the level on which the application should treat check issues as failures. Defaults to warning, which treats both errors and warnings as failures, and exits with error code 3. Possible values are error and warning. Default: warning"
check_failure_level: "error"
# The comma-separated list of patterns that should be ignored by not-owned-checker. For example, you can specify * and as a result, the * pattern from the CODEOWNERS file will be ignored and files owned by this pattern will be reported as unowned unless a later specific pattern will match that path. It's useful because often we have default owners entry at the begging of the CODOEWNERS file, e.g. * @global-owner1 @global-owner2"
not_owned_checker_skip_patterns: ""
# Specifies whether CODEOWNERS may have unowned files. For example, `/infra/oncall-rotator/oncall-config.yml` doesn't have owner and this is not reported.
owner_checker_allow_unowned_patterns: "false"
# Specifies whether only teams are allowed as owners of files.
owner_checker_owners_must_be_teams: "false"

View File

@@ -6,6 +6,7 @@
name: "CodeQL"
on:
workflow_dispatch:
push:
branches: [main, v1.8.x, v2.0.x, v2.1.x, v2.6.x, v3.0.x, v3.1.x, v4.0.x, v4.1.x, v4.2.x, v4.3.x, v4.4.x, v4.5.x, v4.6.x, v4.7.x, v5.0.x, v5.1.x, v5.2.x, v5.3.x, v5.4.x, v6.0.x, v6.1.x, v6.2.x, v6.3.x, v6.4.x, v6.5.x, v6.6.x, v6.7.x, v7.0.x, v7.1.x, v7.2.x]
paths-ignore:
@@ -39,6 +40,12 @@ jobs:
# a pull request then we can checkout the head.
fetch-depth: 2
- if: matrix.language == 'go'
name: Set go version
uses: actions/setup-go@v3
with:
go-version: '1.20.10'
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
@@ -49,5 +56,11 @@ jobs:
# Prefix the list here with "+" to use these queries and those in the config file.
# queries: ./path/to/local/query, your-org/your-repo/queries@main
- if: matrix.language == 'go'
name: Build go files
run: |
go mod verify
make build-go
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2

View File

@@ -0,0 +1,34 @@
# Workflow for skipping the Levitate detection
# (This is needed because workflows that are skipped due to path filtering will show up as pending in Github.
# As this has the same name as the one in detect-breaking-changes-build.yml it will take over in these cases and succeed quickly.)
name: Levitate / Detect breaking changes
on:
pull_request:
paths-ignore:
- "packages/**"
branches:
- 'main'
jobs:
detect:
name: Detect breaking changes
runs-on: ubuntu-latest
steps:
- name: Skipping
run: echo "No modifications in the public API (packages/), skipping."
# Build and persist output as a JSON (we need to tell the report workflow that the check has been skipped)
- name: Persisting the check output
run: |
mkdir -p ./levitate
echo "{ \"shouldSkip\": true }" > ./levitate/result.json
# Upload artifact (so it can be used in the more privileged "report" workflow)
- name: Upload check output as artifact
uses: actions/upload-artifact@v3
with:
name: levitate
path: levitate/

View File

@@ -1,6 +1,14 @@
# Only runs if anything under the packages/ directory changes.
# (Otherwise detect-breaking-changes-build-skip.yml takes over)
name: Levitate / Detect breaking changes
on: pull_request
on:
pull_request:
paths:
- 'packages/**'
branches:
- 'main'
jobs:
buildPR:
@@ -12,34 +20,36 @@ jobs:
steps:
- uses: actions/checkout@v3
with:
with:
path: './pr'
- uses: actions/setup-node@v3
- uses: actions/setup-node@v3.5.1
with:
node-version: 16.16.0
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"
run: echo "dir=$(yarn config get cacheFolder)" >> $GITHUB_OUTPUT
- name: Restore yarn cache
uses: actions/cache@v2
uses: actions/cache@v3.0.11
id: yarn-cache
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: yarn-cache-folder-${{ hashFiles('**/yarn.lock', '.yarnrc.yml') }}
restore-keys: |
yarn-cache-folder-
- name: Install dependencies
run: yarn install --immutable
- name: Build packages
run: yarn packages:build
- name: Zip built packages
run: zip -r ./pr_built_packages.zip ./packages/**/dist
- name: Pack packages
run: yarn packages:pack --out ./%s.tgz
- name: Zip built tarballed packages
run: zip -r ./pr_built_packages.zip ./packages/**/*.tgz
- name: Upload build output as artifact
uses: actions/upload-artifact@v3
@@ -56,35 +66,38 @@ jobs:
steps:
- uses: actions/checkout@v3
with:
with:
path: './base'
ref: ${{ github.event.pull_request.base.ref }}
- uses: actions/setup-node@v3
- uses: actions/setup-node@v3.5.1
with:
node-version: 16.16.0
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"
run: echo "dir=$(yarn config get cacheFolder)" >> $GITHUB_OUTPUT
- name: Restore yarn cache
uses: actions/cache@v2
uses: actions/cache@v3.0.11
id: yarn-cache
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: yarn-cache-folder-${{ hashFiles('**/yarn.lock', '.yarnrc.yml') }}
restore-keys: |
yarn-cache-folder-
- name: Install dependencies
run: yarn install --immutable
- name: Build packages
run: yarn packages:build
- name: Zip built packages
run: zip -r ./base_built_packages.zip ./packages/**/dist
- name: Pack packages
run: yarn packages:pack --out ./%s.tgz
- name: Zip built tarballed packages
run: zip -r ./base_built_packages.zip ./packages/**/*.tgz
- name: Upload build output as artifact
uses: actions/upload-artifact@v3
@@ -97,7 +110,7 @@ jobs:
runs-on: ubuntu-latest
needs: ['buildPR', 'buildBase']
env:
GITHUB_STEP_NUMBER: 7
GITHUB_STEP_NUMBER: 8
steps:
- uses: actions/checkout@v3
@@ -111,24 +124,25 @@ jobs:
uses: actions/download-artifact@v3
with:
name: buildBase
- name: Unzip artifact from pr
run: unzip pr_built_packages.zip -d ./pr && rm pr_built_packages.zip
run: unzip -j pr_built_packages.zip -d ./pr && rm pr_built_packages.zip
- name: Unzip artifact from base
run: unzip base_built_packages.zip -d ./base && rm base_built_packages.zip
run: unzip -j base_built_packages.zip -d ./base && rm base_built_packages.zip
- name: Get link for the Github Action job
id: job
uses: actions/github-script@v6
with:
script: |
const name = 'Detect breaking changes';
const script = require('./.github/workflows/scripts/pr-get-job-link.js')
await script({github, context, core})
await script({name, github, context, core})
- name: Detect breaking changes
id: breaking-changes
run: ./scripts/check-breaking-changes.sh
run: ./scripts/check-breaking-changes.sh
env:
FORCE_COLOR: 3
GITHUB_JOB_LINK: ${{ steps.job.outputs.link }}
@@ -143,7 +157,7 @@ jobs:
with:
name: levitate
path: levitate/
- name: Exit
run: exit ${{ steps.breaking-changes.outputs.is_breaking }}
shell: bash

View File

@@ -10,12 +10,13 @@ jobs:
name: Report
runs-on: ubuntu-latest
env:
ARTIFACT_FOLDER: '${{ github.workspace }}/tmp'
ARTIFACT_NAME: 'levitate'
ARTIFACT_NAME: 'levitate' # The name of the artifact that we would like to download
ARTIFACT_FOLDER: '${{ github.workspace }}/tmp' # The name of the folder where we will download the artifact to
steps:
- uses: actions/checkout@v3
# Download artifact (as a .zip archive)
- name: 'Download artifact'
uses: actions/github-script@v6
env:
@@ -49,9 +50,12 @@ jobs:
fs.mkdirSync(artifactFolder, { recursive: true });
fs.writeFileSync(`${ artifactFolder }/${ artifactName }.zip`, Buffer.from(download.data));
# Unzip artifact
- name: Unzip artifact
run: unzip "${ARTIFACT_FOLDER}/${ARTIFACT_NAME}.zip" -d "${ARTIFACT_FOLDER}"
# Parse the artifact and register fields as step output variables
# (All fields in the JSON will be available as ${{ steps.levitate-run.outputs.<field-name> }}
- name: Parsing levitate result
uses: actions/github-script@v6
id: levitate-run
@@ -61,8 +65,15 @@ jobs:
const script = require('./.github/workflows/scripts/json-file-to-job-output.js');
await script({ core, filePath });
# Skip - print a message if the "Detect" workflow was skipped
- name: Check if the workflow should be skipped
if: steps.levitate-run.outputs.shouldSkip == 'true'
run: echo "Skipping."
# Check if label exists
- name: Check if "levitate breaking change" label exists
id: does-label-exist
if: steps.levitate-run.outputs.shouldSkip != 'true'
uses: actions/github-script@v6
env:
PR_NUMBER: ${{ github.event.workflow_run.pull_requests[0].number }}
@@ -78,8 +89,9 @@ jobs:
return doesExist ? 1 : 0;
# Comment on the PR
- name: Comment on PR
if: ${{ steps.levitate-run.outputs.exit_code == 1 }}
if: steps.levitate-run.outputs.exit_code == 1 && steps.levitate-run.outputs.shouldSkip != 'true'
uses: marocchino/sticky-pull-request-comment@v2
with:
number: ${{ steps.levitate-run.outputs.pr_number }}
@@ -93,8 +105,9 @@ jobs:
[Console output](${{ steps.levitate-run.outputs.job_link }})
[Read our guideline](https://github.com/grafana/grafana/blob/main/contribute/breaking-changes-guide.md)
- name: Remove comment on PR
if: ${{ steps.levitate-run.outputs.exit_code == 0 }}
# Remove comment from the PR (no more breaking changes)
- name: Remove comment from PR
if: steps.levitate-run.outputs.exit_code == 0 && steps.levitate-run.outputs.shouldSkip != 'true'
uses: marocchino/sticky-pull-request-comment@v2
with:
number: ${{ steps.levitate-run.outputs.pr_number }}
@@ -103,8 +116,8 @@ jobs:
# Posts a notification to Slack if a PR has a breaking change and it did not have a breaking change before
- name: Post to Slack
id: slack
if: ${{ steps.levitate-run.outputs.exit_code == 1 && steps.does-label-exist.outputs.result == 0 }}
uses: slackapi/slack-github-action@v1.19.0
if: steps.levitate-run.outputs.exit_code == 1 && steps.does-label-exist.outputs.result == 0 && steps.levitate-run.outputs.shouldSkip != 'true'
uses: slackapi/slack-github-action@v1.23.0
with:
payload: |
{
@@ -117,8 +130,9 @@ jobs:
env:
SLACK_WEBHOOK_URL: ${{ secrets.SLACK_LEVITATE_WEBHOOK_URL }}
# Add the label
- name: Add "levitate breaking change" label
if: ${{ steps.levitate-run.outputs.exit_code == 1 && steps.does-label-exist.outputs.result == 0 }}
if: steps.levitate-run.outputs.exit_code == 1 && steps.does-label-exist.outputs.result == 0 && steps.levitate-run.outputs.shouldSkip != 'true'
uses: actions/github-script@v6
env:
PR_NUMBER: ${{ steps.levitate-run.outputs.pr_number }}
@@ -132,8 +146,9 @@ jobs:
labels: ['levitate breaking change']
})
# Remove label (no more breaking changes)
- name: Remove "levitate breaking change" label
if: ${{ steps.levitate-run.outputs.exit_code == 0 && steps.does-label-exist.outputs.result == 1 }}
if: steps.levitate-run.outputs.exit_code == 0 && steps.does-label-exist.outputs.result == 1 && steps.levitate-run.outputs.shouldSkip != 'true'
uses: actions/github-script@v6
env:
PR_NUMBER: ${{ steps.levitate-run.outputs.pr_number }}
@@ -147,10 +162,11 @@ jobs:
name: 'levitate breaking change'
})
# Add reviewers
# This is very weird, the actual request goes through (comes back with a 201), but does not assign the team.
# Related issue: https://github.com/renovatebot/renovate/issues/1908
- name: Add "grafana/plugins-platform-frontend" as a reviewer
if: ${{ steps.levitate-run.outputs.exit_code == 1 }}
if: steps.levitate-run.outputs.exit_code && steps.levitate-run.outputs.shouldSkip != 'true'
uses: actions/github-script@v6
env:
PR_NUMBER: ${{ steps.levitate-run.outputs.pr_number }}
@@ -165,8 +181,9 @@ jobs:
team_reviewers: ['grafana/plugins-platform-frontend']
});
# Remove reviewers (no more breaking changes)
- name: Remove "grafana/plugins-platform-frontend" from the list of reviewers
if: ${{ steps.levitate-run.outputs.exit_code == 0 }}
if: steps.levitate-run.outputs.exit_code == 0 && steps.levitate-run.outputs.shouldSkip != 'true'
uses: actions/github-script@v6
env:
PR_NUMBER: ${{ steps.levitate-run.outputs.pr_number }}

View File

@@ -7,10 +7,10 @@ jobs:
doc-validator:
runs-on: "ubuntu-latest"
container:
image: "grafana/doc-validator:latest"
image: "grafana/doc-validator:v1.9.0"
steps:
- name: "Checkout code"
uses: "actions/checkout@v3"
- name: "Run doc-validator tool"
# Ensure that the CI always passes until all errors are resolved.
run: "doc-validator ./docs/sources || true"
run: "doc-validator --skip-image-validation ./docs/sources /docs/grafana/latest || true"

View File

@@ -23,4 +23,4 @@ jobs:
repository: grafana/grafana-enterprise
event_type: oss-pull-request
client_payload:
'{"source_branch": "${{ github.head_ref }}", "target_branch": "${{ github.base_ref }}", "pr_number": "${{ github.event.number }}"}'
'{"source_sha": "${{ github.event.pull_request.head.sha }}", "source_branch": "${{ github.head_ref }}", "target_branch": "${{ github.base_ref }}", "pr_number": "${{ github.event.number }}"}'

View File

@@ -0,0 +1,134 @@
name: When epic issues changed in Platform UX squad projects, check if epic is part of specified child projects and update on Platform UX parent project
on:
issues:
types: [opened, closed, edited, reopened, assigned, unassigned, labeled, unlabeled]
labels:
- 'type/epic'
env:
GITHUB_TOKEN: ${{ secrets.GH_BOT_PROJECTS_ACCESS_TOKEN }}
ORGANIZATION: ${{ github.repository_owner }}
REPO: ${{ github.event.repository.name }}
PARENT_PROJECT: 304
CHILD_PROJECT_1: 78
CHILD_PROJECT_2: 111
CHILD_PROJECT_3: 202
concurrency:
group: issue-add-to-parent-project-${{ github.event.number }}
jobs:
main:
runs-on: ubuntu-latest
steps:
- name: Check if issue is in child or parent projects
run: |
gh api graphql -f query='
query($org: String!, $repo: String!) {
repository(name: $repo, owner: $org) {
issue (number: ${{ github.event.issue.number }}) {
projectItems(first:20) {
nodes {
id,
project {
number,
title
},
fieldValueByName(name:"Status") {
... on ProjectV2ItemFieldSingleSelectValue {
optionId
name
}
}
}
}
}
}
}' -f org=$ORGANIZATION -f repo=$REPO > projects_data.json
echo 'IN_PARENT_PROJ='$(jq '.data.repository.issue.projectItems.nodes[] | select(.project.number==${{ env.PARENT_PROJECT }}) | .project != null' projects_data.json) >> $GITHUB_ENV
echo 'PARENT_PROJ_STATUS_ID='$(jq '.data.repository.issue.projectItems.nodes[] | select(.project.number==${{ env.PARENT_PROJECT }}) | select(.fieldValueByName != null) | .fieldValueByName.optionId' projects_data.json) >> $GITHUB_ENV
echo 'ITEM_ID='$(jq '.data.repository.issue.projectItems.nodes[] | select(.project.number==${{ env.PARENT_PROJECT }}) | .id' projects_data.json) >> $GITHUB_ENV
echo 'IN_CHILD_PROJ='$(jq 'first(.data.repository.issue.projectItems.nodes[] | select(.project.number==${{ env.CHILD_PROJECT_1 }} or .project.number==${{ env.CHILD_PROJECT_2 }} or .project.number==${{ env.CHILD_PROJECT_3 }}) | .project != null)' projects_data.json) >> $GITHUB_ENV
echo 'CHILD_PROJ_STATUS='$(jq -r '.data.repository.issue.projectItems.nodes[] | select(.project.number==${{ env.CHILD_PROJECT_1 }} or .project.number==${{ env.CHILD_PROJECT_2 }} or .project.number==${{ env.CHILD_PROJECT_3 }}) | select(.fieldValueByName != null) | .fieldValueByName.name' projects_data.json) >> $GITHUB_ENV
- name: Get parent project project data
if: env.IN_CHILD_PROJ
run: |
gh api graphql -f query='
query($org: String!, $number: Int!) {
organization(login: $org){
projectV2(number: $number) {
id
fields(first:20) {
nodes {
... on ProjectV2Field {
id
name
}
... on ProjectV2SingleSelectField {
id
name
options {
id
name
}
}
}
}
}
}
}' -f org=$ORGANIZATION -F number=$PARENT_PROJECT > project_data.json
echo 'PROJECT_ID='$(jq '.data.organization.projectV2.id' project_data.json) >> $GITHUB_ENV
echo 'STATUS_FIELD_ID='$(jq '.data.organization.projectV2.fields.nodes[] | select(.name== "Status") | .id' project_data.json) >> $GITHUB_ENV
echo 'TODO_OPTION_ID='$(jq '.data.organization.projectV2.fields.nodes[] | select(.name== "Status") | .options[] | select(.name=="Todo") |.id' project_data.json) >> $GITHUB_ENV
echo 'PROGRESS_OPTION_ID='$(jq '.data.organization.projectV2.fields.nodes[] | select(.name== "Status") | .options[] | select(.name=="In Progress") |.id' project_data.json) >> $GITHUB_ENV
echo 'DONE_OPTION_ID='$(jq '.data.organization.projectV2.fields.nodes[] | select(.name== "Status") | .options[] | select(.name=="Done") |.id' project_data.json) >> $GITHUB_ENV
- name: Add issue to parent project
if: env.IN_CHILD_PROJ && !env.IN_PARENT_PROJ
run: |
item_id="$( gh api graphql -f query='
mutation($project:ID!, $issue:ID!) {
addProjectV2ItemById(input: {projectId: $project, contentId: $issue}) {
item {
id
}
}
}' -f project=$PROJECT_ID -f issue=${{ github.event.issue.node_id }} --jq '.data.addProjectV2ItemById.item.id')"
echo 'ITEM_ID='$item_id >> $GITHUB_ENV
- name: Set parent project status Done
if: contains(env.CHILD_PROJ_STATUS, 'Done')
run: |
echo 'OPTION_ID='$DONE_OPTION_ID >> $GITHUB_ENV
- name: Set parent project status In Progress
if: contains(env.CHILD_PROJ_STATUS, 'In ') || contains(env.CHILD_PROJ_STATUS, 'Blocked')
run: |
echo 'OPTION_ID='$PROGRESS_OPTION_ID >> $GITHUB_ENV
- name: Set parent project status To do
if: env.CHILD_PROJ_STATUS && !contains(env.CHILD_PROJ_STATUS, 'In ') && !contains(env.CHILD_PROJ_STATUS, 'Blocked') && ! contains(env.CHILD_PROJ_STATUS, 'Done')
run: |
echo 'OPTION_ID='$TODO_OPTION_ID >> $GITHUB_ENV
- name: Set issue status in parent project
if: env.OPTION_ID && (env.OPTION_ID != env.PARENT_PROJ_STATUS_ID)
run: |
gh api graphql -f query='
mutation (
$project: ID!
$item: ID!
$status_field: ID!
$status_value: String!
) {
set_status: updateProjectV2ItemFieldValue(input: {
projectId: $project
itemId: $item
fieldId: $status_field
value: {
singleSelectOptionId: $status_value
}
}) {
projectV2Item {
id
}
}
}' -f project=$PROJECT_ID -f item=$ITEM_ID -f status_field=$STATUS_FIELD_ID -f status_value=${{ env.OPTION_ID }} --silent

View File

@@ -3,7 +3,7 @@ on:
workflow_dispatch:
inputs:
version:
required: true
required: true
description: Needs to match, exactly, the name of a milestone (NO v prefix)
jobs:
main:
@@ -14,11 +14,17 @@ jobs:
with:
repository: "grafana/grafana-github-actions"
path: ./actions
ref: main
ref: main
- name: Install Actions
run: npm install --production --prefix ./actions
- name: "Generate token"
id: generate_token
uses: tibdex/github-app-token@b62528385c34dbc9f38e5f4225ac829252d1ea92
with:
app_id: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_ID }}
private_key: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_PEM }}
- name: Run github release action
uses: ./actions/github-release
with:
token: ${{secrets.GH_BOT_ACCESS_TOKEN}}
token: ${{ steps.generate_token.outputs.token }}
metricsWriteAPIKey: ${{secrets.GRAFANA_MISC_STATS_API_KEY}}

View File

@@ -14,23 +14,37 @@ jobs:
- name: "Determine which team to notify"
run: |
# Default to null values.
BOARD="null"
CHANNEL="null"
echo "${{ github.event.label.name }} label added"
export CURRENT_LABEL="${{ github.event.label.name }}" # Enable the use of the label in yq evaluations
# yq is installed by default in ubuntu-latest
if [[ $(yq e 'keys | .[] | select(. == env(CURRENT_LABEL))' teams.yml ) ]]; then
# Check if we have a board set to use.
if [[ $(yq '.[env(CURRENT_LABEL)] | has("github-board")' teams.yml ) == true ]]; then
BOARD=$(yq '.[env(CURRENT_LABEL)].github-board' teams.yml)
echo "Ready to add issue to Grafana board ${BOARD}"
fi
# Check if we have a channel set to notify on comments.
if [[ $(yq '.[env(CURRENT_LABEL)] | has("channel-label")' teams.yml ) == true ]]; then
CHANNEL=$(yq '.[env(CURRENT_LABEL)].channel-label' teams.yml)
echo "Ready to send issue to channel ID ${CHANNEL}"
fi
fi
# set environment for next step
echo "BOARD=${BOARD}" >> $GITHUB_ENV
echo "CHANNEL=${CHANNEL}" >> $GITHUB_ENV
# Debug logging
echo "Ready to send issue to channel ID ${CHANNEL}"
- name: "Add to GitHub board"
if: ${{ env.BOARD != 'null' }}
uses: leonsteinhaeuser/project-beta-automations@v1.3.0
with:
project_id: ${{ env.BOARD }}
organization: grafana
resource_node_id: ${{ github.event.issue.node_id }}
gh_token: ${{ secrets.GITHUB_TOKEN }}
- name: "Prepare payload"
uses: frabert/replace-string-action@v2.0
@@ -43,7 +57,8 @@ jobs:
flags: 'g'
- name: "Send Slack notification"
uses: slackapi/slack-github-action@v1.14.0
if: ${{ env.CHANNEL != 'null' }}
uses: slackapi/slack-github-action@v1.23.0
with:
payload: >
{

View File

@@ -10,12 +10,10 @@ jobs:
uses: grafana/grafana/.github/workflows/remove-milestone.yml@main
with:
version_call: ${{ github.event.inputs.version_input }}
secrets:
token: ${{ secrets.GH_BOT_ACCESS_TOKEN }}
secrets: inherit
call-close-milestone:
uses: grafana/grafana/.github/workflows/close-milestone.yml@main
with:
version_call: ${{ github.event.inputs.version_input }}
secrets:
token: ${{ secrets.GH_BOT_ACCESS_TOKEN }}
needs: call-remove-milestone
secrets: inherit
needs: call-remove-milestone

21
.github/workflows/ox-code-coverage.yml vendored Normal file
View File

@@ -0,0 +1,21 @@
name: Observability Experience test code coverage
on:
pull_request:
paths:
- 'pkg/services/queryhistory/**'
- 'pkg/tsdb/loki/**'
- 'pkg/tsdb/elasticsearch/**'
- 'public/app/features/explore/**'
- 'public/app/features/correlations/**'
- 'public/app/plugins/datasource/loki/**'
- 'public/app/plugins/datasource/elasticsearch/**'
branches-ignore:
- dependabot/**
- backport-*
jobs:
workflow-call:
uses: grafana/code-coverage/.github/workflows/code-coverage.yml@v0.1.18
with:
frontend-path-regexp: public\/app\/features\/(explore|correlations)|public\/app\/plugins\/datasource\/(loki|elasticsearch)
backend-path-regexp: pkg\/services\/(queryhistory)|pkg\/tsdb\/(loki|elasticsearch)

View File

@@ -1,6 +1,7 @@
name: "CodeQL for PR / go"
on:
workflow_dispatch:
pull_request:
branches: [main]
paths:
@@ -19,11 +20,21 @@ jobs:
# a pull request then we can checkout the head.
fetch-depth: 2
- name: Set go version
uses: actions/setup-go@v3
with:
go-version: '1.20.10'
# Initializes the CodeQL tools for scanning.
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
languages: "go"
- name: Build go files
run: |
go mod verify
make build-go
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2

View File

@@ -1,6 +1,7 @@
name: "CodeQL for PR / javascript"
on:
workflow_dispatch:
pull_request:
branches: [main]
paths:

View File

@@ -1,6 +1,7 @@
name: "CodeQL for PR / python"
on:
workflow_dispatch:
pull_request:
branches: [main]
paths:

24
.github/workflows/pr-patch-check.yml vendored Normal file
View File

@@ -0,0 +1,24 @@
# Owned by grafana-delivery-squad
# Intended to be dropped into the base repo Ex: grafana/grafana
name: Check for patch conflicts
run-name: check-patch-conflicts-${{ github.base_ref }}-${{ github.head_ref }}
on:
pull_request_target:
types:
- opened
branches:
- "main"
- "v*.*.*"
- "release-*"
# Since this is run on a pull request, we want to apply the patches intended for the
# target branch onto the source branch, to verify compatibility before merging.
jobs:
trigger_downstream_patch_check:
uses: grafana/security-patch-actions/.github/workflows/test-patches.yml@main
with:
src_repo: "${{ github.repository }}"
src_ref: "${{ github.head_ref }}" # this is the source branch name, Ex: "feature/newthing"
patch_repo: "${{ github.repository }}-security-patches"
patch_ref: "${{ github.base_ref }}" # this is the target branch name, Ex: "main"
secrets: inherit

View File

@@ -1,23 +0,0 @@
name: Prepare release
on:
workflow_dispatch:
inputs:
version_input:
description: 'The version to be released please respect: major.minor.patch or major.minor.patch-beta<number> format. example: 7.4.3 or 7.4.3-beta1'
required: true
jobs:
call-bump-version:
uses: grafana/grafana/.github/workflows/bump-version.yml@main
with:
version_call: ${{ github.event.inputs.version_input }}
secrets:
token: ${{ secrets.GH_BOT_ACCESS_TOKEN }}
metricsWriteAPIKey: ${{ secrets.GRAFANA_MISC_STATS_API_KEY }}
call-update-changelog:
uses: grafana/grafana/.github/workflows/update-changelog.yml@main
with:
version_call: ${{ github.event.inputs.version_input }}
secrets:
token: ${{ secrets.GH_BOT_ACCESS_TOKEN }}
metricsWriteAPIKey: ${{ secrets.GRAFANA_MISC_STATS_API_KEY }}
needs: call-bump-version

View File

@@ -0,0 +1,38 @@
name: "publish-technical-documentation-next"
on:
push:
branches:
- "main"
paths:
- "docs/sources/**"
workflow_dispatch:
jobs:
sync:
if: "github.repository == 'grafana/grafana'"
runs-on: "ubuntu-latest"
steps:
- name: "Checkout Grafana repo"
uses: "actions/checkout@v3"
- name: "Clone website-sync Action"
# WEBSITE_SYNC_TOKEN is a fine-grained GitHub Personal Access Token that expires.
# It must be regenerated in the grafanabot GitHub account and requires a Grafana organization
# GitHub administrator to update the organization secret.
# The IT helpdesk can update the organization secret.
run: "git clone --single-branch --no-tags --depth 1 -b master https://grafanabot:${{ secrets.WEBSITE_SYNC_TOKEN }}@github.com/grafana/website-sync ./.github/actions/website-sync"
- name: "Publish to website repository (next)"
uses: "./.github/actions/website-sync"
id: "publish-next"
with:
repository: "grafana/website"
branch: "master"
host: "github.com"
# PUBLISH_TO_WEBSITE_TOKEN is a fine-grained GitHub Personal Access Token that expires.
# It must be regenerated in the grafanabot GitHub account and requires a Grafana organization
# GitHub administrator to update the organization secret.
# The IT helpdesk can update the organization secret.
github_pat: "grafanabot:${{ secrets.PUBLISH_TO_WEBSITE_TOKEN }}"
source_folder: "docs/sources"
target_folder: "content/docs/grafana/next"

View File

@@ -0,0 +1,68 @@
name: "publish-technical-documentation-release"
on:
push:
branches:
- v[0-9]+.[0-9]+.x
tags:
- v[0-9]+.[0-9]+.[0-9]+
paths:
- "docs/sources/**"
workflow_dispatch:
jobs:
sync:
if: "github.repository == 'grafana/grafana'"
runs-on: "ubuntu-latest"
steps:
- name: "Checkout Grafana repo"
uses: "actions/checkout@v3"
with:
fetch-depth: 0
- name: "Checkout Actions library"
uses: "actions/checkout@v3"
with:
repository: "grafana/grafana-github-actions"
path: "./actions"
- name: "Install Actions from library"
run: "npm install --production --prefix ./actions"
- name: "Determine if there is a matching release tag"
id: "has-matching-release-tag"
uses: "./actions/has-matching-release-tag"
with:
ref_name: "${{ github.ref_name }}"
release_tag_regexp: "^v(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.(0|[1-9]\\d*)$"
release_branch_regexp: "^v(0|[1-9]\\d*)\\.(0|[1-9]\\d*)\\.x$"
- name: "Determine technical documentation version"
if: "steps.has-matching-release-tag.outputs.bool == 'true'"
uses: "./actions/docs-target"
id: "target"
with:
ref_name: "${{ github.ref_name }}"
- name: "Clone website-sync Action"
if: "steps.has-matching-release-tag.outputs.bool == 'true'"
# WEBSITE_SYNC_TOKEN is a fine-grained GitHub Personal Access Token that expires.
# It must be regenerated in the grafanabot GitHub account and requires a Grafana organization
# GitHub administrator to update the organization secret.
# The IT helpdesk can update the organization secret.
run: "git clone --single-branch --no-tags --depth 1 -b master https://grafanabot:${{ secrets.WEBSITE_SYNC_TOKEN }}@github.com/grafana/website-sync ./.github/actions/website-sync"
- name: "Publish to website repository (release)"
if: "steps.has-matching-release-tag.outputs.bool == 'true'"
uses: "./.github/actions/website-sync"
id: "publish-release"
with:
repository: "grafana/website"
branch: "master"
host: "github.com"
# PUBLISH_TO_WEBSITE_TOKEN is a fine-grained GitHub Personal Access Token that expires.
# It must be regenerated in the grafanabot GitHub account and requires a Grafana organization
# GitHub administrator to update the organization secret.
# The IT helpdesk can update the organization secret.
github_pat: "grafanabot:${{ secrets.PUBLISH_TO_WEBSITE_TOKEN }}"
source_folder: "docs/sources"
target_folder: "content/docs/grafana/${{ steps.target.outputs.target }}"

View File

@@ -1,49 +0,0 @@
name: publish_docs
on:
push:
branches:
- v9.1.x
paths:
- 'docs/sources/**'
- 'packages/grafana-*/**'
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- run: git clone --single-branch --no-tags --depth 1 -b master https://grafanabot:${{ secrets.GH_BOT_ACCESS_TOKEN }}@github.com/grafana/website-sync ./.github/actions/website-sync
- name: generate-packages-docs
uses: actions/setup-node@v3.4.0
id: generate-docs
with:
node-version: '16'
- name: Get yarn cache directory path
id: yarn-cache-dir-path
run: echo "::set-output name=dir::$(yarn config get cacheFolder)"
- uses: actions/cache@v2.1.7
with:
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
key: yarn-${{ hashFiles('**/yarn.lock') }}
restore-keys: |
yarn-
- run: yarn install --immutable
- run: ./scripts/ci-reference-docs-build.sh
- name: publish-to-git
uses: ./.github/actions/website-sync
id: publish
with:
repository: grafana/website
branch: master
host: github.com
github_pat: '${{ secrets.GH_BOT_ACCESS_TOKEN }}'
source_folder: docs/sources
target_folder: content/docs/grafana/latest
allow_no_changes: 'true'
- shell: bash
run: |
test -n "${{ steps.publish.outputs.commit_hash }}"
test -n "${{ steps.publish.outputs.working_directory }}"

View File

@@ -11,9 +11,7 @@ on:
description: Needs to match, exactly, the name of a milestone
required: true
type: string
secrets:
token:
required: true
jobs:
main:
runs-on: ubuntu-latest
@@ -26,14 +24,20 @@ jobs:
ref: main
- name: Install Actions
run: npm install --production --prefix ./actions
- name: "Generate token"
id: generate_token
uses: tibdex/github-app-token@b62528385c34dbc9f38e5f4225ac829252d1ea92
with:
app_id: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_ID }}
private_key: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_PEM }}
- name: Remove milestone from open issues (manually invoked)
if: ${{ github.event.inputs.version != '' }}
uses: ./actions/remove-milestone
with:
token: ${{ secrets.GH_BOT_ACCESS_TOKEN }}
token: ${{ steps.generate_token.outputs.token }}
- name: Remove milestone from open issues (workflow invoked)
if: ${{ inputs.version_call != '' }}
uses: ./actions/remove-milestone
with:
version_call: ${{ inputs.version_call }}
token: ${{ secrets.token }}
token: ${{ steps.generate_token.outputs.token }}

20
.github/workflows/sbom-report.yml vendored Normal file
View File

@@ -0,0 +1,20 @@
name: syft-sbom-ci
on:
release:
types: [created]
jobs:
syft-sbom:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Anchore SBOM Action
uses: anchore/sbom-action@v0.12.0
with:
artifact-name: ${{ github.event.repository.name }}-spdx.json

View File

@@ -1,9 +1,9 @@
module.exports = async ({ github, context, core }) => {
module.exports = async ({ name, github, context, core }) => {
const { owner, repo } = context.repo;
const url = `https://api.github.com/repos/${owner}/${repo}/actions/runs/${context.runId}/jobs`
const result = await github.request(url)
const link = `https://github.com/grafana/grafana/runs/${result.data.jobs[0].id}?check_suite_focus=true`;
core.setOutput('link', link);
}
const result = await github.request(url);
const job = result.data.jobs.find(j => j.name === name);
core.setOutput('link', `${job.html_url}?check_suite_focus=true`);
}

View File

@@ -7,7 +7,7 @@ jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v5
- uses: actions/stale@v6
with:
repo-token: ${{ secrets.GH_BOT_ACCESS_TOKEN }}
# Number of days of inactivity before a stale Issue or Pull Request is closed.

25
.github/workflows/sync-mirror.yml vendored Normal file
View File

@@ -0,0 +1,25 @@
# Owned by grafana-delivery-squad
# Intended to be dropped into the base repo, Ex: grafana/grafana
name: Sync to mirror
run-name: sync-to-mirror-${{ github.ref_name }}
on:
workflow_dispatch:
push:
branches:
- "main"
- "v*.*.*"
- "release-*"
# This is run after the pull request has been merged, so we'll run against the target branch
jobs:
trigger_downstream_patch_mirror:
concurrency: patch-mirror-${{ github.ref_name }}
uses: grafana/security-patch-actions/.github/workflows/mirror-branch-and-apply-patches.yml@main
if: github.repository == 'grafana/grafana'
with:
ref: "${{ github.ref_name }}" # this is the target branch name, Ex: "main"
src_repo: "${{ github.repository }}"
dest_repo: "${{ github.repository }}-security-mirror"
patch_repo: "${{ github.repository }}-security-patches"
secrets: inherit

View File

@@ -4,22 +4,17 @@ on:
inputs:
version:
required: true
description: Needs to match, exactly, the name of a milestone
workflow_call:
inputs:
version_call:
description: Needs to match, exactly, the name of a milestone
required: true
type: string
secrets:
token:
required: true
metricsWriteAPIKey:
required: true
description: 'Needs to match, exactly, the name of a milestone. The version to be released please respect: major.minor.patch or major.minor.patch-beta<number> format. example: 7.4.3 or 7.4.3-beta1'
jobs:
main:
runs-on: ubuntu-latest
steps:
- name: "Generate token"
id: generate_token
uses: tibdex/github-app-token@b62528385c34dbc9f38e5f4225ac829252d1ea92
with:
app_id: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_ID }}
private_key: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_PEM }}
- name: Checkout Actions
uses: actions/checkout@v3
with:
@@ -29,15 +24,7 @@ jobs:
- name: Install Actions
run: npm install --production --prefix ./actions
- name: Run update changelog (manually invoked)
if: ${{ github.event.inputs.version != '' }}
uses: ./actions/update-changelog
with:
token: ${{ secrets.GH_BOT_ACCESS_TOKEN }}
token: ${{ steps.generate_token.outputs.token }}
metricsWriteAPIKey: ${{ secrets.GRAFANA_MISC_STATS_API_KEY }}
- name: Run update changelog (workflow invoked)
if: ${{ inputs.version_call != '' }}
uses: ./actions/update-changelog
with:
version_call: ${{ inputs.version_call }}
token: ${{ secrets.token }}
metricsWriteAPIKey: ${{ secrets.metricsWriteAPIKey }}

31
.gitignore vendored
View File

@@ -40,6 +40,8 @@ tsconfig.tsbuildinfo
# Enterprise devenv
/devenv/docker/blocks/grafana-enterprise
/devenv/docker/blocks/saml-enterprise
# This is the new place of the block, but I leave the previous here for a while
/devenv/docker/blocks/auth/saml-enterprise
/tmp
tools/phantomjs/phantomjs
@@ -59,6 +61,7 @@ public/css/*.min.css
*.sublime-workspace
*.swp
.idea/
.fleet/
*.iml
*.tmp
.DS_Store
@@ -73,7 +76,11 @@ public/css/*.min.css
# devenv
/devenv/docker-compose.yaml
/devenv/docker-compose.override.yaml
/devenv/.env
/devenv/docker/blocks/tempo/tempo-data/
/devenv/docker/ha-test-unified-alerting/logs/webhook/dumps/
/devenv/docker/ha-test-unified-alerting/logs/webhook/webhook-listener.log
conf/custom.ini
/conf/provisioning/**/custom.yaml
@@ -100,6 +107,7 @@ debug.test
/packaging/**/*.tar.gz
/packaging/**/*.tar.gz.sha256
pkg/cmd/grafana-server/__debug_bin
pkg/services/quota/quotaimpl/storage/storage.json
# Ignore OSX indexing
.DS_Store
@@ -121,10 +129,18 @@ pkg/cmd/grafana-server/__debug_bin
!.yarn/patches/*.patch
# Ignoring frontend packages specifics
/packages/grafana-ui/.yarn/.cache
/packages/**/dist
/packages/**/compiled
/packages/**/.rpt2_cache
/packages/**/tsdoc-metadata.json
/packages/**/package.tgz
/packages/grafana-toolkit/sass
## CI places the packages in a different location
/npm-artifacts/*.tgz
# Ignore frontend build manifest
manifest.json
# Ignore go local build dependencies
/scripts/go/bin/**
@@ -143,6 +159,8 @@ compilation-stats.json
/e2e/benchmarks/**/results/*
/e2e/benchmarks/**/results
/e2e/build_results.zip
/e2e/extensions
/e2e/extensions-suite
# grafana server
/scripts/grafana-server/server.log
@@ -157,16 +175,17 @@ compilation-stats.json
# auto generated frontend docs
/docs/sources/packages_api
# auto generated Go files
*_gen.go
!pkg/services/featuremgmt/toggles_gen.go
!pkg/coremodel/**/*_gen.go
!pkg/framework/**/*_gen.go
# wire generated files
**/wire_gen.go
# Auto-generated internationalization files
public/locales/_build/
public/locales/**/*.js
public/locales/*/*.js
public/locales/*/grafana_old.json
deployment_tools_config.json
.betterer.cache
# Temporary file for backporting PRs
.pr-body.txt

View File

@@ -13,6 +13,14 @@ ignore-generated-header = false
severity = "warning"
confidence = 3
[linters-settings.depguard]
list-type = "blacklist"
include-go-root = true
packages = ["io/ioutil"]
[[linters-settings.depguard.packages-with-error-message]]
"io/ioutil" = "Deprecated: As of Go 1.16, the same functionality is now provided by package io or package os, and those implementations should be preferred in new code. See the specific function documentation for details."
"gopkg.in/yaml.v2" = "Grafana packages are not allowed to depend on gopkg.in/yaml.v2 as gopkg.in/yaml.v3 is now available"
[linters-settings.gocritic]
enabled-checks = ["ruleguard"]
[linters-settings.gocritic.settings.ruleguard]
@@ -49,7 +57,6 @@ enable = [
"typecheck",
"asciicheck",
"errorlint",
"sqlclosecheck",
"revive",
]
@@ -76,7 +83,11 @@ text = "ST1001"
# Use golang.org/x/text/cases instead.
[[issues.exclude-rules]]
linters = ["staticcheck"]
text = "SA1019"
text = "SA1019: strings.Title"
[[issues.exclude-rules]]
linters = ["staticcheck"]
text = "use fake service and real access control evaluator instead"
[[issues.exclude-rules]]
linters = ["gosec"]

2
.nvmrc
View File

@@ -1 +1 @@
v16.14.0
v18.12.0

View File

@@ -1,3 +1,48 @@
var dashboardSettings = [
{
url: '${HOST}/d/O6f11TZWk/panel-tests-bar-gauge?orgId=1&editview=settings',
wait: 500,
rootElement: '.main-view',
threshold: 0,
},
{
url: '${HOST}/d/O6f11TZWk/panel-tests-bar-gauge?orgId=1&editview=annotations',
wait: 500,
rootElement: '.main-view',
threshold: 0,
},
{
url: '${HOST}/d/O6f11TZWk/panel-tests-bar-gauge?orgId=1&editview=templating',
wait: 500,
rootElement: '.main-view',
threshold: 0,
},
{
url: '${HOST}/d/O6f11TZWk/panel-tests-bar-gauge?orgId=1&editview=links',
wait: 500,
rootElement: '.main-view',
threshold: 0,
},
{
url: '${HOST}/d/O6f11TZWk/panel-tests-bar-gauge?orgId=1&editview=versions',
wait: 500,
rootElement: '.main-view',
threshold: 0,
},
{
url: '${HOST}/d/O6f11TZWk/panel-tests-bar-gauge?orgId=1&editview=permissions',
wait: 500,
rootElement: '.main-view',
threshold: 9,
},
{
url: '${HOST}/d/O6f11TZWk/panel-tests-bar-gauge?orgId=1&editview=dashboard_json',
wait: 500,
rootElement: '.main-view',
threshold: 2,
},
];
var config = {
defaults: {
concurrency: 1,
@@ -17,7 +62,7 @@ var config = {
url: '${HOST}/login',
wait: 500,
rootElement: '.main-view',
threshold: 12,
threshold: 13,
},
{
url: '${HOST}/login',
@@ -29,7 +74,7 @@ var config = {
"click element button[aria-label='Login button']",
"wait for element [aria-label='Skip change password button'] to be visible",
],
threshold: 13,
threshold: 14,
rootElement: '.main-view',
},
{
@@ -43,12 +88,7 @@ var config = {
rootElement: '.main-view',
threshold: 0,
},
{
url: '${HOST}/d/O6f11TZWk/panel-tests-bar-gauge?orgId=1&editview=settings',
wait: 500,
rootElement: '.main-view',
threshold: 0,
},
...dashboardSettings,
{
url: '${HOST}/?orgId=1&search=open',
wait: 500,
@@ -61,49 +101,49 @@ var config = {
rootElement: '.main-view',
// the unified alerting promotion alert's content contrast is too low
// see https://github.com/grafana/grafana/pull/41829
threshold: 4,
threshold: 6,
},
{
url: '${HOST}/datasources',
wait: 500,
rootElement: '.main-view',
threshold: 0,
threshold: 1,
},
{
url: '${HOST}/org/users',
wait: 500,
rootElement: '.main-view',
threshold: 0,
threshold: 1,
},
{
url: '${HOST}/org/teams',
wait: 500,
rootElement: '.main-view',
threshold: 0,
threshold: 1,
},
{
url: '${HOST}/plugins',
wait: 500,
rootElement: '.main-view',
threshold: 0,
threshold: 1,
},
{
url: '${HOST}/org',
wait: 500,
rootElement: '.main-view',
threshold: 0,
threshold: 1,
},
{
url: '${HOST}/org/apikeys',
wait: 500,
rootElement: '.main-view',
threshold: 3,
threshold: 4,
},
{
url: '${HOST}/dashboards',
wait: 500,
rootElement: '.main-view',
threshold: 0,
threshold: 1,
},
],
};

View File

@@ -1,3 +1,40 @@
var dashboardSettings = [
{
url: '${HOST}/d/O6f11TZWk/panel-tests-bar-gauge?orgId=1&editview=settings',
wait: 500,
rootElement: '.main-view',
},
{
url: '${HOST}/d/O6f11TZWk/panel-tests-bar-gauge?orgId=1&editview=annotations',
wait: 500,
rootElement: '.main-view',
},
{
url: '${HOST}/d/O6f11TZWk/panel-tests-bar-gauge?orgId=1&editview=templating',
wait: 500,
rootElement: '.main-view',
},
{
url: '${HOST}/d/O6f11TZWk/panel-tests-bar-gauge?orgId=1&editview=links',
wait: 500,
rootElement: '.main-view',
},
{
url: '${HOST}/d/O6f11TZWk/panel-tests-bar-gauge?orgId=1&editview=versions',
wait: 500,
rootElement: '.main-view',
},
{
url: '${HOST}/d/O6f11TZWk/panel-tests-bar-gauge?orgId=1&editview=permissions',
wait: 500,
rootElement: '.main-view',
},
{
url: '${HOST}/d/O6f11TZWk/panel-tests-bar-gauge?orgId=1&editview=dashboard_json',
wait: 500,
rootElement: '.main-view',
},
];
var config = {
defaults: {
concurrency: 1,
@@ -39,11 +76,7 @@ var config = {
wait: 500,
rootElement: '.main-view',
},
{
url: '${HOST}/d/O6f11TZWk/panel-tests-bar-gauge?orgId=1&editview=settings',
wait: 500,
rootElement: '.main-view',
},
...dashboardSettings,
{
url: '${HOST}/?orgId=1&search=open',
wait: 500,

View File

@@ -25,3 +25,16 @@ public/locales/**/*.js
# Auto-generated theme files
theme.light.generated.json
theme.dark.generated.json
# Generated Swagger API specs
public/api-spec.json
public/api-merged.json
public/openapi3.json
# Generated Kinds report
kinds/report.json
# Generated schema docs
docs/sources/developers/kinds/
scripts/cli/bettererIssueTemplate.md

19
.vscode/launch.json vendored
View File

@@ -6,10 +6,17 @@
"type": "go",
"request": "launch",
"mode": "auto",
"program": "${workspaceFolder}/pkg/cmd/grafana-server/",
"program": "${workspaceFolder}/pkg/cmd/grafana/",
"env": {},
"cwd": "${workspaceFolder}",
"args": ["--homepath", "${workspaceFolder}", "--packaging", "dev"]
"args": ["server", "--homepath", "${workspaceFolder}", "--packaging", "dev"]
},
{
"name": "Attach to Chrome",
"port": 9222,
"request": "attach",
"type": "chrome",
"webRoot": "${workspaceFolder}"
},
{
"name": "Debug Jest test",
@@ -20,6 +27,14 @@
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen",
"port": 9229
},
{
"name": "Debug Go test",
"type": "go",
"request": "launch",
"mode": "test",
"program": "${workspaceFolder}/${relativeFileDirname}",
"showLog": true
}
]
}

Binary file not shown.

Binary file not shown.

File diff suppressed because one or more lines are too long

807
.yarn/releases/yarn-3.3.0.cjs vendored Executable file

File diff suppressed because one or more lines are too long

View File

@@ -1,13 +1,13 @@
#!/usr/bin/env node
const {existsSync} = require(`fs`);
const {createRequire, createRequireFromPath} = require(`module`);
const {createRequire} = require(`module`);
const {resolve} = require(`path`);
const relPnpApiPath = "../../../../.pnp.cjs";
const absPnpApiPath = resolve(__dirname, relPnpApiPath);
const absRequire = (createRequire || createRequireFromPath)(absPnpApiPath);
const absRequire = createRequire(absPnpApiPath);
if (existsSync(absPnpApiPath)) {
if (!process.versions.pnp) {

View File

@@ -1,13 +1,13 @@
#!/usr/bin/env node
const {existsSync} = require(`fs`);
const {createRequire, createRequireFromPath} = require(`module`);
const {createRequire} = require(`module`);
const {resolve} = require(`path`);
const relPnpApiPath = "../../../../.pnp.cjs";
const absPnpApiPath = resolve(__dirname, relPnpApiPath);
const absRequire = (createRequire || createRequireFromPath)(absPnpApiPath);
const absRequire = createRequire(absPnpApiPath);
if (existsSync(absPnpApiPath)) {
if (!process.versions.pnp) {

View File

@@ -1,6 +1,6 @@
{
"name": "eslint",
"version": "8.20.0-sdk",
"version": "8.32.0-sdk",
"main": "./lib/api.js",
"type": "commonjs"
}

View File

@@ -1,13 +1,13 @@
#!/usr/bin/env node
const {existsSync} = require(`fs`);
const {createRequire, createRequireFromPath} = require(`module`);
const {createRequire} = require(`module`);
const {resolve} = require(`path`);
const relPnpApiPath = "../../../.pnp.cjs";
const absPnpApiPath = resolve(__dirname, relPnpApiPath);
const absRequire = (createRequire || createRequireFromPath)(absPnpApiPath);
const absRequire = createRequire(absPnpApiPath);
if (existsSync(absPnpApiPath)) {
if (!process.versions.pnp) {

View File

@@ -1,6 +1,6 @@
{
"name": "prettier",
"version": "2.7.1-sdk",
"version": "2.8.1-sdk",
"main": "./index.js",
"type": "commonjs"
}

View File

@@ -1,13 +1,13 @@
#!/usr/bin/env node
const {existsSync} = require(`fs`);
const {createRequire, createRequireFromPath} = require(`module`);
const {createRequire} = require(`module`);
const {resolve} = require(`path`);
const relPnpApiPath = "../../../../.pnp.cjs";
const absPnpApiPath = resolve(__dirname, relPnpApiPath);
const absRequire = (createRequire || createRequireFromPath)(absPnpApiPath);
const absRequire = createRequire(absPnpApiPath);
if (existsSync(absPnpApiPath)) {
if (!process.versions.pnp) {

View File

@@ -1,13 +1,13 @@
#!/usr/bin/env node
const {existsSync} = require(`fs`);
const {createRequire, createRequireFromPath} = require(`module`);
const {createRequire} = require(`module`);
const {resolve} = require(`path`);
const relPnpApiPath = "../../../../.pnp.cjs";
const absPnpApiPath = resolve(__dirname, relPnpApiPath);
const absRequire = (createRequire || createRequireFromPath)(absPnpApiPath);
const absRequire = createRequire(absPnpApiPath);
if (existsSync(absPnpApiPath)) {
if (!process.versions.pnp) {

View File

@@ -1,13 +1,13 @@
#!/usr/bin/env node
const {existsSync} = require(`fs`);
const {createRequire, createRequireFromPath} = require(`module`);
const {createRequire} = require(`module`);
const {resolve} = require(`path`);
const relPnpApiPath = "../../../../.pnp.cjs";
const absPnpApiPath = resolve(__dirname, relPnpApiPath);
const absRequire = (createRequire || createRequireFromPath)(absPnpApiPath);
const absRequire = createRequire(absPnpApiPath);
if (existsSync(absPnpApiPath)) {
if (!process.versions.pnp) {

View File

@@ -1,13 +1,13 @@
#!/usr/bin/env node
const {existsSync} = require(`fs`);
const {createRequire, createRequireFromPath} = require(`module`);
const {createRequire} = require(`module`);
const {resolve} = require(`path`);
const relPnpApiPath = "../../../../.pnp.cjs";
const absPnpApiPath = resolve(__dirname, relPnpApiPath);
const absRequire = (createRequire || createRequireFromPath)(absPnpApiPath);
const absRequire = createRequire(absPnpApiPath);
const moduleWrapper = tsserver => {
if (!process.versions.pnp) {

View File

@@ -1,13 +1,13 @@
#!/usr/bin/env node
const {existsSync} = require(`fs`);
const {createRequire, createRequireFromPath} = require(`module`);
const {createRequire} = require(`module`);
const {resolve} = require(`path`);
const relPnpApiPath = "../../../../.pnp.cjs";
const absPnpApiPath = resolve(__dirname, relPnpApiPath);
const absRequire = (createRequire || createRequireFromPath)(absPnpApiPath);
const absRequire = createRequire(absPnpApiPath);
const moduleWrapper = tsserver => {
if (!process.versions.pnp) {

View File

@@ -1,13 +1,13 @@
#!/usr/bin/env node
const {existsSync} = require(`fs`);
const {createRequire, createRequireFromPath} = require(`module`);
const {createRequire} = require(`module`);
const {resolve} = require(`path`);
const relPnpApiPath = "../../../../.pnp.cjs";
const absPnpApiPath = resolve(__dirname, relPnpApiPath);
const absRequire = (createRequire || createRequireFromPath)(absPnpApiPath);
const absRequire = createRequire(absPnpApiPath);
if (existsSync(absPnpApiPath)) {
if (!process.versions.pnp) {

View File

@@ -1,6 +1,6 @@
{
"name": "typescript",
"version": "4.7.4-sdk",
"version": "4.8.4-sdk",
"main": "./lib/typescript.js",
"type": "commonjs"
}

View File

@@ -3,38 +3,36 @@ enableTelemetry: false
nodeLinker: pnp
packageExtensions:
'@mdx-js/loader@1.6.22':
peerDependencies:
react: 17.0.1
'@storybook/addon-docs@6.4.21':
peerDependencies:
'@storybook/manager-webpack5': 6.4.21
'@storybook/addon-essentials@6.4.21':
peerDependencies:
'@storybook/components': 6.4.21
'@storybook/core-events': 6.4.21
'@storybook/manager-webpack5': 6.4.21
'@storybook/theming': 6.4.21
'@storybook/core-server@6.4.21':
'@storybook/addon-docs@6.5.12':
peerDependencies:
'@babel/core': ^7.0.0
'@storybook/core@6.4.21':
'@storybook/manager-webpack5': 6.5.12
'webpack': 5.74.0
'@storybook/addon-essentials@6.5.12':
peerDependencies:
'@storybook/components': 6.5.12
'@storybook/core-events': 6.5.12
'@storybook/manager-webpack5': 6.5.12
'@storybook/theming': 6.5.12
'@storybook/core-server@6.5.12':
peerDependencies:
'@babel/core': ^7.0.0
'@storybook/manager-webpack5': 6.4.21
'@storybook/csf-tools@6.4.21':
'@storybook/core@6.5.12':
peerDependencies:
'@babel/core': ^7.0.0
'@storybook/react@6.4.21':
'@storybook/manager-webpack5': 6.5.12
'@storybook/csf-tools@6.5.12':
peerDependencies:
'@storybook/manager-webpack5': 6.4.21
'@babel/core': ^7.0.0
'@storybook/mdx2-csf@0.0.3':
dependencies:
'@babel/types': ^7.14.8
'@storybook/react@6.5.12':
peerDependencies:
'@storybook/manager-webpack5': 6.5.12
doctrine@3.0.0:
dependencies:
assert: 2.0.0
moveable@0.30.0:
dependencies:
'@daybrush/utils': 1.7.0
framework-utils: ^1.1.0
rc-time-picker@3.7.3:
peerDependencies:
react: 17.0.1
@@ -46,29 +44,12 @@ packageExtensions:
react-compat-css-styled@1.0.8:
dependencies:
react-simple-compat: 1.2.2
react-compat-moveable@0.18.0:
dependencies:
'@egjs/agent': ^2.2.1
'@egjs/children-differ': ^1.0.1
'@scena/matrix': 1.1.1
css-to-mat: ^1.0.3
gesto: ^1.9.0
overlap-area: ^1.0.0
react-simple-compat: 1.2.2
peerDependencies:
framework-utils: ^1.1.0
react-docgen-typescript-loader@3.7.2:
peerDependencies:
webpack: 4.41.5
react-icons@2.2.7:
peerDependencies:
prop-types: '*'
react-resizable@3.0.4:
peerDependencies:
react-dom: 17.0.1
'@npmcli/run-script@4.1.3':
dependencies:
which: ^2.0.2
plugins:
- path: .yarn/plugins/@yarnpkg/plugin-typescript.cjs
@@ -78,4 +59,11 @@ plugins:
- path: .yarn/plugins/@yarnpkg/plugin-outdated.cjs
spec: 'https://mskelton.dev/yarn-outdated/v2'
yarnPath: .yarn/releases/yarn-3.2.2.cjs
yarnPath: .yarn/releases/yarn-3.3.0.cjs
# Uncomment the following lines if you want to use Verdaccio local npm registry. Read more at packages/README.md
# npmScopes:
# grafana:
# npmRegistryServer: http://localhost:4873
# unsafeHttpWhitelist:
# - 'localhost'

File diff suppressed because it is too large Load Diff

View File

@@ -15,6 +15,8 @@ You can contribute to Grafana in several ways. Here are some examples:
- Organize meetups and user groups in your local area.
- Help others by answering questions about Grafana.
**Please note:** We do not currently accept contributions for translations. Please do not submit pull requests for messages.po files - they will be rejected.
For more ways to contribute, check out the [Open Source Guides](https://opensource.guide/how-to-contribute/).
### Report bugs

View File

@@ -1,8 +1,17 @@
FROM node:16-alpine3.15 as js-builder
# syntax=docker/dockerfile:1
ARG BASE_IMAGE=alpine:3.18.3
ARG JS_IMAGE=node:18-alpine3.18
ARG GO_IMAGE=golang:1.20.10-alpine3.18
ARG GO_SRC=go-builder
ARG JS_SRC=js-builder
FROM ${JS_IMAGE} as js-builder
ENV NODE_OPTIONS=--max_old_space_size=8000
WORKDIR /grafana
WORKDIR /tmp/grafana
COPY package.json yarn.lock .yarnrc.yml ./
COPY .yarn .yarn
@@ -13,84 +22,145 @@ RUN yarn install
COPY tsconfig.json .eslintrc .editorconfig .browserslistrc .prettierrc.js babel.config.json .linguirc ./
COPY public public
COPY tools tools
COPY scripts scripts
COPY emails emails
ENV NODE_ENV production
RUN yarn build
FROM golang:1.19.1-alpine3.15 as go-builder
FROM ${GO_IMAGE} as go-builder
RUN apk add --no-cache gcc g++ make
# Install build dependencies
RUN if grep -i -q alpine /etc/issue; then \
apk add --no-cache gcc g++ make; \
fi
WORKDIR /grafana
WORKDIR /tmp/grafana
COPY go.mod go.sum embed.go Makefile build.go package.json ./
COPY go.* ./
COPY .bingo .bingo
RUN go mod download && \
go install github.com/bwplotka/bingo@latest && \
bingo get
COPY embed.go Makefile build.go package.json ./
COPY cue.mod cue.mod
COPY kinds kinds
COPY local local
COPY packages/grafana-schema packages/grafana-schema
COPY public/app/plugins public/app/plugins
COPY public/api-spec.json public/api-spec.json
COPY pkg pkg
COPY scripts scripts
COPY cue.mod cue.mod
COPY .bingo .bingo
COPY conf conf
COPY .github .github
COPY LICENSE ./
RUN go mod verify
RUN make build-go
# Final stage
FROM alpine:3.15.6
FROM ${BASE_IMAGE} as tgz-builder
LABEL maintainer="Grafana team <hello@grafana.com>"
WORKDIR /tmp/grafana
ARG GRAFANA_TGZ="grafana-latest.linux-x64-musl.tar.gz"
COPY ${GRAFANA_TGZ} /tmp/grafana.tar.gz
# add -v to make tar print every file it extracts
RUN tar x -z -f /tmp/grafana.tar.gz --strip-components=1
# helpers for COPY --from
FROM ${GO_SRC} as go-src
FROM ${JS_SRC} as js-src
# Final stage
FROM ${BASE_IMAGE}
LABEL maintainer="Grafana Labs <hello@grafana.com>"
ARG GF_UID="472"
ARG GF_GID="0"
ENV PATH="/usr/share/grafana/bin:$PATH" \
GF_PATHS_CONFIG="/etc/grafana/grafana.ini" \
GF_PATHS_DATA="/var/lib/grafana" \
GF_PATHS_HOME="/usr/share/grafana" \
GF_PATHS_LOGS="/var/log/grafana" \
GF_PATHS_PLUGINS="/var/lib/grafana/plugins" \
GF_PATHS_PROVISIONING="/etc/grafana/provisioning"
GF_PATHS_CONFIG="/etc/grafana/grafana.ini" \
GF_PATHS_DATA="/var/lib/grafana" \
GF_PATHS_HOME="/usr/share/grafana" \
GF_PATHS_LOGS="/var/log/grafana" \
GF_PATHS_PLUGINS="/var/lib/grafana/plugins" \
GF_PATHS_PROVISIONING="/etc/grafana/provisioning"
WORKDIR $GF_PATHS_HOME
RUN apk add --no-cache ca-certificates bash tzdata musl-utils
RUN apk add --no-cache openssl ncurses-libs ncurses-terminfo-base --repository=http://dl-cdn.alpinelinux.org/alpine/edge/main
RUN apk upgrade ncurses-libs ncurses-terminfo-base --repository=http://dl-cdn.alpinelinux.org/alpine/edge/main
RUN apk info -vv | sort
# Install dependencies
RUN if grep -i -q alpine /etc/issue; then \
apk add --no-cache ca-certificates bash tzdata musl-utils && \
apk info -vv | sort; \
elif grep -i -q ubuntu /etc/issue; then \
DEBIAN_FRONTEND=noninteractive && \
apt-get update && \
apt-get install -y ca-certificates curl tzdata musl && \
apt-get autoremove -y && \
rm -rf /var/lib/apt/lists/*; \
else \
echo 'ERROR: Unsupported base image' && /bin/false; \
fi
COPY conf ./conf
# glibc support for alpine x86_64 only
RUN if grep -i -q alpine /etc/issue && [ `arch` = "x86_64" ]; then \
wget -q -O /etc/apk/keys/sgerrand.rsa.pub https://alpine-pkgs.sgerrand.com/sgerrand.rsa.pub && \
wget https://github.com/sgerrand/alpine-pkg-glibc/releases/download/2.35-r0/glibc-2.35-r0.apk \
-O /tmp/glibc-2.35-r0.apk && \
wget https://github.com/sgerrand/alpine-pkg-glibc/releases/download/2.35-r0/glibc-bin-2.35-r0.apk \
-O /tmp/glibc-bin-2.35-r0.apk && \
apk add --force-overwrite --no-cache /tmp/glibc-2.35-r0.apk /tmp/glibc-bin-2.35-r0.apk && \
rm -f /lib64/ld-linux-x86-64.so.2 && \
ln -s /usr/glibc-compat/lib64/ld-linux-x86-64.so.2 /lib64/ld-linux-x86-64.so.2 && \
rm -f /tmp/glibc-2.35-r0.apk && \
rm -f /tmp/glibc-bin-2.35-r0.apk && \
rm -f /lib/ld-linux-x86-64.so.2 && \
rm -f /etc/ld.so.cache; \
fi
COPY --from=go-src /tmp/grafana/conf ./conf
RUN if [ ! $(getent group "$GF_GID") ]; then \
addgroup -S -g $GF_GID grafana; \
fi
if grep -i -q alpine /etc/issue; then \
addgroup -S -g $GF_GID grafana; \
else \
addgroup --system --gid $GF_GID grafana; \
fi; \
fi && \
GF_GID_NAME=$(getent group $GF_GID | cut -d':' -f1) && \
mkdir -p "$GF_PATHS_HOME/.aws" && \
if grep -i -q alpine /etc/issue; then \
adduser -S -u $GF_UID -G "$GF_GID_NAME" grafana; \
else \
adduser --system --uid $GF_UID --ingroup "$GF_GID_NAME" grafana; \
fi && \
mkdir -p "$GF_PATHS_PROVISIONING/datasources" \
"$GF_PATHS_PROVISIONING/dashboards" \
"$GF_PATHS_PROVISIONING/notifiers" \
"$GF_PATHS_PROVISIONING/plugins" \
"$GF_PATHS_PROVISIONING/access-control" \
"$GF_PATHS_PROVISIONING/alerting" \
"$GF_PATHS_LOGS" \
"$GF_PATHS_PLUGINS" \
"$GF_PATHS_DATA" && \
cp conf/sample.ini "$GF_PATHS_CONFIG" && \
cp conf/ldap.toml /etc/grafana/ldap.toml && \
chown -R "grafana:$GF_GID_NAME" "$GF_PATHS_DATA" "$GF_PATHS_HOME/.aws" "$GF_PATHS_LOGS" "$GF_PATHS_PLUGINS" "$GF_PATHS_PROVISIONING" && \
chmod -R 777 "$GF_PATHS_DATA" "$GF_PATHS_HOME/.aws" "$GF_PATHS_LOGS" "$GF_PATHS_PLUGINS" "$GF_PATHS_PROVISIONING"
RUN export GF_GID_NAME=$(getent group $GF_GID | cut -d':' -f1) && \
mkdir -p "$GF_PATHS_HOME/.aws" && \
adduser -S -u $GF_UID -G "$GF_GID_NAME" grafana && \
mkdir -p "$GF_PATHS_PROVISIONING/datasources" \
"$GF_PATHS_PROVISIONING/dashboards" \
"$GF_PATHS_PROVISIONING/notifiers" \
"$GF_PATHS_PROVISIONING/plugins" \
"$GF_PATHS_PROVISIONING/access-control" \
"$GF_PATHS_PROVISIONING/alerting" \
"$GF_PATHS_LOGS" \
"$GF_PATHS_PLUGINS" \
"$GF_PATHS_DATA" && \
cp "$GF_PATHS_HOME/conf/sample.ini" "$GF_PATHS_CONFIG" && \
cp "$GF_PATHS_HOME/conf/ldap.toml" /etc/grafana/ldap.toml && \
chown -R "grafana:$GF_GID_NAME" "$GF_PATHS_DATA" "$GF_PATHS_HOME/.aws" "$GF_PATHS_LOGS" "$GF_PATHS_PLUGINS" "$GF_PATHS_PROVISIONING" && \
chmod -R 777 "$GF_PATHS_DATA" "$GF_PATHS_HOME/.aws" "$GF_PATHS_LOGS" "$GF_PATHS_PLUGINS" "$GF_PATHS_PROVISIONING"
COPY --from=go-builder /grafana/bin/*/grafana-server /grafana/bin/*/grafana-cli ./bin/
COPY --from=js-builder /grafana/public ./public
COPY --from=js-builder /grafana/tools ./tools
COPY --from=go-src /tmp/grafana/bin/grafana* /tmp/grafana/bin/*/grafana* ./bin/
COPY --from=js-src /tmp/grafana/public ./public
COPY --from=go-src /tmp/grafana/LICENSE ./
EXPOSE 3000
COPY ./packaging/docker/run.sh /run.sh
ARG RUN_SH=./packaging/docker/run.sh
USER grafana
COPY ${RUN_SH} /run.sh
USER "$GF_UID"
ENTRYPOINT [ "/run.sh" ]

View File

@@ -1,87 +0,0 @@
FROM node:16-alpine3.15 as js-builder
ENV NODE_OPTIONS=--max_old_space_size=8000
WORKDIR /usr/src/app/
COPY package.json yarn.lock ./
COPY packages packages
COPY .yarnrc.yml ./
COPY .yarn .yarn
COPY plugins-bundled plugins-bundled
RUN yarn install
COPY tsconfig.json .eslintrc .editorconfig .browserslistrc .prettierrc.js babel.config.json .linguirc ./
COPY public public
COPY tools tools
COPY scripts scripts
COPY emails emails
ENV NODE_ENV production
RUN yarn build
FROM golang:1.19.1 AS go-builder
WORKDIR /src/grafana
COPY go.mod go.sum embed.go ./
COPY Makefile build.go package.json ./
COPY .bingo .bingo
COPY pkg pkg/
COPY cue.mod cue.mod/
COPY packages/grafana-schema packages/grafana-schema/
COPY public/app/plugins public/app/plugins/
COPY public/api-spec.json public/api-spec.json
RUN go mod verify
RUN make build-go
FROM ubuntu:20.04
LABEL maintainer="Grafana team <hello@grafana.com>"
EXPOSE 3000
ARG GF_UID="472"
ARG GF_GID="472"
ENV PATH="/usr/share/grafana/bin:$PATH" \
GF_PATHS_CONFIG="/etc/grafana/grafana.ini" \
GF_PATHS_DATA="/var/lib/grafana" \
GF_PATHS_HOME="/usr/share/grafana" \
GF_PATHS_LOGS="/var/log/grafana" \
GF_PATHS_PLUGINS="/var/lib/grafana/plugins" \
GF_PATHS_PROVISIONING="/etc/grafana/provisioning"
WORKDIR $GF_PATHS_HOME
COPY conf conf
# curl should be part of the image
RUN apt-get update && apt-get install -y ca-certificates curl
RUN mkdir -p "$GF_PATHS_HOME/.aws" && \
addgroup --system --gid $GF_GID grafana && \
adduser --uid $GF_UID --system --ingroup grafana grafana && \
mkdir -p "$GF_PATHS_PROVISIONING/datasources" \
"$GF_PATHS_PROVISIONING/dashboards" \
"$GF_PATHS_PROVISIONING/notifiers" \
"$GF_PATHS_PROVISIONING/plugins" \
"$GF_PATHS_PROVISIONING/access-control" \
"$GF_PATHS_PROVISIONING/alerting" \
"$GF_PATHS_LOGS" \
"$GF_PATHS_PLUGINS" \
"$GF_PATHS_DATA" && \
cp conf/sample.ini "$GF_PATHS_CONFIG" && \
cp conf/ldap.toml /etc/grafana/ldap.toml && \
chown -R grafana:grafana "$GF_PATHS_DATA" "$GF_PATHS_HOME/.aws" "$GF_PATHS_LOGS" "$GF_PATHS_PLUGINS" "$GF_PATHS_PROVISIONING" && \
chmod -R 777 "$GF_PATHS_DATA" "$GF_PATHS_HOME/.aws" "$GF_PATHS_LOGS" "$GF_PATHS_PLUGINS" "$GF_PATHS_PROVISIONING"
COPY --from=go-builder /src/grafana/bin/*/grafana-server /src/grafana/bin/*/grafana-cli bin/
COPY --from=js-builder /usr/src/app/public public
COPY --from=js-builder /usr/src/app/tools tools
COPY packaging/docker/run.sh /
USER grafana
ENTRYPOINT [ "/run.sh" ]

View File

@@ -20,43 +20,52 @@ If you don't have the knowledge or time to code, consider helping with triage. T
<!-- https://textik.com/#610afa78553def29 -->
```
+--------------------------+
+----------------+ New issue opened/ |
| | more information added |
| +-------------+------------+
| Ask for more |
| information +-------------+------------+
| | All information needed |
| +--------+ to categorize the issue? +--------+
| | | | |
| | NO +--------------------------+ YES |
| | |
+------+-------+-------------+ +------------+---------+ +----------------------------+
| | | | | |
| label: needs more info | | Needs investigation? +--YES---+ label: needs investigation |
| | | | | |
+----------------------------+ +----------------+-----+ +--------------+-------------+
NO | |
| Investigate |
+-----------+----------+ |
| label: type/* | |
| label: area/* +------------------+
| label: datasource/* |
+-----|----------+-----+
| |
| |
| +--+--------------------+ +--------------------+
| | | | label: priority/* |
| | Needs priority? +--YES---+| milestone? |
| | | | |
| +--------------------+--+ +----+---------------+
| NO | |
| | |
+----+-------------+ +---+----------+ |
| | | | |
| Close issue +----------+ Done +------+
| | | |
+------------------+ +--------------+
+-------------------+
| |
| new issue/ | +
| more info added |
| |
+---------|---------+
|
+-------------|-----------+
| |
NO +------- all info needed to ------+ YES
| | categorize the issue? | |
| | | |
| +-------------------------+ |
+------|-----------+ +------------|----------+
| | | |
| label: | | label: type/* |
| needs more info | | label: area/* |
| | | label: datasource/* |
+------------------+ | | |
+------------|----------+
|
+--------|-------+
| |
NO +---------- is duplicate? --------------------+ YES
| | | |
| +----------------+ |
| +----------------|---------------+
+------|-----+ | |
| | | add comment: |
NO +------------ can repro? ------------+ YES | |
| | | | | /duplicate of #<issue number> |
| +------------+ | | |
| | +--------------------------------+
+-------------|-------------+ |
| | +--------|---------+
| label: | | |
| triage/needs-confirmation | NO +-------- needs priority? ------+ YES
| | | | | |
+-------------|-------------+ | +------------------+ |
| | |
+-------------|------+ +-------|--------+ +----------|---------+
| | | | | |
| Assign to project ------ Done -------------- label: priority/* |
| | | | | |
+--------------------+ +----------------+ +--------------------+
```
## 1. Find uncategorized issues
@@ -87,28 +96,29 @@ Given a certain [issue template](https://github.com/grafana/grafana/issues/new/c
Should explain what happened, what was expected and how to reproduce it together with any additional information that may help giving a complete picture of what happened such as screenshots, [query inspector](https://community.grafana.com/t/using-grafanas-query-inspector-to-troubleshoot-issues/2630) output and any environment related information that's applicable and/or maybe related to the reported problem:
- Grafana version
- Data source type & version
- Platform & OS Grafana is installed on
- User OS & Browser + versions
- Using docker + what environment
- Which plugins
- Configuration database in use (sqlite, mysql, postgres)
- Reverse proxy in front of Grafana, what version and configuration
- Non-default configuration settings
- Development environment like Go and Node versions, if applicable
- Grafana version:
- Data source type & version:
- OS Grafana is installed on:
- User OS & Browser:
- Grafana plugins:
- Others:
#### Enhancement requests
Should explain what enhancement or feature that the author wants to be added and why that is needed.
Enhancement requests (aka. feature requests) should be created as a [Github discussion](https://github.com/grafana/grafana/discussions). When submitting an enhancement request we ask that users focus on the problem they'd like to solve and why its a problem rather than focusing on the solution itself. To facilitate this we recommend using the following template:
- What would you like to be added?:
- Why is this needed (describe your use case and goals)\*\*?:
#### Accessibility issues
This is a mix between a bug report and enhancement request but focused on accessibility issues to help make Grafana improve keyboard navigation, screen-reader support and being accessible to everyone. The report should include relevant WCAG criteria, if applicable.
This is a mix between a bug report and enhancement request but focused on accessibility issues to help make Grafana improve keyboard navigation, screen-reader support and being accessible to everyone. The report should include relevant [WCAG criteria](https://www.w3.org/WAI/WCAG21/quickref/?versions=2.0), if applicable.
Grafana Labs is dedicated to improving our graphical user interfaces and overall experience so that our product becomes usable and accessible for people with disabilities as well as anyone else. Learn more about Grafana's commitment to [A11y](https://grafana.com/accessibility/) (accessibility).
#### Support requests
In general, if the issue description and title is perceived as a question no more information is needed.
In general, if the issue description and title is perceived as a question no more information is needed. See how to categorize these requests [here](#support-requests-1).
### Good practices
@@ -122,7 +132,7 @@ To make it easier for everyone to understand and find issues they're searching f
### Do you have all the information needed to categorize an issue?
Depending on the issue, you might not feel all this information is needed. Use your best judgement. If you cannot triage an issue using what its author provided, explain kindly to the author that they must provide the above information to clarify the problem. Label issue with `needs more detail` and add any related `area/*` or `datasource/*` labels.
Depending on the issue, you might not feel all this information is needed. Use your best judgement. If you cannot triage an issue using what its author provided, explain kindly to the author that they must provide the above information to clarify the problem. Label issue with `needs more info` and add any related `area/*` or `datasource/*` labels. Alternatively, use `bot/needs more info` label and the Grafana bot will request it for you.
If the author provides the standard information but you are still unable to triage the issue, request additional information. Do this kindly and politely because you are asking for more of the author's time.
@@ -158,7 +168,7 @@ Make sure it's not a duplicate by searching existing issues using related terms
1. Add a comment `/duplicate of #<issue number>`. GitHub will recognize this and add some additional context to the issue activity.
2. The Grafana bot will do the rest, adding the correct label and closing comment
3. Optionally add any related `area/*` or `datasource/*` labels.
3. Add `type/duplicate` label. Optionally add any related `area/*` or `datasource/*` labels.
### Bug reports
@@ -183,8 +193,8 @@ If it's not perfectly clear that it's an actual bug, quickly try to reproduce it
### Enhancement/feature?
1. Label the issue `type/feature-request` and at least one `area/*` or `datasource/*` label.
2. Move on to [prioritizing the issue](#4-prioritization-of-issues).
1. Remind the contributor that enhancement/feature request should be created as a GitHub discussion. See [Enhancements requests.](https://github.com/grafana/grafana/blob/main/ISSUE_TRIAGE.md#enhancement-requests)
2. Label the issue `type/feature-request` and at least one `area/*` or `datasource/*` label.
### Documentation issue?
@@ -215,7 +225,7 @@ There's a minor typo/error/lack of information that adds a lot of confusion for
### Support requests
1. Kindly and politely direct the issue author to the [community site](https://community.grafana.com/) and explain that GitHub is mainly used for tracking bugs and feature requests. If possible, it's usually a good idea to add some pointers to the issue author's question.
2. Close the issue and label it with `type/question`.
2. Label the issue with `bot/question`. The Grafana bot will automatically close the issue, and it will add the type/question label for you.
## 4. Prioritization of issues
@@ -296,7 +306,7 @@ In many cases the issue author or community as a whole is more suitable to contr
## Investigation of issues
When an issue has all basic information provided, but the triage responsible haven't been able to reproduce the reported problem at a first glance, the issue is labeled [Needs investigation](https://github.com/grafana/grafana/labels/needs%20investigation). Depending on the perceived severity and/or number of [upvotes](https://github.blog/2016-03-10-add-reactions-to-pull-requests-issues-and-comments), the investigation will either be delegated to another maintainer for further investigation or put on hold until someone else (maintainer or contributor) picks it up and eventually starts investigating it.
When an issue has all basic information provided, but the triage responsible haven't been able to reproduce the reported problem at a first glance, the issue is labeled [`triage/needs-confirmation`](https://github.com/grafana/grafana/labels/triage%2Fneeds-confirmation). Depending on the perceived severity and/or number of [upvotes](https://github.blog/2016-03-10-add-reactions-to-pull-requests-issues-and-comments), the investigation will either be delegated to another maintainer for further investigation or put on hold until someone else (maintainer or contributor) picks it up and eventually starts investigating it.
Investigating issues can be a very time consuming task, especially for the maintainers, given the huge number of combinations of plugins, data sources, platforms, databases, browsers, tools, hardware, integrations, versions and cloud services, etc that are being used with Grafana. There is a certain number of combinations that are more common than others, and these are in general easier for maintainers to investigate.
@@ -308,19 +318,16 @@ Even if you don't have the time or knowledge to investigate an issue we highly r
We have some automation that triggers on comments or labels being added to issues. Many of these automated behaviors are defined in [commands.json](https://github.com/grafana/grafana/blob/main/.github/commands.json). Or in other [GitHub Actions](https://github.com/grafana/grafana/tree/main/.github/workflows)
- Add /duplicate `#<issue number>` to have Grafana label & close issue with an appropriate message.
- Add `bot/question` and the bot will close it with an appropriate message.
[Read more on bot actions](https://github.com/grafana/grafana/blob/main/.github/bot.md)
## External PRs
Part of issue triage should also be triaging of external PRs. Main goal should be to make sure PRs from external contributors have an owner/reviewer and are not forgotten.
1. Check new external PRs which do not have a reviewer.
1. Check if there is a link to an existing issue.
1. If not and you know which issue it is solving, add the link yourself, otherwise ask the author to link the issue or create one.
1. Assign a reviewer based on who was handling the linked issue or what code or feature does the PR touches (look at who was the last to make changes there if all else fails).
1. Check new external PRs which do not have a reviewer. You can easily search for pull requests made by external contributors by using the label: `pr/external` in your [query search](https://github.com/grafana/grafana/pulls?q=is%3Aopen+is%3Apr+label%3Apr%2Fexternal) Note: external PRs are automatically labeled with `pr/external` upon creation.
2. Check if there is a link to an existing issue. The link to a existing issue should be in the description section, underneath “Which issue(s) does this PR fix?:”.
3. If not and you know which issue it is solving, add the link yourself, otherwise ask the author to link the issue or create one.
4. Assign a reviewer based on who was handling the linked issue or what code or feature does the PR touches (look at who was the last to make changes there if all else fails).
## Appendix

View File

@@ -15,12 +15,16 @@ packages/grafana-e2e-selectors/
packages/grafana-runtime/
packages/grafana-toolkit/
packages/grafana-ui/
packages/jaeger-ui-components/
packaging/
pkg/coremodel/
pkg/framework/coremodel/
kinds/
pkg/kinds/
pkg/kindsys/
pkg/registry/corekind/
grafana-mixin/
cue/
public/app/plugins/datasource/tempo
public/app/features/explore/TraceView/components
public/img/icons/solid/
public/img/icons/unicons/
```
The following directories and their subdirectories are licensed under their original upstream licenses:

View File

@@ -7,12 +7,13 @@ WIRE_TAGS = "oss"
-include local/Makefile
include .bingo/Variables.mk
.PHONY: all deps-go deps-js deps build-go build-server build-cli build-js build build-docker-full build-docker-full-ubuntu lint-go golangci-lint test-go test-js gen-ts test run run-frontend clean devenv devenv-down protobuf drone help gen-go gen-cue
.PHONY: all deps-go deps-js deps build-go build-backend build-server build-cli build-js build build-docker-full build-docker-full-ubuntu lint-go golangci-lint test-go test-js gen-ts test run run-frontend clean devenv devenv-down protobuf drone help gen-go gen-cue fix-cue
GO = go
GO_FILES ?= ./pkg/...
SH_FILES ?= $(shell find ./scripts -name *.sh)
GO_BUILD_FLAGS += $(if $(GO_BUILD_DEV),-dev)
GO_BUILD_FLAGS += $(if $(GO_BUILD_DEV),-dev)
GO_BUILD_FLAGS += $(if $(GO_BUILD_TAGS),-build-tags=$(GO_BUILD_TAGS))
all: deps build
@@ -42,35 +43,55 @@ $(MERGED_SPEC_TARGET): $(SPEC_TARGET) $(NGALERT_SPEC_TARGET) $(SWAGGER) ## Merge
# known conflicts DsPermissionType, AddApiKeyCommand, Json, Duration (identical models referenced by both specs)
$(SWAGGER) mixin $(SPEC_TARGET) $(NGALERT_SPEC_TARGET) --ignore-conflicts -o $(MERGED_SPEC_TARGET)
--swagger-api-spec: $(SWAGGER) ## Generate API Swagger specification
SWAGGER_GENERATE_EXTENSION=false $(SWAGGER) generate spec -m -w pkg/server -o public/api-spec.json \
$(SPEC_TARGET): $(SWAGGER) ## Generate API Swagger specification
SWAGGER_GENERATE_EXTENSION=false $(SWAGGER) generate spec -m -w pkg/server -o $(SPEC_TARGET) \
-x "github.com/grafana/grafana/pkg/services/ngalert/api/tooling/definitions" \
-x "github.com/prometheus/alertmanager" \
-i pkg/api/swagger_tags.json
-i pkg/api/swagger_tags.json \
--exclude-tag=alpha
swagger-api-spec: gen-go --swagger-api-spec $(MERGED_SPEC_TARGET) validate-api-spec
swagger-api-spec: gen-go $(SPEC_TARGET) $(MERGED_SPEC_TARGET) validate-api-spec
validate-api-spec: $(MERGED_SPEC_TARGET) $(SWAGGER) ## Validate API spec
$(SWAGGER) validate $(<)
clean-api-spec:
rm $(SPEC_TARGET) $(MERGED_SPEC_TARGET)
rm $(SPEC_TARGET) $(MERGED_SPEC_TARGET) $(OAPI_SPEC_TARGET)
##@ OpenAPI 3
OAPI_SPEC_TARGET = public/openapi3.json
openapi3-gen: swagger-api-spec ## Generates OpenApi 3 specs from the Swagger 2 already generated
$(GO) run scripts/openapi3/openapi3conv.go $(MERGED_SPEC_TARGET) $(OAPI_SPEC_TARGET)
##@ Building
gen-cue: ## Do all CUE/Thema code generation
@echo "generate code from .cue files"
go generate ./pkg/framework/coremodel
go generate ./public/app/plugins
go generate ./pkg/plugins/plugindef
go generate ./kinds/gen.go
go generate ./public/app/plugins/gen.go
go generate ./pkg/kindsys/report.go
gen-go: $(WIRE) gen-cue
@echo "generate go files"
$(WIRE) gen -tags $(WIRE_TAGS) ./pkg/server ./pkg/cmd/grafana-cli/runner
fix-cue: $(CUE)
@echo "formatting cue files"
$(CUE) fix kinds/**/*.cue
$(CUE) fix public/app/plugins/**/**/*.cue
gen-jsonnet:
go generate ./devenv/jsonnet
build-go: $(MERGED_SPEC_TARGET) gen-go ## Build all Go binaries.
@echo "build go files"
$(GO) run build.go $(GO_BUILD_FLAGS) build
build-backend: ## Build Grafana backend.
@echo "build backend"
$(GO) run build.go $(GO_BUILD_FLAGS) build-backend
build-server: ## Build Grafana server.
@echo "build server"
$(GO) run build.go $(GO_BUILD_FLAGS) build-server
@@ -111,13 +132,13 @@ test-go-integration: ## Run integration tests for backend with flags.
test-go-integration-postgres: devenv-postgres ## Run integration tests for postgres backend with flags.
@echo "test backend integration postgres tests"
$(GO) clean -testcache
$(GO) list './pkg/...' | xargs -I {} sh -c 'GRAFANA_TEST_DB=postgres go test -run Integration -covermode=atomic -timeout=30m {}'
$(GO) list './pkg/...' | xargs -I {} sh -c 'GRAFANA_TEST_DB=postgres go test -run Integration -covermode=atomic -timeout=2m {}'
.PHONY: test-go-integration-mysql
test-go-integration-mysql: devenv-mysql ## Run integration tests for mysql backend with flags.
@echo "test backend integration mysql tests"
$(GO) clean -testcache
$(GO) list './pkg/...' | xargs -I {} sh -c 'GRAFANA_TEST_DB=mysql go test -run Integration -covermode=atomic -timeout=30m {}'
$(GO) list './pkg/...' | xargs -I {} sh -c 'GRAFANA_TEST_DB=mysql go test -run Integration -covermode=atomic -timeout=2m {}'
test-js: ## Run tests for frontend.
@echo "test frontend"
@@ -143,17 +164,22 @@ shellcheck: $(SH_FILES) ## Run checks for shell scripts.
build-docker-full: ## Build Docker image for development.
@echo "build docker container"
docker build --tag grafana/grafana:dev .
DOCKER_BUILDKIT=1 \
docker build \
--tag grafana/grafana:dev .
build-docker-full-ubuntu: ## Build Docker image based on Ubuntu for development.
@echo "build docker container"
docker build --tag grafana/grafana:dev-ubuntu -f ./Dockerfile.ubuntu .
DOCKER_BUILDKIT=1 \
docker build \
--build-arg BASE_IMAGE=ubuntu:20.04 \
--build-arg GO_IMAGE=golang:1.20.10 \
--tag grafana/grafana:dev-ubuntu .
##@ Services
# create docker-compose file with provided sources and start them
# example: make devenv sources=postgres,openldap
# example: make devenv sources=postgres,auth/openldap
ifeq ($(sources),)
devenv:
@printf 'You have to define sources for this command \nexample: make devenv sources=postgres,openldap\n'
@@ -213,5 +239,12 @@ drone: $(DRONE)
$(DRONE) lint .drone.yml --trusted
$(DRONE) --server https://drone.grafana.net sign --save grafana/grafana
# Generate an Emacs tags table (https://www.gnu.org/software/emacs/manual/html_node/emacs/Tags-Tables.html) for Starlark files.
scripts/drone/TAGS: $(shell find scripts/drone -name '*.star')
etags --lang none --regex="/def \(\w+\)[^:]+:/\1/" --regex="/\s*\(\w+\) =/\1/" $^ -o $@
format-drone:
buildifier -r scripts/drone
help: ## Display this help.
@awk 'BEGIN {FS = ":.*##"; printf "\nUsage:\n make \033[36m<target>\033[0m\n"} /^[a-zA-Z_-]+:.*?##/ { printf " \033[36m%-15s\033[0m %s\n", $$1, $$2 } /^##@/ { printf "\n\033[1m%s\033[0m\n", substr($$0, 5) } ' $(MAKEFILE_LIST)

View File

@@ -1,33 +0,0 @@
# Plugin development
This document is not meant as a complete guide for developing plugins but more as a changelog for changes in
Grafana that can impact plugin development. Whenever you as a plugin author encounter an issue with your plugin after
upgrading Grafana please check here before creating an issue.
## Plugin development resources
- [Grafana plugin developer guide](https://grafana.com/docs/grafana/latest/developers/plugins/)
- [Webpack Grafana plugin template project](https://github.com/CorpGlory/grafana-plugin-template-webpack)
- [Simple JSON datasource plugin](https://github.com/grafana/simple-json-datasource)
## Changes in Grafana v4.6
This version of Grafana has big changes that will impact a limited set of plugins. We moved from systemjs to webpack
for built-in plugins and everything internal. External plugins still use systemjs but now with a limited
set of Grafana components they can import. Plugins can depend on libs like lodash & moment and internal components
like before using the same import paths. However since everything in Grafana is no longer accessible, a few plugins could encounter issues when importing a Grafana dependency.
[List of exposed components plugins can import/require](https://github.com/grafana/grafana/blob/main/public/app/features/plugins/plugin_loader.ts#L48)
If you think we missed exposing a crucial lib or Grafana component let us know by opening an issue.
### Deprecated components
The angular directive `<spectrum-picker>` is now deprecated (will still work for a version more) but we recommend plugin authors
upgrade to new `<color-picker color="ctrl.color" onChange="ctrl.onSparklineColorChange"></color-picker>`
## Changes in Grafana v6.0
### DashboardSrv.ts
If you utilize [DashboardSrv](https://github.com/grafana/grafana/commit/8574dca081002f36e482b572517d8f05fd44453f#diff-1ab99561f9f6a10e1fafcddc39bc1d65) in your plugin code, `dash` was renamed to `dashboard`.

View File

@@ -18,7 +18,7 @@ Grafana allows you to query, visualize, alert on and understand your metrics no
## Get started
- [Get Grafana](https://grafana.com/get)
- [Installation guides](http://docs.grafana.org/installation/)
- [Installation guides](https://grafana.com/docs/grafana/latest/setup-grafana/installation/)
Unsure if Grafana is for you? Watch Grafana in action on [play.grafana.org](https://play.grafana.org/)!

View File

@@ -14,7 +14,6 @@ Grafana Labs will send you a response indicating the next steps in handling your
## Security announcements
We maintain a category on the community site called [Security Announcements](https://community.grafana.com/c/support/security-announcements),
where we will post a summary, remediation, and mitigation details for any patch containing security fixes.
We will post a summary, remediation, and mitigation details for any patch containing security fixes on the Grafana blog. The security announcement blog posts will be tagged with the [security tag](https://grafana.com/tags/security/).
You can also subscribe to email updates to this category if you have a grafana.com account and sign on to the community site or track updates via an [RSS feed](https://community.grafana.com/c/support/security-announcements.rss).
You can also track security announcements via the [RSS feed](https://grafana.com/tags/security/index.xml).

View File

@@ -1,38 +0,0 @@
{
"$schema": "https://developer.microsoft.com/json-schemas/api-extractor/v7/api-extractor.schema.json",
"mainEntryPointFilePath": "<projectFolder>/dist/index.d.ts",
"bundledPackages": [],
"compiler": {},
"apiReport": {
"enabled": false
},
"docModel": {
"enabled": true,
"apiJsonFilePath": "<projectFolder>/../../reports/docs/<unscopedPackageName>.api.json"
},
"dtsRollup": {
"enabled": false
},
"tsdocMetadata": {},
"messages": {
"compilerMessageReporting": {
"default": {
"logLevel": "warning"
}
},
"extractorMessageReporting": {
"default": {
"logLevel": "warning"
},
"ae-internal-missing-underscore": {
"logLevel": "none",
"addToApiReportFile": false
}
},
"tsdocMessageReporting": {
"default": {
"logLevel": "warning"
}
}
}
}

View File

@@ -66,6 +66,15 @@ enable_gzip = false
cert_file =
cert_key =
# Unix socket gid
# Changing the gid of a file without privileges requires that the target group is in the group of the process and that the process is the file owner
# It is recommended to set the gid as http server user gid
# Not set when the value is -1
socket_gid = -1
# Unix socket mode
socket_mode = 0660
# Unix socket path
socket = /tmp/grafana.sock
@@ -76,6 +85,11 @@ cdn_url =
# `0` means there is no timeout for reading the request.
read_timeout = 0
# This setting enables you to specify additional headers that the server adds to HTTP(S) responses.
[server.custom_response_headers]
#exampleHeader1 = exampleValue1
#exampleHeader2 = exampleValue2
#################################### Database ############################
[database]
# You can configure the database connection by specifying type, host, name, user and password
@@ -125,9 +139,18 @@ path = grafana.db
# For "sqlite3" only. cache mode setting used for connecting to the database
cache_mode = private
# For "sqlite3" only. Enable/disable Write-Ahead Logging, https://sqlite.org/wal.html. Default is false.
wal = false
# For "mysql" only if migrationLocking feature toggle is set. How many seconds to wait before failing to lock the database for the migrations, default is 0.
locking_attempt_timeout_sec = 0
# For "sqlite" only. How many times to retry query in case of database is locked failures. Default is 0 (disabled).
query_retries = 0
# For "sqlite" only. How many times to retry transaction in case of database is locked failures. Default is 5.
transaction_retries = 5
#################################### Cache server #############################
[remote_cache]
# Either "redis", "memcached" or "database" default is "database"
@@ -139,6 +162,12 @@ type = database
# memcache: 127.0.0.1:11211
connstr =
# prefix prepended to all the keys in the remote cache
prefix =
# This enables encryption of values stored in the remote cache
encryption =
#################################### Data proxy ###########################
[dataproxy]
@@ -212,6 +241,12 @@ check_for_plugin_updates = true
# Google Analytics universal tracking code, only enabled if you specify an id here
google_analytics_ua_id =
# Google Analytics 4 tracking code, only enabled if you specify an id here
google_analytics_4_id =
# When Google Analytics 4 Enhanced event measurement is enabled, we will try to avoid sending duplicate events and let Google Analytics 4 detect navigation changes, etc.
google_analytics_4_send_manual_page_views = false
# Google Tag Manager ID, only enabled if you specify an id here
google_tag_manager_id =
@@ -227,6 +262,9 @@ rudderstack_sdk_url =
# Rudderstack Config url, optional, used by Rudderstack SDK to fetch source config
rudderstack_config_url =
# Intercom secret, optional, used to hash user_id before passing to Intercom via Rudderstack
intercom_secret =
# Application Insights connection string. Specify an URL string to enable this feature.
application_insights_connection_string =
@@ -247,6 +285,9 @@ admin_user = admin
# default admin password, can be changed before first start of grafana, or in profile settings
admin_password = admin
# default admin email, created on startup
admin_email = admin@localhost
# used for signing
secret_key = SW2YcwTIb9zpOOhoPsMm
@@ -305,6 +346,15 @@ content_security_policy = false
# $ROOT_PATH is server.root_url without the protocol.
content_security_policy_template = """script-src 'self' 'unsafe-eval' 'unsafe-inline' 'strict-dynamic' $NONCE;object-src 'none';font-src 'self';style-src 'self' 'unsafe-inline' blob:;img-src * data:;base-uri 'self';connect-src 'self' grafana.com ws://$ROOT_PATH wss://$ROOT_PATH;manifest-src 'self';media-src 'none';form-action 'self';"""
# Enable adding the Content-Security-Policy-Report-Only header to your requests.
# Allows you to monitor the effects of a policy without enforcing it.
content_security_policy_report_only = false
# Set Content Security Policy Report Only template used when adding the Content-Security-Policy-Report-Only header to your requests.
# $NONCE in the template includes a random nonce.
# $ROOT_PATH is server.root_url without the protocol.
content_security_policy_report_only_template = """script-src 'self' 'unsafe-eval' 'unsafe-inline' 'strict-dynamic' $NONCE;object-src 'none';font-src 'self';style-src 'self' 'unsafe-inline' blob:;img-src * data:;base-uri 'self';connect-src 'self' grafana.com ws://$ROOT_PATH wss://$ROOT_PATH;manifest-src 'self';media-src 'none';form-action 'self';"""
# Controls if old angular plugins are supported or not. This will be disabled by default in future release
angular_support_enabled = true
@@ -319,6 +369,9 @@ data_keys_cache_cleanup_interval = 1m
#################################### Snapshots ###########################
[snapshots]
# set to false to remove snapshot functionality
enabled = true
# snapshot sharing options
external_enabled = true
external_snapshot_url = https://snapshots.raintank.io
@@ -373,11 +426,11 @@ verify_email_enabled = false
login_hint = email or username
password_hint = password
# Default UI theme ("dark" or "light")
# Default UI theme ("dark" or "light" or "system")
default_theme = dark
# Default locale (supported IETF language tag, such as en-US)
default_locale = en-US
# Default UI language (supported IETF language tag, such as en-US)
default_language = en-US
# Path to a custom home page. Users are only redirected to this if the default home dashboard is used. It should match a frontend route and contain a leading slash.
home_page =
@@ -399,10 +452,17 @@ user_invite_max_lifetime_duration = 24h
# Enter a comma-separated list of usernames to hide them in the Grafana UI. These users are shown to Grafana admins and to themselves.
hidden_users =
[service_accounts]
# When set, Grafana will not allow the creation of tokens with expiry greater than this setting.
token_expiration_day_limit =
[auth]
# Login cookie name
login_cookie_name = grafana_session
# Disable usage of Grafana build-in login solution.
disable_login = false
# The maximum lifetime (duration) an authenticated user can be inactive before being required to login at next visit. Default is 7 days (7d). This setting should be expressed as a duration, e.g. 5m (minutes), 6h (hours), 10d (days), 2w (weeks), 1M (month). The lifetime resets at each successful token rotation (token_rotation_interval_minutes).
login_maximum_inactive_lifetime_duration =
@@ -423,6 +483,7 @@ signout_redirect_url =
# Set to true to attempt login with OAuth automatically, skipping the login screen.
# This setting is ignored if multiple OAuth providers are configured.
# Deprecated, use auto_login option for specific provider instead.
oauth_auto_login = false
# OAuth state max age cookie duration in seconds. Defaults to 600 seconds.
@@ -443,6 +504,9 @@ sigv4_verbose_logging = false
# Set to true to enable Azure authentication option for HTTP-based datasources
azure_auth_enabled = false
# Use email lookup in addition to the unique ID provided by the IdP
oauth_allow_insecure_email_lookup = false
#################################### Anonymous Auth ######################
[auth.anonymous]
# enable anonymous access
@@ -461,6 +525,7 @@ hide_version = false
[auth.github]
enabled = false
allow_sign_up = true
auto_login = false
client_id = some_id
client_secret =
scopes = user:email,read:org
@@ -473,11 +538,17 @@ allowed_organizations =
role_attribute_path =
role_attribute_strict = false
allow_assign_grafana_admin = false
skip_org_role_sync = false
tls_skip_verify_insecure = false
tls_client_cert =
tls_client_key =
tls_client_ca =
#################################### GitLab Auth #########################
[auth.gitlab]
enabled = false
allow_sign_up = true
auto_login = false
client_id = some_id
client_secret =
scopes = api
@@ -489,11 +560,13 @@ allowed_groups =
role_attribute_path =
role_attribute_strict = false
allow_assign_grafana_admin = false
skip_org_role_sync = false
#################################### Google Auth #########################
[auth.google]
enabled = false
allow_sign_up = true
auto_login = false
client_id = some_client_id
client_secret =
scopes = https://www.googleapis.com/auth/userinfo.profile https://www.googleapis.com/auth/userinfo.email
@@ -502,6 +575,7 @@ token_url = https://accounts.google.com/o/oauth2/token
api_url = https://www.googleapis.com/oauth2/v1/userinfo
allowed_domains =
hosted_domain =
skip_org_role_sync = false
#################################### Grafana.com Auth ####################
# legacy key names (so they work in env variables)
@@ -516,16 +590,19 @@ allowed_organizations =
[auth.grafana_com]
enabled = false
allow_sign_up = true
auto_login = false
client_id = some_id
client_secret =
scopes = user:email
allowed_organizations =
skip_org_role_sync = false
#################################### Azure AD OAuth #######################
[auth.azuread]
name = Azure AD
enabled = false
allow_sign_up = true
auto_login = false
client_id = some_client_id
client_secret =
scopes = openid email profile
@@ -535,6 +612,7 @@ allowed_domains =
allowed_groups =
role_attribute_strict = false
allow_assign_grafana_admin = false
force_use_graph_api = false
#################################### Okta OAuth #######################
[auth.okta]
@@ -542,6 +620,7 @@ name = Okta
icon = okta
enabled = false
allow_sign_up = true
auto_login = false
client_id = some_id
client_secret =
scopes = openid profile email groups
@@ -553,6 +632,7 @@ allowed_groups =
role_attribute_path =
role_attribute_strict = false
allow_assign_grafana_admin = false
skip_org_role_sync = false
#################################### Generic OAuth #######################
[auth.generic_oauth]
@@ -560,6 +640,7 @@ name = OAuth
icon = signin
enabled = false
allow_sign_up = true
auto_login = false
client_id = some_id
client_secret =
scopes = user:email
@@ -614,15 +695,21 @@ username_claim =
jwk_set_url =
jwk_set_file =
cache_ttl = 60m
expected_claims = {}
expect_claims = {}
key_file =
role_attribute_path =
role_attribute_strict = false
auto_sign_up = false
url_login = false
allow_assign_grafana_admin = false
skip_org_role_sync = false
#################################### Auth LDAP ###########################
[auth.ldap]
enabled = false
config_file = /etc/grafana/ldap.toml
allow_sign_up = true
skip_org_role_sync = false
# LDAP background sync (Enterprise only)
# At 1 am every day
@@ -660,9 +747,13 @@ managed_identity_client_id =
#################################### Role-based Access Control ###########
[rbac]
# If enabled, cache permissions in a in memory cache (Enterprise only)
# If enabled, cache permissions in a in memory cache
permission_cache = true
# Reset basic roles permissions on boot
# Warning left to true, basic roles permissions will be reset on every boot
reset_basic_roles = false
#################################### SMTP / Emailing #####################
[smtp]
enabled = false
@@ -874,10 +965,17 @@ max_attempts = 3
min_interval = 10s
[unified_alerting.screenshots]
# Enable screenshots in notifications. This option requires the Grafana Image Renderer plugin.
# Enable screenshots in notifications. You must have either installed the Grafana image rendering
# plugin, or set up Grafana to use a remote rendering service.
# For more information on configuration options, refer to [rendering].
capture = false
# The timeout for capturing screenshots. If a screenshot cannot be captured within the timeout then
# the notification is sent without a screenshot. The maximum duration is 30 seconds. This timeout
# should be less than the minimum Interval of all Evaluation Groups to avoid back pressure on alert
# rule evaluation.
capture_timeout = 10s
# The maximum number of screenshots that can be taken at the same time. This option is different from
# concurrent_render_request_limit as max_concurrent_screenshots sets the number of concurrent screenshots
# that can be taken at the same time for all firing alerts where as concurrent_render_request_limit sets
@@ -894,6 +992,10 @@ upload_external_image_storage = false
# For example: `disabled_labels=grafana_folder`
disabled_labels =
[unified_alerting.state_history]
# Enable the state history functionality in Unified Alerting. The previous states of alert rules will be visible in panels and in the UI.
enabled = true
#################################### Alerting ############################
[alerting]
# Enable the legacy alerting sub-system and interface. If Unified Alerting is already enabled and you try to go back to legacy alerting, all data that is part of Unified Alerting will be deleted. When this configuration section and flag are not defined, the state is defined at runtime. See the documentation for more details.
@@ -936,6 +1038,10 @@ max_annotations_to_keep =
# Configures the batch size for the annotation clean-up job. This setting is used for dashboard, API, and alert annotations.
cleanupjob_batchsize = 100
# Enforces the maximum allowed length of the tags for any newly introduced annotations. It can be between 500 and 4096 inclusive (which is the respective's column length). Default value is 500.
# Setting it to a higher value would impact performance therefore is not recommended.
tags_length = 500
[annotations.dashboard]
# Dashboard annotations means that annotations are associated with the dashboard they are created on.
@@ -1007,6 +1113,7 @@ url = https://grafana.com
[grafana_com]
url = https://grafana.com
api_url = https://grafana.com/api
#################################### Distributed tracing ############
# Opentracing is deprecated use opentelemetry instead
@@ -1033,6 +1140,11 @@ zipkin_propagation = false
# Not disabling is the most common setting when using Zipkin elsewhere in your infrastructure.
disable_shared_zipkin_spans = false
[tracing.opentelemetry]
# attributes that will always be included in when creating new spans. ex (key1:value1,key2:value2)
custom_attributes =
[tracing.opentelemetry.jaeger]
# jaeger destination (ex http://localhost:14268/api/traces)
address =
@@ -1079,6 +1191,7 @@ signed_url_expiration =
account_name =
account_key =
container_name =
sas_token_expiration_days =
[external_image_storage.local]
# does not require any configuration
@@ -1094,6 +1207,11 @@ renderer_token = -
# Concurrent render request limit affects when the /render HTTP endpoint is used. Rendering many images at the same time can overload the server,
# which this setting can help protect against by only allowing a certain amount of concurrent requests.
concurrent_render_request_limit = 30
# Determines the lifetime of the render key used by the image renderer to access and render Grafana.
# This setting should be expressed as a duration. Examples: 10s (seconds), 5m (minutes), 2h (hours).
# Default is 5m. This should be more than enough for most deployments.
# Change the value only if image rendering is failing and you see `Failed to get the render key from cache` in Grafana logs.
render_key_lifetime = 5m
[panels]
# here for to support old env variables, can remove after a few months
@@ -1208,20 +1326,10 @@ license_path =
# enable = feature1,feature2
enable =
# The new prometheus visual query builder
promQueryBuilder = true
# The new loki visual query builder
lokiQueryBuilder = true
# Experimental Explore to Dashboard workflow
explore2Dashboard = true
# Experimental Command Palette
commandPalette = true
# Use dynamic labels in CloudWatch datasource
cloudWatchDynamicLabels = true
# Some features are enabled by default, see:
# https://grafana.com/docs/grafana/next/setup-grafana/configure-grafana/feature-toggles/
# To enable features by default, set `Expression: "true"` in:
# https://github.com/grafana/grafana/blob/main/pkg/services/featuremgmt/registry.go
# feature1 = true
# feature2 = false
@@ -1298,3 +1406,24 @@ full_reindex_interval = 5m
# Defines the frequency of partial index updates based on recent changes such as dashboard updates.
# This is a temporary settings that might be removed in the future.
index_update_interval = 10s
# Move an app plugin referenced by its id (including all its pages) to a specific navigation section
# Dependencies: needs the `topnav` feature to be enabled
# Format: <Plugin ID> = <Section ID> <Sort Weight>
[navigation.app_sections]
# Move a specific app plugin page (referenced by its `path` field) to a specific navigation section
# Format: <Page URL> = <Section ID> <Sort Weight>
[navigation.app_standalone_pages]
#################################### Secure Socks5 Datasource Proxy #####################################
[secure_socks_datasource_proxy]
enabled = false
root_ca_cert =
client_key =
client_cert =
server_name =
# The address of the socks5 proxy datasources should connect to
proxy_address =

View File

@@ -24,6 +24,8 @@ bind_dn = "cn=admin,dc=grafana,dc=org"
# Search user bind password
# If the password contains # or ; you have to wrap it with triple quotes. Ex """#password;"""
bind_password = 'grafana'
# We recommend using variable expansion for the bind_password, for more info https://grafana.com/docs/grafana/latest/setup-grafana/configure-grafana/#variable-expansion
# bind_password = '$__env{LDAP_BIND_PASSWORD}'
# Timeout in seconds (applies to each host specified in the 'host' entry (space separated))
timeout = 10
@@ -58,7 +60,7 @@ org_role = "Admin"
# org_id = 1
[[servers.group_mappings]]
group_dn = "cn=users,ou=groups,dc=grafana,dc=org"
group_dn = "cn=editors,ou=groups,dc=grafana,dc=org"
org_role = "Editor"
[[servers.group_mappings]]

View File

@@ -19,9 +19,9 @@
# # <string, required> action allowed.
# - action: 'users:read'
# #<string> scope it applies to.
# scope: 'users:*'
# scope: 'global.users:*'
# - action: 'users:write'
# scope: 'users:*'
# scope: 'global.users:*'
# - action: 'users:create'
# - name: 'custom:global:users:reader'
# # <bool> overwrite org id and creates a global role.
@@ -42,9 +42,9 @@
# # <list> list of the permissions to add/remove on top of the copied ones.
# permissions:
# - action: 'users:read'
# scope: 'users:*'
# scope: 'global.users:*'
# - action: 'users:write'
# scope: 'users:*'
# scope: 'global.users:*'
# # <string> state of the permission. Defaults to 'present'. If 'absent', the permission will be removed.
# state: absent

View File

@@ -11,7 +11,7 @@ apiVersion: 1
# folder: my_first_folder
# # <duration, required> interval of the rule group evaluation
# interval: 60s
# # <list, required> list of rules that are part of the rule group
# # <list, required> list of rules that are part of the rule group
# rules:
# # <string, required> unique identifier for the rule
# - uid: my_id_1
@@ -23,7 +23,7 @@ apiVersion: 1
# # evaluation - should be obtained via the API
# data:
# - refId: A
# datasourceUid: "-100"
# datasourceUid: "__expr__"
# model:
# conditions:
# - evaluator:
@@ -40,7 +40,7 @@ apiVersion: 1
# type: query
# datasource:
# type: __expr__
# uid: "-100"
# uid: "__expr__"
# expression: 1==0
# intervalMs: 1000
# maxDataPoints: 43200
@@ -53,18 +53,20 @@ apiVersion: 1
# # <string> state of the alert rule when no data is returned
# # possible values: "NoData", "Alerting", "OK", default = NoData
# noDataState: Alerting
# # <string> state of the alert rule when the query execution
# # <string> state of the alert rule when the query execution
# # fails - possible values: "Error", "Alerting", "OK"
# # default = Alerting
# executionErrorState: Alerting
# # <duration, required> how long the alert condition should be breached before Firing. Before this time has elapsed, the alert is considered to be Pending
# for: 60s
# # <map<string, string>> map of strings to attach arbitrary custom data
# annotations:
# some_key: some_value
# # <map<string, string> map of strings to filter and
# # <map<string, string> map of strings to filter and
# # route alerts
# labels:
# team: sre_team_1
# isPaused: false
# # List of alert rule UIDs that should be deleted
# deleteRules:
@@ -102,7 +104,7 @@ apiVersion: 1
# # <list<string>> The labels by which incoming alerts are grouped together. For example,
# # multiple alerts coming in for cluster=A and alertname=LatencyHigh would
# # be batched into a single group.
# #
# #
# # To aggregate by all possible labels, use the special value '...' as
# # the sole label name, for example:
# # group_by: ['...']
@@ -126,18 +128,18 @@ apiVersion: 1
# mute_time_intervals:
# - abc
# # <duration> How long to initially wait to send a notification for a group
# # of alerts. Allows to collect more initial alerts for the same group.
# # of alerts. Allows to collect more initial alerts for the same group.
# # (Usually ~0s to few minutes), default = 30s
# group_wait: 30s
# # <duration> How long to wait before sending a notification about new alerts that
# # are added to a group of alerts for which an initial notification has
# # already been sent. (Usually ~5m or more), default = 5m
# group_internval: 5m
# group_interval: 5m
# # <duration> How long to wait before sending a notification again if it has already
# # been sent successfully for an alert. (Usually ~3h or more), default = 4h
# repeat_interval: 4h
# # <list> Zero or more child routes
# routes:
# routes:
# ...
# # List of orgIds that should be reset to the default policy

View File

@@ -67,6 +67,15 @@
;cert_file =
;cert_key =
# Unix socket gid
# Changing the gid of a file without privileges requires that the target group is in the group of the process and that the process is the file owner
# It is recommended to set the gid as http server user gid
# Not set when the value is -1
;socket_gid =
# Unix socket mode
;socket_mode =
# Unix socket path
;socket =
@@ -77,6 +86,11 @@
# `0` means there is no timeout for reading the request.
;read_timeout = 0
# This setting enables you to specify additional headers that the server adds to HTTP(S) responses.
[server.custom_response_headers]
#exampleHeader1 = exampleValue1
#exampleHeader2 = exampleValue2
#################################### Database ####################################
[database]
# You can configure the database connection by specifying type, host, name, user and password
@@ -94,7 +108,8 @@
# Example: mysql://user:secret@host:port/database
;url =
# For "postgres" only, either "disable", "require" or "verify-full"
# For "postgres", use either "disable", "require" or "verify-full"
# For "mysql", use either "true", "false", or "skip-verify".
;ssl_mode = disable
# Database drivers may support different transaction isolation levels.
@@ -126,9 +141,18 @@
# For "sqlite3" only. cache mode setting used for connecting to the database. (private, shared)
;cache_mode = private
# For "sqlite3" only. Enable/disable Write-Ahead Logging, https://sqlite.org/wal.html. Default is false.
;wal = false
# For "mysql" only if migrationLocking feature toggle is set. How many seconds to wait before failing to lock the database for the migrations, default is 0.
;locking_attempt_timeout_sec = 0
# For "sqlite" only. How many times to retry query in case of database is locked failures. Default is 0 (disabled).
;query_retries = 0
# For "sqlite" only. How many times to retry transaction in case of database is locked failures. Default is 5.
;transaction_retries = 5
################################### Data sources #########################
[datasources]
# Upper limit of data sources that Grafana will return. This limit is a temporary configuration and it will be deprecated when pagination will be introduced on the list data sources API.
@@ -145,6 +169,12 @@
# memcache: 127.0.0.1:11211
;connstr =
# prefix prepended to all the keys in the remote cache
; prefix =
# This enables encryption of values stored in the remote cache
;encryption =
#################################### Data proxy ###########################
[dataproxy]
@@ -218,6 +248,12 @@
# Google Analytics universal tracking code, only enabled if you specify an id here
;google_analytics_ua_id =
# Google Analytics 4 tracking code, only enabled if you specify an id here
;google_analytics_4_id =
# When Google Analytics 4 Enhanced event measurement is enabled, we will try to avoid sending duplicate events and let Google Analytics 4 detect navigation changes, etc.
;google_analytics_4_send_manual_page_views = false
# Google Tag Manager ID, only enabled if you specify an id here
;google_tag_manager_id =
@@ -233,6 +269,9 @@
# Rudderstack Config url, optional, used by Rudderstack SDK to fetch source config
;rudderstack_config_url =
# Intercom secret, optional, used to hash user_id before passing to Intercom via Rudderstack
;intercom_secret =
# Controls if the UI contains any links to user feedback forms
;feedback_links_enabled = true
@@ -247,6 +286,9 @@
# default admin password, can be changed before first start of grafana, or in profile settings
;admin_password = admin
# default admin email, created on startup
;admin_email = admin@localhost
# used for signing
;secret_key = SW2YcwTIb9zpOOhoPsMm
@@ -305,6 +347,14 @@
# $ROOT_PATH is server.root_url without the protocol.
;content_security_policy_template = """script-src 'self' 'unsafe-eval' 'unsafe-inline' 'strict-dynamic' $NONCE;object-src 'none';font-src 'self';style-src 'self' 'unsafe-inline' blob:;img-src * data:;base-uri 'self';connect-src 'self' grafana.com ws://$ROOT_PATH wss://$ROOT_PATH;manifest-src 'self';media-src 'none';form-action 'self';"""
# Enable adding the Content-Security-Policy-Report-Only header to your requests.
# Allows you to monitor the effects of a policy without enforcing it.
;content_security_policy_report_only = false
# Set Content Security Policy Report Only template used when adding the Content-Security-Policy-Report-Only header to your requests.
# $NONCE in the template includes a random nonce.
# $ROOT_PATH is server.root_url without the protocol.
;content_security_policy_report_only_template = """script-src 'self' 'unsafe-eval' 'unsafe-inline' 'strict-dynamic' $NONCE;object-src 'none';font-src 'self';style-src 'self' 'unsafe-inline' blob:;img-src * data:;base-uri 'self';connect-src 'self' grafana.com ws://$ROOT_PATH wss://$ROOT_PATH;manifest-src 'self';media-src 'none';form-action 'self';"""
# Controls if old angular plugins are supported or not. This will be disabled by default in future release
;angular_support_enabled = true
@@ -325,6 +375,9 @@
#################################### Snapshots ###########################
[snapshots]
# set to false to remove snapshot functionality
;enabled = true
# snapshot sharing options
;external_enabled = true
;external_snapshot_url = https://snapshots.raintank.io
@@ -363,7 +416,7 @@
# Set this value to automatically add new users to the provided organization (if auto_assign_org above is set to true)
;auto_assign_org_id = 1
# Default role new users will be automatically assigned (if disabled above is set to true)
# Default role new users will be automatically assigned (if auto_assign_org above is set to true)
;auto_assign_org_role = Viewer
# Require email validation before sign up completes
@@ -376,8 +429,8 @@
# Default UI theme ("dark" or "light")
;default_theme = dark
# Default locale (supported IETF language tag, such as en-US)
;default_locale = en-US
# Default UI language (supported IETF language tag, such as en-US)
;default_language = en-US
# Path to a custom home page. Users are only redirected to this if the default home dashboard is used. It should match a frontend route and contain a leading slash.
;home_page =
@@ -399,10 +452,18 @@
# Enter a comma-separated list of users login to hide them in the Grafana UI. These users are shown to Grafana admins and themselves.
; hidden_users =
[service_accounts]
# Service account maximum expiration date in days.
# When set, Grafana will not allow the creation of tokens with expiry greater than this setting.
; token_expiration_day_limit =
[auth]
# Login cookie name
;login_cookie_name = grafana_session
# Disable usage of Grafana build-in login solution.
;disable_login = false
# The maximum lifetime (duration) an authenticated user can be inactive before being required to login at next visit. Default is 7 days (7d). This setting should be expressed as a duration, e.g. 5m (minutes), 6h (hours), 10d (days), 2w (weeks), 1M (month). The lifetime resets at each successful token rotation.
;login_maximum_inactive_lifetime_duration =
@@ -423,6 +484,7 @@
# Set to true to attempt login with OAuth automatically, skipping the login screen.
# This setting is ignored if multiple OAuth providers are configured.
# Deprecated, use auto_login option for specific provider instead.
;oauth_auto_login = false
# OAuth state max age cookie duration in seconds. Defaults to 600 seconds.
@@ -443,6 +505,12 @@
# Set to true to enable Azure authentication option for HTTP-based datasources.
;azure_auth_enabled = false
# Set to skip the organization role from JWT login and use system's role assignment instead.
; skip_org_role_sync = false
# Use email lookup in addition to the unique ID provided by the IdP
;oauth_allow_insecure_email_lookup = false
#################################### Anonymous Auth ######################
[auth.anonymous]
# enable anonymous access
@@ -461,6 +529,7 @@
[auth.github]
;enabled = false
;allow_sign_up = true
;auto_login = false
;client_id = some_id
;client_secret = some_secret
;scopes = user:email,read:org
@@ -473,11 +542,13 @@
;role_attribute_path =
;role_attribute_strict = false
;allow_assign_grafana_admin = false
;skip_org_role_sync = false
#################################### GitLab Auth #########################
[auth.gitlab]
;enabled = false
;allow_sign_up = true
;auto_login = false
;client_id = some_id
;client_secret = some_secret
;scopes = api
@@ -489,11 +560,13 @@
;role_attribute_path =
;role_attribute_strict = false
;allow_assign_grafana_admin = false
;skip_org_role_sync = false
#################################### Google Auth ##########################
[auth.google]
;enabled = false
;allow_sign_up = true
;auto_login = false
;client_id = some_client_id
;client_secret = some_client_secret
;scopes = https://www.googleapis.com/auth/userinfo.profile https://www.googleapis.com/auth/userinfo.email
@@ -502,21 +575,25 @@
;api_url = https://www.googleapis.com/oauth2/v1/userinfo
;allowed_domains =
;hosted_domain =
;skip_org_role_sync = false
#################################### Grafana.com Auth ####################
[auth.grafana_com]
;enabled = false
;allow_sign_up = true
;auto_login = false
;client_id = some_id
;client_secret = some_secret
;scopes = user:email
;allowed_organizations =
;skip_org_role_sync = false
#################################### Azure AD OAuth #######################
[auth.azuread]
;name = Azure AD
;enabled = false
;allow_sign_up = true
;auto_login = false
;client_id = some_client_id
;client_secret = some_client_secret
;scopes = openid email profile
@@ -526,12 +603,15 @@
;allowed_groups =
;role_attribute_strict = false
;allow_assign_grafana_admin = false
# prevent synchronizing users organization roles
;skip_org_role_sync = false
#################################### Okta OAuth #######################
[auth.okta]
;name = Okta
;enabled = false
;allow_sign_up = true
;auto_login = false
;client_id = some_id
;client_secret = some_secret
;scopes = openid profile email groups
@@ -543,12 +623,14 @@
;role_attribute_path =
;role_attribute_strict = false
;allow_assign_grafana_admin = false
;skip_org_role_sync = false
#################################### Generic OAuth ##########################
[auth.generic_oauth]
;enabled = false
;name = OAuth
;allow_sign_up = true
;auto_login = false
;client_id = some_id
;client_secret = some_secret
;scopes = user:email,read:org
@@ -604,16 +686,21 @@
;jwk_set_url = https://foo.bar/.well-known/jwks.json
;jwk_set_file = /path/to/jwks.json
;cache_ttl = 60m
;expected_claims = {"aud": ["foo", "bar"]}
;expect_claims = {"aud": ["foo", "bar"]}
;key_file = /path/to/key/file
;role_attribute_path =
;role_attribute_strict = false
;auto_sign_up = false
;url_login = false
;allow_assign_grafana_admin = false
#################################### Auth LDAP ##########################
[auth.ldap]
;enabled = false
;config_file = /etc/grafana/ldap.toml
;allow_sign_up = true
# prevent synchronizing ldap users organization roles
;skip_org_role_sync = false
# LDAP background sync (Enterprise only)
# At 1 am every day
@@ -649,6 +736,11 @@
#################################### Role-based Access Control ###########
[rbac]
;permission_cache = true
# Reset basic roles permissions on boot
# Warning left to true, basic roles permissions will be reset on every boot
#reset_basic_roles = false
#################################### SMTP / Emailing ##########################
[smtp]
;enabled = false
@@ -905,6 +997,10 @@
# Configures the batch size for the annotation clean-up job. This setting is used for dashboard, API, and alert annotations.
;cleanupjob_batchsize = 100
# Enforces the maximum allowed length of the tags for any newly introduced annotations. It can be between 500 and 4096 inclusive (which is the respective's column length). Default value is 500.
# Setting it to a higher value would impact performance therefore is not recommended.
;tags_length = 500
[annotations.dashboard]
# Dashboard annotations means that annotations are associated with the dashboard they are created on.
@@ -976,6 +1072,7 @@
# Url used to import dashboards directly from Grafana.com
[grafana_com]
;url = https://grafana.com
;api_url = https://grafana.com/api
#################################### Distributed tracing ############
# Opentracing is deprecated use opentelemetry instead
@@ -1002,6 +1099,10 @@
# Not disabling is the most common setting when using Zipkin elsewhere in your infrastructure.
;disable_shared_zipkin_spans = false
[tracing.opentelemetry]
# attributes that will always be included in when creating new spans. ex (key1:value1,key2:value2)
;custom_attributes = key1:value1,key2:value2
[tracing.opentelemetry.jaeger]
# jaeger destination (ex http://localhost:14268/api/traces)
; address = http://localhost:14268/api/traces
@@ -1045,6 +1146,7 @@
;account_name =
;account_key =
;container_name =
;sas_token_expiration_days =
[external_image_storage.local]
# does not require any configuration
@@ -1060,6 +1162,11 @@
# Concurrent render request limit affects when the /render HTTP endpoint is used. Rendering many images at the same time can overload the server,
# which this setting can help protect against by only allowing a certain amount of concurrent requests.
;concurrent_render_request_limit = 30
# Determines the lifetime of the render key used by the image renderer to access and render Grafana.
# This setting should be expressed as a duration. Examples: 10s (seconds), 5m (minutes), 2h (hours).
# Default is 5m. This should be more than enough for most deployments.
# Change the value only if image rendering is failing and you see `Failed to get the render key from cache` in Grafana logs.
;render_key_lifetime = 5m
[panels]
# If set to true Grafana will allow script tags in text panels. Not recommended as it enable XSS vulnerabilities.
@@ -1211,3 +1318,24 @@
# Enable or disable loading other base map layers
;enable_custom_baselayers = true
# Move an app plugin referenced by its id (including all its pages) to a specific navigation section
# Dependencies: needs the `topnav` feature to be enabled
[navigation.app_sections]
# The following will move an app plugin with the id of `my-app-id` under the `starred` section
# my-app-id = admin
# Move a specific app plugin page (referenced by its `path` field) to a specific navigation section
[navigation.app_standalone_pages]
# The following will move the page with the path "/a/my-app-id/starred-content" from `my-app-id` to the `starred` section
# /a/my-app-id/starred-content = starred
#################################### Secure Socks5 Datasource Proxy #####################################
[secure_socks_datasource_proxy]
; enabled = false
; root_ca_cert =
; client_key =
; client_cert =
; server_name =
# The address of the socks5 proxy datasources should connect to
; proxy_address =

View File

@@ -10,8 +10,7 @@ This directory contains guides for contributors to the Grafana project.
The `style-guides` directory contains style guides for the Grafana software project and documentation.
- [Backend style guide](style-guides/backend.md) for how to style and format backend functionality and code.
- [Documentation style guide](style-guides/documentation-style-guide.md) for how to style and format documentation.
- [Backend style guide](backend/style-guide.md) for how to style and format backend functionality and code.
- [Frontend style guide](style-guides/frontend.md) for how to style and format the user-facing functionality and code.
- [Redux framework](style-guides/redux.md) for designing the Grafana redux framework.
- [Themes style guide](style-guides/themes.md) for designing and updating Grafana themes.

View File

@@ -4,9 +4,9 @@ Are you looking to take on contributions with bigger impact? These guides help y
Learn more about the backend architecture:
- Part 1: [Services](backend/services.md)
- Part 2: [Communication](backend/communication.md)
- Part 3: [Database](backend/database.md)
- Part 1: [Services](../backend/services.md)
- Part 2: [Communication](../backend/communication.md)
- Part 3: [Database](../backend/database.md)
Learn more about the frontend architecture:

View File

@@ -1,81 +0,0 @@
# Errors
Grafana introduced its own error type `github.com/grafana/grafana/pkg/util/errutil.Error`
in June 2022. It's built on top of the Go `error` interface extended to
contain all the information necessary by Grafana to handle errors in an
informative and safe way.
Previously, Grafana has passed around regular Go errors and have had to
rely on bespoke solutions in API handlers to communicate informative
messages to the end-user. With the new `errutil.Error`, the API handlers
can be slimmed as information about public messaging, structured data
related to the error, localization metadata, log level, HTTP status
code, and so forth are carried by the error.
## Basic use
### Declaring errors
For a service, declare the different categories of errors that may occur
from your service (this corresponds to what you might want to have
specific public error messages or their templates for) by globally
constructing variables using the `errutil.NewBase(status, messageID, opts...)`
function.
The status code loosely corresponds to HTTP status codes and provides a
default log level for errors to ensure that the request logging is
properly informing administrators about various errors occurring in
Grafana (e.g. `StatusBadRequest` is generally speaking not as relevant
as `StatusInternal`). All available status codes live in the `errutil`
package and have names starting with `Status`.
The messageID is constructed as `<servicename>.<error-identifier>` where
the `<servicename>` corresponds to the root service directory per
[the package hierarchy](package-hierarchy.md) and `<error-identifier>`
is a short identifier using dashes for word separation that identifies
the specific category of errors within the service.
To set a static message sent to the client when the error occurs, the
`errutil.WithPublicMessage(message string)` option may be appended to
the NewBase function call. For dynamic messages or more options, refer
to the `errutil` package's GoDocs.
Errors are then constructed using the `Base.Errorf` method, which
functions like the [fmt.Errorf](https://pkg.go.dev/fmt#Errorf) method
except that it creates an `errutil.Error`.
```go
package main
import (
"errors"
"github.com/grafana/grafana/pkg/util/errutil"
"example.org/thing"
)
var ErrBaseNotFound = errutil.NewBase(errutil.StatusNotFound, "main.not-found", errutil.WithPublicMessage("Thing not found"))
func Look(id int) (*Thing, error) {
t, err := thing.GetByID(id)
if errors.Is(err, thing.ErrNotFound) {
return nil, ErrBaseNotFound.Errorf("did not find thing with ID %d: %w", id, err)
}
return t, nil
}
```
Check out [errutil's GoDocs](https://pkg.go.dev/github.com/grafana/grafana@v0.0.0-20220621133844-0f4fc1290421/pkg/util/errutil)
for details on how to construct and use Grafana style errors.
### Handling errors in the API
API handlers use the `github.com/grafana/grafana/pkg/api/response.Err`
function to create responses based on `errutil.Error`s.
> **Note:** (@sakjur 2022-06) `response.Err` requires all errors to be
> `errutil.Error` or it'll be considered an internal server error.
> This is something that should be fixed in the near future to allow
> fallback behavior to make it possible to correctly handle Grafana
> style errors if they're present but allow fallback to a reasonable
> default otherwise.

View File

@@ -1,6 +1,6 @@
# Data requests
[BackendSrv](https://grafana.com/docs/grafana/latest/packages_api/runtime/backendsrv) handles all outgoing HTTP requests from Grafana. This document explains the high-level concepts used by `BackendSrv`.
[BackendSrv](https://github.com/grafana/grafana/blob/main/packages/grafana-runtime/src/services/backendSrv.ts) handles all outgoing HTTP requests from Grafana. This document explains the high-level concepts used by `BackendSrv`.
## Canceling requests
@@ -14,7 +14,7 @@ Grafana uses a concept called _request cancellation_ to cancel any ongoing reque
#### Before Grafana 7.2
Before Grafana can cancel any data request, it has to identify that request. Grafana identifies a request using the property `requestId` [passed as options](https://github.com/grafana/grafana/blob/main/docs/sources/packages_api/runtime/backendsrvrequest.md) when you use [BackendSrv](https://grafana.com/docs/grafana/latest/packages_api/runtime/backendsrv).
Before Grafana can cancel any data request, it has to identify that request. Grafana identifies a request using the property `requestId` [passed as options](https://github.com/grafana/grafana/blob/main/packages/grafana-runtime/src/services/backendSrv.ts#L47) when you use [BackendSrv](https://github.com/grafana/grafana/blob/main/packages/grafana-runtime/src/services/backendSrv.ts).
The cancellation logic is as follows:
@@ -23,7 +23,7 @@ The cancellation logic is as follows:
#### After Grafana 7.2
Grafana 7.2 introduced an additional way of canceling requests using [RxJs](https://github.com/ReactiveX/rxjs). To support the new cancellation functionality, the data source needs to use the new `fetch` function in [BackendSrv](https://grafana.com/docs/grafana/latest/packages_api/runtime/backendsrv).
Grafana 7.2 introduced an additional way of canceling requests using [RxJs](https://github.com/ReactiveX/rxjs). To support the new cancellation functionality, the data source needs to use the new `fetch` function in [BackendSrv](https://github.com/grafana/grafana/blob/main/packages/grafana-runtime/src/services/backendSrv.ts).
Migrating the core data sources to the new `fetch` function [is an ongoing process that you can read about in this issue.](https://github.com/grafana/grafana/issues/27222)

View File

@@ -0,0 +1,98 @@
# Backend
This document gives an overview of the directory structure, and ongoing refactorings.
For more information on developing for the backend:
- [Backend style guide](/contribute/backend/style-guide.md)
- [Architecture](/contribute/architecture)
## Central folders of Grafana's backend
| folder | description |
| --------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| /pkg/api | HTTP handlers and routing. Almost all handler funcs are global which is something we would like to improve in the future. Handlers should be associated with a struct that refers to all dependencies. |
| /pkg/cmd | The binaries that we build: grafana-server and grafana-cli. |
| /pkg/components | A mix of third-party packages and packages we have implemented ourselves. Includes our packages that have out-grown the util package and don't naturally belong somewhere else. |
| /pkg/infra | Packages in infra should be packages that are used in multiple places in Grafana without knowing anything about the Grafana domain. |
| /pkg/services | Packages in services are responsible for persisting domain objects and manage the relationship between domain objects. Services should communicate with each other using DI when possible. Most of Grafana's codebase still relies on global state for this. Any new features going forward should use DI. |
| /pkg/tsdb | All backend implementations of the data sources in Grafana. Used by both Grafana's frontend and alerting. |
| /pkg/util | Small helper functions that are used in multiple parts of the codebase. Many functions are placed directly in the util folders which is something we want to avoid. Its better to give the util function a more descriptive package name. Ex `errutil`. |
## Central components of Grafana's backend
| package | description |
| ---------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| /pkg/bus | The bus is described in more details under [Communication](/contribute/backend/communication.md) |
| /pkg/models | This is where we keep our domain model. This package should not depend on any package outside standard library. It does contain some references within Grafana but that is something we should avoid going forward. |
| /pkg/registry | Package for managing services. |
| /pkg/services/alerting | Grafana's alerting services. The alerting engine runs in a separate goroutine and shouldn't depend on anything else within Grafana. |
| /pkg/services/sqlstore | Currently where the database logic resides. |
| /pkg/setting | Anything related to Grafana global configuration should be dealt with in this package. |
## Dependency management
Refer to [UPGRADING_DEPENDENCIES.md](https://github.com/grafana/grafana/blob/main/UPGRADING_DEPENDENCIES.md).
## Ongoing refactoring
These issues are not something we want to address all at once but something we will improve incrementally. Since Grafana is released at a regular schedule the preferred approach is to do this in batches. Not only is it easier to review, but it also reduces the risk of conflicts when cherry-picking fixes from main to release branches. Please try to submit changes that span multiple locations at the end of the release cycle. We prefer to wait until the end because we make fewer patch releases at the end of the release cycle, so there are fewer opportunities for complications.
### Global state
Global state makes testing and debugging software harder and it's something we want to avoid when possible. Unfortunately, there is quite a lot of global state in Grafana.
We want to migrate away from this by using the `inject` package to wire up all dependencies either in `pkg/cmd/grafana-server/main.go` or self-registering using `registry.RegisterService` ex https://github.com/grafana/grafana/blob/main/pkg/services/cleanup/cleanup.go#L25.
### Limit the use of the init() function
Only use the init() function to register services/implementations.
### Settings refactoring
The plan is to move all settings to from package level vars in settings package to the [setting.Cfg](https://github.com/grafana/grafana/blob/df917663e6f358a076ed3daa9b199412e95c11f4/pkg/setting/setting.go#L210) struct. To access the settings, services and components can inject this setting.Cfg struct:
[Cfg struct](https://github.com/grafana/grafana/blob/df917663e6f358a076ed3daa9b199412e95c11f4/pkg/setting/setting.go#L210)
[Injection example](https://github.com/grafana/grafana/blob/df917663e6f358a076ed3daa9b199412e95c11f4/pkg/services/cleanup/cleanup.go#L20)
### Reduce the use of GoConvey
We want to migrate away from using GoConvey. Instead, we want to use stdlib testing, because it's the most common approach in the Go community and we think it will be easier for new contributors. Read more about how we want to write tests in the [style guide](/contribute/backend/style-guide.md).
### Refactor SqlStore
The `sqlstore` handlers all use a global xorm engine variable. Refactor them to use the `SqlStore` instance.
### Avoid global HTTP handler functions
Refactor HTTP handlers so that the handler methods are on the HttpServer instance or a more detailed handler struct. E.g (AuthHandler). This ensures they get access to HttpServer service dependencies (and Cfg object) and can avoid global state.
### Date comparison
Store newly introduced date columns in the database as epochs if they require date comparison. This permits a unified approach for comparing dates against all the supported databases instead of handling dates differently for each database. Also, by comparing epochs, we no longer need error pruning transformations to and from other time zones.
### Avoid use of the simplejson package
Use of the `simplejson` package (`pkg/components/simplejson`) in place of types (Go structs) results in code that is difficult to maintain. Instead, create types for objects and use the Go standard library's [`encoding/json`](https://golang.org/pkg/encoding/json/) package.
### Provisionable\*
All new features that require state should be possible to configure using config files. For example:
- [Data sources](https://github.com/grafana/grafana/tree/main/pkg/services/provisioning/datasources)
- [Alert notifiers](https://github.com/grafana/grafana/tree/main/pkg/services/provisioning/notifiers)
- [Dashboards](https://github.com/grafana/grafana/tree/main/pkg/services/provisioning/dashboards)
Today its only possible to provision data sources and dashboards but this is something we want to support all over Grafana.
### Use context.Context "everywhere"
The package [context](https://golang.org/pkg/context/) should be used and propagated through all the layers of the code. For example the `context.Context` of an incoming API request should be propagated to any other layers being used such as the bus, service and database layers. Utility functions/methods normally doesn't need `context.Context` To follow best practices, any function/method that receives a context.Context argument should receive it as its first argument.
To be able to solve certain problems and/or implement and support certain features making sure that `context.Context` is passed down through all layers of the code is vital. Being able to provide contextual information for the full life-cycle of an API request allows us to use contextual logging, provide contextual information about the authenticated user, create multiple spans for a distributed trace of service calls and database queries etc.
Code should use `context.TODO` when it's unclear which Context to use or it is not yet available (because the surrounding function has not yet been extended to accept a `context.Context` argument).
More details in [Services](/contribute/backend/services.md), [Communication](/contribute/backend/communication.md) and [Database](/contribute/backend/database.md).
[Original design doc](https://docs.google.com/document/d/1ebUhUVXU8FlShezsN-C64T0dOoo-DaC9_r-c8gB2XEU/edit#).

Some files were not shown because too many files have changed in this diff Show More