Skip to content

Move DependencyProxyUsage to CE

Sheldon Led requested to merge led/371824-move-dependency-proxy-usage-to-ce into master

What does this MR do and why?

This is the third of a series of MRs that aim to migrate the Namespace Storage Vue App to CE so that this view is available for all GitLab Editions and Distributions. Related to: Move storage app to CE (#371824 - closed)

Here we move DependencyProxyUsage and its tests to the CE directory.

MR Cadence

Description MR
Introduce NamespaceStorageApp in core !138689 (merged)
Create StorageUsageStatistics in CE !139111 (merged)
Move DependencyProxyUsage to CE 👈 you're here
Move ContainerRegistryUsage to CE !139252 (merged)
Move Usage Quotas test fixtures to CE !142067 (merged)
Move SearchAndSortBar to CE !139434 (merged)
Move ProjectList to CE !139449 (merged)
Finish moving NamespaceStorageApp to CE !139568 (merged)
Replace placeholder with NamespaceStorageApp !140209 (closed)

Screenshots or screen recordings

All the changes here are behind a Feature Flag: usage_quotas_for_all_editions, so there should be no UI or behavior change for now.

How to set up and validate locally

We need to validate this in 4 scenarios:

  1. GitLab EE Unlicensed: this is probably how your GDK is right now. If you have a license in your GDK, remove it in https://gdk.test:3443/admin/subscription
  2. GitLab EE: by having a test license in your GDK.
  3. GitLab SaaS: setup a license like the above and simulate SaaS
  4. GitLab CE: by executing
    1. export FOSS_ONLY=1
    2. gdk restart
    3. Tanuki gdk website icon (the one in the browser tab) should be blue, then you're in CE

Now go to any Group Usage Quotas: https://gdk.test:3443/groups/flightjs/-/usage_quotas and check if your local setup matches the expected behavior.

  • To enable the FF: Feature.enable(:usage_quotas_for_all_editions)
  • To disable the FF: Feature.disable(:usage_quotas_for_all_editions)

Expected behavior:

  • Expected behavior with Feature Flag on: Page loads a placeholder (storage_app_placeholder) for all the scenarios.
GitLab Distribution Expected behavior FF off
GitLab EE Unlicensed Renders a 404 page
GitLab EE Loads the page normally, hiding SaaS UI (e.g. the right hand side card in Namespace overview)
GitLab SaaS Page loads normally, like it is on master/GitLab.com
GitLab CE Renders a 404 page

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Edited by Sheldon Led

Merge request reports