diff options
author | Stan Hu <stanhu@gmail.com> | 2018-02-07 22:23:15 -0800 |
---|---|---|
committer | Sean McGivern <sean@gitlab.com> | 2018-02-08 10:28:50 +0000 |
commit | 9a323c7e1f806bca099158e29561e0958baa06a6 (patch) | |
tree | 585b09782d8c48283d6bd4819e29ace7f2aea98c /lib/api | |
parent | 828357fb828fc2d07b201f4f97f22ef964ab6a89 (diff) | |
download | gitlab-ce-9a323c7e1f806bca099158e29561e0958baa06a6.tar.gz |
Memoize MergeRequest#rebase_in_progress? to prevent N+1 queries in Gitalysh-fix-rebase-in-progress-nplus-one
MergeRequest#rebase_in_progress? and MergeRequest#rebase_path were called
twice each time per request. This memoization helps reduce the overall number
of queries.
See https://gitlab.com/gitlab-org/gitlab-ee/-/jobs/51616319 as a failing
job.
Closes gitlab-org/gitlab-ee#4857
Diffstat (limited to 'lib/api')
0 files changed, 0 insertions, 0 deletions