kevinjqliu commented on code in PR #12299: URL: https://github.com/apache/iceberg/pull/12299#discussion_r1989925583
########## gradle/libs.versions.toml: ########## @@ -22,6 +22,7 @@ [versions] activation = "1.1.1" aliyun-sdk-oss = "3.10.2" +analyticsaccelerator = "1.0.0" Review Comment: double checked that `1.0.0` exists https://mvnrepository.com/artifact/software.amazon.s3.analyticsaccelerator/analyticsaccelerator-s3 ########## kafka-connect/build.gradle: ########## Review Comment: we should double check if this affects LICENSE. See https://github.com/apache/iceberg/pull/12365 ########## aws/src/integration/java/org/apache/iceberg/aws/s3/TestS3FileIOIntegration.java: ########## @@ -255,6 +256,48 @@ public void testNewInputStreamWithMultiRegionAccessPoint() throws Exception { validateRead(s3FileIO); } + @Test + public void testNewInputStreamWithAnalyticsAccelerator() throws Exception { + s3.putObject( + PutObjectRequest.builder().bucket(bucketName).key(objectKey).build(), + RequestBody.fromBytes(contentBytes)); + S3FileIO s3FileIO = new S3FileIO(); + s3FileIO.initialize( + ImmutableMap.of(S3FileIOProperties.S3_ANALYTICS_ACCELERATOR_ENABLED, String.valueOf(true))); + validateRead(s3FileIO); + } + + @Test + public void testNewInputStreamWithAnalyticsAcceleratorAndCRT() throws Exception { + s3.putObject( + PutObjectRequest.builder().bucket(bucketName).key(objectKey).build(), + RequestBody.fromBytes(contentBytes)); + S3FileIO s3FileIO = new S3FileIO(); + s3FileIO.initialize( + ImmutableMap.of( + S3FileIOProperties.S3_ANALYTICS_ACCELERATOR_ENABLED, + String.valueOf(true), + S3FileIOProperties.S3_CRT_ENABLED, + String.valueOf(true))); + validateRead(s3FileIO); + } + + @Test + public void testNewInputStreamWithAnalyticsAcceleratorCustomConfigured() throws Exception { + final String prefetchingMode = "logicalio.prefetching.mode"; + final String s3Uri = String.format("s3://%s/%s/%s", bucketName, prefix, "testFile.parquet"); Review Comment: should this use `objectKey`? ########## aws/src/main/java/org/apache/iceberg/aws/s3/S3FileIOProperties.java: ########## @@ -72,6 +72,32 @@ public class S3FileIOProperties implements Serializable { public static final boolean S3_ACCESS_GRANTS_ENABLED_DEFAULT = false; + /** + * This property is used to enable using the S3 Analytics Accelerator library to accelerate data + * access from client applications to Amazon S3. + * + * <p>For more details, see: https://github.com/awslabs/analytics-accelerator-s3 + */ + public static final String S3_ANALYTICS_ACCELERATOR_ENABLED = "s3.analytics-accelerator.enabled"; Review Comment: we should add these to the docs https://iceberg.apache.org/docs/latest/aws/ -- 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: issues-unsubscr...@iceberg.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@iceberg.apache.org For additional commands, e-mail: issues-h...@iceberg.apache.org