RussellSpitzer commented on code in PR #13949:
URL: https://github.com/apache/iceberg/pull/13949#discussion_r2317066770


##########
arrow/src/main/java/org/apache/iceberg/arrow/vectorized/VectorizedArrowReader.java:
##########
@@ -217,6 +217,10 @@ public VectorHolder read(VectorHolder reuse, int 
numValsToRead) {
   }
 
   private void allocateFieldVector(boolean dictionaryEncodedVector) {
+    // Allocate-only: caller must ensure there is no active vector in use.
+    Preconditions.checkState(
+        vec == null,
+        "allocateFieldVector must be called only when no active vector is in 
use (vec == null)");

Review Comment:
   We could check if the vec.isClosed? I think that also is fine and let 
garbage collection just drag it away



-- 
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