Use project issues search instead of global search
Context
While working on gitlab-org/gitlab!140998 (merged), I noticed by accident that we had different flaky tests issues created, but the test had the same hash:
- https://gitlab.com/gitlab-org/quality/engineering-productivity/flaky-tests/-/issues/52
- https://gitlab.com/gitlab-org/quality/engineering-productivity/flaky-tests/-/issues/54
The problem
It seems to be related to the global search that has a delay of 20-30s for indexing the newly created issue (see the Screen Recordings
section for a demo).
What does this MR do and why?
We revert to using the project issues search, which seems to be more or less instantaneous in my local testing.
Screen Recordings
main
branch
branch of this MR
How to set up and validate locally
You can use the artifacts of https://gitlab.com/gitlab-org/gitlab/-/jobs/5861540558 as an example.
export PROJECT_ID=51263763 # https://gitlab.com/ddieulivol/sandbox
# GITLAB_API_PRIVATE_TOKEN is a private Personal Access Token
exe/flaky-test-issues \
--input-files "/Users/gitlab/Downloads/artifacts/rspec/rspec-*.json" \
--project "${PROJECT_ID}" \
--token "${GITLAB_API_PRIVATE_TOKEN}"
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Edited by David Dieulivol