52 Commits

Author SHA1 Message Date
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
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
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
b2f80d4dca Dashboards: Add Dashboard API Validation tests and fix underlying issues (#103502) 2025-04-07 05:44:28 +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
7c2890384a K8s: Dashboards: Set v1alpha1 as priority (#102729) 2025-03-25 10:32:49 -06:00
da95ee22cc K8s: Fix dashboard creation timestamp (#102578) 2025-03-21 07:47:09 +02:00
bb881f38bb K8s/Dashboards: Remove uid+version from spec (#101992) 2025-03-16 20:46:12 -05:00
5c24312625 Dashboards: Fix duplicate provisioning when errors occur on title-only based provisioning (#102249)
Dashboards: fix title based provisioning
2025-03-15 21:12:48 -06:00
5d2ba10113 K8s/Dashboards: Extract Dashboard APIs to an app submodule (#102029)
* Move dashboard k8s APIs to a separate app

Signed-off-by: Igor Suleymanov <igor.suleymanov@grafana.com>

* Copy dashboard code in Dockerfile

Signed-off-by: Igor Suleymanov <igor.suleymanov@grafana.com>

* Fix conversion generation

Signed-off-by: Igor Suleymanov <igor.suleymanov@grafana.com>

* Update OpenAPI snapshot for dashboard/v0alpha1

Signed-off-by: Igor Suleymanov <igor.suleymanov@grafana.com>

---------

Signed-off-by: Igor Suleymanov <igor.suleymanov@grafana.com>
2025-03-13 11:05:01 +02:00
dc2defd84f K8s/Annotations: Use manager/source annotations rather than repo (#101313)
Co-authored-by: Stephanie Hingtgen <stephanie.hingtgen@grafana.com>
2025-03-05 08:54:20 +02:00
c1b48cc488 Dashboards: Add apiVersion to dashboard table (#100845) 2025-03-04 07:47:45 +03:00
67be9aeed6 K8s: Search fallback: Support all sort by methods (#100776) 2025-02-18 12:30:11 -06:00
e2081c3e0c K8s: Fix legacy fallback provisioning (#100566) 2025-02-13 21:32:25 +02:00
b06f83670e Cleanup: comment out unreachable code (#99723) 2025-01-29 07:00:49 +03:00
5cd1efb2d1 K8s/Dashboard: Improve legacy error handling (#99658) 2025-01-28 18:47:02 -06:00
0cef2b9ae7 Dashboard Versions: Make compatible with app platform (#99327) 2025-01-28 08:17:52 -06:00
be8396cafa Setup legacy search based on mode (#98908) 2025-01-27 12:32:07 -06:00
3bc9f10bb3 Dashboards/SQL: Improve SQL query behavior (#99253)
* update legacy dashboard SQL

* merge main

* trim message
2025-01-21 19:35:33 +03:00
d8b6ded101 K8s: use deprecatedInternalID label rather than SQL annotation (#99263) 2025-01-21 12:38:14 +03:00
680e6bc1f8 Authlib: Use types package rather than claims (#99243) 2025-01-21 12:06:55 +03:00
356b32008b Storage: Show history+trash using the list command (#99009)
Co-authored-by: Stephanie Hingtgen <stephanie.hingtgen@grafana.com>
2025-01-17 15:54:25 +03:00
7c04247d6f K8s/Dashboard: Set generation from version (#99142) 2025-01-17 13:52:01 +02:00
9ec10be1c7 K8s: Provisioned dashboard support (#98843) 2025-01-13 08:14:12 -06:00
b4ab55ae38 K8s: Dashboard spec should not have id (#98336) 2025-01-03 09:28:45 -06:00
1a46039037 K8s/Dashboards: Pass the legacy internal ID into labels (#98311)
---------

Co-authored-by: Stephanie Hingtgen <stephanie.hingtgen@grafana.com>
Co-authored-by: Todd Treece <360020+toddtreece@users.noreply.github.com>
2024-12-20 21:33:49 +02:00
ea17b79c09 Search: Return counts for values within an folder/repository (#97534) 2024-12-10 20:37:37 +02:00
8165258a2d Storage: Query stats within a namespace (#97403) 2024-12-05 13:58:13 +03:00
9d89d8757f Search: Build index from resource stats (#97320) 2024-12-03 20:20:27 +03:00
3a17d0c927 IAM: align AuthInfo interface (#97228)
* Update to use updated interface
2024-12-03 15:11:17 +01:00
3990637af9 IAM: remove duplicated functions (#96989)
* Remove duplicated function and use the one provided by claims package
2024-11-26 09:22:45 +01:00
66d5c051aa Dashboards: Add v1alpha1 and v2alpha1 conversion (#96415)
---------

Co-authored-by: Stephanie Hingtgen <stephanie.hingtgen@grafana.com>
2024-11-15 15:49:45 -05:00
cc6d057a18 Provisioning: Rename k8s origin metadata to repo (#96524) 2024-11-15 17:26:14 +03:00
c3571752b6 Unitstore: Fix the Folder migration (#96078)
* UniStore: Add folder to the SQL backend

This reverts commit aaa4f4a23e3ba0e02526f8beb05321761382259f.

* fix folder migration
2024-11-12 12:52:04 +01:00
b6596db75e Unified Storage Indexer: Build tenant indexes concurrently (#95795)
* WIP - build tenant indexes concurrently

* adds local dev seeders and readme for indexer

* update logging and adds locking in getShard()

* update logs

* Adds Namespaces func. Initializes index after ResourceServer is created.

* fixes Count() and updates test lint issues

* Initialize index separately. Don't do it when creating the resource server. Makes testing really awkward.

* fix lint error

* handles error when getting namespaces

* updates test and index helper funcs
2024-11-06 12:58:07 -06:00
aaa4f4a23e Revert "UniStore: Add folder to the SQL backend" (#95966)
Revert "UniStore: Add folder to the SQL backend (#95671)"

This reverts commit f0756626969f1a2d345874f92463b275c721ab79.
2024-11-06 17:04:57 +02:00
f075662696 UniStore: Add folder to the SQL backend (#95671)
* Add folder to the SQL backend

* remove unused key

* fix tests

* Return folders from watch
2024-11-05 10:37:23 +01:00
a8b07b0c81 [authn] use authlib client+interceptors for in-proc mode (#93124)
* Add authlib gRPC authenticators for in-proc mode

* implement `StaticRequester` signing in the unified resource client
- [x] when the `claims.AuthInfo` value type is `identity.StaticRequester`, and there's no ID token set, create an internal token and sign it with symmetrical key. This is a workaround for `go-jose` not offering the possibility to create an unsigned token.
- [x] update `IDClaimsWrapper` to support the scenario above
- [x] Switch to using `claims.From()` in `dashboardSqlAccess.SaveDashboard()`

---------

Co-authored-by: gamab <gabriel.mabille@grafana.com>
2024-09-24 09:03:48 +03:00
419edef4dc LibraryPanels: Expose library panels in dashboard apiserver (#92213) 2024-08-27 12:12:22 +03:00
9567275365 SQL: Add more legacy helpers (#92006) 2024-08-19 12:15:43 +03:00
f432a1713b SQLTemplate: Swap the IFace with the concrete struct (#92008) 2024-08-16 15:12:37 +03:00
d9cabe5e14 SQL: Add sql template test helper (#91953) 2024-08-16 14:36:56 +03:00
a0cd89860e Identity: Add endpoint to get display info for an identifier (#91828) 2024-08-15 14:38:43 +03:00
8bcd9c2594 Identity: Remove typed id (#91801)
* Refactor identity struct to store type in separate field

* Update ResolveIdentity to take string representation of typedID

* Add IsIdentityType to requester interface

* Use IsIdentityType from interface

* Remove usage of TypedID

* Remote typedID struct

* fix GetInternalID
2024-08-13 10:18:28 +02:00
21d4a4f49e Auth: use IdentityType from authlib (#91763) 2024-08-12 09:26:53 +03:00
9e116d13a5 K8s/Dashboards: Fix dashboard list and add tests (#91523) 2024-08-07 13:43:13 +03:00
f804b0baa3 Storage: Return an iterator from backend List (#91185) 2024-07-31 12:05:59 +03:00
be7b1ce2df Chore: Replace appcontext.User(ctx) with identity.GetRequester(ctx) (#91030) 2024-07-26 16:39:23 +03:00