84632f0aff
Reduce SQL query counts in IssueReferenceFilter ## What does this MR do? This MR adds a preparation phase for reference filters that allows them to prepare/create data structures used while iterating over HTML nodes. In this particular case the preparation phase is used for issue references to greatly cut down the amount of queries executed to get projects/issues for Markdown references. ## Are there points in the code the reviewer needs to double check? No. ## Why was this MR needed? Rendering Markdown containing issue references would run at most two queries for every issue reference: one to get the project and one to get the issue from said project. When rendering Markdown with lots of issue references this would result in _a lot_ of queries being executed. ## What are the relevant issue numbers? #18042 See merge request !4410 |
||
---|---|---|
.. | ||
config | ||
controllers | ||
factories | ||
features | ||
finders | ||
fixtures | ||
helpers | ||
initializers | ||
javascripts | ||
lib | ||
mailers | ||
models | ||
requests | ||
routing | ||
services | ||
support | ||
tasks/gitlab | ||
views | ||
workers | ||
factories_spec.rb | ||
rails_helper.rb | ||
spec_helper.rb | ||
teaspoon_env.rb |