Skip to content

Add virtual registry setting toggle and call graphql query and mutation

What does this MR do and why?

This MR adds in a toggle to the package and registries setting to enable/disable the virtual registry feature.

This is an EE only feature.

This feature is enabled by default due to the default value for enabled being set to true.

This is the last MR for this feature #554069

Latest design, which includes the beta badge #569623[BetaBadge.png]

Main changes are:

  • add new EE virtual registries setting component
  • add mutation
  • new EE component is imported into the existing group_settings_app page.
  • Updated the existing query to use fragments, so that in FOSS mode the query doesn't include the virtual registries settings, but does include the virtual registries settings query in EE. I saw a couple of different implementations in the codebase, and thought this way was a neat way to approach this.
  • Added a separate group_settings_app test coverage in EE. This contributes to the larger size MR. I thought this was the simplest cleanest way to test EE and FOSS separately. But open to other suggestions.

Note: The MR is on the larger side, I looked at splitting this out into backend and frontend changes, but that wouldn't make a big impact as the backend changes are quite small (pushing abilities and adding search section). The frontend changes all really need to go in together to work. Happy to try a different approach if this is too hard to review.

References

Screenshots or screen recordings

Before After
Screenshot_2025-10-07_at_9.27.44_pm Screenshot_2025-10-07_at_9.23.37_pm
. Screenshot_2025-10-07_at_9.23.44_pm
Kapture_2025-10-07_at_21.37.43 Kapture_2025-10-07_at_21.21.03
Screenshot_2025-10-07_at_9.46.05_pm
Screenshot_2025-10-07_at_9.46.11_pm

How to set up and validate locally

Setup:

1. Ensure that you have setup an ee licence locally 1. Dependency proxy should be enabled by default 1. Check that the maven virtual registry flag is enabled 1. Switch to this branch
[2] pry(main)> ::Feature.enabled?(:maven_virtual_registry)
=> true

Validate persistence to db, links and popover:

  1. Run gdk psql
  2. select * from virtual_registries_settings;
  3. There will be no entries initially. The setting is enabled by defailt.

Screenshot_2025-09-10_at_3.54.48_pm

  1. Go to http://gdk.test:3000/groups/twitter/-/settings/packages_and_registries
  2. Under enable virtual registry
  3. Disable toggle
  4. Check psql and there will be an entry for that group, with enabled false.

Kapture_2025-10-07_at_21.21.03

Accessibility:

  1. On a mac you can press command + F5 to enable screen reader
  2. Go to http://gdk.test:3000/groups/twitter/-/settings/packages_and_registries
  3. Tab to virtual registry toggle, should be enabled.

Screenshot_2025-10-07_at_9.44.31_pm

Screenshot_2025-10-07_at_9.44.58_pm

FOSS mode:

  1. Run export FOSS_ONLY=true
  2. Restart your gdk gdk restart

Screenshot_2025-10-07_at_9.36.10_pm

  1. Go to http://gdk.test:3000/groups/twitter/-/settings/packages_and_registries
  2. The virtual registry setting should not be showing and all other settings continue to work.

Kapture_2025-10-07_at_21.37.43

Validation of the impact of disabling this toggle (i.e graphql queries, apis, views) has been done in this MR !204305 (merged)

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #562237

Edited by Fiona McCawley

Merge request reports

Loading