accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From e..@apache.org
Subject svn commit: r1450400 - in /accumulo/branches/1.5/server/src/main/java/org/apache/accumulo/server: master/tableOps/BulkImport.java master/tableOps/TableRangeOp.java tabletserver/TabletServer.java
Date Tue, 26 Feb 2013 20:42:34 GMT
Author: ecn
Date: Tue Feb 26 20:42:34 2013
New Revision: 1450400

URL: http://svn.apache.org/r1450400
Log:
ACCUMULO-1114 improve message reporting

Modified:
    accumulo/branches/1.5/server/src/main/java/org/apache/accumulo/server/master/tableOps/BulkImport.java
    accumulo/branches/1.5/server/src/main/java/org/apache/accumulo/server/master/tableOps/TableRangeOp.java
    accumulo/branches/1.5/server/src/main/java/org/apache/accumulo/server/tabletserver/TabletServer.java

Modified: accumulo/branches/1.5/server/src/main/java/org/apache/accumulo/server/master/tableOps/BulkImport.java
URL: http://svn.apache.org/viewvc/accumulo/branches/1.5/server/src/main/java/org/apache/accumulo/server/master/tableOps/BulkImport.java?rev=1450400&r1=1450399&r2=1450400&view=diff
==============================================================================
--- accumulo/branches/1.5/server/src/main/java/org/apache/accumulo/server/master/tableOps/BulkImport.java
(original)
+++ accumulo/branches/1.5/server/src/main/java/org/apache/accumulo/server/master/tableOps/BulkImport.java
Tue Feb 26 20:42:34 2013
@@ -103,7 +103,8 @@ import org.apache.thrift.TException;
  */
 
 public class BulkImport extends MasterRepo {
-  
+  public static final String FAILURES_TXT = "failures.txt";
+
   private static final long serialVersionUID = 1L;
   
   private static final Logger log = Logger.getLogger(BulkImport.class);
@@ -363,13 +364,13 @@ class CopyFailed extends MasterRepo {
 	  
     FileSystem fs = master.getFileSystem();
 	  
-    if (!fs.exists(new Path(error, "failures.txt")))
+    if (!fs.exists(new Path(error, BulkImport.FAILURES_TXT)))
       return new CleanUpBulkImport(tableId, source, bulk, error);
     
     HashMap<String,String> failures = new HashMap<String,String>();
     HashMap<String,String> loadedFailures = new HashMap<String,String>();
     
-    FSDataInputStream failFile = fs.open(new Path(error, "failures.txt"));
+    FSDataInputStream failFile = fs.open(new Path(error, BulkImport.FAILURES_TXT));
     BufferedReader in = new BufferedReader(new InputStreamReader(failFile));
     try {
       String line = null;
@@ -408,7 +409,7 @@ class CopyFailed extends MasterRepo {
       Path orig = new Path(failure);
       Path dest = new Path(error, orig.getName());
       fs.rename(orig, dest);
-      log.debug("tid " + tid + " renamed " + orig + " to " + dest + ": failed");
+      log.debug("tid " + tid + " renamed " + orig + " to " + dest + ": import failed");
     }
     
     if (loadedFailures.size() > 0) {
@@ -432,7 +433,7 @@ class CopyFailed extends MasterRepo {
       bifCopyQueue.waitUntilDone(workIds);
     }
 
-    fs.delete(new Path(error, "failures.txt"), true);
+    fs.delete(new Path(error, BulkImport.FAILURES_TXT), true);
     return new CleanUpBulkImport(tableId, source, bulk, error);
   }
   
@@ -539,7 +540,7 @@ class LoadFiles extends MasterRepo {
                 failures.addAll(fail);
               }
             } catch (Exception ex) {
-              log.error("rpc failed server:" + server + ", tid:" + tid + " " + ex, ex);
+              log.error("rpc failed server:" + server + ", tid:" + tid + " " + ex);
             } finally {
               ServerClient.close(client);
             }
@@ -556,7 +557,7 @@ class LoadFiles extends MasterRepo {
       }
     }
     
-    FSDataOutputStream failFile = fs.create(new Path(errorDir, "failures.txt"), true);
+    FSDataOutputStream failFile = fs.create(new Path(errorDir, BulkImport.FAILURES_TXT),
true);
     BufferedWriter out = new BufferedWriter(new OutputStreamWriter(failFile));
     try {
       for (String f : filesToLoad) {

Modified: accumulo/branches/1.5/server/src/main/java/org/apache/accumulo/server/master/tableOps/TableRangeOp.java
URL: http://svn.apache.org/viewvc/accumulo/branches/1.5/server/src/main/java/org/apache/accumulo/server/master/tableOps/TableRangeOp.java?rev=1450400&r1=1450399&r2=1450400&view=diff
==============================================================================
--- accumulo/branches/1.5/server/src/main/java/org/apache/accumulo/server/master/tableOps/TableRangeOp.java
(original)
+++ accumulo/branches/1.5/server/src/main/java/org/apache/accumulo/server/master/tableOps/TableRangeOp.java
Tue Feb 26 20:42:34 2013
@@ -92,7 +92,7 @@ class TableRangeOpWait extends MasterRep
   public Repo<Master> call(long tid, Master master) throws Exception {
     Text tableIdText = new Text(tableId);
     MergeInfo mergeInfo = master.getMergeInfo(tableIdText);
-    log.warn("removing merge information " + mergeInfo);
+    log.info("removing merge information " + mergeInfo);
     master.clearMergeState(tableIdText);
     Utils.unreserveTable(tableId, tid, true);
     // We can't add entries to the metadata table if it is offline for this merge.
@@ -159,7 +159,7 @@ public class TableRangeOp extends Master
     Text tableIdText = new Text(tableId);
     MergeInfo mergeInfo = env.getMergeInfo(tableIdText);
     if (mergeInfo.getState() != MergeState.NONE)
-      log.warn("removing merge information " + mergeInfo);
+      log.info("removing merge information " + mergeInfo);
     env.clearMergeState(tableIdText);
     Utils.unreserveTable(tableId, tid, true);
   }

Modified: accumulo/branches/1.5/server/src/main/java/org/apache/accumulo/server/tabletserver/TabletServer.java
URL: http://svn.apache.org/viewvc/accumulo/branches/1.5/server/src/main/java/org/apache/accumulo/server/tabletserver/TabletServer.java?rev=1450400&r1=1450399&r2=1450400&view=diff
==============================================================================
--- accumulo/branches/1.5/server/src/main/java/org/apache/accumulo/server/tabletserver/TabletServer.java
(original)
+++ accumulo/branches/1.5/server/src/main/java/org/apache/accumulo/server/tabletserver/TabletServer.java
Tue Feb 26 20:42:34 2013
@@ -2353,9 +2353,8 @@ public class TabletServer extends Abstra
           log.debug("Failed to unload tablet " + extent + "... it was alread closing or closed
: " + e.getMessage());
         } else {
           log.error("Failed to close tablet " + extent + "... Aborting migration", e);
+          enqueueMasterMessage(new TabletStatusMessage(TabletLoadState.UNLOAD_ERROR, extent));
         }
-        
-        enqueueMasterMessage(new TabletStatusMessage(TabletLoadState.UNLOAD_ERROR, extent));
         return;
       }
       



Mime
View raw message