Skip to content
代码片段 群组 项目
未验证 提交 19205b66 编辑于 作者: Abdul Wadood's avatar Abdul Wadood 提交者: GitLab
浏览文件

Fix admin_mode enforcement in AdjournedProjectDeletionWorker

This change addresses an issue where project deletion fails when
scheduled by an admin with admin mode enabled. The problem occurs
because the `admin_mode` session value is not persisted to Sidekiq.

To resolve this, we introduce an `admin_mode` flag for
`ProjectDestroyWorker`, creating a temporary admin session for
project deletion. This approach ensures that other policy checks,
such as blocking or user permissions, remain enforced while
bypassing the admin_mode check. The admin_mode check should only be
performed when the deletion is scheduled. We have previously
implemented a similar solution for groups in a separate merge
request https://gitlab.com/gitlab-org/gitlab/-/merge_requests/163071.

Changelog: fixed
EE: true
上级 922d4cd0
No related branches found
No related tags found
加载中
加载中
0% 加载中 .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册