incubator-accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From e..@apache.org
Subject svn commit: r1292415 - in /incubator/accumulo/trunk: ./ src/core/ src/server/ src/server/src/main/java/org/apache/accumulo/server/master/ src/server/src/main/java/org/apache/accumulo/server/master/state/ src/server/src/main/java/org/apache/accumulo/ser...
Date Wed, 22 Feb 2012 17:43:29 GMT
Author: ecn
Date: Wed Feb 22 17:43:29 2012
New Revision: 1292415

URL: http://svn.apache.org/viewvc?rev=1292415&view=rev
Log:
ACCUMULO-424 merge to trunk

Modified:
    incubator/accumulo/trunk/   (props changed)
    incubator/accumulo/trunk/src/core/   (props changed)
    incubator/accumulo/trunk/src/server/   (props changed)
    incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/master/Master.java
    incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/master/state/MergeStats.java
    incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/trace/TraceServer.java
    incubator/accumulo/trunk/src/server/src/test/java/org/apache/accumulo/server/master/TestMergeState.java

Propchange: incubator/accumulo/trunk/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Wed Feb 22 17:43:29 2012
@@ -1,3 +1,3 @@
 /incubator/accumulo/branches/1.3:1190280,1190413,1190420,1190427,1190500,1195622,1195625,1195629,1195635,1196044,1196054,1196057,1196071-1196072,1196106,1197066,1198935,1199383,1203683,1204625,1205547,1205880,1206169,1208031,1209124,1209526,1209532,1209539,1209541,1209587,1209657,1210518,1210571,1210596,1210598,1213424,1214320,1225006,1227215,1227231,1227611,1228195,1230180,1230736,1231043,1236873,1245632
 /incubator/accumulo/branches/1.3.5rc:1209938
-/incubator/accumulo/branches/1.4:1201902-1292029
+/incubator/accumulo/branches/1.4:1201902-1292413

Propchange: incubator/accumulo/trunk/src/core/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Wed Feb 22 17:43:29 2012
@@ -1,3 +1,3 @@
-/incubator/accumulo/branches/1.3.5rc/src/core:1209938
 /incubator/accumulo/branches/1.3/src/core:1190280,1190413,1190420,1190427,1190500,1195622,1195625,1195629,1195635,1196044,1196054,1196057,1196071-1196072,1196106,1197066,1198935,1199383,1203683,1204625,1205547,1205880,1206169,1208031,1209124,1209526,1209532,1209539,1209541,1209587,1209657,1210518,1210571,1210596,1210598,1213424,1214320,1225006,1227215
-/incubator/accumulo/branches/1.4/src/core:1201902-1292029
+/incubator/accumulo/branches/1.3.5rc/src/core:1209938
+/incubator/accumulo/branches/1.4/src/core:1201902-1292413

Propchange: incubator/accumulo/trunk/src/server/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Wed Feb 22 17:43:29 2012
@@ -1,3 +1,3 @@
-/incubator/accumulo/branches/1.3.5rc/src/server:1209938
 /incubator/accumulo/branches/1.3/src/server:1190280,1190413,1190420,1190427,1190500,1195622,1195625,1195629,1195635,1196044,1196054,1196057,1196071-1196072,1196106,1197066,1198935,1199383,1203683,1204625,1205547,1205880,1206169,1208031,1209124,1209526,1209532,1209539,1209541,1209587,1209657,1210518,1210571,1210596,1210598,1213424,1214320,1225006,1227215,1227231,1227611
-/incubator/accumulo/branches/1.4/src/server:1201902-1292029
+/incubator/accumulo/branches/1.3.5rc/src/server:1209938
+/incubator/accumulo/branches/1.4/src/server:1201902-1292413

Modified: incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/master/Master.java
URL: http://svn.apache.org/viewvc/incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/master/Master.java?rev=1292415&r1=1292414&r2=1292415&view=diff
==============================================================================
--- incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/master/Master.java
(original)
+++ incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/master/Master.java
Wed Feb 22 17:43:29 2012
@@ -824,10 +824,10 @@ public class Master implements LiveTServ
           log.error(serverName + " reports assignment failed for tablet " + tablet);
           break;
         case LOADED:
-          nextEvent.event("tablet %s was loaded", tablet);
+          nextEvent.event("tablet %s was loaded on %s", tablet, serverName);
           break;
         case UNLOADED:
-          nextEvent.event("tablet %s was unloaded", tablet);
+          nextEvent.event("tablet %s was unloaded from %s", tablet, serverName);
           break;
         case UNLOAD_ERROR:
           log.error(serverName + " reports unload failed for tablet " + tablet);
@@ -1231,10 +1231,11 @@ public class Master implements LiveTServ
             case SPLITTING:
               return TabletGoalState.HOSTED;
             case WAITING_FOR_CHOPPED:
-              return tls.chopped ? TabletGoalState.UNASSIGNED : TabletGoalState.HOSTED;
             case WAITING_FOR_OFFLINE:
             case MERGING:
-              return TabletGoalState.UNASSIGNED;
+              if (tls.walogs.isEmpty() && tls.chopped)
+                return TabletGoalState.UNASSIGNED;
+              return TabletGoalState.HOSTED;
           }
         }
       }
