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

Bitbucket Branch Source Plugin should build merged branches in Multibranch Pipeline

    Details

    • Similar Issues:

      Description

      Just updated the Bitbucket Branch Source Plugin within a multibranch pipeline to the latest version, and it is full of welcome changes (thank you!). I'm using a webhook to send events to Jenkins from Bitbucket private instance. 

      One thing that appears to be missing, is a feature that we commonly use in our workflow, which is to build `dev` or `master` whenever the PR is merged. So with this plugin, we have the following outcome

      Branch Push -> Build

      PR Open -> Build

      PR Updated (via pushing code) -> Build

      PR Merged into Dev -> *Dev NOT built (*I would like `dev` to be built here.)

       

      I am seeing the hook in the pipeline events, but `dev` does not build unless I do a manual scan (or a timed scan, but that defeats the purpose of build triggers) 

      Am I doing something wrong, or is this a feature request?

        Attachments

          Activity

          Hide
          abayer Andrew Bayer added a comment -

          Is this with Git or Mercurial?

          Show
          abayer Andrew Bayer added a comment - Is this with Git or Mercurial?
          Hide
          maniacmouse Andréas Berg added a comment -

          We've got the same issue and we are using Git.

          Show
          maniacmouse Andréas Berg added a comment - We've got the same issue and we are using Git.
          Hide
          maniacmouse Andréas Berg added a comment -

          Why is this set as a minor improvement?

          Should be a major bug in my opinion.

          Show
          maniacmouse Andréas Berg added a comment - Why is this set as a minor improvement? Should be a major bug in my opinion.
          Hide
          jeubank Josiah Eubank added a comment -

          If I'm not mistaken, this is just configuring the webhook manually to send a trigger on PR merge

          Show
          jeubank Josiah Eubank added a comment - If I'm not mistaken, this is just configuring the webhook manually to send a trigger on PR merge
          Hide
          maniacmouse Andréas Berg added a comment -

          This is a rather old issue. I've not investigated it for quite some time but I've seen indications that this might be working now.

          Show
          maniacmouse Andréas Berg added a comment - This is a rather old issue. I've not investigated it for quite some time but I've seen indications that this might be working now.
          Hide
          jack_white Jack White added a comment - - edited

          We are seeing the same issue on Jenkins 2.93 with version 2.2.9 of the plugin

          We can see in the events log the following when the hook is triggered from a merge

          [Thu Aug 16 12:27:19 GMT 2018] Received com.cloudbees.jenkins.plugins.bitbucket.hooks.PullRequestHookProcessor$1 REMOVED event from 10.20.0.11 ⇒ https://{jenkins-url}/bitbucket-scmsource-hook/notify with timestamp Thu Aug 16 12:27:19 GMT 2018
          Connecting to https://{bitbucket-url} using *******/****** (Bitbucket credentials for API requests)
          Repository type: Git
          Looking up HELMDEPL/ipt-envconfig-global for branches
          Checking branch master from HELMDEPL/ipt-envconfig-global
          Checking branch CASE-10236 from HELMDEPL/ipt-envconfig-global
          
            2 branches were processed
          Looking up HELMDEPL/ipt-envconfig-global for pull requests
          
            0 pull requests were processed
          [Thu Aug 16 12:27:20 GMT 2018] com.cloudbees.jenkins.plugins.bitbucket.hooks.PullRequestHookProcessor$1 REMOVED event from 10.20.0.11 ⇒ https://{jenkins-url}/bitbucket-scmsource-hook/notify with timestamp Thu Aug 16 12:27:19 GMT 2018 processed in 1.4 sec

          This was after a PR merge from Branch CASE-10236 -> master
          The job for master did not trigger after the merge and had to be ran manually

          Further digging and the issue may be related to: https://mohamicorp.atlassian.net/browse/JENK-248

          Show
          jack_white Jack White added a comment - - edited We are seeing the same issue on Jenkins 2.93 with version 2.2.9 of the plugin We can see in the events log the following when the hook is triggered from a merge [Thu Aug 16 12:27:19 GMT 2018] Received com.cloudbees.jenkins.plugins.bitbucket.hooks.PullRequestHookProcessor$1 REMOVED event from 10.20.0.11 ⇒ https: //{jenkins-url}/bitbucket-scmsource-hook/notify with timestamp Thu Aug 16 12:27:19 GMT 2018 Connecting to https: //{bitbucket-url} using *******/****** (Bitbucket credentials for API requests) Repository type: Git Looking up HELMDEPL/ipt-envconfig-global for branches Checking branch master from HELMDEPL/ipt-envconfig-global Checking branch CASE-10236 from HELMDEPL/ipt-envconfig-global 2 branches were processed Looking up HELMDEPL/ipt-envconfig-global for pull requests 0 pull requests were processed [Thu Aug 16 12:27:20 GMT 2018] com.cloudbees.jenkins.plugins.bitbucket.hooks.PullRequestHookProcessor$1 REMOVED event from 10.20.0.11 ⇒ https: //{jenkins-url}/bitbucket-scmsource-hook/notify with timestamp Thu Aug 16 12:27:19 GMT 2018 processed in 1.4 sec This was after a PR merge from Branch CASE-10236 -> master The job for master did not trigger after the merge and had to be ran manually Further digging and the issue may be related to:  https://mohamicorp.atlassian.net/browse/JENK-248

            People

            • Assignee:
              Unassigned
              Reporter:
              chadmott chad mott
            • Votes:
              3 Vote for this issue
              Watchers:
              9 Start watching this issue

              Dates

              • Created:
                Updated: