Prepare async index for vulnerability_occurrences table
What does this MR do and why?
This new index will be utilized to address query timeout issues in override uuids logic.
Database review
The timing out query
SELECT
"vulnerability_occurrences".*
FROM
"vulnerability_occurrences"
WHERE
"vulnerability_occurrences"."project_id" = 278964
AND "vulnerability_occurrences"."report_type" = 0
AND "vulnerability_occurrences"."location_fingerprint" IN (...)
- Before the index: https://console.postgres.ai/gitlab/gitlab-production-tunnel-pg12/sessions/17493/commands/58516
- After the index: https://console.postgres.ai/gitlab/gitlab-production-tunnel-pg12/sessions/17493/commands/58536
Related to OverrideUuidsService is raising `PG::QueryCance... (#397004 - closed).
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 Mehmet Emin INAC