aokolnychyi commented on a change in pull request #2763:
URL: https://github.com/apache/iceberg/pull/2763#discussion_r661075485
##########
File path:
spark/src/main/java/org/apache/iceberg/spark/actions/BaseRemoveReachableFilesSparkAction.java
##########
@@ -80,6 +84,10 @@ public void accept(String file) {
public BaseRemoveReachableFilesSparkAction(SparkSession spark, String
metadataLocation) {
super(spark);
this.metadataLocation = metadataLocation;
+ TableMetadata metadata = TableMetadataParser.read(io, metadataLocation);
Review comment:
Question: since we are reading the version file here, can we already
cache `TableMetadata` to avoid reading it twice? Seems like we can replace
`metadataLocation` with `metadata` and then use `metadataFileLocation()` if
needed.
--
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]