Convert GLQL Finder to a more generic Advanced Finder
What does this MR do and why?
- This MR converts the current GLQL WorkItems finder to a more generic Advanced Finder naming.
- This way we can also introduce an extra feature flag to reuse the existing ES integration with WorkItems lists.
- I also moved the existing advanced finder from
ee/app/finders/ee/work_items/glql/work_items_finder.rbtoee/lib/ee/search/elastic/advanced_finders/work_items_finder.rbto avoid having to get database reviews which are required for all files within/findersdir.
References
#544820 (closed)
#561475
&17460
Screenshots or screen recordings
| Before | After |
|---|---|
How to set up and validate locally
There are two testing scenarios. First one is to test that everything for GLQL works as it used to. The working integration tests are supporting that nothing changed there. The manual test would be the following:
- Follow this guide to have ES enabled locally for GDK
- GLQL relies on
crypto.subtle, which is unavailable in insecure contexts (except forlocalhost), it won’t work if you're using a custom URL likehttp://gdk.test:3000locally. To resolve this, one of the options is to enable HTTPS in GDK by following this link. - Enable the following feature flags in
rails c:
=> Feature.enable(:glql_integration)
=> Feature.enable(:glql_work_items)
=> Feature.enable(:glql_es_integration)
- Navigate to any issue comment or description field where Markdown is supported
- Add any GLQL query into the field, it should work (make sure to build the query only based on the currently supported ES fields):
```glql
display: table
fields: title, labels, milestone
query: group = "gitlab-org" and label = any
```
The flow to test it with work items lists would be the following:
- Have the following feature flags enabled:
=> Feature.enable(:work_items_project_issues_list)
=> Feature.enable(:work_item_planning_view)
=> Feature.enable(:work_items_list_es_integration)
Navigate to the work items overview page https://gdk.test:3443/groups/gitlab-org/-/work_items or https://gdk.test:3443/gitlab-org/gitlab/-/work_items and now you can see that the page loads results from the ES (can be checked via the performance bar).
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.
Related to #544820 (closed)