Group setting toggle for hierarchy optimization
What does this MR do and why?
This MR adds a temporary group setting toggle (behind feature flag) for enabling the group hierarchy query optimizations for a group. I decided to have an actual toggle on the UI so we have an easy way to enable and disable the optimization for a group on production before rolling the optimization out globally. The other approach would be creating the Namespaces::Descendants
record via rails console which make testing the feature on smaller/isolated groups difficult (creating a change request).
Related epic: &11469
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Screenshots or screen recordings
How to set up and validate locally
- In rails console enable the experiment fully
Feature.enable(:group_hierarchy_optimization)
- Go to a group and go to
Settings > General
- Find the performance toggle (bottom) in the
Permissions and group features
section. - The setting should be persisted.
- When uncheckng the toggle, the setting should be also persisted (unchecked).
Related to #433478 (closed)
Edited by Adam Hegyi