hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From szets...@apache.org
Subject svn commit: r911646 - in /hadoop/common/trunk: CHANGES.txt src/java/org/apache/hadoop/fs/HarFileSystem.java src/test/core/org/apache/hadoop/fs/TestHarFileSystem.java
Date Thu, 18 Feb 2010 23:22:52 GMT
Author: szetszwo
Date: Thu Feb 18 23:22:52 2010
New Revision: 911646

URL: http://svn.apache.org/viewvc?rev=911646&view=rev
Log:
HADOOP-6558. Return null in HarFileSystem.getFileChecksum(..) since no checksum algorithm
is implemented.

Modified:
    hadoop/common/trunk/CHANGES.txt
    hadoop/common/trunk/src/java/org/apache/hadoop/fs/HarFileSystem.java
    hadoop/common/trunk/src/test/core/org/apache/hadoop/fs/TestHarFileSystem.java

Modified: hadoop/common/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/CHANGES.txt?rev=911646&r1=911645&r2=911646&view=diff
==============================================================================
--- hadoop/common/trunk/CHANGES.txt (original)
+++ hadoop/common/trunk/CHANGES.txt Thu Feb 18 23:22:52 2010
@@ -210,6 +210,9 @@
     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

Modified: hadoop/common/trunk/src/java/org/apache/hadoop/fs/HarFileSystem.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/src/java/org/apache/hadoop/fs/HarFileSystem.java?rev=911646&r1=911645&r2=911646&view=diff
==============================================================================
--- hadoop/common/trunk/src/java/org/apache/hadoop/fs/HarFileSystem.java (original)
+++ hadoop/common/trunk/src/java/org/apache/hadoop/fs/HarFileSystem.java Thu Feb 18 23:22:52
2010
@@ -540,6 +540,13 @@
   }
 
   /**
+   * @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 
    * file name and the size and start of the file.

Modified: hadoop/common/trunk/src/test/core/org/apache/hadoop/fs/TestHarFileSystem.java
URL: http://svn.apache.org/viewvc/hadoop/common/trunk/src/test/core/org/apache/hadoop/fs/TestHarFileSystem.java?rev=911646&r1=911645&r2=911646&view=diff
==============================================================================
--- hadoop/common/trunk/src/test/core/org/apache/hadoop/fs/TestHarFileSystem.java (original)
+++ hadoop/common/trunk/src/test/core/org/apache/hadoop/fs/TestHarFileSystem.java Thu Feb
18 23:22:52 2010
@@ -45,4 +45,11 @@
       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));
+  }
 }



Mime
View raw message