I have a GitHub repo with many developers, hence many pull requests are opened at the same time.
This repo has a webhook – a Jenkins multibranch pipeline.
When a pull request is merged, all other opened pull requests are triggered in Jenkins and run again.
Normally, this is the desired behavior, but since this repo has many pull request that are opened simultaneously, it causes a lot a load on the Jenkins server – sometimes 20 builds are triggered and run at the same time.
How can I prevent open pull requests from automatically rebuilding after merge to the target branch?