Preload gitaly data before create

What does this MR do and why?

We currently have an issue (https://gitlab.com/gitlab-org/gitlab/-/issues/527205) where we have gitaly calls within database transactions. This can lead to a number of database transactions being in an idle state while the gitaly calls are made.

This merge request is to move these calls into a preload to be performed before the DB TXN occurs.

To Test:

  • Checkout branch
  • Turn on preload_mr_diff_gitaly_data feature flag
  • Create an MR, push to it, ensure the diff is as expected
Edited by Marc Shaw

Merge request reports

Loading