@@ -1329,7 +1330,7 @@ public class Master implements LiveTServ
             TServerInstance server = tls.getServer();
             TabletState state = tls.getState(currentTServers.keySet());
             stats.update(tableId, state);
-            mergeStats.update(tls.extent, state, tls.chopped);
+            mergeStats.update(tls.extent, state, tls.chopped, !tls.walogs.isEmpty());
             sendChopRequest(mergeStats.getMergeInfo(), state, tls);
             sendSplitRequest(mergeStats.getMergeInfo(), state, tls);
             

Modified: incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/master/state/MergeStats.java
URL: http://svn.apache.org/viewvc/incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/master/state/MergeStats.java?rev=1292415&r1=1292414&r2=1292415&view=diff
==============================================================================
--- incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/master/state/MergeStats.java
(original)
+++ incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/master/state/MergeStats.java
Wed Feb 22 17:43:29 2012
@@ -63,7 +63,7 @@ public class MergeStats {
     return info;
   }
 
-  public void update(KeyExtent ke, TabletState state, boolean chopped) {
+  public void update(KeyExtent ke, TabletState state, boolean chopped, boolean hasWALs) {
     if (info.getState().equals(MergeState.NONE))
       return;
     if (!upperSplit && info.getRange().getEndRow().equals(ke.getPrevEndRow())) {
@@ -78,7 +78,7 @@ public class MergeStats {
       return;
     if (info.needsToBeChopped(ke)) {
       this.needsToBeChopped++;
-      if (chopped)
+      if (chopped && !hasWALs)
         this.chopped++;
     }
     this.total++;
@@ -178,6 +178,9 @@ public class MergeStats {
       if (!tls.extent.getTableId().equals(tableId)) {
         break;
       }
+      if (!tls.walogs.isEmpty()) {
+        return false;
+      }
       
       if (prevExtent == null) {
         // this is the first tablet observed, it must be offline and its prev row must be
less than the start of the merge range
@@ -194,7 +197,7 @@ public class MergeStats {
       
       prevExtent = tls.extent;
 
-      verify.update(tls.extent, tls.getState(master.onlineTabletServers()), tls.chopped);
+      verify.update(tls.extent, tls.getState(master.onlineTabletServers()), tls.chopped,
!tls.walogs.isEmpty());
       // stop when we've seen the tablet just beyond our range
       if (tls.extent.getPrevEndRow() != null && extent.getEndRow() != null &&
tls.extent.getPrevEndRow().compareTo(extent.getEndRow()) > 0) {
         break;

Modified: incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/trace/TraceServer.java
URL: http://svn.apache.org/viewvc/incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/trace/TraceServer.java?rev=1292415&r1=1292414&r2=1292415&view=diff
==============================================================================
--- incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/trace/TraceServer.java
(original)
+++ incubator/accumulo/trunk/src/server/src/main/java/org/apache/accumulo/server/trace/TraceServer.java
Wed Feb 22 17:43:29 2012
@@ -29,6 +29,7 @@ import org.apache.accumulo.core.conf.Acc
 import org.apache.accumulo.core.conf.Property;
 import org.apache.accumulo.core.data.Mutation;
 import org.apache.accumulo.core.data.Value;
+import org.apache.accumulo.core.trace.TraceFormatter;
 import org.apache.accumulo.core.util.AddressUtil;
 import org.apache.accumulo.core.util.UtilWaitThread;
 import org.apache.accumulo.core.zookeeper.ZooUtil;
@@ -152,6 +153,7 @@ public class TraceServer implements Watc
         if (!connector.tableOperations().exists(table)) {
           connector.tableOperations().create(table);
         }
+        connector.tableOperations().setProperty(table, Property.TABLE_FORMATTER_CLASS.getKey(),
TraceFormatter.class.getName());
         break;
       } catch (Exception ex) {
         log.info("waiting to checking/create the trace table: " + ex);

Modified: incubator/accumulo/trunk/src/server/src/test/java/org/apache/accumulo/server/master/TestMergeState.java
URL: http://svn.apache.org/viewvc/incubator/accumulo/trunk/src/server/src/test/java/org/apache/accumulo/server/master/TestMergeState.java?rev=1292415&r1=1292414&r2=1292415&view=diff
==============================================================================
--- incubator/accumulo/trunk/src/server/src/test/java/org/apache/accumulo/server/master/TestMergeState.java
(original)
+++ incubator/accumulo/trunk/src/server/src/test/java/org/apache/accumulo/server/master/TestMergeState.java
Wed Feb 22 17:43:29 2012
@@ -191,7 +191,7 @@ public class TestMergeState {
     MergeStats stats = new MergeStats(state.mergeInfo);
     stats.getMergeInfo().setState(MergeState.WAITING_FOR_OFFLINE);
     for (TabletLocationState tss : metaDataStateStore) {
-      stats.update(tss.extent, tss.getState(state.onlineTabletServers()), tss.chopped);
+      stats.update(tss.extent, tss.getState(state.onlineTabletServers()), tss.chopped, false);
     }
     return stats;
   }



Mime
View raw message