Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -258,4 +258,9 @@ public boolean exists(Path f) throws IOException {
public Configuration getConf() {
return fileSystem.getConf();
}

@Override
public String getScheme() {
return fileSystem.getScheme();
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@
import java.util.Arrays;
import java.util.List;

import static org.junit.jupiter.api.Assertions.assertDoesNotThrow;
import static org.junit.jupiter.api.Assertions.assertThrows;

/**
Expand Down Expand Up @@ -79,6 +80,14 @@ public void testProcessFilesWithExceptions() throws Exception {
folders.forEach(f -> assertThrows(RuntimeException.class, () -> metaClient.getFs().mkdirs(new Path(new Path(basePath), f))));
}

@Test
public void testGetSchema() {
FakeRemoteFileSystem fakeFs = new FakeRemoteFileSystem(FSUtils.getFs(metaClient.getMetaPath(), metaClient.getHadoopConf()), 100);
FileSystem fileSystem = new HoodieRetryWrapperFileSystem(fakeFs, maxRetryIntervalMs, maxRetryNumbers, initialRetryIntervalMs, "");
HoodieWrapperFileSystem fs = new HoodieWrapperFileSystem(fileSystem, new NoOpConsistencyGuard());
assertDoesNotThrow(fs::getScheme, "Method #getSchema does not implement correctly");
}

/**
* Fake remote FileSystem which will throw RuntimeException something like AmazonS3Exception 503.
*/
Expand Down Expand Up @@ -205,5 +214,10 @@ public RemoteIterator<LocatedFileStatus> listLocatedStatus(Path f) throws IOExce
public Configuration getConf() {
return fs.getConf();
}

@Override
public String getScheme() {
return fs.getScheme();
}
}
}