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

Improve queries in publish task to utilize select_related #1114

Merged
merged 1 commit into from
Jul 11, 2024

Conversation

hstct
Copy link
Contributor

@hstct hstct commented Jul 8, 2024

closes #1115

@hstct hstct force-pushed the improve_publish_queries branch 9 times, most recently from c128333 to a32953f Compare July 9, 2024 14:13
Copy link
Collaborator

@quba42 quba42 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The changes look very clean to me, and I can see how they would dramatically improve query performance! The only thing I am not sure about is the select_related("release", "distribution") on ReleaseComponents. Can we double check if that actually does anything? If not it should be dropped.

Also, using release_components_filtered to create the list of components and the prcs looks like a bugfix to me. Was this correct before?!

pulp_deb/app/tasks/publishing.py Outdated Show resolved Hide resolved
pulp_deb/app/tasks/publishing.py Show resolved Hide resolved
pulp_deb/app/tasks/publishing.py Show resolved Hide resolved
@hstct hstct force-pushed the improve_publish_queries branch from a32953f to 6c281cb Compare July 11, 2024 13:22
@hstct hstct merged commit b29542e into pulp:main Jul 11, 2024
11 checks passed
@hstct hstct deleted the improve_publish_queries branch July 11, 2024 13:36
Copy link

patchback bot commented Aug 6, 2024

Backport to 3.2: 💚 backport PR created

✅ Backport PR branch: patchback/backports/3.2/b29542e8ddb547fec1c8607148fda51e65d9b99e/pr-1114

Backported as #1129

🤖 @patchback
I'm built with octomachinery and
my source is open — https://github.com/sanitizers/patchback-github-app.

Copy link

patchback bot commented Aug 6, 2024

Backport to 3.3: 💚 backport PR created

✅ Backport PR branch: patchback/backports/3.3/b29542e8ddb547fec1c8607148fda51e65d9b99e/pr-1114

Backported as #1130

🤖 @patchback
I'm built with octomachinery and
my source is open — https://github.com/sanitizers/patchback-github-app.

patchback bot pushed a commit that referenced this pull request Aug 6, 2024
Improve queries in publish task to utilize select_related

(cherry picked from commit b29542e)
patchback bot pushed a commit that referenced this pull request Aug 6, 2024
Improve queries in publish task to utilize select_related

(cherry picked from commit b29542e)
quba42 added a commit that referenced this pull request Aug 6, 2024
…b547fec1c8607148fda51e65d9b99e/pr-1114

[PR #1114/b29542e8 backport][3.2] Improve queries in publish task to utilize select_related
quba42 added a commit that referenced this pull request Aug 6, 2024
…b547fec1c8607148fda51e65d9b99e/pr-1114

[PR #1114/b29542e8 backport][3.3] Improve queries in publish task to utilize select_related
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Improve publish task database queries
2 participants