197 Commits

Author SHA1 Message Date
c47fc53eee fix: set withHistory flag to true for non-interactive mode (#107263) 2025-06-26 16:08:30 +00:00
79fe8a9902 Library Panels: Modify connection api endpoint to be compatible with unified storage (#107088) 2025-06-25 22:21:56 +00:00
8a05378ef3 apiserver/folders: use exact match on GetFolderByTitle in legacy (#106867)
* apiserver/folders: use exact match on GetFolderByTitle in legacy

Signed-off-by: Maicon Costa <maiconscosta@gmail.com>


---------

Signed-off-by: Maicon Costa <maiconscosta@gmail.com>
2025-06-24 17:42:08 -03:00
ef6e28b955 K8s: Make v0alpha1 opt-in (#107056) 2025-06-20 16:37:17 -05:00
3a13c2db64 chore: add logging around migration cli (#107046) 2025-06-20 15:20:06 +00:00
945bc53b4c DualWrite: Manage values from KV store (not file) (#106772) 2025-06-18 10:37:44 +03:00
59c2f15433 Dashboard V0->V1 Migration: Schema migration v36 (#100757)
---------

Co-authored-by: Todd Treece <360020+toddtreece@users.noreply.github.com>
Co-authored-by: Haris Rozajac <haris.rozajac12@gmail.com>
Co-authored-by: Stephanie Hingtgen <stephanie.hingtgen@grafana.com>
2025-06-16 15:53:41 +02:00
feeced9618 K8s: Dashboards /apis: Fix library element connections (#106734) 2025-06-13 21:40:39 +02:00
ab99211b40 Dashboard Provisioning: Reduce db load (#106114) 2025-05-29 09:39:07 +03:00
5c0194955e Dashboards: Fix FindDashboards when kubernetesClientDashboardsFolders is disabled (#105974)
Dashboards: fix legacy FindDashboards
2025-05-24 07:06:30 -06:00
04d39cbbc6 unistore: split ListIterator and ListHistory in StorageBackend (#105654)
split listIterator from ListHistory
2025-05-23 15:00:18 +02:00
d896f31c43 Dashboards: report valid folder count (#105484) 2025-05-16 14:51:04 +03:00
002f46736a refactor(unified-storage): move generated protos to own pkg (#105356) 2025-05-15 21:36:52 +02:00
da24ad06bd Provisioning: Hide full path for classic provisioing resources (#105440) 2025-05-15 16:01:12 +00:00
9edf2f6356 Folders and Dashboards: Version check fixes (#104663)
Folders: Fix version mismatch errors
2025-04-30 03:04:30 +03:00
129e8bb1e4 Dashboards: Fix moving to general folder (#104655) 2025-04-30 03:03:57 +03:00
9968576acf Folders & Dashboards: Cleanup timestamps and error codes (#104665)
K8s: Fix timestamps and error codes
2025-04-30 03:03:21 +03:00
b5281c923f K8s: Dashboards: Fix provisioned dashboard cleanup (#104504) 2025-04-25 05:55:50 -06:00
b09d79b21c K8s/Dashboard: Promote from alpha1 to beta1 (#104009) 2025-04-23 20:54:35 +03:00
b887e8aa05 K8s: Dashboards: Add fine grained access control checks to /apis (#104347)
---------

Co-authored-by: Ieva <ieva.vasiljeva@grafana.com>
Co-authored-by: Gabriel MABILLE <gabriel.mabille@grafana.com>
Co-authored-by: Marco de Abreu <marco.deabreu@grafana.com>
Co-authored-by: Georges Chaudy <chaudyg@gmail.com>
2025-04-23 03:29:05 +01:00
fc9f32a9f6 SQLTemplates: Add helper to ensure all templates have a test-case (#103964)
* SQLTemplates: Add helper to ensure all templates have a test-case associated

* UnifiedStorage: Add missing sql template test case

* LegacyDashboards: Add sql templates fs to test cases for exhaustiveness check

* RBACStore: Add sql templates fs to test cases for exhaustiveness check

* LegacyIAM: Add missing sql template test cases
2025-04-22 11:21:51 +02:00
efd9334295 Provisioning: route provisioning storage to the provisioning client (#104082) 2025-04-18 21:47:37 +03:00
d57fa1291f Dashboards: Disallow List with RV filter on legacy & align RV format (#104003)
Throw errors when trying to call List in legacy with an RV specified
Change ResourceVersion to microseconds

Co-authored-by: Marco de Abreu <18629099+marcoabreu@users.noreply.github.com>
2025-04-15 22:08:54 +01:00
0283c98e30 K8s/Folders: Use v1beta1 and app-sdk based spec (#103975) 2025-04-14 23:20:10 +03:00
c47ab101d1 Dashboards: Add Dashboard Schema validation (2) (#103844)
* Activate schema validation and align underlying systems

* update to save as v0 if not the right schema version

* Resolve merge conflicts

* Move RequireApiErrorStatus to tests package

* Add mutation tests

* Fix lint

* Only do min version check if dashboard is v1

* Fix lint and disable provisioning test

* Revert provisioning changes

* Revert more tests and add schema test

* Reran gen

* SQL Dashboard save

* Adjust APIVERSION

* Fixed mutation test

* Add logging on downgrade

---------

Co-authored-by: Marco de Abreu <18629099+marcoabreu@users.noreply.github.com>
Co-authored-by: Stephanie Hingtgen <stephanie.hingtgen@grafana.com>
2025-04-11 23:05:41 +02:00
b39eaac69e Unistore: Keep apiVersion from the legacy SQL table (#103939)
keep apiversion
2025-04-11 22:49:45 +03:00
bba85c1128 K8s: Dashboards: Fix error handling (#103929) 2025-04-11 13:31:41 -06:00
95f04c79cd Dashboards: Add Dashboard Schema validation (1) (#103662) 2025-04-11 16:52:46 +00:00
f5ad1ef69b K8s: Folders: Add v1 api (#103842) 2025-04-11 13:09:52 +01:00
757be6365a CI: Bump golangci-lint to 2.0.2 (#103572) 2025-04-10 14:42:23 +02:00
a01d8a0871 K8s: Dashboards: Allow userID to not be set for quota check (#103745) 2025-04-09 19:53:43 +01:00
af8a70bbab K8s/Permissions: Enable a grant-permissions annotation action to set default permissions (#102527)
* create permissions

* add key

* lint

* structure as a delayed callback

* legacy API hook

* merge main

* wired up

* and folders

* watch repos

* missing return statement

* Set the correct permissions

* add TestAfterCreatePermissionCreator

* do not add perms on folder create

* fix tests

* add annotation on create

* lint

* lint

* ensure we set permissions when the FT is disabled

* remove custom folder_storage

* fix lint

* change default

* lint

* lint

* fix: annotation

* ensure permissions are added on folder legacy

* remove folderstorage again

* fix tests

* add FT

* undo change to folder

* dashboard on create

* remove annotation for folder

* fix tests

* fix prepare after rebase

* fix tests

* fix tests

* fix tests

* lint

* address comments

* add test for prepareObjectForStorage

* add again skipIfMode as per comment

---------

Co-authored-by: Georges Chaudy <chaudyg@gmail.com>
2025-04-09 13:05:37 +02:00
9ba5606c3f K8s: Dashboards V1: Run migrations in mutation hook (#103670) 2025-04-09 01:48:09 -05:00
0c79a8927b Dashboards: Add validation tests for all dual writer modes (#103570)
* Add validation tests for mode 0 and 4

* Add mode 1, 2, 3, 5

---------

Co-authored-by: Marco de Abreu <18629099+marcoabreu@users.noreply.github.com>
2025-04-08 14:37:50 +02:00
c8c55621fb Dashboards: Fix dashboard UID inconsistency between creation and retrieval in legacy storage (#103568) 2025-04-08 12:25:32 +02:00
df537d6f0f UniStore/Large Objects: Make threshold configurable (#101774)
* Make blob threshold configurable
* Test condition for deconstructing large objects
* Refactor blob threshold naming
2025-04-08 10:50:35 +02:00
b2f80d4dca Dashboards: Add Dashboard API Validation tests and fix underlying issues (#103502) 2025-04-07 05:44:28 +03:00
364247e26b Provisioning: add most mocks to unit test provisioning jobs (#103446)
* Use interface for factories

* Add most mocks to unit test jobs

* Generate more mocks for main jobs package

* Interface for parser

* Use clients directly without parser

* Regenerate mock

* Eliminate resource clients from Parser

* Interface for folder tree
2025-04-04 15:42:20 +03:00
04fb9f534e Dashboards: Only expose LibraryPanels and search on v0 (not v1+v2) (#103335) 2025-04-03 20:24:12 +03:00
4918d8720c Dashboard Restore: Remove experimental functionality under feature flag dashboardRestore for now - this will be reworked (#103204) 2025-04-03 02:52:54 -05:00
08042ae827 search: add legacy id for all resources in bleve (#103206)
* add legacy id for all resources in bleve
2025-04-02 08:20:23 -04:00
4cb756c5d1 K8s: Fix error conversion for provisioned dashboards (#103074) 2025-03-31 14:34:54 +01:00
f84654d162 Stats: Optimize getting folder stats (#103033) 2025-03-28 20:17:50 -05:00
12c5b81850 K8s: Dashboards: Reduce db calls to get users on list (#103020) 2025-03-27 22:57:49 +02:00
7c2890384a K8s: Dashboards: Set v1alpha1 as priority (#102729) 2025-03-25 10:32:49 -06:00
4d79d5e80c K8s: Fix legacy dashboard folder check (#102660) 2025-03-22 06:22:59 +03:00
08bbd7a536 fix (unified-storage): always do perm filtering in bleve by default (#102541)
* make unifiedStorageSearchPermissionFiltering default true
2025-03-21 10:06:01 -04:00
e2737f195b RBAC: Remove dashboard guardians pt 2 (#102556)
* remove NewByDashboard guardian

* remove unused authorizer

* more cleanup

* simplify canAdmin evaluation
2025-03-21 10:32:27 +00:00
2e2b5942c8 K8s/Unified: Consolidate generation logic in apistore client (#102260) 2025-03-21 10:45:25 +02:00
da95ee22cc K8s: Fix dashboard creation timestamp (#102578) 2025-03-21 07:47:09 +02:00