Skip to content
Permalink
Browse files

[JENKINS-28621] Jenkins jobs get held up in queue waiting for available

executors, even though all are available

Refactored to avoid using apis intruduced in 1.7
  • Loading branch information...
emsa23 committed Jun 6, 2015
1 parent 1e08b07 commit bc5faa9ccbf5a61096af6482f8ebdaa05093926f
Showing with 2 additions and 2 deletions.
  1. +2 −2 src/main/java/jenkins/advancedqueue/sorter/ItemInfo.java
@@ -151,9 +151,9 @@ public ItemStatus getItemStatus() {
public int compareTo(ItemInfo o) {
if(this.getWeight() == o.getWeight()) {
if(this.getSortableInQueueSince() == o.getSortableInQueueSince()) {
return Integer.compare(this.getItemId(), o.getItemId());
return new Integer(this.getItemId()).compareTo(o.getItemId());
}
return Long.compare(this.getInQueueSince(), o.getInQueueSince());
return new Long(this.getInQueueSince()).compareTo(o.getInQueueSince());
}
return Float.compare(this.getWeight(), o.getWeight());
}

0 comments on commit bc5faa9

Please sign in to comment.
You can’t perform that action at this time.