Zoekt cache should invalidate if multi match chunk size changes
What does this MR do and why?
This MR invalidates the Zoekt cache if the requested chunk count is changed when zoekt multi match is enabled
References
Please include cross links to any resources that are relevant to this MR. This will give reviewers and future readers helpful context to give an efficient review of the changes introduced.
- Related to #517374 (closed)
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Screenshots or screen recordings
Screenshots are required for UI changes, and strongly recommended for all other merge requests.
How to set up and validate locally
-
setup gdk for zoekt
-
enable feature flags
Feature.enable(:zoekt_cache_search_responses) Feature.enable(:zoekt_multimatch_frontend) -
upload this file to any zoekt indexed project: https://gitlab.com/gitlab-org/gitlab/-/blob/master/ee/app/models/search/zoekt.rb
-
search in using graphQL in group
licensed_and_indexing_enabledas the search term -
change the
chunkCountand verify that the results returned change the number of chunks returned
{
blobSearch(search: "licensed_and_indexing_enabled",
chunkCount: 5,
groupId: "gid://gitlab/Group/112") {
matchCount
perPage
fileCount
searchType
searchLevel
files {
path
fileUrl
chunks {
matchCountInChunk
lines {
lineNumber
text
}
}
}
}
}