Skip to content

Commit d6d6ffe

Browse files
Space fix
1 parent 6cc9448 commit d6d6ffe

File tree

2 files changed

+22
-21
lines changed

2 files changed

+22
-21
lines changed

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

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -58,17 +58,17 @@ public class ITestAbfsReadWriteAndSeek extends AbstractAbfsScaleTest {
5858
@Parameterized.Parameters(name = "Size={0}-readahead={1}")
5959
public static Iterable<Object[]> sizes() {
6060
return Arrays.asList(new Object[][]{{MIN_BUFFER_SIZE, true},
61-
{DEFAULT_READ_BUFFER_SIZE, false},
62-
{DEFAULT_READ_BUFFER_SIZE, true},
63-
{APPENDBLOB_MAX_WRITE_BUFFER_SIZE, false},
64-
{MAX_BUFFER_SIZE, true}});
61+
{DEFAULT_READ_BUFFER_SIZE, false},
62+
{DEFAULT_READ_BUFFER_SIZE, true},
63+
{APPENDBLOB_MAX_WRITE_BUFFER_SIZE, false},
64+
{MAX_BUFFER_SIZE, true}});
6565
}
6666

6767
private final int size;
6868
private final boolean readaheadEnabled;
6969

7070
public ITestAbfsReadWriteAndSeek(final int size,
71-
final boolean readaheadEnabled) throws Exception {
71+
final boolean readaheadEnabled) throws Exception {
7272
this.size = size;
7373
this.readaheadEnabled = readaheadEnabled;
7474
}
@@ -93,7 +93,7 @@ private void testReadWriteAndSeek(int bufferSize) throws Exception {
9393
try {
9494
stream.write(b);
9595
} finally{
96-
stream.close();
96+
stream.close();
9797
}
9898
logIOStatisticsAtLevel(LOG, IOSTATISTICS_LOGGING_LEVEL_INFO, stream);
9999

@@ -103,10 +103,10 @@ private void testReadWriteAndSeek(int bufferSize) throws Exception {
103103
try (FSDataInputStream inputStream = fs.open(testPath)) {
104104
statisticsSource = inputStream;
105105
((AbfsInputStream) inputStream.getWrappedStream()).registerListener(
106-
new TracingHeaderValidator(abfsConfiguration.getClientCorrelationId(),
107-
fs.getFileSystemId(), FSOperationType.READ, true, 0,
108-
((AbfsInputStream) inputStream.getWrappedStream())
109-
.getStreamID()));
106+
new TracingHeaderValidator(abfsConfiguration.getClientCorrelationId(),
107+
fs.getFileSystemId(), FSOperationType.READ, true, 0,
108+
((AbfsInputStream) inputStream.getWrappedStream())
109+
.getStreamID()));
110110
inputStream.seek(bufferSize);
111111
result = inputStream.read(readBuffer, bufferSize, bufferSize);
112112
assertNotEquals(-1, result);
@@ -138,10 +138,10 @@ public void testReadAheadRequestID() throws java.io.IOException {
138138
Path testPath = path(TEST_PATH);
139139
try (FSDataOutputStream stream = fs.create(testPath)) {
140140
((AbfsOutputStream) stream.getWrappedStream()).registerListener(
141-
new TracingHeaderValidator(abfsConfiguration.getClientCorrelationId(),
142-
fs.getFileSystemId(), FSOperationType.WRITE, false, 0,
143-
((AbfsOutputStream) stream.getWrappedStream())
144-
.getStreamID()));
141+
new TracingHeaderValidator(abfsConfiguration.getClientCorrelationId(),
142+
fs.getFileSystemId(), FSOperationType.WRITE, false, 0,
143+
((AbfsOutputStream) stream.getWrappedStream())
144+
.getStreamID()));
145145
stream.write(b);
146146
logIOStatisticsAtLevel(LOG, IOSTATISTICS_LOGGING_LEVEL_INFO, stream);
147147
}
@@ -150,17 +150,17 @@ public void testReadAheadRequestID() throws java.io.IOException {
150150
final byte[] readBuffer = new byte[4 * bufferSize];
151151
int result;
152152
fs.registerListener(
153-
new TracingHeaderValidator(abfsConfiguration.getClientCorrelationId(),
154-
fs.getFileSystemId(), FSOperationType.OPEN, false, 0));
153+
new TracingHeaderValidator(abfsConfiguration.getClientCorrelationId(),
154+
fs.getFileSystemId(), FSOperationType.OPEN, false, 0));
155155
try (FSDataInputStream inputStream = fs.open(testPath)) {
156156
((AbfsInputStream) inputStream.getWrappedStream()).registerListener(
157-
new TracingHeaderValidator(abfsConfiguration.getClientCorrelationId(),
158-
fs.getFileSystemId(), FSOperationType.READ, false, 0,
159-
((AbfsInputStream) inputStream.getWrappedStream())
160-
.getStreamID()));
157+
new TracingHeaderValidator(abfsConfiguration.getClientCorrelationId(),
158+
fs.getFileSystemId(), FSOperationType.READ, false, 0,
159+
((AbfsInputStream) inputStream.getWrappedStream())
160+
.getStreamID()));
161161
result = inputStream.read(readBuffer, 0, bufferSize*4);
162162
logIOStatisticsAtLevel(LOG, IOSTATISTICS_LOGGING_LEVEL_INFO, inputStream);
163163
}
164164
fs.registerListener(null);
165165
}
166-
}
166+
}

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

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@
3939
import org.apache.hadoop.fs.azurebfs.contracts.services.ReadBufferStatus;
4040
import org.apache.hadoop.fs.azurebfs.utils.TestCachedSASToken;
4141
import org.apache.hadoop.fs.azurebfs.utils.TracingContext;
42+
import org.mockito.Mockito;
4243

4344
import static org.mockito.ArgumentMatchers.any;
4445
import static org.mockito.Mockito.doReturn;

0 commit comments

Comments
 (0)