Loading
Add support for epics in GLQL
What does this MR do and why?
Add support for epics in GLQL
Add support for querying epics type = Epic) and querying issues by epic (epic = gitlab-org&1) in GLQL.
Legacy epics only support querying by a single epic (epic = gitlab-org&1) But work items support multiple epics (epic in (gitlab-org&1, gitlab-org&2, &3)).
References
- Closely related to https://gitlab.com/gitlab-org/gitlab-query-language/glql-rust/-/issues/30+. While that issue talks about
parent. We only introduce support forepicsin this MR first. - Support for
epicfield in GLQL was added (and improved upon) in the following MRs:- https://gitlab.com/gitlab-org/gitlab-query-language/glql-rust/-/merge_requests/152+
- https://gitlab.com/gitlab-org/gitlab-query-language/glql-rust/-/merge_requests/154+
- https://gitlab.com/gitlab-org/gitlab-query-language/glql-rust/-/merge_requests/158+
- https://gitlab.com/gitlab-org/gitlab-query-language/glql-rust/-/merge_requests/159+
- https://gitlab.com/gitlab-org/gitlab-query-language/glql-rust/-/merge_requests/161+
Screenshots or screen recordings
Screenshots for the output of a GLQL query largely remain unchanged. However, we can now execute the following queries:
With the legacy epics API
epic = 123 # Epic ID can be a number
epic = &123 # Reference, without a group prefix
epic = gitlab-org&123 # Reference with a group prefix
epic = "123" # Quoted number
epic = "&123" # Quoted reference without a group prefix
epic = "gitlab-org&123" # Quoted reference with a group prefix
type = Epic # List all epics only. Cannot be combined with issues. Example: `type in (Epic, Issue)` - NOT ALLOWEDWith the new work items API
If you enable feature flag glql_work_items, the epic query also supports the IN operator with any of the variants defined above:
epic in (123, 456)
epic in (&456, "123", gitlab-org&1, gitlab-com&2) # Any combination is allowed
type in (Epic, Issue) # ALLOWED!How to set up and validate locally
- Add an epic to one or more issues.
- Try any of the GLQL queries above.
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.
Edited by Himanshu Kapoor