deniskuzZ commented on code in PR #9301:
URL: https://github.com/apache/iceberg/pull/9301#discussion_r1428070146


##########
orc/src/main/java/org/apache/iceberg/orc/OrcIterable.java:
##########
@@ -134,7 +134,13 @@ private static VectorizedRowBatchIterator newOrcIterator(
 
     try {
       return new VectorizedRowBatchIterator(
-          file.location(), readerSchema, orcFileReader.rows(options), 
recordsPerBatch);
+          file.location(), readerSchema, orcFileReader.rows(options), 
recordsPerBatch) {
+        @Override
+        public void close() throws IOException {

Review Comment:
   created test and then noticed that 'file' is being closed in `rows.close()`
   ````
     public void close() throws IOException {
   ...
       dataReader.close();
     }
   ````
   RecordReaderUtils.DefaultDataReader
   ````
   public void close() throws IOException {
   ...
         if (pool != null) {
           pool.clear();
         }
         // close both zcr and file
         try (HadoopShims.ZeroCopyReaderShim myZcr = zcr) {
           if (file != null) {
             file.close();
             file = null;
           }
         }
       }
   
   ````



-- 
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: issues-unsubscr...@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org
For additional commands, e-mail: issues-h...@iceberg.apache.org

Reply via email to