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

monitoring jenkins agents "build queue length" inconsistent with server dashboard

      The jenkins monitoring "agent" would display the following (relative url: /monitoring/nodes?period=jour):

      While the server dashboard (releative url /) would display something like:

      We would like to have the Build Queue size tracked by monitoring.  Currently, jenkins monitoring "agents" "build queue length" does not reflect the build queue size.  The dashboard is verifiably correct because the jobs on the queue are listed.

          [JENKINS-69785] monitoring jenkins agents "build queue length" inconsistent with server dashboard

          peng wu created issue -
          peng wu made changes -
          Description Original: The jekins monitoring agent would display the following (relative url: /monitoring/nodes?period=jour):

          !image-2022-10-05-14-19-47-200.png!

          While the server dashboard (releative url /) would display something like (which is correct):

          !image-2022-10-05-14-24-13-696.png!

          We would like to have something monitoring the Build Queue size as showing in monitoring.  Currently, monitoring jenkins agents "build queue length" does not reflect the build queue length on the dashboard, which is verifiably correct because the jobs on the queue is listed right  below.
          New: The jenkins monitoring "agent" would display the following (relative url: /monitoring/nodes?period=jour):

          !image-2022-10-05-14-19-47-200.png!

          While the server dashboard (releative url /) would display something like:

          !image-2022-10-05-14-24-13-696.png!

          We would like to have the Build Queue size showing on dashboard tracked by monitoring.  Currently, jenkins monitoring "agents" "build queue length" does not reflect the build queue size, much smaller.  The dashboard is verifiably correct because the jobs on the queue are listed.
          peng wu made changes -
          Description Original: The jenkins monitoring "agent" would display the following (relative url: /monitoring/nodes?period=jour):

          !image-2022-10-05-14-19-47-200.png!

          While the server dashboard (releative url /) would display something like:

          !image-2022-10-05-14-24-13-696.png!

          We would like to have the Build Queue size showing on dashboard tracked by monitoring.  Currently, jenkins monitoring "agents" "build queue length" does not reflect the build queue size, much smaller.  The dashboard is verifiably correct because the jobs on the queue are listed.
          New: The jenkins monitoring "agent" would display the following (relative url: /monitoring/nodes?period=jour):

          !image-2022-10-05-14-19-47-200.png!

          While the server dashboard (releative url /) would display something like:

          !image-2022-10-05-14-24-13-696.png!

          We would like to have the Build Queue size tracked by monitoring.  Currently, jenkins monitoring "agents" "build queue length" does not reflect the build queue size.  The dashboard is verifiably correct because the jobs on the queue are listed.

          evernat added a comment -

          In the monitoring plugin, the NodesCollector class uses Jenkins.getInstance().getQueue().getBuildableItems().size(), including buildable and pending items. The monitoring plugin currently counts the items in queue like the Load Statistics in the /manage/load-statistics page.

          While the UI probably uses Jenkins.getInstance().getQueue().getItems().length including blocked and waiting items.

          The difference you see is probably the blocked items count.

          evernat added a comment - In the monitoring plugin, the NodesCollector class uses Jenkins.getInstance().getQueue().getBuildableItems().size() , including buildable and pending items. The monitoring plugin currently counts the items in queue like the Load Statistics in the /manage/load-statistics page. While the UI probably uses Jenkins.getInstance().getQueue().getItems().length including blocked and waiting items. The difference you see is probably the blocked items count.

          evernat added a comment -

          fixed by https://github.com/jenkinsci/monitoring-plugin/commit/b5e1a9732681e1b694ad891db4993494b3f7e00e

          The monitoring plugin will now use Jenkins.getInstance().getQueue().getItems().length instead of Jenkins.getInstance().getQueue().getBuildableItems().size().

          evernat added a comment - fixed by https://github.com/jenkinsci/monitoring-plugin/commit/b5e1a9732681e1b694ad891db4993494b3f7e00e The monitoring plugin will now use Jenkins.getInstance().getQueue().getItems().length instead of Jenkins.getInstance().getQueue().getBuildableItems().size() .
          evernat made changes -
          Resolution New: Fixed [ 1 ]
          Status Original: Open [ 1 ] New: Fixed but Unreleased [ 10203 ]
          evernat made changes -
          Status Original: Fixed but Unreleased [ 10203 ] New: Resolved [ 5 ]

            evernat evernat
            wu105 peng wu
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: