private void checkThreadOk() throws InterruptedException {
            if (futureTask.isDone()) {
                try {
                    futureTask.get();
                } catch (ExecutionException e) {
                    throw new RuntimeException(e.getCause());
                }
            }
        }
this checks to make sure that the thread hasn't terminated early.
Will return true if the thread has successfully completed or if
it has not completed.  Will return false if there has been a thread
interrupt. Will throw a RuntimeException if there's been
an execution exception in the thread.
tika-core/src/main/java/org/apache/tika/pipes/pipesiterator/PipesIterator.java