Use dashboard limit on storage alerts
What does this MR do and why?
This implements https://gitlab.com/gitlab-org/gitlab/-/issues/431395
This MR is dependent on !138331 (merged)
Screenshots or screen recordings
Before | After | After with purchased storage |
---|---|---|
How to set up and validate locally
Use these commands in rails console
:
Gitlab::CurrentSettings.update!(automatic_purchased_storage_allocation: true)
Gitlab::CurrentSettings.update!(enforce_namespace_storage_limit: true)
Plan.free.actual_limits.update!(notification_limit: 5*1024)
Plan.free.actual_limits.update!(enforcement_limit: 10*1024)
Plan.free.actual_limits.update!(storage_size_limit: 5*1024)
-
Project.find(29).statistics.update(repository_size: 12.gigabytes)
Sidekiq.redis(&:flushdb)
Namespaces::ScheduleAggregationWorker.perform_sync(89)
Namespaces::RootStatisticsWorker.perform_sync(89)
Feature.enable(:namespace_storage_limit_show_preenforcement_banner, Group.find(89))
Feature.enable(:namespace_storage_limit, Group.find(89))
Check the number in the banner is storage_size_limit
and not enforcement_limit
.
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