Skip to content

Commit 2da3985

Browse files
Added comments
1 parent 6aed814 commit 2da3985

File tree

2 files changed

+22
-2
lines changed

2 files changed

+22
-2
lines changed

hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azurebfs/AbfsConfiguration.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -143,8 +143,7 @@ public class AbfsConfiguration{
143143

144144
@IntegerConfigurationValidatorAnnotation(ConfigurationKey = AZURE_MIN_BACKOFF_INTERVAL,
145145
DefaultValue = DEFAULT_MIN_BACKOFF_INTERVAL)
146-
private int
147-
minBackoffInterval;
146+
private int minBackoffInterval;
148147

149148
@IntegerConfigurationValidatorAnnotation(ConfigurationKey = AZURE_MAX_BACKOFF_INTERVAL,
150149
DefaultValue = DEFAULT_MAX_BACKOFF_INTERVAL)

hadoop-tools/hadoop-azure/src/test/java/org/apache/hadoop/fs/azurebfs/services/ITestAbfsInputStream.java

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,10 @@ public void testWithNoOptimization() throws Exception {
6767
}
6868
}
6969

70+
/**
71+
* These ranges should not be merged as difference in offsets is greater than 4 KB.
72+
* @throws Throwable
73+
*/
7074
@Test
7175
public void testDisjointRangesWithVectoredRead() throws Throwable {
7276
int fileSize = ONE_MB;
@@ -90,6 +94,11 @@ public void testDisjointRangesWithVectoredRead() throws Throwable {
9094
}
9195
}
9296

97+
/**
98+
* The last two ranges should get merged, so it covers the case of combinedFileRanges
99+
* where there is a single underlying child and multiple as well.
100+
* @throws Throwable
101+
*/
93102
@Test
94103
public void testMultipleDisjointRangesWithVectoredRead() throws Throwable {
95104
int fileSize = ONE_MB;
@@ -114,6 +123,10 @@ public void testMultipleDisjointRangesWithVectoredRead() throws Throwable {
114123
}
115124
}
116125

126+
/**
127+
* Case which covers multiple disjoint ranges.
128+
* @throws Throwable
129+
*/
117130
@Test
118131
public void testMultipleRangesWithVectoredRead() throws Throwable {
119132
int fileSize = ONE_MB;
@@ -139,6 +152,10 @@ public void testMultipleRangesWithVectoredRead() throws Throwable {
139152
}
140153
}
141154

155+
/**
156+
* Case to verify two ranges with offset difference less than 4 KB will get merged.
157+
* @throws Throwable
158+
*/
142159
@Test
143160
public void testMergedRangesWithVectoredRead() throws Throwable {
144161
int fileSize = ONE_MB;
@@ -162,6 +179,10 @@ public void testMergedRangesWithVectoredRead() throws Throwable {
162179
}
163180
}
164181

182+
/**
183+
* Verify read ranges for a huge file.
184+
* @throws Throwable
185+
*/
165186
@Test
166187
public void test_045_vectoredIOHugeFile() throws Throwable {
167188
int fileSize = 100 * ONE_MB;

0 commit comments

Comments
 (0)