Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-53694

Add event "Pull request review comments" to the webhook trigger

    • Icon: Task Task
    • Resolution: Unresolved
    • Icon: Major Major
    • github-plugin
    • None

      The webhooks created right now are triggered only for "Pull Request" & "Push" events.

      Please also add the event "Pull request review comments" to the webhook created.

       

      Usecase :
      The build can fail due to network connectivity issues; overload of resources or parallel builds eating up too many resources or just times out.

      Solution :
      Ability to re-trigger the build through "pull request review comments".

       

          [JENKINS-53694] Add event "Pull request review comments" to the webhook trigger

          Nitin Surana added a comment -

          The support has been added long back - https://github.com/kohsuke/github-api/commit/0108a0c146cbe2146929238675fb3ff9057ec7e2

          Please find the pull request for this small feature here - https://github.com/jenkinsci/github-branch-source-plugin/pull/185

          Nitin Surana added a comment - The support has been added long back - https://github.com/kohsuke/github-api/commit/0108a0c146cbe2146929238675fb3ff9057ec7e2 Please find the pull request for this small feature here -  https://github.com/jenkinsci/github-branch-source-plugin/pull/185

          Priyatham Tadikonda added a comment - - edited

          I would like to resume my pipeline when the code-review is submitted for the PR.

          I am pushing all the web hook events from Github. I created a multi branch pipeline project and I am able to start a pipeline and run the tests when a PR is created in Github, I want to merge the PR when the code-review is completed. 

          I would like to know how can I process the code-review push event from GITHUB in Jenkins.

          Please help me if anyone has achieved this.

          Priyatham Tadikonda added a comment - - edited I would like to resume my pipeline when the code-review is submitted for the PR. I am pushing all the web hook events from Github. I created a multi branch pipeline project and I am able to start a pipeline and run the tests when a PR is created in Github, I want to merge the PR when the code-review is completed.  I would like to know how can I process the code-review push event from GITHUB in Jenkins. Please help me if anyone has achieved this.

          Nitin Surana added a comment -

          priyatham Jenkins Github Plugin is not responsible for merging your PR. If your PR is successful, you can either manually merge the PR or create a script that does so. Github can notify your script to merge through a Webhook attached to pull_request event. Your script can be hosted somewhere where it can receive the request from github webhook.

          https://developer.github.com/v3/activity/events/types/#pullrequestevent - Here is what the event payload can contain.

          https://developer.github.com/v3/pulls/#get-if-a-pull-request-has-been-merged - Here is how to check if a PR is merged.

          https://developer.github.com/webhooks/ - The `pull_request` event is triggered when a pull request is assigned, unassigned, labeled, unlabeled, opened, edited, closed, reopened, synchronize, ready_for_review , a pull request review is requested, or a review request is removed.

           

           

          Nitin Surana added a comment - priyatham Jenkins Github Plugin is not responsible for merging your PR. If your PR is successful, you can either manually merge the PR or create a script that does so. Github can notify your script to merge through a Webhook attached to pull_request event. Your script can be hosted somewhere where it can receive the request from github webhook. https://developer.github.com/v3/activity/events/types/#pullrequestevent  - Here is what the event payload can contain. https://developer.github.com/v3/pulls/#get-if-a-pull-request-has-been-merged  - Here is how to check if a PR is merged. https://developer.github.com/webhooks/  - The `pull_request` event is triggered when a pull request is assigned, unassigned, labeled, unlabeled, opened, edited, closed, reopened, synchronize, ready_for_review , a pull request review is requested, or a review request is removed.    

            lanwen Kirill Merkushev
            nsurana Nitin Surana
            Votes:
            2 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: