public synchronized Builder withRetryOnExceptionList(final List<Class<? extends Exception>> exceptionClassList) {
      for (final Class<? extends Exception> exceptionClass : exceptionClassList) {
        if (exceptionClass != null) {
          runnable.retryOn.add(exceptionClass);
        }
      }
      return this;
    }
Class to implement any retry logic in case of exceptions.
ql/src/java/org/apache/hadoop/hive/ql/exec/util/Retryable.java