Skip to content

Commit 7f8ef76

Browse files
HADOOP-17305. Fix ITestCustomSigner to work with s3 compatible endpoints (#2395)
Contributed by Mukund Thakur
1 parent 88a9f42 commit 7f8ef76

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

hadoop-tools/hadoop-aws/src/test/java/org/apache/hadoop/fs/s3a/auth/ITestCustomSigner.java

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -133,11 +133,7 @@ private Configuration createTestConfig(String identifier) {
133133
}
134134

135135
private String determineRegion(String bucketName) throws IOException {
136-
AmazonS3 s3 = AmazonS3ClientBuilder.standard().withCredentials(
137-
new SimpleAWSCredentialsProvider(null, createConfiguration()))
138-
.withForceGlobalBucketAccessEnabled(true).withRegion("us-east-1")
139-
.build();
140-
String region = s3.getBucketLocation(bucketName);
136+
String region = getFileSystem().getBucketLocation(bucketName);
141137
return fixBucketRegion(region);
142138
}
143139

0 commit comments

Comments
 (0)