You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by GitBox <gi...@apache.org> on 2021/03/17 08:08:13 UTC

[GitHub] [iceberg] openinx commented on a change in pull request #2333: Core: fix bug that HadoopFileIO cannot be dynamically loaded

openinx commented on a change in pull request #2333:
URL: https://github.com/apache/iceberg/pull/2333#discussion_r595790212



##########
File path: core/src/test/java/org/apache/iceberg/TestCatalogUtil.java
##########
@@ -123,6 +123,16 @@ public void loadCustomFileIO_noArg() {
     Assert.assertEquals(properties, ((TestFileIONoArg) fileIO).map);
   }
 
+  @Test
+  public void loadCustomFileIO_hadoopConfigConstructor() {
+    Configuration configuration = new Configuration();
+    configuration.set("key", "val");
+    FileIO fileIO = CatalogUtil.loadFileIO(
+        TestFileIOHadoopConstructor.class.getName(), Maps.newHashMap(), configuration);

Review comment:
       Why not just  load the `HadoopFileIO` directly ?  Here we are trying to load an `TestFileIOHadoopConstructor`,  I'm concerning that we could not detect the breaking case if someone change the `HadoopFileIO` constructor....




----------------------------------------------------------------
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:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org