ExecutorTask implements Callable<T> { String action() { return rootAction == null ? "task:" + action : rootAction + ":" + action; } ExecutorTask(String actionId, String action, Instant startTime, ActionLog parentActionLog, LogManager logManager, Callable<T> task); @Override T call();  }
@Test void action() { assertThat(new ExecutorTask<Void>("actionId", "action", Instant.now(), null, null, () -> null).action()) .isEqualTo("task:action"); var parentActionLog = new ActionLog(null, null); parentActionLog.action = "parentAction"; assertThat(new ExecutorTask<Void>("actionId", "action", Instant.now(), parentActionLog, null, () -> null).action()) .isEqualTo("parentAction:action"); parentActionLog.context("root_action", "rootAction"); assertThat(new ExecutorTask<Void>("actionId", "action", Instant.now(), parentActionLog, null, () -> null).action()) .isEqualTo("rootAction:action"); }