Advanced Search: Optimize Group-level Searches for Commits
Overview
Searches that are across entire groups can be slow if the Group has a large number of projects. This is because the query will contain all the project IDs that are part of the selected group.
Adding the Group Hierarchy in the indexed document will allow for the query to specify the group level as a filter and keep eliminate the need to have a large list of project IDs included in the query.
Steps
-
Add namespace_ancestry to Commits index mapping MR example -
Backfill namespace_ancestry for Commits MR example -
Advanced Search: Use namespace_ancestry for Commits MR example -
Advanced Search: Add namespace_ancestry_ids to Commits index MR example
Edited by John McGuire