Suppress webhooks when GitLab is in Silent Mode
What does this MR do and why?
This MR prevents webhooks from executing or being queued when GitLab is in Silent Mode.
- Issue: #393639 (closed)
There is no Changelog
trailer because Silent Mode is an experiment.
How to set up and validate locally
- Create a project hook: 2. Choose a project, and go Settings > Webhooks. 3. Click Add new webhook. 4. Enter a `URL of a webhook receiver. You can visit https://webhook.site to generate a unique webhook receiver URL to test with. 5. Under Trigger, select Issues events. 6. Select Add webhook.
- Close the issue, you should receive a webhook.
- Now set the instance to Silent Mode on the Rails console:
Gitlab::CurrentSettings.update!(silent_mode_enabled: true)
- Wait up to a minute for it to take effect (see #405433).
- Reopen the issue, close it again, you should not receive any webhooks.
Remember to disable Silent Mode again afterwards:
Gitlab::CurrentSettings.update!(silent_mode_enabled: false)
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.
Related to #393639 (closed)
Edited by Luke Duncalfe