public boolean hasException() {
    return exceptionMessage.get() != null;
  }
This class supports passing exception message when using CountDownLatch.
iotdb-core/node-commons/src/main/java/org/apache/iotdb/commons/concurrent/ExceptionalCountDownLatch.java