Add purchased storage available breakdown card
What does this MR do and why?
This implements the card on the right-hand-side of the design in https://gitlab.com/gitlab-org/gitlab/-/issues/419922
| MR description | MR Link |
|---|---|
| Update storage statistics card for namespaces under project limits | !127746 (merged) |
Move total-storage-available-breakdown-card to its own component |
!128897 (merged) |
| Add purchased storage available breakdown card for namespaces under project limits |
|
Screenshots or screen recordings
This is the comparison between the state in !127746 (merged) and here:
| Before | After |
|---|---|
![]() |
![]() |
These screenshots below would follow how the user progress in their storage usage:
- All their projects are under the free tier limit
- One of their projects is over the free tier limit
- They've purchased additional storage and namespace is now under purchased limit (Although almost over the purchased limit)
- They're over the purchased limit and the project is
read-onlyagain
How to set up and validate locally
Go to rails console:
- Grab a group:
g = Group.find(<group id>) - Add some storage to the group's project:
g.projects.first.statistics.update(repository_size: 10*1024*1024*1024) - Play around with the purchased storage:
g.update(additional_purchased_storage_size: 5*1024) - Clean redis queue:
Sidekiq.redis(&:flushdb) - Perform the these job:
Namespaces::ScheduleAggregationWorker.perform_sync(g.id)Namespaces::RootStatisticsWorker.perform_sync(g.id)
- Check the UI (in the browswer
😅 ):https://gdk.test:3443/groups/<your group here>/-/usage_quotas#storage-quota-tab
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Edited by Sheldon Led





