We have many teams using an assortment of webhook plugins (built-in/third-party) for their CI systems. When these systems get a push webhook, they will pull from the mirror and not receive the latest changes. We would like to address this issue without putting more work on the teams using CI.
I was thinking to add an event listener for RepositoryMirrorSynchronizedEvent on each plugin before sending a webhook, however that requires a lot of custom work and maintenance for each plugin (including the Webhooks system app).
Alternatively, I can change the default behavior of RepositoryRefsChangedEvent to wait for a mirror sync before issuing a webhook. This will proactively allow each plugin to send webhooks when everything is synced but may cause other system issues.
What’s the best way of solving this problem so these CI systems don’t have to change their current practices?