Add --no-deref to DeleteRefs RPC
From gitlab#377951 (comment 1152312762), we realized some usage for deleting symbolic refs without affecting the original refs. This is the result of creating deployment refs (refs/environments/<environment-name>/deployments/<deployment-iid>
). In the past, if the deployment points to another ref, it creates a symbolic ref. In next iterations, we changed the implementation so that the ref points to the underlying SHA instead. Unfortunately, the old symbolic refs still exist. In the above issue, we noticed some users facing this issue. It's not possible to remove the symbolic refs at the moment. As a result, their Deployments::ArchiveInProjectWorker
jobs get stucked and they fail to archive the deployments. This may also be the case for self-managed instances.
So, it looks like adding --no-deref
option in the DeleteRefs RPC is the correct solution. In addition, there could also be some use cases in the future for this option.