@Override public BallColor getIconColor() { if(isDisabled()) return isBuilding() ? BallColor.DISABLED_ANIME : BallColor.DISABLED; else return super.getIconColor(); }
/** * Returns the project if any of the upstream project is either * building or is in the queue. * <p> * This means eventually there will be an automatic triggering of * the given project (provided that all builds went smoothly.) */ public AbstractProject getBuildingUpstream() { Set<Task> unblockedTasks = Jenkins.getInstance().getQueue().getUnblockedTasks(); for (AbstractProject tup : getTransitiveUpstreamProjects()) { if (tup!=this && (tup.isBuilding() || unblockedTasks.contains(tup))) return tup; } return null; }
/** * Returns the project if any of the downstream project is either * building, waiting, pending or buildable. * <p> * This means eventually there will be an automatic triggering of * the given project (provided that all builds went smoothly.) */ public AbstractProject getBuildingDownstream() { Set<Task> unblockedTasks = Jenkins.getInstance().getQueue().getUnblockedTasks(); for (AbstractProject tup : getTransitiveDownstreamProjects()) { if (tup!=this && (tup.isBuilding() || unblockedTasks.contains(tup))) return tup; } return null; }
@Override public BallColor getIconColor() { if(isDisabled()) return isBuilding() ? BallColor.DISABLED_ANIME : BallColor.DISABLED; else return super.getIconColor(); }
@JellyAccessible public boolean isBuilding() { return getProject().isBuilding(); }
/** * Returns the project if any of the downstream project (or itself) is * either building or is in the unblocked queue. <p> This means eventually * there will be an automatic triggering of the given project (provided that * all builds went smoothly.) */ public AbstractProject getBuildingDownstream() { Set<Task> unblockedTasks = Hudson.getInstance().getQueue().getUnblockedTasks(); for (AbstractProject tup : getTransitiveDownstreamProjects()) { if (tup!=this && (tup.isBuilding() || unblockedTasks.contains(tup))) return tup; } return null; }
/** * Returns the project if any of the downstream project is either * building, waiting, pending or buildable. * <p> * This means eventually there will be an automatic triggering of * the given project (provided that all builds went smoothly.) */ public AbstractProject getBuildingDownstream() { Set<Task> unblockedTasks = Jenkins.getInstance().getQueue().getUnblockedTasks(); for (AbstractProject tup : getTransitiveDownstreamProjects()) { if (tup!=this && (tup.isBuilding() || unblockedTasks.contains(tup))) return tup; } return null; }
/** * Returns the project if any of the upstream project (or itself) is either * building or is in the unblocked queue. <p> This means eventually there * will be an automatic triggering of the given project (provided that all * builds went smoothly.) */ public AbstractProject getBuildingUpstream() { Set<Task> unblockedTasks = Hudson.getInstance().getQueue().getUnblockedTasks(); for (AbstractProject tup : getTransitiveUpstreamProjects()) { if (tup!=this && (tup.isBuilding() || unblockedTasks.contains(tup))) return tup; } return null; }
/** * Returns the project if any of the upstream project is either * building or is in the queue. * <p> * This means eventually there will be an automatic triggering of * the given project (provided that all builds went smoothly.) */ public AbstractProject getBuildingUpstream() { Set<Task> unblockedTasks = Jenkins.getInstance().getQueue().getUnblockedTasks(); for (AbstractProject tup : getTransitiveUpstreamProjects()) { if (tup!=this && (tup.isBuilding() || unblockedTasks.contains(tup))) return tup; } return null; }
/** * Returns the project if any of the downstream project (or itself) is either * building or is in the unblocked queue. * <p> * This means eventually there will be an automatic triggering of * the given project (provided that all builds went smoothly.) */ protected AbstractProject getBuildingDownstream() { DependencyGraph graph = Hudson.getInstance().getDependencyGraph(); Set<AbstractProject> tups = graph.getTransitiveDownstream(this); tups.add(this); for (AbstractProject tup : tups) { if(tup!=this && (tup.isBuilding() || tup.isInUnblockedQueue())) return tup; } return null; }
/** * Returns the project if any of the downstream project (or itself) is either * building or is in the unblocked queue. * <p> * This means eventually there will be an automatic triggering of * the given project (provided that all builds went smoothly.) */ protected AbstractProject getBuildingDownstream() { DependencyGraph graph = Hudson.getInstance().getDependencyGraph(); Set<AbstractProject> tups = graph.getTransitiveDownstream(this); tups.add(this); for (AbstractProject tup : tups) { if(tup!=this && (tup.isBuilding() || tup.isInUnblockedQueue())) return tup; } return null; }
/** * Returns the project if any of the upstream project (or itself) is either * building or is in the unblocked queue. * <p> * This means eventually there will be an automatic triggering of * the given project (provided that all builds went smoothly.) */ protected AbstractProject getBuildingUpstream() { DependencyGraph graph = Hudson.getInstance().getDependencyGraph(); Set<AbstractProject> tups = graph.getTransitiveUpstream(this); tups.add(this); for (AbstractProject tup : tups) { if(tup!=this && (tup.isBuilding() || tup.isInUnblockedQueue())) return tup; } return null; }
/** * Returns the project if any of the upstream project (or itself) is either * building or is in the unblocked queue. <p> This means eventually there * will be an automatic triggering of the given project (provided that all * builds went smoothly.) */ protected AbstractProject getBuildingUpstream() { DependencyGraph graph = Hudson.getInstance().getDependencyGraph(); Set<AbstractProject> tups = graph.getTransitiveUpstream(this); tups.add(this); for (AbstractProject tup : tups) { if (tup != this && (tup.isBuilding() || tup.isInUnblockedQueue())) { return tup; } } return null; }
/** * Returns jobs that running on current computer. * * @return List<AbstractProject>. */ @Exported public List<AbstractProject> getRunningJobs() { List<AbstractProject> jobs = new ArrayList<AbstractProject>(); Queue queue = Hudson.getInstance().getQueue(); if (getTiedJobs() != null) { for (AbstractProject project : getTiedJobs()) { if (project.isBuilding() || queue.contains(project)) { jobs.add(project); } } } return jobs; }
/** * Returns jobs that running on current computer. * @return List<AbstractProject>. */ @Exported public List<AbstractProject> getRunningJobs() { List<AbstractProject> jobs = new ArrayList<AbstractProject>(); Queue queue = Hudson.getInstance().getQueue(); if (getTiedJobs() != null) { for (AbstractProject project : getTiedJobs()) { if (project.isBuilding() || queue.contains(project)) { jobs.add(project); } } } return jobs; }
public CauseOfBlockage getCauseOfBlockage() { if (isBuilding() && !isConcurrentBuild()) return new BecauseOfBuildInProgress(getLastBuild()); if (blockBuildWhenDownstreamBuilding()) { AbstractProject<?,?> bup = getBuildingDownstream(); if (bup!=null) return new BecauseOfDownstreamBuildInProgress(bup); } if (blockBuildWhenUpstreamBuilding()) { AbstractProject<?,?> bup = getBuildingUpstream(); if (bup!=null) return new BecauseOfUpstreamBuildInProgress(bup); } return null; }
@Override public CauseOfBlockage getCauseOfBlockage() { CauseOfBlockage cob = super.getCauseOfBlockage(); if (cob != null) return cob; if (!getParent().isAggregatorStyleBuild()) { DependencyGraph graph = Hudson.getInstance().getDependencyGraph(); for (AbstractProject tup : graph.getTransitiveUpstream(this)) { if(getParent() == tup.getParent() && (tup.isBuilding() || tup.isInQueue())) return new BecauseOfUpstreamModuleBuildInProgress(tup); } } return null; }
public CauseOfBlockage getCauseOfBlockage() { if (isBuilding() && !isConcurrentBuild()) return new BecauseOfBuildInProgress(getLastBuild()); if (blockBuildWhenDownstreamBuilding()) { AbstractProject<?,?> bup = getBuildingDownstream(); if (bup!=null) return new BecauseOfDownstreamBuildInProgress(bup); } if (blockBuildWhenUpstreamBuilding()) { AbstractProject<?,?> bup = getBuildingUpstream(); if (bup!=null) return new BecauseOfUpstreamBuildInProgress(bup); } return null; }
@Override public CauseOfBlockage getCauseOfBlockage() { CauseOfBlockage cob = super.getCauseOfBlockage(); if (cob != null) return cob; if (!getParent().isAggregatorStyleBuild()) { DependencyGraph graph = Hudson.getInstance().getDependencyGraph(); for (AbstractProject tup : graph.getTransitiveUpstream(this)) { if(getParent() == tup.getParent() && (tup.isBuilding() || tup.isInQueue())) return new BecauseOfUpstreamModuleBuildInProgress(tup); } } return null; }
@Override public CauseOfBlockage getCauseOfBlockage() { CauseOfBlockage cob = super.getCauseOfBlockage(); if (cob != null) return cob; if (!getParent().isAggregatorStyleBuild()) { DependencyGraph graph = Hudson.getInstance().getDependencyGraph(); for (AbstractProject tup : graph.getTransitiveUpstream(this)) { if(getParent() == tup.getParent() && (tup.isBuilding() || tup.isInQueue())) return new BecauseOfUpstreamModuleBuildInProgress(tup); } } return null; }