Skip to content

Fix N+1 queries when loading participants for a commit note

Stan Hu requested to merge sh-fix-award-emoji-nplus-one-participants into master

We saw about 10,000 SQL queries for some commits in the NewNoteWorker, which stalled the Sidekiq queue for other new notes. The notification service took up to 8 minutes to process the commits. Avoiding this N+1 query brings the time down significantly.

image

image

Closes #45526 (closed)

Edited by Stan Hu

Merge request reports