Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Store computed severities in the database #3408

Merged
merged 1 commit into from
Jan 25, 2024

Conversation

nscuro
Copy link
Member

@nscuro nscuro commented Jan 24, 2024

Description

Stores computed severities in the database, instead of calculating it in-memory.

This extends #3287 in the following ways:

  • Alter the behavior of Vulnerability#setSeverity to not clear vectors and scores anymore
  • Address more code areas that create or update vulnerability data, ensuring that severity is always being set
  • During the migration from v4.10.x, update severities of existing vulnerabilities in batches of 500, drastically decreasing database round-trips

Addressed Issue

Closes #2474

Additional Details

N/A

Checklist

  • I have read and understand the contributing guidelines
  • This PR fixes a defect, and I have provided tests to verify that the fix is effective
  • This PR implements an enhancement, and I have provided tests to verify that it works as intended
  • This PR introduces changes to the database model, and I have added corresponding update logic
  • This PR introduces new or alters existing behavior, and I have updated the documentation accordingly

@nscuro nscuro added the enhancement New feature or request label Jan 24, 2024
@nscuro nscuro added this to the 4.11 milestone Jan 24, 2024
This extends DependencyTrack#3287 in the following ways:

* Alter the behavior of `Vulnerability#setSeverity` to *not* clear vectors and scores anymore
* Address more code areas that create or update vulnerability data, ensuring that severity is always being set
* During the migration from v4.10.x, update severities of existing vulnerabilities in batches of 500, drastically decreasing database round-trips

Co-authored-by: Ralf King <rkg@mm-software.com>
Co-authored-by: Marlon Gaethje <mge@mm-software.com>
Signed-off-by: nscuro <nscuro@protonmail.com>
@nscuro nscuro merged commit a3034b8 into DependencyTrack:master Jan 25, 2024
9 checks passed
@nscuro nscuro deleted the issue-2474 branch January 25, 2024 17:20
@nscuro nscuro mentioned this pull request Feb 8, 2024
2 tasks
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 25, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

VULNERABILITY.SEVERITY should be updated in database
1 participant