当前位置: 首页>>代码示例>>Java>>正文


Java BuildFinishedStatus.INTERRUPTED属性代码示例

本文整理汇总了Java中jetbrains.buildServer.agent.BuildFinishedStatus.INTERRUPTED属性的典型用法代码示例。如果您正苦于以下问题:Java BuildFinishedStatus.INTERRUPTED属性的具体用法?Java BuildFinishedStatus.INTERRUPTED怎么用?Java BuildFinishedStatus.INTERRUPTED使用的例子?那么, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在jetbrains.buildServer.agent.BuildFinishedStatus的用法示例。


在下文中一共展示了BuildFinishedStatus.INTERRUPTED属性的9个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: waitBuildFinish

public BuildFinishedStatus waitBuildFinish()
        throws InterruptedException {
    boolean buildFinished = false;
    Build childBuild = null;
    while (!buildFinished && !canceled) {
        childBuild = buildsResource.serveBuild(build.getBuildId().toString(), "");
        buildFinished = isBuildFinished(childBuild);
        Thread.sleep(100L);
    }
    buildProgressLogger.message("Build " + build.getBuildId()
            + " is finished with success");
    if (!canceled) {
        if (childBuild.getStatus().equalsIgnoreCase(BuildStatusConst.ERROR)
                || childBuild.getStatus().equalsIgnoreCase(BuildStatusConst.FAILURE)) {
            return BuildFinishedStatus.FINISHED_WITH_PROBLEMS;
        }
    }
    return canceled ? BuildFinishedStatus.INTERRUPTED : BuildFinishedStatus.FINISHED_SUCCESS;
}
 
开发者ID:presidentio,项目名称:teamcity-matrix-build-plugin,代码行数:19,代码来源:QueuedBuild.java

示例2: waitFor

@NotNull
@Override
public BuildFinishedStatus waitFor() throws RunBuildException {
    while (!isInterrupted && !isFinished) {
        try {
            Thread.sleep(1000);
        } catch (InterruptedException e) {
            throw new RunBuildException(e);
        }
    }

    // MUDO BuildFinishedStatus.FINISHED_WITH_PROBLEMS ??

    return isFinished
            ? (isFailed ? BuildFinishedStatus.FINISHED_FAILED : BuildFinishedStatus.FINISHED_SUCCESS)
            : BuildFinishedStatus.INTERRUPTED;
}
 
开发者ID:rvdginste,项目名称:todo-teamcity-plugin,代码行数:17,代码来源:AbstractBuildProcessAdapter.java

示例3: waitForImpl

@NotNull
protected BuildFinishedStatus waitForImpl() throws RunBuildException {
  if (isInterrupted()) return BuildFinishedStatus.INTERRUPTED;
  for (BuildProcess proc = myProcessList.poll(); proc != null; proc = myProcessList.poll()) {
    myCurrentProcess.set(proc);
    try {
      proc.start();
      final BuildFinishedStatus status = proc.waitFor();
      if (status != BuildFinishedStatus.INTERRUPTED && status != BuildFinishedStatus.FINISHED_SUCCESS) return status;
    } finally {
      myCurrentProcess.set(null);
    }
    if (isInterrupted()) return BuildFinishedStatus.INTERRUPTED;
  }
  if (isInterrupted()) return BuildFinishedStatus.INTERRUPTED;
  return BuildFinishedStatus.FINISHED_SUCCESS;
}
 
开发者ID:jonnyzzz,项目名称:TeamCity.Virtual,代码行数:17,代码来源:CompositeBuildProcessImpl.java

示例4: waitFor

@Override
public @NotNull BuildFinishedStatus waitFor() throws RunBuildException {
    while (!isInterrupted() && !hasFinished) {
        try {
            Thread.sleep(1000);
        } catch (InterruptedException e) {
            throw new RunBuildException(e);
        }
    }
    return hasFinished ?
            hasFailed ? BuildFinishedStatus.FINISHED_FAILED :
                    BuildFinishedStatus.FINISHED_SUCCESS :
            BuildFinishedStatus.INTERRUPTED;
}
 
开发者ID:gonzadocarmo,项目名称:teamcity-s3-plugin,代码行数:14,代码来源:AWSS3BuildProcessAdapter.java

示例5: waitFor

@NotNull
@Override
public BuildFinishedStatus waitFor() throws RunBuildException {
    try {
        processThread.join();
        return buildFinishedStatus;
    } catch (InterruptedException e) {
        buildRunnerContext.getBuild().getBuildLogger().error("Failed on waiting process finished");
        buildRunnerContext.getBuild().getBuildLogger().exception(e);
        return BuildFinishedStatus.INTERRUPTED;
    }
}
 
开发者ID:presidentio,项目名称:teamcity-matrix-build-plugin,代码行数:12,代码来源:MatrixBuildProcess.java

示例6: waitFor

@NotNull
@Override
public BuildFinishedStatus waitFor() throws RunBuildException {
  while (!isInterrupted() && !hasFinished) {
    try {
      Thread.sleep(1000);
    } catch (InterruptedException e) {
      throw new RunBuildException(e);
    }
  }
  return hasFinished ? statusCode : BuildFinishedStatus.INTERRUPTED;
}
 
开发者ID:JetBrains,项目名称:teamcity-deployer-plugin,代码行数:12,代码来源:SyncBuildProcessAdapter.java

示例7: waitFor

@NotNull
@Override
public BuildFinishedStatus waitFor() throws RunBuildException {
    try {
        processThread.join();
        afterProcessSuccessfullyFinished();
        return buildFinishedStatus;
    } catch (InterruptedException e) {
        buildRunnerContext.getBuild().getBuildLogger().exception(e);
        LOGGER.error("Failed on waiting process finished", e);
        return BuildFinishedStatus.INTERRUPTED;
    }
}
 
开发者ID:presidentio,项目名称:teamcity-plugin-jmh,代码行数:13,代码来源:JmhBuildProcess.java

示例8: waitFor

@NotNull
public final BuildFinishedStatus waitFor() throws RunBuildException {
  try {
    if (isInterrupted()) return BuildFinishedStatus.INTERRUPTED;
    BuildFinishedStatus status = waitForImpl();
    if (isInterrupted()) return BuildFinishedStatus.INTERRUPTED;

    return status;
  } finally {
    myIsFinished.set(true);
  }
}
 
开发者ID:jonnyzzz,项目名称:TeamCity.Virtual,代码行数:12,代码来源:BuildProcessBase.java

示例9: waitForImpl

@NotNull
@Override
protected final BuildFinishedStatus waitForImpl() throws RunBuildException {
  try {
    final BuildProcess process = myAction.startImpl();
    myReference.set(process);

    if (isInterrupted()) return BuildFinishedStatus.INTERRUPTED;
    process.start();
    return process.waitFor();
  } finally {
    myReference.set(null);
    myAction.finishedImpl();
  }
}
 
开发者ID:jonnyzzz,项目名称:TeamCity.Virtual,代码行数:15,代码来源:DelegatingBuildProcess.java


注:本文中的jetbrains.buildServer.agent.BuildFinishedStatus.INTERRUPTED属性示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。