Draft: Sort dependency vulnerabilities by severity

What does this MR do and why?

Sorts the vulnerability list for dependencies by severity.

Query Plans

GraphQL

Old

SELECT 
  "sbom_occurrences_vulnerabilities".* 
FROM 
  "sbom_occurrences_vulnerabilities" 
WHERE 
  "sbom_occurrences_vulnerabilities"."sbom_occurrence_id" = 2923 
ORDER BY 
  "sbom_occurrences_vulnerabilities"."vulnerability_id" ASC 

New

SELECT 
  "sbom_occurrences_vulnerabilities".* 
FROM 
  "sbom_occurrences_vulnerabilities" 
  INNER JOIN "vulnerabilities" ON "vulnerabilities"."id" = "sbom_occurrences_vulnerabilities"."vulnerability_id" 
WHERE 
  "sbom_occurrences_vulnerabilities"."sbom_occurrence_id" = 2923 
ORDER BY 
  "vulnerabilities"."severity" DESC, 
  "vulnerabilities"."id" DESC 

API

Old

New

References

Screenshots or screen recordings

Before After
Screenshot 2025-11-17 at 9.54.18 PM.png Screenshot 2025-11-17 at 10.34.55 PM.png

How to set up and validate locally

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #543818

Edited by Harrison Peters

Merge request reports

Loading