wypoon commented on code in PR #7733:
URL: https://github.com/apache/iceberg/pull/7733#discussion_r1274227149
##########
spark/v3.4/spark/src/main/java/org/apache/iceberg/spark/SparkReadConf.java:
##########
@@ -73,7 +73,12 @@ public boolean caseSensitive() {
public boolean localityEnabled() {
boolean defaultValue = Util.mayHaveBlockLocations(table.io(),
table.location());
- return PropertyUtil.propertyAsBoolean(readOptions,
SparkReadOptions.LOCALITY, defaultValue);
+ return confParser
+ .booleanConf()
+ .option(SparkReadOptions.LOCALITY)
+ .sessionConf(SparkSQLProperties.LOCALITY_ENABLED)
+ .defaultValue(defaultValue)
+ .parse();
Review Comment:
If `SparkReadConf#localityEnabled` returns true, even though the table is
not in HDFS, then Iceberg will try to get the block locations, and I am not
sure about this, since I haven't tested it, I think the HDFS call could throw
an IOException and Iceberg will rethrow that. That would be a bad thing.
--
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]