Integrate Artifactory with AWS SDK v2 for S3 Storage
Artifactory's S3 binary storage provider supports AWS SDK v2 starting from Artifactory 7.125.4. This integration allows you to use the latest AWS features and optimizations for a more robust and efficient storage solution, while maintaining full backward compatibility with your existing S3 configurations.
AWS SDK v2 receives all active development, new features, and security updates, ensuring your storage integration remains current.
Note
- AWS SDK v2 is the default AWS SDK for Artifactory versions 7.146.7 and later.
- Customers using AWS SDK storage with KMS client-side encryption should not use AWS SDK v2. If you are using AWS SDK storage with KMS client-side encryption, ensure that in in the
binarystore.xmlfileawsSdkV2is set it tofalse. For more information, see Amazon S3 Template Parameters.- Amazon Web Services made SDK v1 end-of-life at the end of 2025. For customers other than those using KMS client-side encryption, JFrog strongly recommends that you transition to SDK v2 if you currently use SDK v1. For more information, see the AWS announcement.
Enabling AWS SDK v2 in Artifactory
Note
This section is not relevant for Artifactory versions 7.146.7 and later, where AWS SDK v2 is enabled by default.
To enable AWS SDK v2 in Artifactory, add the awsSdkV2 parameter to your S3 provider configuration in the binarystore.xml file and set it to true, as in the following example.
<config version="2">
<chain template="s3-storage-v3-direct"/>
<provider type="s3-storage-v3" id="s3-storage-v3">
<awsSdkV2>true</awsSdkV2>
<!-- Other S3 configuration parameters -->
</provider>
</config>Note
A restart of Artifactory is required for this change to take effect.
Configuration Parameters Relevant to AWS SDK v2
You can modify the behavior of the AWS SDK v2 integration using the following parameters in your binarystore.xml file.
S3 Provider Parameters Introduced in AWS SDK v2
The following parameters are unique to AWS SDK v2.
Parameter | Type | Default | Description |
|---|---|---|---|
awsSdkV2 | Boolean |
| Enables or disables the AWS SDK v2 integration. |
blockingDataReadThreads | Integer | 15 | The number of threads in the dedicated pool for adapting Artifactory's blocking I/O to the SDK's non-blocking clients. |
crtTargetThroughputInGbps | Double | 10.0 | The target network throughput (in Gbps) for the high-performance CRT client. This helps throttle the client on networks with limited bandwidth. |
connectionAcquisitionTimeout | Integer | -1 | The connection acquisition timeout for the AWS client in milliseconds. A value equal to or less than 0 causes Artifactory to use the client's default value. |
disableChecksumValidation | Boolean | false | Disables automatic checksum validation during S3 operations. Note Give careful consideration before enabling this setting. For more information on the AWS checksum validation mechanism, see the AWS documentation. |
Other S3 Provider Parameters Relevant to AWS SDK v2
The following parameters are used in AWS SDK v1 and are also relevant to AWS SDK v2.
| Parameter | Type | Default | Description |
|---|---|---|---|
| multiPartLimit | Integer | 100,000000 (bytes) | File size threshold (in bytes) over which file uploads are chunked and multi-threaded. |
| multipartElementSize | Integer | 8 MB | The chunk size when multiPartLimit is used. A value equal to or less than 0 causes Artifactory to use the AWS default, which is 8 MB. |
| connectionTimeout | Integer | not set | Sets the connection timeout (in milliseconds) for the HTTP clients used by the AWS SDK. A value equal to or less than 0 will cause Artifactory to use the clients' default values. |
Migrating from AWS SDK v1 to AWS SDK v2
This section presents some key considerations and configuration changes required when migrating your Artifactory deployment from AWS SDK v1 to AWS SDK v2.
Regional Endpoint Configuration
Ensure that the region endpoint is explicitly defined in your binarystore.xml file. AWS SDK v2 requires this to correctly route requests to your specific S3 or S3-compatible region.
For example: <region>us-west-1</region>
For more information, see Amazon S3 Template Parameters.
Handling Upload Failures for S3-Compatible Storage
AWS SDK v2 implements stricter checksum validation by default, which can cause upload failure when using some S3-compatible storage solutions that do not fully implement AWS-compliant checksum mechanisms. When this happens, upload failures are accompanied by XAmzContentSHA256Mismatch exceptions in Artifactory logs.
Solution
If you encounter these types of upload failures, consider setting disableChecksumValidation to true in your configuration. The default is false. For more information, see Amazon S3 Template Parameters.
Note
Before disabling checksum validation, carefully evaluate the implications on data integrity. For more information on the AWS checksum validation mechanism, see the AWS documentation.
Self-Signed Certificates
AWS SDK v2 uses the CRT (Common Runtime) client, which does not automatically load the standard Java keystore. This can lead to SSL/TLS handshake failures if you are using custom or self-signed certificates.
To resolve this situation, update the CA certificates within the Artifactory pod. For more information, see How to update the CA certificates within the Artifactory pod.
Related Topics
- Filestore Configuration
- AWS S3 Object Storage
- Artifactory S3 Storage Configuration
- Amazon S3 Template Parameters
- S3 Binary Storage Templates
Frequently Asked Questions
This section provides answers to frequently asked questions.
FAQs
Q: Which minimum Artifactory version is required to use AWS SDK v2?
A: AWS SDK v2 support for the S3 binary storage provider is available starting from Artifactory 7.125.4. Set awsSdkV2 to true in binarystore.xml to enable it.
Q: Is a restart of Artifactory required after enabling AWS SDK v2?
A: Yes. A restart of Artifactory is required for the awsSdkV2=true change to take effect.
Q: Why should I migrate to AWS SDK v2?
A: Amazon Web Services has announced end-of-life for AWS SDK v1 at the end of 2025. JFrog strongly recommends that you transition to SDK v2 if you currently use SDK v1 to continue receiving active development, new features, and security updates.
Q: What is the default multipart chunk size in AWS SDK v2?
A: The default multipartElementSize is 8 MB for AWS SDK v2. In SDK v1, the default is 5 MB. File uploads are chunked when they exceed the multiPartLimit threshold, which defaults to 100,000,000 bytes. See Amazon S3 Template Parameters for the complete parameter reference.
