hbase-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From te...@apache.org
Subject svn commit: r1358989 - in /hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver: HRegion.java Store.java
Date Mon, 09 Jul 2012 09:14:27 GMT
Author: tedyu
Date: Mon Jul  9 09:14:27 2012
New Revision: 1358989

URL: http://svn.apache.org/viewvc?rev=1358989&view=rev
Log:
HBASE-6350 Some logging improvements for RegionServer bulk loading (Harsh J)


Modified:
    hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java
    hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/Store.java

Modified: hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java
URL: http://svn.apache.org/viewvc/hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java?rev=1358989&r1=1358988&r2=1358989&view=diff
==============================================================================
--- hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java
(original)
+++ hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/HRegion.java
Mon Jul  9 09:14:27 2012
@@ -3342,9 +3342,9 @@ public class HRegion implements HeapSize
 
       // validation failed because of some sort of IO problem.
       if (ioes.size() != 0) {
-        LOG.error("There were IO errors when checking if bulk load is ok.  " +
-            "throwing exception!");
-        throw MultipleIOException.createIOException(ioes);
+        IOException e = MultipleIOException.createIOException(ioes);
+        LOG.error("There were one or more IO errors when checking if the bulk load is ok.",
e);
+        throw e;
       }
 
       for (Pair<byte[], String> p : familyPaths) {
@@ -3354,12 +3354,12 @@ public class HRegion implements HeapSize
         try {
           store.bulkLoadHFile(path);
         } catch (IOException ioe) {
-          // a failure here causes an atomicity violation that we currently
-          // cannot recover from since it is likely a failed hdfs operation.
+          // A failure here can cause an atomicity violation that we currently
+          // cannot recover from since it is likely a failed HDFS operation.
 
           // TODO Need a better story for reverting partial failures due to HDFS.
           LOG.error("There was a partial failure due to IO when attempting to" +
-              " load " + Bytes.toString(p.getFirst()) + " : "+ p.getSecond());
+              " load " + Bytes.toString(p.getFirst()) + " : "+ p.getSecond(), ioe);
           throw ioe;
         }
       }

Modified: hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/Store.java
URL: http://svn.apache.org/viewvc/hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/Store.java?rev=1358989&r1=1358988&r2=1358989&view=diff
==============================================================================
--- hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/Store.java
(original)
+++ hbase/trunk/hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/Store.java
Mon Jul  9 09:14:27 2012
@@ -564,14 +564,14 @@ public class Store extends SchemaConfigu
   void bulkLoadHFile(String srcPathStr) throws IOException {
     Path srcPath = new Path(srcPathStr);
 
-    // Move the file if it's on another filesystem
+    // Copy the file if it's on another filesystem
     FileSystem srcFs = srcPath.getFileSystem(conf);
     if (!srcFs.equals(fs)) {
-      LOG.info("File " + srcPath + " on different filesystem than " +
-          "destination store - moving to this filesystem.");
+      LOG.info("Bulk-load file " + srcPath + " is on different filesystem than " +
+          "the destination store. Copying file over to destination filesystem.");
       Path tmpPath = getTmpPath();
       FileUtil.copy(srcFs, srcPath, fs, tmpPath, false, conf);
-      LOG.info("Copied to temporary path on dst filesystem: " + tmpPath);
+      LOG.info("Copied " + srcPath + " to temporary path on destination filesystem: " + tmpPath);
       srcPath = tmpPath;
     }
 
@@ -585,7 +585,7 @@ public class Store extends SchemaConfigu
 
     sf.createReader();
 
-    LOG.info("Moved hfile " + srcPath + " into store directory " +
+    LOG.info("Moved HFile " + srcPath + " into store directory " +
         homedir + " - updating store file list.");
 
     // Append the new storefile into the list



Mime
View raw message