hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From szets...@apache.org
Subject svn commit: r750241 - in /hadoop/core/branches/branch-0.19: CHANGES.txt src/test/org/apache/hadoop/hdfs/DataNodeCluster.java
Date Wed, 04 Mar 2009 23:56:12 GMT
Author: szetszwo
Date: Wed Mar  4 23:56:12 2009
New Revision: 750241

URL: http://svn.apache.org/viewvc?rev=750241&view=rev
Log:
HADOOP-5384. Fix a problem that DataNodeCluster creates blocks with generationStamp == 1.
 (szetszwo)

Modified:
    hadoop/core/branches/branch-0.19/CHANGES.txt
    hadoop/core/branches/branch-0.19/src/test/org/apache/hadoop/hdfs/DataNodeCluster.java

Modified: hadoop/core/branches/branch-0.19/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/core/branches/branch-0.19/CHANGES.txt?rev=750241&r1=750240&r2=750241&view=diff
==============================================================================
--- hadoop/core/branches/branch-0.19/CHANGES.txt (original)
+++ hadoop/core/branches/branch-0.19/CHANGES.txt Wed Mar  4 23:56:12 2009
@@ -35,6 +35,9 @@
     HADOOP-4638. Fixes job recovery to not crash the job tracker for problems
     with a single job file. (Amar Kamat via yhemanth)
 
+    HADOOP-5384. Fix a problem that DataNodeCluster creates blocks with
+    generationStamp == 1.  (szetszwo)
+
 Release 0.19.1 - 2009-02-23
 
   INCOMPATIBLE CHANGES

Modified: hadoop/core/branches/branch-0.19/src/test/org/apache/hadoop/hdfs/DataNodeCluster.java
URL: http://svn.apache.org/viewvc/hadoop/core/branches/branch-0.19/src/test/org/apache/hadoop/hdfs/DataNodeCluster.java?rev=750241&r1=750240&r2=750241&view=diff
==============================================================================
--- hadoop/core/branches/branch-0.19/src/test/org/apache/hadoop/hdfs/DataNodeCluster.java
(original)
+++ hadoop/core/branches/branch-0.19/src/test/org/apache/hadoop/hdfs/DataNodeCluster.java
Wed Mar  4 23:56:12 2009
@@ -24,12 +24,10 @@
 import java.util.Random;
 
 import org.apache.hadoop.conf.Configuration;
+import org.apache.hadoop.fs.FileSystem;
 import org.apache.hadoop.hdfs.protocol.Block;
-import org.apache.hadoop.hdfs.server.common.HdfsConstants;
 import org.apache.hadoop.hdfs.server.common.HdfsConstants.StartupOption;
 import org.apache.hadoop.hdfs.server.datanode.SimulatedFSDataset;
-import org.apache.hadoop.fs.FileSystem;
-import org.apache.hadoop.fs.Path;
 import org.apache.hadoop.net.DNS;
 
 
@@ -196,7 +194,8 @@
         long blkid = startingBlockId;
         for (int i_dn = 0; i_dn < numDataNodes; ++i_dn) {
           for (int i = 0; i < blocks.length; ++i) {
-            blocks[i] = new Block(blkid++, blockSize, 1);
+            blocks[i] = new Block(blkid++, blockSize,
+                Block.GRANDFATHER_GENERATION_STAMP);
           }
           for (int i = 1; i <= replication; ++i) { 
             // inject blocks for dn_i into dn_i and replica in dn_i's neighbors 



Mime
View raw message