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

CauseOfBlockage from QueueTaskDispatcher.canTake discarded

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • core

      If you have a QueueTaskDispatcher which returns a CauseOfBlockage from canRun, that becomes BlockedItem.getCauseOfBlockage, which is displayed in the queue widget.

      But if it returns a CauseOfBlockage from canTake (AFAICT the same for Node.canTake), JobOffer.canTake sees that it is non-null, throws out the actual object with all of its diagnostics, and you wind up with a BuildableItem with CauseOfBlockage.BecauseNodeIsBusy which tells you nothing and may be totally misleading.

      By asking an implementation to return a @CheckForNull CauseOfBlockage rather than a simple boolean, the implication is that a non-null return value will be displayed to the user. Currently this is not the case.

      To add insult to injury, Support Core does not report the result of canTake.

          [JENKINS-38514] CauseOfBlockage from QueueTaskDispatcher.canTake discarded

          Jesse Glick created issue -
          Jesse Glick made changes -
          Link New: This issue relates to JENKINS-35403 [ JENKINS-35403 ]
          Jesse Glick made changes -
          Component/s New: support-core-plugin [ 18146 ]
          Jesse Glick made changes -
          Component/s Original: support-core-plugin [ 18146 ]
          Jesse Glick made changes -
          Assignee New: Jesse Glick [ jglick ]
          Jesse Glick made changes -
          Status Original: Open [ 1 ] New: In Progress [ 3 ]
          Jesse Glick made changes -
          Remote Link New: This issue links to "PR 2651 (Web Link)" [ 15074 ]
          Jesse Glick made changes -
          Status Original: In Progress [ 3 ] New: In Review [ 10005 ]
          Jesse Glick made changes -
          Link New: This issue relates to JENKINS-6598 [ JENKINS-6598 ]
          Jesse Glick made changes -
          Resolution New: Fixed [ 1 ]
          Status Original: In Review [ 10005 ] New: Resolved [ 5 ]
          Oleg Nenashev made changes -
          Link New: This issue is related to JENKINS-45927 [ JENKINS-45927 ]

            jglick Jesse Glick
            jglick Jesse Glick
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: