RussellSpitzer commented on code in PR #7066:
URL: https://github.com/apache/iceberg/pull/7066#discussion_r1140640312
##########
aws/src/main/java/org/apache/iceberg/aws/AwsProperties.java:
##########
@@ -1249,6 +1316,51 @@ private boolean s3KeyIdAccessKeyBothConfigured() {
return (s3AccessKeyId == null) == (s3SecretAccessKey == null);
}
+ private AwsCredentialsProvider credentialsProvider(String
credentialsProviderClazz) {
+ try {
+ Class<?> providerClass =
+ DynClasses.builder()
+ .loader(this.getClass().getClassLoader())
+ .impl(credentialsProviderClazz)
+ .buildChecked();
+
+ ValidationException.check(
Review Comment:
This is the wrong exception type, we throw these only for table validation
errors.
```java
/**
* Exception raised when validation checks fail.
* <p>
* For example, this is thrown when attempting to create a table with a
{@link PartitionSpec} that
* is not compatible with the table {@link Schema}
*/
```
I think this is probably better as a `Preconditions.checkArg`
--
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]