Skip to content

Commit 74ff007

Browse files
authored
HADOOP-19072. S3A: Override fs.s3a.performance.flags for tests (ADDENDUM) (apache#6985)
This is a followup to apache#6543 which ensures all test pass in configurations where fs.s3a.performance.flags is set to "*" or contains "mkdirs" Contributed by VJ Jasani
1 parent 321a6cc commit 74ff007

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

hadoop-tools/hadoop-aws/src/test/java/org/apache/hadoop/fs/contract/s3a/ITestS3AContractMkdir.java

+6-2
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@
2323
import org.apache.hadoop.fs.contract.AbstractFSContract;
2424

2525
import static org.apache.hadoop.fs.s3a.Constants.FS_S3A_CREATE_PERFORMANCE;
26+
import static org.apache.hadoop.fs.s3a.Constants.FS_S3A_PERFORMANCE_FLAGS;
2627
import static org.apache.hadoop.fs.s3a.S3ATestUtils.removeBaseAndBucketOverrides;
2728

2829
/**
@@ -33,8 +34,11 @@ public class ITestS3AContractMkdir extends AbstractContractMkdirTest {
3334
@Override
3435
protected Configuration createConfiguration() {
3536
Configuration conf = super.createConfiguration();
36-
removeBaseAndBucketOverrides(conf,
37-
FS_S3A_CREATE_PERFORMANCE);
37+
removeBaseAndBucketOverrides(
38+
conf,
39+
FS_S3A_CREATE_PERFORMANCE,
40+
FS_S3A_PERFORMANCE_FLAGS);
41+
conf.set(FS_S3A_PERFORMANCE_FLAGS, "");
3842
return conf;
3943
}
4044

hadoop-tools/hadoop-aws/src/test/java/org/apache/hadoop/fs/s3a/fileContext/ITestS3AFileContextCreateMkdir.java

+3-1
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
import org.junit.Before;
2020

2121
import static org.apache.hadoop.fs.s3a.Constants.FS_S3A_CREATE_PERFORMANCE;
22+
import static org.apache.hadoop.fs.s3a.Constants.FS_S3A_PERFORMANCE_FLAGS;
2223
import static org.apache.hadoop.fs.s3a.S3ATestUtils.removeBaseAndBucketOverrides;
2324

2425
/**
@@ -32,7 +33,8 @@ public void setUp() throws Exception {
3233
Configuration conf = new Configuration();
3334
removeBaseAndBucketOverrides(
3435
conf,
35-
FS_S3A_CREATE_PERFORMANCE);
36+
FS_S3A_CREATE_PERFORMANCE,
37+
FS_S3A_PERFORMANCE_FLAGS);
3638
fc = S3ATestUtils.createTestFileContext(conf);
3739
super.setUp();
3840
}

0 commit comments

Comments
 (0)