RussellSpitzer commented on a change in pull request #3724:
URL: https://github.com/apache/iceberg/pull/3724#discussion_r767769476
##########
File path:
spark/v3.2/spark/src/main/java/org/apache/iceberg/spark/actions/Spark3BinPackStrategy.java
##########
@@ -67,6 +68,11 @@ public Table table() {
.option(SparkReadOptions.FILE_OPEN_COST, "0")
.load(table.name());
+ // If got 0 pieces of data, no need write new data file, should return
to expire the data file
+ if (scanDF.count() == 0) {
Review comment:
This will be extremely expensive for all operations where the scanDF
isn't empty forcing a double read for all such data sets. I think we should
look for another solution.
--
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]