Skip to content

Commit 584c0a5

Browse files
committed
HADOOP-18965. review comments + javados
variable name Change-Id: I5fbd6f7c24cd4a057d9823118b15653fed898999
1 parent 09eeb45 commit 584c0a5

File tree

1 file changed

+13
-6
lines changed

1 file changed

+13
-6
lines changed

hadoop-tools/hadoop-aws/src/test/java/org/apache/hadoop/fs/s3a/scale/ITestS3AHugeFilesEncryption.java

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -63,17 +63,24 @@ protected String getBlockOutputBufferName() {
6363
*/
6464
@Override
6565
protected boolean isEncrypted(S3AFileSystem fileSystem) {
66-
Configuration c = new Configuration();
67-
return StringUtils.isNotBlank(getS3EncryptionKey(getTestBucketName(c), c));
66+
Configuration conf = new Configuration();
67+
return StringUtils.isNotBlank(getS3EncryptionKey(getTestBucketName(conf), conf));
6868
}
6969

70+
/**
71+
* This test suite will run if the algorithm is set to SSE_KMS or DSSE_KMS;
72+
* the assertions validate this.
73+
* @param hugeFile file to validate.
74+
* @throws IOException problems with encryption lookup.
75+
* @throws AssertionError if the encryption is not as expected.
76+
*/
7077
@Override
7178
protected void assertEncrypted(Path hugeFile) throws IOException {
72-
Configuration c = new Configuration();
79+
Configuration conf = new Configuration();
7380

74-
final String bucket = getTestBucketName(c);
75-
String kmsKey = getS3EncryptionKey(bucket, c);
76-
final S3AEncryptionMethods algorithm = getEncryptionAlgorithm(bucket, c);
81+
final String bucket = getTestBucketName(conf);
82+
String kmsKey = getS3EncryptionKey(bucket, conf);
83+
final S3AEncryptionMethods algorithm = getEncryptionAlgorithm(bucket, conf);
7784
if (SSE_KMS.equals(algorithm)) {
7885
EncryptionTestUtils.assertEncrypted(getFileSystem(), hugeFile, SSE_KMS, kmsKey);
7986
} else if (DSSE_KMS.equals(algorithm)) {

0 commit comments

Comments
 (0)