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

Run.getPrevious/getNext build do not work for non-AbstractBuild's

    XMLWordPrintable

Details

    Description

      In 1.480.3 if you create an external monitor job, and do three builds, then go the the latest (#3), you will see a Previous Build link as expected. But in newer cores you will not see this link, even though all three builds appear in Build History.

      The reason is that there is nothing actually writing to the previousBuild or nextBuild fields, contrary to their Javadoc: RunMap does not touch them. (dropLinks would update them after deleting a build, if they were not null to begin with, but they are.)

      Attachments

        Activity

          jglick Jesse Glick created issue -

          Code changed in jenkins
          User: Jesse Glick
          Path:
          core/src/main/java/hudson/model/AbstractBuild.java
          core/src/main/java/hudson/model/Run.java
          core/src/main/java/hudson/model/RunMap.java
          http://jenkins-ci.org/commit/jenkins/f024f59058fd8475b78fbb09b23a121e695a1ae1
          Log:
          Making RunMap work properly for non-AbstractProject-based jobs using lazy loading.
          JENKINS-22052 is not fixed by this for existing Job types like ExternalJob which still do not use lazy loading.

          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Jesse Glick Path: core/src/main/java/hudson/model/AbstractBuild.java core/src/main/java/hudson/model/Run.java core/src/main/java/hudson/model/RunMap.java http://jenkins-ci.org/commit/jenkins/f024f59058fd8475b78fbb09b23a121e695a1ae1 Log: Making RunMap work properly for non-AbstractProject-based jobs using lazy loading. JENKINS-22052 is not fixed by this for existing Job types like ExternalJob which still do not use lazy loading.
          danielbeck Daniel Beck made changes -
          Field Original Value New Value
          Link This issue is related to JENKINS-20662 [ JENKINS-20662 ]
          jglick Jesse Glick made changes -
          Link This issue is related to JENKINS-20662 [ JENKINS-20662 ]
          rtyler R. Tyler Croy made changes -
          Workflow JNJira [ 154131 ] JNJira + In-Review [ 178702 ]

          People

            kohsuke Kohsuke Kawaguchi
            jglick Jesse Glick
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated: