Skip to content

search: refactor suggestions to use streaming search

Created by: novoselrok

Fixes #24983 (closed)

Instead of using the SearchSuggestions GQL endpoint, I refactored the client suggestions to use streaming search endpoint. For example, to get suggestions for repo:source filter we transform the query into repo:source type:repo count:50 and use the search results as suggestions.

TODO:

  • Fix client tests
  • Support for file and symbol suggestions

Notes:

  • ️ Browser extension still uses GQL suggestions (will have to be removed in a separate PR)
  • ️ Support for context: suggestions has been removed because contexts are not an eligible search result type
  • ️ Support for repogroup: suggestions has been removed for the same reason as well

Merge request reports

Loading