@Override
    public boolean next(K key, V value) throws IOException {

      while ((curReader == null)
          || !doNextWithExceptionHandler((K) ((CombineHiveKey) key).getKey(),
              value)) {
        if (!initNextRecordReader(key)) {
          return false;
        }
      }
      return true;
    }
Base implemention for shims against secure Hadoop 0.20.3/0.23.
shims/common/src/main/java/org/apache/hadoop/hive/shims/HadoopShimsSecure.java