Skip to content

Remove support for newly_detected vulnerability status

Marcos Rocha requested to merge mc_rocha-remove-newly-detected-422414 into master

What does this MR do and why?

This MR removes the support for newly_detected vulnerability status for scan_result_policies

Migrations

approval_project_rules

Up
main: == 20240205171942 ChangeApprovalProjectRulesVulnerabilityStatesDefault: migrating 
main: -- change_column_default("approval_project_rules", "vulnerability_states", {:from=>["newly_detected"], :to=>["new_needs_triage", "new_dismissed"]})
main:    -> 0.0282s
main: == 20240205171942 ChangeApprovalProjectRulesVulnerabilityStatesDefault: migrated (0.0322s) 

Down

main: == 20240205171942 ChangeApprovalProjectRulesVulnerabilityStatesDefault: reverting 
main: -- change_column_default("approval_project_rules", "vulnerability_states", {:from=>["new_needs_triage", "new_dismissed"], :to=>["newly_detected"]})
main:    -> 0.0175s
main: == 20240205171942 ChangeApprovalProjectRulesVulnerabilityStatesDefault: reverted (0.0213s) 

approval_merge_request_rules

Up
main: == 20240205170838 ChangeApprovalMergeRequestRulesVulnerabilityStatesDefault: migrating 
main: -- change_column_default("approval_merge_request_rules", "vulnerability_states", {:from=>["newly_detected"], :to=>["new_needs_triage", "new_dismissed"]})
main:    -> 0.0203s
main: == 20240205170838 ChangeApprovalMergeRequestRulesVulnerabilityStatesDefault: migrated (0.0292s) 

Down

main: == 20240205170838 ChangeApprovalMergeRequestRulesVulnerabilityStatesDefault: reverting 
main: -- change_column_default("approval_merge_request_rules", "vulnerability_states", {:from=>["new_needs_triage", "new_dismissed"], :to=>["newly_detected"]})
main:    -> 0.0181s
main: == 20240205170838 ChangeApprovalMergeRequestRulesVulnerabilityStatesDefault: reverted (0.0218s) 

As described here we want to have MR ready in %16.9 and prepared to be merged in %17.0.

Related to: #422414 (closed)

MR acceptance checklist

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

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Before After

How to set up and validate locally

Numbered steps to set up and validate the change are strongly suggested.

Edited by Marcos Rocha

Merge request reports

Loading