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

On first index after upgrade to 2.0.0 all open PRs are rebuilt


    • Similar Issues:


      See https://github.com/jenkinsci/bitbucket-branch-source-plugin/blob/470cd820d33002661370f34e4b6b739560ad9c7c/src/main/java/com/cloudbees/jenkins/plugins/bitbucket/SCMHeadWithOwnerAndRepo.java#L65-L67

      Now that there is the SCMHeadMigration API we can attempt to fix the issue during item loading by querying bitbucket to get the list of targets for each PR (which was not possible from readResolve() as the head does not contain details of the target repository so we cannot look up the target branch in the target repository! (However once we have the SCMSource we can ask the target repository for the target branch of the PR with id = XYZ and all is right in the world again)

      NOTE If the connection to BitBucket fails while Jenkins is loading all the jobs, a rebuild will be triggered on the next index as failing to load the job (the only alternative) would not only trigger a rebuild anyway, but would also overwrite old builds... hence it is the lesser of two evils.


          Issue Links


            stephenconnolly Stephen Connolly created issue -
            stephenconnolly Stephen Connolly made changes -
            Field Original Value New Value
            Epic Link JENKINS-41234 [ 177999 ]
            amuniz Antonio Muñiz made changes -
            Status Open [ 1 ] Resolved [ 5 ]
            Resolution Fixed [ 1 ]
            stephenconnolly Stephen Connolly made changes -
            Status Resolved [ 5 ] Closed [ 6 ]
            cloudbees CloudBees Inc. made changes -
            Remote Link This issue links to "CloudBees Internal OSS-1901 (Web Link)" [ 18521 ]


              • Assignee:
                stephenconnolly Stephen Connolly
                stephenconnolly Stephen Connolly
              • Votes:
                0 Vote for this issue
                2 Start watching this issue


                • Created: