DependencyTrack / dependency-track

Dependency-Track is an intelligent Component Analysis platform that allows organizations to identify and reduce risk in the software supply chain.
https://dependencytrack.org/
Apache License 2.0
2.61k stars 552 forks source link

The Audit Vulnerabilities list query is too slow #3811

Closed x-zim closed 1 month ago

x-zim commented 3 months ago

Current Behavior

The number of Audit Vulnerabilities is about 200, and the query is very slow. Is there any solution here

Steps to Reproduce

1.Click on the Audit Vulnerabilities list, and the above problems appear

Expected Behavior

Expect a solution here

Dependency-Track Version

4.11.0

Dependency-Track Distribution

Container Image

Database Server

PostgreSQL

Database Server Version

No response

Browser

Google Chrome

Checklist

nscuro commented 3 months ago

You are definitely right.

The endpoint suffers from the N+1 problem and does not yet support pagination.

There's nothing you can do from your end, this needs a code change.

x-zim commented 3 months ago

Is this problem solved with version iteration in mind

nscuro commented 3 months ago

I had a look at this today and was able to make some quite substantial improvements: https://github.com/DependencyTrack/dependency-track/pull/3869

There's still plenty of headroom for further optimization, but it's a good start I think.

nscuro commented 1 month ago

I'm going to close this issue under the assumption that #3869 resolves it. Please feel free to open a new issue if the v4.12 release does not satisfy your expectation.

github-actions[bot] commented 1 day ago

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.