Skip to content

Delete records of all replicas that were deleted transactionally

Sami Hiltunen requested to merge smh-transactional-delete into master

We recently added transaction support for repository deletions to alleviate races that occur when quickly deleting a repository and creating it again. As the deletes were not transactional, a deletion job to a secondary would be scheduled and could be applied to the newly created repository if it is created again on the secondary that is pending the deletion job. While most of the other parts of making deletes transactional are in place, we don't currently delete the database records of all of the replicas that were deleted transactionally, only the primary's. This then leaves some stale state in the database that can affect the newly created repository. This commit fixes this by deleting the database records of all replicas that participated in the delete transaction.

Related to: !3603 (merged)

Edited by Sami Hiltunen

Merge request reports