RussellSpitzer commented on a change in pull request #1350:
URL: https://github.com/apache/iceberg/pull/1350#discussion_r474283896



##########
File path: spark2/src/main/java/org/apache/iceberg/spark/source/Reader.java
##########
@@ -143,8 +143,9 @@
       } catch (IOException ioe) {
         LOG.warn("Failed to get Hadoop Filesystem", ioe);
       }
+      Boolean localityFallback = LOCALITY_WHITELIST_FS.contains(scheme);
       this.localityPreferred = 
options.get("locality").map(Boolean::parseBoolean)
-          .orElse(LOCALITY_WHITELIST_FS.contains(scheme));
+          .orElse(localityFallback);

Review comment:
       I think actually this would actually be fine, but to make the rules 
happy we would have to reassign Scheme anyway so I figured we may as well just 
put the result in a local var 




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

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