docs: public void synchronizeEnd(Executor e, Queue.Executable executable, Throwable problems, long duration) throws InterruptedException {
          endLatch.synchronize();
  
          // the main thread will send a notification
          WorkUnit wu = e.getCurrentWorkUnit();
          if (wu.isMainWork()) {
              if (problems == null) {
                  future.set(executable);
                  e.getOwner().taskCompleted(e, task, duration);
              } else {
                  future.set(problems);
                  e.getOwner().taskCompletedWithProblems(e, task, duration, problems);
              }
          }
      }