Access request email notification not sent


I am running GitLab 13.7.1-ee and sending emails via mailgun smtp service. When someone requests access there should be an email notification going out to maintainers/owners. However, this is not happening. I can see the access request in GitLab itself but the email is never sent. All other notifications are sent without problems.

I’ve already looked up the logs in mailgun and tried another service, but nothing changes. The only thing I found in the GitLab logs is this:

{"severity":"ERROR","time":"2021-01-11T09:37:10.169Z","correlation_id":"d149c1195a3d7a1cab3c7381455ba46d","message":"Cannot obtain an exclusive lease for namespace:namespaces_root_statistics:27. There must be another instance already in execution."}

This error shows up everytime the “Request Access” button is clicked.