/** * Launches a task, and sets its exit value in the result variable. */ public void runSequential() { int exitVal = -101; try { exitVal = tsk.executeTask(); } catch (Throwable t) { if (tsk.getException() == null) { tsk.setException(t); } LOG.error("Error in executeTask", t); } result.setExitVal(exitVal); if (tsk.getException() != null) { result.setTaskError(tsk.getException()); } }
/** * Launches a task, and sets its exit value in the result variable. */ public void runSequential() { int exitVal = -101; try { exitVal = tsk.executeTask(ss == null ? null : ss.getHiveHistory()); } catch (Throwable t) { if (tsk.getException() == null) { tsk.setException(t); } LOG.error("Error in executeTask", t); } result.setExitVal(exitVal); if (tsk.getException() != null) { result.setTaskError(tsk.getException()); } }
subtask = taskExec; int ret = taskExec.execute(driverCxt); if (subtask.getException() != null) { setException(subtask.getException());
subtask = task; int ret = task.execute(driverCxt); if (subtask.getException() != null) { setException(subtask.getException());
subtask = task; int ret = task.execute(driverCxt); if (subtask.getException() != null) { setException(subtask.getException());
subtask = taskExec; int ret = taskExec.execute(driverCxt); if (subtask.getException() != null) { setException(subtask.getException());
/** * Launches a task, and sets its exit value in the result variable. */ public void runSequential() { int exitVal = -101; try { exitVal = tsk.executeTask(); } catch (Throwable t) { if (tsk.getException() == null) { tsk.setException(t); } t.printStackTrace(); } result.setExitVal(exitVal, tsk.getException()); }
public void finish() { Task task = new Task<Void>() { @Override public Void call() throws Exception { StandingsCreationHelper.createStandingsFile(); return null; } }; task.setOnFailed(e -> { Throwable ex = task.getException(); Alert alertStandingsFileExecution = Dialog.getExceptionDialog(ex); alertStandingsFileExecution.showAndWait(); }); task.setOnSucceeded(e -> owner.close()); Scene scene = new Scene(new ProgressBarWindow(owner)); owner.setScene(scene); owner.show(); new Thread(task).start(); }