Include constraints in suggested metric names [RUN ALL RSPEC] [RUN AS-IF-FOSS]
What does this MR do?
This MR enhances automated metrics name generation feature by including variable part in metric names suggestion (enclosed in <>
) if underlying metric query includes constraints (where source_table.some_col = 123
) that applies to source relation of the metric. Handling joined relation is scope of follow up issue #323219 (closed)
Implementes #323193 (closed)
Test locally
Make sure that feature flag is enabled
::Feature.enable(:product_intelligence_metrics_names_suggestions)
Run generator
$ bundle exec rails generate gitlab:usage_metric_definition counts.jira_imports_total_imported_issues_count --dir=7d
Screenshots (strongly suggested)
Does this MR meet the acceptance criteria?
Conformity
-
📋 Does this MR need a changelog?-
I have included a changelog entry. -
I have not included a changelog entry because change is behind a feature flag, and it is considered to be tooling improvement.
-
- [-] Documentation (if required) will be added at #323587 (closed)
-
Code review guidelines -
Merge request performance guidelines -
Style guides
Edited by Mikołaj Wawrzyniak