Commit Graph

8961 Commits

Author SHA1 Message Date
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
Levente Balogh
ae5e8bc53b
refactor: rename Data Connections to Connections (#56353) 2022-10-05 09:56:58 +02: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
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
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
Ryan McKinley
d5e2713168
Storage: Add HTTP endpoint for object store service (#56214) 2022-10-04 09:40:15 -07:00
Ryan McKinley
3b1a8d45ed
Playlist: update service so it supports both read+write (#55959) 2022-10-04 11:11:18 -04:00
Dimitris Sotirakis
d94af21cac
Replace filename with path without the local dir (#56296) 2022-10-04 17:18:07 +03:00
Todd Treece
152c7f149a
Prometheus: Add Exemplar sampling for streaming parser (#56049) 2022-10-04 08:40:01 -04: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
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
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
Dimitris Sotirakis
26d64a778e
Add cronjob option at switch case (#56272) 2022-10-04 11:15:47 +01: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
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
Will Browne
4087ad413f
re-use fake trace + feature toggles (#56186) 2022-10-04 10:15:10 +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
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
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
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
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
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
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
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
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
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
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
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
sam boyer
59a3e18bb2
Fix prefix dropper in Go codegen (#56041) 2022-09-29 12:01:02 -04:00
Sofia Papagiannaki
6099e55e62
SQLStore: Remove call to deleted store.NewSession() (#56025) 2022-09-29 10:17:33 -04: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
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
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
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