sullis commented on code in PR #12758:
URL: https://github.com/apache/iceberg/pull/12758#discussion_r2037765524


##########
aws/src/test/java/org/apache/iceberg/aws/TestAwsClientFactories.java:
##########
@@ -56,6 +56,47 @@ public void testLoadDefault() {
         .isInstanceOf(AwsClientFactories.DefaultAwsClientFactory.class);
   }
 
+  @Test
+  public void testS3AsyncClientCrtEnabledTrue() {
+    Map<String, String> properties = Maps.newHashMap();
+    properties.put(S3FileIOProperties.ACCESS_KEY_ID, "keyId");
+    properties.put(S3FileIOProperties.SECRET_ACCESS_KEY, "accessKey");
+    properties.put(S3FileIOProperties.S3_CRT_ENABLED, "true");
+    properties.put(AwsClientProperties.CLIENT_REGION, "us-east-1");
+
+    AwsClientFactory clientFactory = AwsClientFactories.from(properties);
+    S3AsyncClient s3AsyncClient = clientFactory.s3Async();
+    assertThat(s3AsyncClient.getClass().getName())
+        
.isEqualTo("software.amazon.awssdk.services.s3.internal.crt.DefaultS3CrtAsyncClient");
+  }
+
+  @Test
+  public void testS3AsyncClientWithCrtEnabledFalse() {
+    Map<String, String> properties = Maps.newHashMap();
+    properties.put(S3FileIOProperties.ACCESS_KEY_ID, "keyId");
+    properties.put(S3FileIOProperties.SECRET_ACCESS_KEY, "accessKey");
+    properties.put(S3FileIOProperties.S3_CRT_ENABLED, "false");
+    properties.put(AwsClientProperties.CLIENT_REGION, "us-east-1");
+
+    AwsClientFactory clientFactory = AwsClientFactories.from(properties);
+    S3AsyncClient s3AsyncClient = clientFactory.s3Async();
+    assertThat(s3AsyncClient.getClass().getName())

Review Comment:
   Done.



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

Reply via email to