@Override public void notify(DelegateExecution exec) throws Exception { if (LOG.isLoggable(Level.FINE)){ LOG.fine("name = "+name); LOG.fine("exec.getEventName() -> "+exec.getEventName()); LOG.fine("exec.getId() -> "+exec.getId()); LOG.fine("exec.getProcessBusinessKey() -> "+exec.getProcessBusinessKey()); LOG.fine("exec.getProcessInstanceId() -> "+exec.getProcessInstanceId()); LOG.fine("jenkow_build_parent = "+exec.getVariable("jenkow_build_parent")); LOG.fine("jenkow_build_number = "+exec.getVariable("jenkow_build_number")); } PrintStream log = BuildLoggerMap.get(exec.getVariable("jenkow_build_parent"),exec.getVariable("jenkow_build_number")); if (log != null){ String ev = exec.getEventName(); if (ev != null) ev += "ed"; log.println(Consts.UI_PREFIX+": "+name+" "+ev); } } }
@Override public void notify(DelegateExecution execution) { if (!ExecutionListener.EVENTNAME_END.equals(execution.getEventName())) { return; } LOGGER.trace("Signalling process end; execution id = {}, current activity id = {}, current activity name = {}, instance id = {}", execution.getId(), execution.getCurrentActivityId(), execution.getCurrentActivityName(), execution.getProcessInstanceId()); try { getActivitiInterface().notifyMidpointAboutProcessFinishedEvent(execution); } catch (RuntimeException e) { LOGGER.trace("Got exception while processing process end event in midpoint", e); if (TRUE.equals(execution.getVariable(CommonProcessVariableNames.VARIABLE_PROCESS_INSTANCE_IS_STOPPING))) { LOGGER.trace("... the process is ending anyway, so we just ignore this exception"); } else { throw e; } } } }