8431 commented on issue #11627:
URL:
https://github.com/apache/dolphinscheduler/issues/11627#issuecomment-1237581959
private S3Utils() {
if
(PropertyUtils.getString(RESOURCE_STORAGE_TYPE).equals(STORAGE_S3)) {
AWSCredentialsProvider provider = new
AWSCredentialsProviderChain(
new EC2ContainerCredentialsProviderWrapper(),
new AWSStaticCredentialsProvider(new
BasicAWSCredentials(ACCESS_KEY_ID, SECRET_KEY_ID)));
if
(!StringUtils.isEmpty(PropertyUtils.getString(AWS_END_POINT))) {
s3Client = AmazonS3ClientBuilder
.standard()
.withPathStyleAccessEnabled(true)
.withEndpointConfiguration(new
AwsClientBuilder.EndpointConfiguration(PropertyUtils.getString(AWS_END_POINT),
Regions.fromName(REGION).getName()))
.withCredentials(provider)
.build();
} else {
s3Client = AmazonS3ClientBuilder
.standard()
.withCredentials(provider)
.withRegion(Regions.fromName(REGION))
.build();
}
checkBucketNameIfNotPresent(BUCKET_NAME);
}
}
--
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]