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 2020/10/05 23:36:10 UTC

[GitHub] [iceberg] mickjermsurawong-stripe edited a comment on pull request #1531: Allow impl for LocationProvider for to be created during runtime

mickjermsurawong-stripe edited a comment on pull request #1531:
URL: https://github.com/apache/iceberg/pull/1531#issuecomment-703944728


   Propagating the causes now should give stacktrace for these two cases, with more specific causes.
   
   ```
    java.lang.IllegalArgumentException: Unable to find a constructor for implementation org.apache.iceberg.TestLocationProvider$InvalidArgTypesDynamicallyLoadedLocationProvider of interface org.apache.iceberg.io.LocationProvider. Make sure the implementation is in classpath, and that it either has a public no-arg constructor or a two-arg constructor taking in the string base table location and its property string map.
           at org.apache.iceberg.LocationProviders.locationsFor(LocationProviders.java:48)
           at org.apache.iceberg.TestTables$TestTableOperations.locationProvider(TestTables.java:212)
           at org.apache.iceberg.BaseTable.locationProvider(BaseTable.java:199)
           at org.apache.iceberg.TestLocationProvider.testInvalidArgTypesDynamicallyLoadedLocationProvider(TestLocationProvider.java:208)
   
           Caused by:
           java.lang.NoSuchMethodException: Cannot find constructor for interface org.apache.iceberg.io.LocationProvider
                   Missing org.apache.iceberg.TestLocationProvider$InvalidArgTypesDynamicallyLoadedLocationProvider() [java.lang.NoSuchMethodException: org.apache.iceberg.TestLocationProvider$InvalidArgTypesDynamicallyLoadedLocationProvider.<init>()]
                   Missing org.apache.iceberg.TestLocationProvider$InvalidArgTypesDynamicallyLoadedLocationProvider(java.lang.String,java.util.Map) [java.lang.NoSuchMethodException: org.apache.iceberg.TestLocationProvider$InvalidArgTypesDynamicallyLoadedLocationProvider.<init>(java.lang.String, java.util.Map)]
   ```
   
   and
   
   ```
   java.lang.IllegalArgumentException: Provided implementation for dynamic instantiation should implement interface org.apache.iceberg.io.LocationProvider.
           at org.apache.iceberg.LocationProviders.locationsFor(LocationProviders.java:59)
           at org.apache.iceberg.TestTables$TestTableOperations.locationProvider(TestTables.java:212)
           at org.apache.iceberg.BaseTable.locationProvider(BaseTable.java:199)
           at org.apache.iceberg.TestLocationProvider.testInvalidNoInterfaceDynamicallyLoadedLocationProvider(TestLocationProvider.java:190)
   
           Caused by:
           java.lang.ClassCastException: org.apache.iceberg.TestLocationProvider$InvalidNoInterfaceDynamicallyLoadedLocationProvider cannot be cast to org.apache.iceberg.io.LocationProvider
               at org.apache.iceberg.LocationProviders.locationsFor(LocationProviders.java:56)
               ... 3 more
   ```


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