deniskuzZ commented on code in PR #6793:
URL: https://github.com/apache/hive/pull/6793#discussion_r4154375677


##########
llap-client/src/java/org/apache/hadoop/hive/llap/io/api/LlapIo.java:
##########
@@ -74,11 +74,15 @@ InputFormat<NullWritable, T> getInputFormat(
    * @param fileKey fileId of the Parquet file (either the Long fileId of HDFS 
or the SyntheticFileId).
    *                Optional, if it is not provided, it will be generated, see:
    *                org.apache.hadoop.hive.ql.io.HdfsUtils#getFileId()
+   * @param cacheHit optional out-parameter; when supplied, its {@code value} 
field is written
+   *                 with {@code true} on a cache hit and {@code false} on a 
miss, so the caller
+   *                 (which lives in llap-server and holds {@code 
QueryFragmentCounters}) can bump
+   *                 {@code METADATA_CACHE_HIT} / {@code METADATA_CACHE_MISS} 
for the LLAP IO summary.
    * @return
    * @throws IOException
    */
-  MemoryBufferOrBuffers getParquetFooterBuffersFromCache(Path path, JobConf 
conf, @Nullable Object fileKey)
-      throws IOException;
+  MemoryBufferOrBuffers getParquetFooterBuffersFromCache(Path path, JobConf 
conf, @Nullable Object fileKey,

Review Comment:
   could we group format specific methods under sub-interfaces?
   
   ````
   public interface LlapIo<T> {
     InputFormat<NullWritable, T> getInputFormat(InputFormat<?, ?> src, 
@Nullable Deserializer serde);
     … close, getMemoryInfo, purge, evictEntity, initCacheOnlyInputFormat, 
fetchCachedContentInfo, loadDataIntoCache, usingLowLevelCache …
     LlapOrcIo orc();
     LlapParquetIo parquet();
   }
   public interface LlapOrcIo {
     OrcTail getTailFromCache(Path, Configuration, CacheTag, @Nullable Object 
fileKey) throws IOException;
     RecordReader<NullWritable, VectorizedRowBatch> 
vectorizedReaderForPath(Object fileKey, Path, CacheTag,
         List<Integer> tableIncludedCols, JobConf, long offset, long length, 
Reporter) throws IOException;
   }
   public interface LlapParquetIo {
     MemoryBufferOrBuffers getFooterBuffersFromCache(Path, JobConf, @Nullable 
Object fileKey, @Nullable BooleanRef cacheHit) throws IOException;
     // vectorizedReaderForPath(...) arrives with its Iceberg caller
   }
   ````



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to