Add mutation to unlink policy project
What does this MR do and why?
This change adds new mutation that allows users to unlink security orchestration policy project from selected project.
Mutation
mutation {
securityPolicyProjectUnassign(input: { projectPath: "root/project" }) {
errors
}
}
Success:
{
"data": {
"securityPolicyProjectUnassign": {
"errors": []
}
}
}
Failure:
{
"data": {
"securityPolicyProjectUnassign": {
"errors": [
"Policy project doesn't exist"
]
}
}
}
How to set up and validate locally
- Create new project.
- Go to GraphQL explorer, use
securityPolicyProjectAssign
mutation to assign policy project to selected project. - In GraphQL explorer use
securityPolicyProjectUnassign
to remove association. - Verify if
securityPolicyProject
is no longer associated with the project.
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.
Related to #343268 (closed)