-
Bug
-
Resolution: Done
-
Minor
-
None
The DefaultPushGHEventSubscriber provides an extension point for "other plugins [that] may be interested in listening for these updates" (GitHubWebHook.Listener). However, the only information those other plugins can receive is the name of the pusher and the repository URL.
It'd be useful to also give the GHEvent, the string payload, or both to the listener, so that the extension can make useful decisions about what to do on the push event. As it is, a listener can know a push happened on a repo, but not what was pushed.
This restricts the ability of the listeners to perform useful tasks such as only updating a single branch (e.g. https://github.com/jenkinsci/github-branch-source-plugin/blob/master@%7B2016-09-02%7D/src/main/java/org/jenkinsci/plugins/github_branch_source/GitHubWebhookListenerImpl.java#L49) - seems to be the root cause behind major missing functionality in github-branch-source, for instance