hadoop-hdfs-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rang...@apache.org
Subject svn commit: r794953 - in /hadoop/hdfs/trunk: CHANGES.txt src/test/hdfs/org/apache/hadoop/hdfs/server/namenode/CreateEditsLog.java
Date Fri, 17 Jul 2009 03:55:49 GMT
Author: rangadi
Date: Fri Jul 17 03:55:49 2009
New Revision: 794953

URL: http://svn.apache.org/viewvc?rev=794953&view=rev
Log:
HDFS-463. CreateEditLog utility broken after HDFS-396 (URI for
FSImage). (Suresh Srinivas via rangadi)

Modified:
    hadoop/hdfs/trunk/CHANGES.txt
    hadoop/hdfs/trunk/src/test/hdfs/org/apache/hadoop/hdfs/server/namenode/CreateEditsLog.java

Modified: hadoop/hdfs/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/hdfs/trunk/CHANGES.txt?rev=794953&r1=794952&r2=794953&view=diff
==============================================================================
--- hadoop/hdfs/trunk/CHANGES.txt (original)
+++ hadoop/hdfs/trunk/CHANGES.txt Fri Jul 17 03:55:49 2009
@@ -83,6 +83,9 @@
     HDFS-445. pread() does not pick up changes to block locations. 
     (Kan Zhang via rangadi) 
 
+    HDFS-463. CreateEditLog utility broken after HDFS-396 (URI for
+    FSImage). (Suresh Srinivas via rangadi)
+
 Release 0.20.1 - Unreleased
 
   IMPROVEMENTS

Modified: hadoop/hdfs/trunk/src/test/hdfs/org/apache/hadoop/hdfs/server/namenode/CreateEditsLog.java
URL: http://svn.apache.org/viewvc/hadoop/hdfs/trunk/src/test/hdfs/org/apache/hadoop/hdfs/server/namenode/CreateEditsLog.java?rev=794953&r1=794952&r2=794953&view=diff
==============================================================================
--- hadoop/hdfs/trunk/src/test/hdfs/org/apache/hadoop/hdfs/server/namenode/CreateEditsLog.java
(original)
+++ hadoop/hdfs/trunk/src/test/hdfs/org/apache/hadoop/hdfs/server/namenode/CreateEditsLog.java
Fri Jul 17 03:55:49 2009
@@ -54,7 +54,7 @@
 public class CreateEditsLog {
   static final String BASE_PATH = "/createdViaInjectingInEditsLog";
   static final String EDITS_DIR = "/tmp/EditsLogOut";
-  static String edits_dir = "file:// " + EDITS_DIR; // process as URI
+  static String edits_dir = EDITS_DIR;
   static final public long BLOCK_GENERATION_STAMP =
     GenerationStamp.FIRST_VALID_STAMP;
   
@@ -198,16 +198,9 @@
       }
     }
     
-    FSImage fsImage = null;
-    try {
-      fsImage = new FSImage(new URI(edits_dir));
-    } catch (URISyntaxException use) {
-      throw new IOException("Error while processing URI: " + edits_dir + 
-          ". The full error message was: " + use.getMessage());
-    }
+    FSImage fsImage = new FSImage(editsLogDir.getAbsoluteFile().toURI());
     FileNameGenerator nameGenerator = new FileNameGenerator(BASE_PATH, 100);
 
-
     FSEditLog editLog = fsImage.getEditLog();
     editLog.createEditLogFile(fsImage.getFsEditName());
     editLog.open();



Mime
View raw message