本文整理了Java中hudson.model.Messages._Queue_HudsonIsAboutToShutDown()
方法的一些代码示例,展示了Messages._Queue_HudsonIsAboutToShutDown()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Messages._Queue_HudsonIsAboutToShutDown()
方法的具体详情如下:
包路径:hudson.model.Messages
类名称:Messages
方法名:_Queue_HudsonIsAboutToShutDown
[英]Hudson is about to shut down
[中]哈德逊即将关闭
代码示例来源:origin: jenkinsci/jenkins
public CauseOfBlockage getCauseOfBlockage() {
Jenkins jenkins = Jenkins.getInstance();
if(isBlockedByShutdown(task))
return CauseOfBlockage.fromMessage(Messages._Queue_HudsonIsAboutToShutDown());
List<CauseOfBlockage> causesOfBlockage = transientCausesOfBlockage;
Label label = getAssignedLabel();
List<Node> allNodes = jenkins.getNodes();
if (allNodes.isEmpty())
label = null; // no master/agent. pointless to talk about nodes
if (label != null) {
Set<Node> nodes = label.getNodes();
if (label.isOffline()) {
if (nodes.size() != 1) return new BecauseLabelIsOffline(label);
else return new BecauseNodeIsOffline(nodes.iterator().next());
} else {
if (causesOfBlockage != null && label.getIdleExecutors() > 0) {
return new CompositeCauseOfBlockage(causesOfBlockage);
}
if (nodes.size() != 1) return new BecauseLabelIsBusy(label);
else return new BecauseNodeIsBusy(nodes.iterator().next());
}
} else if (causesOfBlockage != null && new ComputerSet().getIdleExecutors() > 0) {
return new CompositeCauseOfBlockage(causesOfBlockage);
} else {
return CauseOfBlockage.createNeedsMoreExecutor(Messages._Queue_WaitingForNextAvailableExecutor());
}
}
代码示例来源:origin: jenkinsci/jenkins
} else {
LOGGER.log(Level.FINEST, "Item {0} was unable to be made a buildable and is now a blocked item.", topTaskDisplayName);
new BlockedItem(top, CauseOfBlockage.fromMessage(Messages._Queue_HudsonIsAboutToShutDown())).enter(this);
代码示例来源:origin: hudson/hudson-2.x
public CauseOfBlockage getCauseOfBlockage() {
Hudson hudson = Hudson.getInstance();
if(ifBlockedByHudsonShutdown(task))
return CauseOfBlockage.fromMessage(Messages._Queue_HudsonIsAboutToShutDown());
Label label = task.getAssignedLabel();
if (hudson.getNodes().isEmpty())
label = null; // no master/slave. pointless to talk about nodes
if (label != null) {
if (label.isOffline()) {
Set<Node> nodes = label.getNodes();
if (nodes.size() != 1) return new BecauseLabelIsOffline(label);
else return new BecauseNodeIsOffline(nodes.iterator().next());
}
}
if(label==null)
return CauseOfBlockage.fromMessage(Messages._Queue_WaitingForNextAvailableExecutor());
Set<Node> nodes = label.getNodes();
if (nodes.size() != 1) return new BecauseLabelIsBusy(label);
else return new BecauseNodeIsBusy(nodes.iterator().next());
}
代码示例来源:origin: org.jvnet.hudson.main/hudson-core
public CauseOfBlockage getCauseOfBlockage() {
Hudson hudson = Hudson.getInstance();
if(ifBlockedByHudsonShutdown(task))
return CauseOfBlockage.fromMessage(Messages._Queue_HudsonIsAboutToShutDown());
Label label = task.getAssignedLabel();
if (hudson.getNodes().isEmpty())
label = null; // no master/slave. pointless to talk about nodes
if (label != null) {
if (label.isOffline()) {
Set<Node> nodes = label.getNodes();
if (nodes.size() != 1) return new BecauseLabelIsOffline(label);
else return new BecauseNodeIsOffline(nodes.iterator().next());
}
}
if(label==null)
return CauseOfBlockage.fromMessage(Messages._Queue_WaitingForNextAvailableExecutor());
Set<Node> nodes = label.getNodes();
if (nodes.size() != 1) return new BecauseLabelIsBusy(label);
else return new BecauseNodeIsBusy(nodes.iterator().next());
}
代码示例来源:origin: org.eclipse.hudson.main/hudson-core
public CauseOfBlockage getCauseOfBlockage() {
Hudson hudson = Hudson.getInstance();
if(ifBlockedByHudsonShutdown(task))
return CauseOfBlockage.fromMessage(Messages._Queue_HudsonIsAboutToShutDown());
Label label = task.getAssignedLabel();
if (hudson.getNodes().isEmpty())
label = null; // no master/slave. pointless to talk about nodes
if (label != null) {
if (label.isOffline()) {
Set<Node> nodes = label.getNodes();
if (nodes.size() != 1) return new BecauseLabelIsOffline(label);
else return new BecauseNodeIsOffline(nodes.iterator().next());
}
}
if(label==null)
return CauseOfBlockage.fromMessage(Messages._Queue_WaitingForNextAvailableExecutor());
Set<Node> nodes = label.getNodes();
if (nodes.size() != 1) return new BecauseLabelIsBusy(label);
else return new BecauseNodeIsBusy(nodes.iterator().next());
}
代码示例来源:origin: org.jenkins-ci.main/jenkins-core
public CauseOfBlockage getCauseOfBlockage() {
Jenkins jenkins = Jenkins.getInstance();
if(isBlockedByShutdown(task))
return CauseOfBlockage.fromMessage(Messages._Queue_HudsonIsAboutToShutDown());
List<CauseOfBlockage> causesOfBlockage = transientCausesOfBlockage;
Label label = getAssignedLabel();
List<Node> allNodes = jenkins.getNodes();
if (allNodes.isEmpty())
label = null; // no master/agent. pointless to talk about nodes
if (label != null) {
Set<Node> nodes = label.getNodes();
if (label.isOffline()) {
if (nodes.size() != 1) return new BecauseLabelIsOffline(label);
else return new BecauseNodeIsOffline(nodes.iterator().next());
} else {
if (causesOfBlockage != null && label.getIdleExecutors() > 0) {
return new CompositeCauseOfBlockage(causesOfBlockage);
}
if (nodes.size() != 1) return new BecauseLabelIsBusy(label);
else return new BecauseNodeIsBusy(nodes.iterator().next());
}
} else if (causesOfBlockage != null && new ComputerSet().getIdleExecutors() > 0) {
return new CompositeCauseOfBlockage(causesOfBlockage);
} else {
return CauseOfBlockage.createNeedsMoreExecutor(Messages._Queue_WaitingForNextAvailableExecutor());
}
}
代码示例来源:origin: org.eclipse.hudson/hudson-core
Hudson hudson = Hudson.getInstance();
if (ifBlockedByHudsonShutdown(task)) {
return CauseOfBlockage.fromMessage(Messages._Queue_HudsonIsAboutToShutDown());
代码示例来源:origin: org.jenkins-ci.main/jenkins-core
} else {
LOGGER.log(Level.FINEST, "Item {0} was unable to be made a buildable and is now a blocked item.", topTaskDisplayName);
new BlockedItem(top, CauseOfBlockage.fromMessage(Messages._Queue_HudsonIsAboutToShutDown())).enter(this);
内容来源于网络,如有侵权,请联系作者删除!