Loading
Document GLQL parameterized fields and duplicate field aliases
What does this MR do and why?
Documents the GLQL analytics mode field parameters and duplicate field aliasing released in GLQL 0.31.0, now in production and shipping in GitLab 19.3:
- Field parameters: dimensions and metrics accept a parameter in parentheses, e.g.
finished(weekly)for time dimension granularity (daily,weekly,monthly) anddurationQuantile(0.5)for quantiles (0.01 to 0.99). Defaults apply when omitted. - Duplicate parameterized fields with aliases: e.g.
metrics: durationQuantile(0.5) as "Median", durationQuantile(0.95) as "p95".
Changes:
doc/user/glql/_index.md: new "Field parameters" subsection in Analytics mode, extended "Custom aliases" with duplicate parameterized field rules, sorting clarification for aliased fieldsdoc/user/glql/data_sources/pipeline_analytics.md: configurable granularity onfinished/started, configurable quantile ondurationQuantile, removed the stale fixed-granularity note, new "Median and p95 pipeline duration by week" exampledoc/user/glql/data_sources/contributions.md: configurable granularity oncreated(defaultmonthly)doc/user/glql/data_sources/code_suggestions.md: note thattimestamponly acceptsmonthlygranularity
Related work
The 0.31.0 bumps this documents are merged and in production:
- REST API: Expose field, type, and parameters in GLQL REST... (!243518 - merged)
- Frontend: Use compile output parameter metadata for time ... (!241834 - merged)
The AI gateway change is still in review: feat: add parameterised field and alias syntax ... (gitlab-org/modelops/applied-ml/code-suggestions/ai-assist!6050 - merged)
How to test
- Check the four changed pages render correctly in the docs review app.
- To verify the documented behaviour end-to-end, follow the setup steps in Use compile output parameter metadata for time ... (!241834 - merged) and run the new "Median and p95 pipeline duration by week" example from
pipeline_analytics.md.
Note for review
Confirmed against the 0.31.0 compiler: you can sort by either the alias or the original field name when it's unambiguous. Duplicated fields with different parameters must be sorted by their alias. The docs now say this.
References
Edited by Robert Hunt