Draft: Filter jobs by name
What does this MR do and why?
- Adds the ability to filter jobs by name
- Adds name token to UI
- Code refactor to support multiple search tokens
NOTE: This MR should stay a draft until the name
column has been added to the appropriate index on the ci_builds
table.
- Async index MR: !107102 (closed)
- Sync index MR: TBD
Screenshots or screen recordings
UI selections
UI Results
Query testing results
Query
plan SELECT "ci_builds".* FROM "ci_builds" WHERE "ci_builds"."type" = 'Ci::Build' AND "ci_builds"."project_id" = 278964 AND ("ci_builds"."status" NOT IN ('created')) AND "ci_builds"."name" = 'detect-tests' AND ("ci_builds"."status" IN ('success')) ORDER BY "ci_builds"."id" DESC
Plan
Sort (cost=61096088.46..61096109.17 rows=8286 width=1250)
Sort Key: id DESC
-> Index Scan using "<13343>btree_ci_builds_status_created_at_project_id_name" on ci_builds (cost=0.08..61095549.19 rows=8286 width=1250)
Index Cond: (((status)::text = 'success'::text) AND (project_id = 278964) AND ((name)::text = 'detect-tests'::text))
How to set up and validate locally
- Visit CI/CD > Jobs
- Filter jobs by name
- Filter jobs by status
- Filter jobs by status and name
- Filter jobs by custom query string in URL I.E
?name=coverage_job&statuses=SUCCESS
- Confirm all is working
✅
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 Payton Burdette