Skip to content

Skip repository disconnect if project is pending delete

Jacob Vosmaer requested to merge jv-skip-pool-unlink into master

Fixes #368463 (closed).

When we unlink a Git repository from a pool repository, we make a call to the Gitaly DisconnectAlternates RPC to make sure that the repository becomes self-contained again. This is a waste of effort if we are about to delete the repository.

This MR adds a performance optimization where we skip the DisconnectAlternates call if the pending_delete flag is set for the project the repository belongs to.

Edited by Jacob Vosmaer

Merge request reports

Loading