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

With lazy-build loading estimated build duration may become expensive

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      With lazy-build loading the computation for the estimated duration may become expensive:

      • it searches of the last 3 unstable (or better) builds to compute the runtime.
        In the (not very probable, but still possible) that there are a lot of builds and less than 3 have been unstable, it can be very expensive to lookup the builds.

      Limit the number to build to go back in time and maybe also consider failed builds in the calculation

        Attachments

          Issue Links

            Activity

            Hide
            kutzi kutzi added a comment - - edited
            Show
            kutzi kutzi added a comment - - edited See pull request https://github.com/jenkinsci/jenkins/pull/837
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Kohsuke Kawaguchi
            Path:
            core/src/main/java/hudson/model/Job.java
            core/src/main/java/hudson/model/Result.java
            maven-plugin/src/main/java/hudson/maven/MavenModuleSet.java
            maven-plugin/src/main/java/hudson/maven/MavenModuleSetBuild.java
            test/src/test/java/hudson/model/SimpleJobTest.java
            http://jenkins-ci.org/commit/jenkins/12e9a55c39b0e8db47578fbc9f7ff87cf25fca93
            Log:
            Merge pull request #837 from kutzi/estimated-time

            [FIXED JENKINS-18196] Change to the estimated duratrion calculation to prevent performance issues with lazy build loading

            Compare: https://github.com/jenkinsci/jenkins/compare/84388823d5c3...12e9a55c39b0

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Kohsuke Kawaguchi Path: core/src/main/java/hudson/model/Job.java core/src/main/java/hudson/model/Result.java maven-plugin/src/main/java/hudson/maven/MavenModuleSet.java maven-plugin/src/main/java/hudson/maven/MavenModuleSetBuild.java test/src/test/java/hudson/model/SimpleJobTest.java http://jenkins-ci.org/commit/jenkins/12e9a55c39b0e8db47578fbc9f7ff87cf25fca93 Log: Merge pull request #837 from kutzi/estimated-time [FIXED JENKINS-18196] Change to the estimated duratrion calculation to prevent performance issues with lazy build loading Compare: https://github.com/jenkinsci/jenkins/compare/84388823d5c3...12e9a55c39b0
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Christoph Kutzinski
            Path:
            core/src/main/java/hudson/model/Job.java
            core/src/main/java/hudson/model/Result.java
            maven-plugin/src/main/java/hudson/maven/MavenModuleSetBuild.java
            test/src/test/java/hudson/model/SimpleJobTest.java
            http://jenkins-ci.org/commit/jenkins/693ee2ac76d97b13fd65e0c1391858c6dfbc83fb
            Log:
            [FIXED JENKINS-18196] Loading the last 3 successful builds may be very expensive in certain rare, but possible situations (all newer builds failed, only some very old builds were successful).
            Go only up to 6 build into the past for calculating the estimated duration.
            Also take failed builds into account, if we don't find any successful ones.
            (cherry picked from commit 04d85eb476bdc57eb7ac3c2bb34e91be5b55c487)

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Christoph Kutzinski Path: core/src/main/java/hudson/model/Job.java core/src/main/java/hudson/model/Result.java maven-plugin/src/main/java/hudson/maven/MavenModuleSetBuild.java test/src/test/java/hudson/model/SimpleJobTest.java http://jenkins-ci.org/commit/jenkins/693ee2ac76d97b13fd65e0c1391858c6dfbc83fb Log: [FIXED JENKINS-18196] Loading the last 3 successful builds may be very expensive in certain rare, but possible situations (all newer builds failed, only some very old builds were successful). Go only up to 6 build into the past for calculating the estimated duration. Also take failed builds into account, if we don't find any successful ones. (cherry picked from commit 04d85eb476bdc57eb7ac3c2bb34e91be5b55c487)
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Christoph Kutzinski
            Path:
            core/src/main/java/hudson/model/Job.java
            maven-plugin/src/main/java/hudson/maven/MavenModuleSetBuild.java
            http://jenkins-ci.org/commit/jenkins/6244e51a7466ac8bf74a86a57b44232cdb5f7b18
            Log:
            [FIXED JENKINS-18196] fixed typo
            (cherry picked from commit 5ce7ea0f048bb7330ac4ca642812a43e6a49d67b)

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Christoph Kutzinski Path: core/src/main/java/hudson/model/Job.java maven-plugin/src/main/java/hudson/maven/MavenModuleSetBuild.java http://jenkins-ci.org/commit/jenkins/6244e51a7466ac8bf74a86a57b44232cdb5f7b18 Log: [FIXED JENKINS-18196] fixed typo (cherry picked from commit 5ce7ea0f048bb7330ac4ca642812a43e6a49d67b)
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Christoph Kutzinski
            Path:
            core/src/main/java/hudson/model/Job.java
            maven-plugin/src/main/java/hudson/maven/MavenModuleSet.java
            http://jenkins-ci.org/commit/jenkins/0b5f6b28007780ffff1cbe2b6df5ea60643f3338
            Log:
            [FIXED JENKINS-18196] reduce visibility of getEstimatedDurationCandidates to protected
            (cherry picked from commit e77441f6f1483679c600fe29ec2e39d1e36cf1a9)

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Christoph Kutzinski Path: core/src/main/java/hudson/model/Job.java maven-plugin/src/main/java/hudson/maven/MavenModuleSet.java http://jenkins-ci.org/commit/jenkins/0b5f6b28007780ffff1cbe2b6df5ea60643f3338 Log: [FIXED JENKINS-18196] reduce visibility of getEstimatedDurationCandidates to protected (cherry picked from commit e77441f6f1483679c600fe29ec2e39d1e36cf1a9)
            Hide
            scm_issue_link SCM/JIRA link daemon added a comment -

            Code changed in jenkins
            User: Kohsuke Kawaguchi
            Path:
            src/main/java/hudson/maven/MavenModuleSet.java
            src/main/java/hudson/maven/MavenModuleSetBuild.java
            http://jenkins-ci.org/commit/maven-plugin/ad5401e93a868ec4574cd80dd14fc27728fce1a9
            Log:
            Merge pull request #837 from kutzi/estimated-time

            [FIXED JENKINS-18196] Change to the estimated duratrion calculation to prevent performance issues with lazy build loading
            Originally-Committed-As: 12e9a55c39b0e8db47578fbc9f7ff87cf25fca93

            Show
            scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Kohsuke Kawaguchi Path: src/main/java/hudson/maven/MavenModuleSet.java src/main/java/hudson/maven/MavenModuleSetBuild.java http://jenkins-ci.org/commit/maven-plugin/ad5401e93a868ec4574cd80dd14fc27728fce1a9 Log: Merge pull request #837 from kutzi/estimated-time [FIXED JENKINS-18196] Change to the estimated duratrion calculation to prevent performance issues with lazy build loading Originally-Committed-As: 12e9a55c39b0e8db47578fbc9f7ff87cf25fca93

              People

              • Assignee:
                kutzi kutzi
                Reporter:
                kutzi kutzi
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: