RaythaHQ / raytha

Raytha is a powerful CMS with an easy-to-use interface and fast performance. It offers custom content types, a template engine, and various access controls. It supports multiple storage providers and an automatically generated REST API. Upgrade your development workflow with Raytha.
MIT License
155 stars 30 forks source link

Show database storage usage on dashboard #75

Closed apexdodge closed 1 year ago

apexdodge commented 1 year ago

We need another block on the dashboard for Database storage usage.

image

The block should show:

The storage allotted can be pulled from appsettings.json.

image

The GetDashboardMetrics.Query needs the code for querying the database for its size.

https://github.com/RaythaHQ/raytha/blob/main/src/Raytha.Application/Dashboard/Queries/GetDashboardMetrics.cs

I believe we can make a query with Dappr.

EXEC sp_spaceused @oneresultset = 1

Result:

image

apexdodge commented 1 year ago

image

To be released with v1.0.6