GLQL: Expose field, type, and parameters in REST API entity

Summary

API::Entities::Glql::Field currently only exposes key, label, and name. The GLQL compiler now emits additional properties that API consumers need:

  • field: the base field name, distinct from key for aliased parameterised fields (e.g. key: "p50", field: "durationQuantile")
  • type: "dimension" or "metric", used by the frontend for dimensionsOf/metricsOf filtering
  • parameters: resolved parameter metadata (e.g. { granularity: "weekly" }, { quantile: 0.5 })

These properties are present in the compile output but silently dropped by the Grape entity whitelist.

What needs to change

  1. Add expose :field, expose :type, and expose :parameters to lib/api/entities/glql/field.rb with appropriate documentation
  2. Update spec/lib/api/entities/glql/field_spec.rb with test coverage for the new properties
  3. Update doc/api/glql.md response attributes table to document fields[].field, fields[].type, and fields[].parameters
  4. Update the gitlab_query_language gem version to the release that includes glql!412 (closed)

Blocked on

  • GLQL release including glql!412 (closed) (the field property)
  • The gem version bump depends on that release being cut

Related: !241834 (merged), glql#130 (closed), glql#153 (closed)