Fix bug with batched gitaly ref deletion duplicates
What does this MR do and why?
Fix bug with batched gitaly ref deletion duplicates
If there are duplicates sent in a single Git command we get an error.
This de-duplication works around this. We could also consider
de-duplicating in the queue but this is tricky to do without race
conditions and would also require a migration. Without the uniq
fix
this new test fails with:
1) BatchedGitRefUpdates::ProjectCleanupService#execute handles duplicates
Failure/Error: raise Gitlab::Git::CommandError, e
Gitlab::Git::CommandError:
13:unable to prepare: reference has been updated multiple times within a transaction.
Related to:
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Edited by Kamil Trzciński