HyukjinKwon commented on code in PR #50080:
URL: https://github.com/apache/spark/pull/50080#discussion_r1971047232


##########
sql/catalyst/src/main/scala/org/apache/spark/sql/execution/arrow/ArrowWriter.scala:
##########
@@ -112,6 +112,16 @@ class ArrowWriter(val root: VectorSchemaRoot, fields: 
Array[ArrowFieldWriter]) {
     count += 1
   }
 
+  def sizeInBytes(): Int = {
+    var i = 0
+    var bytes = 0

Review Comment:
   This actually represents the size of the whole Arrow batch. ArrowFieldWriter 
will be in charge of writing single column, and here we get the size of all 
columns. Since we're getting the size of the buffer being used in individual 
ArrowFieldWriter, it should work regardless of specific types.
   
   



-- 
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: reviews-unsubscr...@spark.apache.org

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


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

Reply via email to