code: public static void awaitUninterruptibly(CountDownLatch latch) {
      boolean interrupted = false;
      try {
        while (true) {
          try {
            latch.await();
            return;
          } catch (InterruptedException e) {
            interrupted = true;
          }
        }
      } finally {
        if (interrupted) {
          Thread.currentThread().interrupt();
        }
      }
    }
docs: Invokes {@code latch.}{@link CountDownLatch#await() await()}
  uninterruptibly.