本文整理了Java中hudson.model.Executor.recordCauseOfInterruption()
方法的一些代码示例,展示了Executor.recordCauseOfInterruption()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Executor.recordCauseOfInterruption()
方法的具体详情如下:
包路径:hudson.model.Executor
类名称:Executor
方法名:recordCauseOfInterruption
[英]report cause of interruption and record it to the build, if available.
[中]报告中断原因,并将其记录到构建(如果可用)。
代码示例来源:origin: jenkinsci/jenkins
Executor.currentExecutor().recordCauseOfInterruption(Run.this,listener);
LOGGER.log(Level.INFO, this + " aborted", e);
} catch( Throwable e ) {
代码示例来源:origin: jenkinsci/docker-slaves-plugin
@Override public void interrupt(boolean forShutdown) {
if (forShutdown) {
return;
}
LOGGER.log(FINE, "interrupted {0}", cookie);
// TODO save the BodyExecution somehow and call .cancel() here; currently we just interrupt the build as a whole:
Executor masterExecutor = r.getExecutor();
if (masterExecutor != null) {
masterExecutor.interrupt();
} else { // ?
super.getExecutor().recordCauseOfInterruption(r, listener);
}
}
@Override public boolean blocksRestart() {
代码示例来源:origin: io.jenkins.plugins/docker-slaves
@Override public void interrupt(boolean forShutdown) {
if (forShutdown) {
return;
}
LOGGER.log(FINE, "interrupted {0}", cookie);
// TODO save the BodyExecution somehow and call .cancel() here; currently we just interrupt the build as a whole:
Executor masterExecutor = r.getExecutor();
if (masterExecutor != null) {
masterExecutor.interrupt();
} else { // ?
super.getExecutor().recordCauseOfInterruption(r, listener);
}
}
@Override public boolean blocksRestart() {
代码示例来源:origin: groupon/DotCi
} catch (final InterruptedException e) {
final Executor x = Executor.currentExecutor();
x.recordCauseOfInterruption(DynamicBuild.this, listener);
return x.abortResult();
} catch (final Exception e) {
logger.println(ExceptionUtils.getStackTrace(e));
final Executor x = Executor.currentExecutor();
x.recordCauseOfInterruption(DynamicBuild.this, listener);
x.doStop();
return Result.FAILURE;
代码示例来源:origin: org.jenkins-ci.main/jenkins-core
Executor.currentExecutor().recordCauseOfInterruption(Run.this,listener);
LOGGER.log(Level.INFO, this + " aborted", e);
} catch( Throwable e ) {
代码示例来源:origin: i-m-c/jenkins-inheritance-plugin
Executor.currentExecutor().recordCauseOfInterruption(
run, listener
);
代码示例来源:origin: org.jenkins-ci.plugins/matrix-project
throw new IOException("The build has been aborted, but its executor is not available");
x.recordCauseOfInterruption(MatrixBuild.this, listener);
return x.abortResult();
} catch (AbortException e) {
内容来源于网络,如有侵权,请联系作者删除!