@Override
    public int read() throws IOException {
      // This is not called by ConsecutiveChunk stuff in Parquet.
      // If this were used, it might make sense to make it faster.
      byte[] theByte = new byte[1];
      int result = read(theByte, 0, 1);
      if (result != 1) throw new EOFException();
      return theByte[0] & 0xFF;
    }
This is currently only used by Parquet; however, a generally applicable approach is used -
you pass in a set of offset pairs for a file, and the file is cached with these boundaries.
Don't add anything format specific here.
ql/src/java/org/apache/hadoop/hive/llap/LlapCacheAwareFs.java