public void start() { if(!blockBuildEvents) onStartBuilding(); startTime = System.currentTimeMillis(); try { sync(); listener.setSideOutputStream(log); } catch (IOException e) { e.printStackTrace(); } RunListener.fireStarted(MavenBuild.this, listener); }
public void end() { if(result==null) setResult(Result.SUCCESS); if(!blockBuildEvents) onEndBuilding(); duration += System.currentTimeMillis()- startTime; parentBuild.notifyModuleBuild(MavenBuild.this); try { sync(); listener.setSideOutputStream(null); save(); } catch (IOException e) { e.printStackTrace(); } try { updateSymlinks(listener); } catch (InterruptedException x) { Logger.getLogger(MavenBuild.class.getName()).log(Level.WARNING, null, x); } RunListener.fireCompleted(MavenBuild.this, listener); }
/** * Sends the accumulated log in {@link SplittableBuildListener} to the log of this build. */ public void appendLastLog() { try { sync(); listener.setSideOutputStream(log); listener.setSideOutputStream(null); } catch (IOException e) { e.printStackTrace(); } }
sync(); log.close(); } catch (IOException e) {