yyanyy commented on code in PR #57487:
URL: https://github.com/apache/spark/pull/57487#discussion_r3687036102


##########
sql/catalyst/src/main/scala/org/apache/spark/sql/execution/datasources/v2/DataSourceV2Relation.scala:
##########
@@ -463,9 +484,20 @@ object DataSourceV2Relation {
         })
       })
     }
+    val attributeStats = AttributeMap(colStats)
+    // Prefer the source-reported size. Otherwise infer a projection-aware 
size from the row count
+    // (numRows * outputRowSize via getOutputSize). Fall back to the default 
size when neither is
+    // available.
+    val sizeInBytes = if (v2Statistics.sizeInBytes().isPresent) {

Review Comment:
   This was originally java method declared with `()`, and it seems that the 
surrounding java getter calls all have `()` so this was to keep consistent; 
though I'm happy to drop it if you feel strongly



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