HADOOP-6558. Return null in HarFileSystem.getFileChecksum(..) since no checksum algorithm is implemented.
git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@911646 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
4b4e9d741e
commit
50dcc335be
|
@ -210,6 +210,9 @@ Trunk (unreleased changes)
|
|||
HADOOP-6570. RPC#stopProxy throws NPE if getProxyEngine(proxy) returns
|
||||
null. (hairong)
|
||||
|
||||
HADOOP-6558. Return null in HarFileSystem.getFileChecksum(..) since no
|
||||
checksum algorithm is implemented. (szetszwo)
|
||||
|
||||
Release 0.21.0 - Unreleased
|
||||
|
||||
INCOMPATIBLE CHANGES
|
||||
|
|
|
@ -539,6 +539,13 @@ public class HarFileSystem extends FilterFileSystem {
|
|||
makeRelative(this.uri.toString(), new Path(hstatus.name)));
|
||||
}
|
||||
|
||||
/**
|
||||
* @return null since no checksum algorithm is implemented.
|
||||
*/
|
||||
public FileChecksum getFileChecksum(Path f) {
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a har input stream which fakes end of
|
||||
* file. It reads the index files to get the part
|
||||
|
|
|
@ -45,4 +45,11 @@ public class TestHarFileSystem {
|
|||
e.printStackTrace(System.out);
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testFileChecksum() {
|
||||
final Path p = new Path("har://file-localhost/foo.har/file1");
|
||||
final HarFileSystem harfs = new HarFileSystem();
|
||||
Assert.assertEquals(null, harfs.getFileChecksum(p));
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue