Adding readiness score argument to link vulnerability merge request mutation
What does this MR do and why?
This MR adds a readiness score argument to the VulnerabilityLinkMergeRequest mutation, this will represent the confidence of the ai workflow created resolution MR.
References
#570181
How to set up and validate locally
- Navigate to a project with a vulnerability
- Create an MR
- In the graphql explorer
/-/graphql-explorermake the following mutation
mutation linkMergeRequest {
vulnerabilityLinkMergeRequest(input: {
vulnerabilityId: "gid://gitlab/Vulnerability/<id>",
mergeRequestId: "gid://gitlab/MergeRequest/<id>",
readinessScore: 0.3
}) {
vulnerability {
id
mergeRequests {
nodes {
id
title
}
}
}
errors
}
}
- You can check the merge request link record in rails console and whether the readinessScore was updated or not by running following command, ensure readiness score is there:
Vulnerabilities::MergeRequestLink.last
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 #570181
Edited by Hitesh Raghuvanshi