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

Job status not updated in web UI during build

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Component/s: core
    • Environment:
    • Similar Issues:

      Description

      Job status is not updated in the web browser during build. The progress bar appears and the dot starts blinking, but they never move - even when the job is finished. Reloading the page shows proper status (if job is completed) or proper progress (if it is still building).

      Problem observed with latest Firefox and Chrome (other browsers not checked). Inspecting AJAX calls in browser's console reveals that AJAX requests are sent each few seconds and all get 200 OK, but the response body is empty. (On a properly working system the response body is not empty while the job is building).

      jenkins.log shows no error or exception - in fact even at log level 7, it shows nothing about the AJAX call. It just denotes at INFO level that a job is starting, then that it completes.

        Attachments

          Activity

          Hide
          danielbeck Daniel Beck added a comment -

          Matthew Reiter Could you submit this as a PR on GitHub?

          Show
          danielbeck Daniel Beck added a comment - Matthew Reiter Could you submit this as a PR on GitHub?
          Hide
          matthewreiter Matthew Reiter added a comment -

          I've created the pull request: https://github.com/jenkinsci/jenkins/pull/2542

          Show
          matthewreiter Matthew Reiter added a comment - I've created the pull request: https://github.com/jenkinsci/jenkins/pull/2542
          Hide
          scm_issue_link SCM/JIRA link daemon added a comment -

          Code changed in jenkins
          User: Matthew Reiter
          Path:
          core/src/main/java/hudson/widgets/BuildHistoryWidget.java
          core/src/main/java/hudson/widgets/HistoryWidget.java
          core/src/main/resources/hudson/widgets/HistoryWidget/index.jelly
          http://jenkins-ci.org/commit/jenkins/0268b988d5c88cd29be12ed25e95d5bc448c2840
          Log:
          [FIXED JENKINS-31487] (#2542)

          There were two issues preventing the build history from updating properly:
          1) The next build number being fetched wasn't taking into account running builds, so any builds already running when the page is refreshed would be ignored. The fix was to use nextBuildNumberToFetch if it is available (which is the case if there are running builds) and to fall back to the next build otherwise.
          2) The first transient build key (used to clear out builds from the history that are being updated) wasn't being set when the page first loads. This was fixed by making getHistoryPageFilter calculate the value so that it happens in all cases rather than just during the ajax call.

          Show
          scm_issue_link SCM/JIRA link daemon added a comment - Code changed in jenkins User: Matthew Reiter Path: core/src/main/java/hudson/widgets/BuildHistoryWidget.java core/src/main/java/hudson/widgets/HistoryWidget.java core/src/main/resources/hudson/widgets/HistoryWidget/index.jelly http://jenkins-ci.org/commit/jenkins/0268b988d5c88cd29be12ed25e95d5bc448c2840 Log: [FIXED JENKINS-31487] (#2542) There were two issues preventing the build history from updating properly: 1) The next build number being fetched wasn't taking into account running builds, so any builds already running when the page is refreshed would be ignored. The fix was to use nextBuildNumberToFetch if it is available (which is the case if there are running builds) and to fall back to the next build otherwise. 2) The first transient build key (used to clear out builds from the history that are being updated) wasn't being set when the page first loads. This was fixed by making getHistoryPageFilter calculate the value so that it happens in all cases rather than just during the ajax call.
          Hide
          kmandeville Kevin Mandeville added a comment -

          Is there any chance of getting this fix into the 1.x version?

          Show
          kmandeville Kevin Mandeville added a comment - Is there any chance of getting this fix into the 1.x version?
          Hide
          danielbeck Daniel Beck added a comment -

          Is there any chance of getting this fix into the 1.x version?

          We are no longer maintaining any releases of the 1.x line. Regular weekly releases are at 2.25, LTS releases are at 2.19.x.

          Show
          danielbeck Daniel Beck added a comment - Is there any chance of getting this fix into the 1.x version? We are no longer maintaining any releases of the 1.x line. Regular weekly releases are at 2.25, LTS releases are at 2.19.x.

            People

            • Assignee:
              danielbeck Daniel Beck
              Reporter:
              mistoffelees Assen Totin
            • Votes:
              14 Vote for this issue
              Watchers:
              18 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: