We make 40 database queries against the repository group table in /api/repository/

RESOLVED FIXED

Status

Tree Management
Treeherder
RESOLVED FIXED
6 months ago
6 months ago

People

(Reporter: wlach, Assigned: wlach)

Tracking

Details

Attachments

(1 attachment)

This can result in slow load times, in some cases. We can avoid this by using select_related.

Comment 1

6 months ago
Created attachment 8802666 [details] [review]
[treeherder] wlach:1311511 > mozilla:master
Comment on attachment 8802666 [details] [review]
[treeherder] wlach:1311511 > mozilla:master

Noticed this while trying to figure out why the bug suggestions endpoint is so slow.
Attachment #8802666 - Flags: review?(emorley)
Comment on attachment 8802666 [details] [review]
[treeherder] wlach:1311511 > mozilla:master

Good spot :-)
Attachment #8802666 - Flags: review?(emorley) → review+

Comment 4

6 months ago
Commit pushed to master at https://github.com/mozilla/treeherder

https://github.com/mozilla/treeherder/commit/0aca73c39c26aee23e96d2bd37d2540f88eb2153
Bug 1311511 - Fix unnecessary database querying in /api/repository/ endpoint (#1938)
Status: NEW → RESOLVED
Last Resolved: 6 months ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.