コード例 #1
0
ファイル: SCMTrigger.java プロジェクト: hehonghui/hudson.core
 @Override
 public void onAddedTo(AbstractBuild build) {
   try {
     BuildAction a = new BuildAction(build);
     FileUtils.writeStringToFile(a.getPollingLogFile(), pollingLog);
     build.addAction(a);
   } catch (IOException e) {
     LOGGER.log(WARNING, "Failed to persist the polling log", e);
   }
   pollingLog = null;
 }
コード例 #2
0
ファイル: SCMTrigger.java プロジェクト: nparry/jenkins
    @Override
    public void onAddedTo(AbstractBuild build) {
      BuildAction oldAction = build.getAction(BuildAction.class);
      if (oldAction != null) {
        build.getActions().remove(oldAction);
      }

      try {
        BuildAction a = new BuildAction(build);
        FileUtils.writeStringToFile(a.getPollingLogFile(), pollingLog);
        build.addAction(a);
      } catch (IOException e) {
        LOGGER.log(WARNING, "Failed to persist the polling log", e);
      }
      pollingLog = null;
    }