hudson.model.Computer.isPartiallyIdle()方法的使用及代码示例

x33g5p2x  于2022-01-18 转载在 其他  
字(1.2k)|赞(0)|评价(0)|浏览(83)

本文整理了Java中hudson.model.Computer.isPartiallyIdle()方法的一些代码示例,展示了Computer.isPartiallyIdle()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Computer.isPartiallyIdle()方法的具体详情如下:
包路径:hudson.model.Computer
类名称:Computer
方法名:isPartiallyIdle

Computer.isPartiallyIdle介绍

[英]Returns true if this computer has some idle executors that can take more workload.
[中]如果此计算机的某些空闲执行器可能会承担更多工作负载,则返回true。

代码示例

代码示例来源:origin: jenkinsci/jenkins

final HashMap<Computer, Integer> availableComputers = new HashMap<>();
for (Computer o : Jenkins.get().getComputers()) {
  if ((o.isOnline() || o.isConnecting()) && o.isPartiallyIdle() && o.isAcceptingTasks()) {
    final int idleExecutors = o.countIdle();
    if (idleExecutors>0)

代码示例来源:origin: org.jenkins-ci.main/jenkins-core

final HashMap<Computer, Integer> availableComputers = new HashMap<Computer, Integer>();
for (Computer o : Jenkins.getInstance().getComputers()) {
  if ((o.isOnline() || o.isConnecting()) && o.isPartiallyIdle() && o.isAcceptingTasks()) {
    final int idleExecutors = o.countIdle();
    if (idleExecutors>0)

代码示例来源:origin: org.eclipse.hudson/hudson-core

CauseOfBlockage c = null;
for (Node node : allNodes) {
  if (node.toComputer().isPartiallyIdle()) {
    c = canTake(node);
    if (c == null) {

相关文章

微信公众号

最新文章

更多