hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From st...@apache.org
Subject svn commit: r770006 - in /hadoop/hbase/trunk: CHANGES.txt src/java/org/apache/hadoop/hbase/HConstants.java src/java/org/apache/hadoop/hbase/regionserver/HLog.java
Date Wed, 29 Apr 2009 23:44:47 GMT
Author: stack
Date: Wed Apr 29 23:44:47 2009
New Revision: 770006

URL: http://svn.apache.org/viewvc?rev=770006&view=rev
Log:
HBASE-1112 we will lose data if the table name happens to be the logs' dir name

Modified:
    hadoop/hbase/trunk/CHANGES.txt
    hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/HConstants.java
    hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/regionserver/HLog.java

Modified: hadoop/hbase/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/hadoop/hbase/trunk/CHANGES.txt?rev=770006&r1=770005&r2=770006&view=diff
==============================================================================
--- hadoop/hbase/trunk/CHANGES.txt (original)
+++ hadoop/hbase/trunk/CHANGES.txt Wed Apr 29 23:44:47 2009
@@ -180,6 +180,8 @@
                regions in a table (Vimal Mathew via Stack)
    HBASE-1271  Allow multiple tests to run on one machine
                (Evgeny Ryabitskiy via Stack)
+   HBASE-1112  we will lose data if the table name happens to be the logs' dir
+               name (Samuel Guo via Stack)
 
 Release 0.19.0 - 01/21/2009
   INCOMPATIBLE CHANGES

Modified: hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/HConstants.java
URL: http://svn.apache.org/viewvc/hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/HConstants.java?rev=770006&r1=770005&r2=770006&view=diff
==============================================================================
--- hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/HConstants.java (original)
+++ hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/HConstants.java Wed Apr 29 23:44:47
2009
@@ -117,8 +117,9 @@
   /** Parameter name for HBase instance root directory */
   static final String HBASE_DIR = "hbase.rootdir";
   
-  /** Used to construct the name of the log directory for a region server */
-  static final String HREGION_LOGDIR_NAME = "log";
+  /** Used to construct the name of the log directory for a region server 
+   * Use '@' as a special character to seperate the log files from table data */
+  static final String HREGION_LOGDIR_NAME = "@LOGS@";
 
   /** Name of old log file for reconstruction */
   static final String HREGION_OLDLOGFILE_NAME = "oldlogfile.log";
@@ -284,4 +285,4 @@
   
   public static final int MODIFY_TABLE_FLUSH = MODIFY_CLOSE_REGION + 1;
   public static final int MODIFY_TABLE_MAJOR_COMPACT = MODIFY_TABLE_FLUSH + 1;
-}
\ No newline at end of file
+}

Modified: hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/regionserver/HLog.java
URL: http://svn.apache.org/viewvc/hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/regionserver/HLog.java?rev=770006&r1=770005&r2=770006&view=diff
==============================================================================
--- hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/regionserver/HLog.java (original)
+++ hadoop/hbase/trunk/src/java/org/apache/hadoop/hbase/regionserver/HLog.java Wed Apr 29
23:44:47 2009
@@ -870,7 +870,7 @@
    */
   public static String getHLogDirectoryName(String serverName) {
     StringBuilder dirName = new StringBuilder(HConstants.HREGION_LOGDIR_NAME);
-    dirName.append("_");
+    dirName.append("/");
     dirName.append(serverName);
     return dirName.toString();
   }



Mime
View raw message