accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From e..@apache.org
Subject [1/3] git commit: ACCUMULO-1832 prep for command to re-write uris
Date Tue, 05 Nov 2013 18:44:12 GMT
Updated Branches:
  refs/heads/master 8f87c720d -> 6239604c1


ACCUMULO-1832 prep for command to re-write uris


Project: http://git-wip-us.apache.org/repos/asf/accumulo/repo
Commit: http://git-wip-us.apache.org/repos/asf/accumulo/commit/e86a8d06
Tree: http://git-wip-us.apache.org/repos/asf/accumulo/tree/e86a8d06
Diff: http://git-wip-us.apache.org/repos/asf/accumulo/diff/e86a8d06

Branch: refs/heads/master
Commit: e86a8d063e68ff94fb6aaf71a778f3b8c6ba4a9b
Parents: 109c179
Author: Eric Newton <eric.newton@gmail.com>
Authored: Tue Nov 5 13:41:46 2013 -0500
Committer: Eric Newton <eric.newton@gmail.com>
Committed: Tue Nov 5 13:41:46 2013 -0500

----------------------------------------------------------------------
 .../core/client/admin/TableOperationsImpl.java  |  6 +-
 .../core/tabletserver/log/LogEntry.java         | 36 +++++++++
 .../core/util/shell/commands/OnlineCommand.java |  6 +-
 .../master/state/MetaDataTableScanner.java      |  4 +-
 .../master/state/ZooTabletStateStore.java       |  6 +-
 .../accumulo/server/util/MetadataTableUtil.java | 79 ++------------------
 .../server/util/OfflineMetadataScanner.java     |  2 +-
 .../gc/GarbageCollectWriteAheadLogs.java        |  3 +-
 .../java/org/apache/accumulo/master/Master.java | 10 +--
 .../accumulo/master/TabletGroupWatcher.java     |  2 +-
 .../org/apache/accumulo/tserver/Tablet.java     |  4 +-
 .../apache/accumulo/tserver/TabletServer.java   |  4 +-
 12 files changed, 67 insertions(+), 95 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/accumulo/blob/e86a8d06/core/src/main/java/org/apache/accumulo/core/client/admin/TableOperationsImpl.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/accumulo/core/client/admin/TableOperationsImpl.java
b/core/src/main/java/org/apache/accumulo/core/client/admin/TableOperationsImpl.java
index 1b652f9..85d9fa2 100644
--- a/core/src/main/java/org/apache/accumulo/core/client/admin/TableOperationsImpl.java
+++ b/core/src/main/java/org/apache/accumulo/core/client/admin/TableOperationsImpl.java
@@ -1177,8 +1177,10 @@ public class TableOperationsImpl extends TableOperationsHelper {
         range = new KeyExtent(new Text(tableId), null, null).toMetadataRange();
       else
         range = new Range(startRow, lastRow);
-      
-      Scanner scanner = instance.getConnector(credentials.getPrincipal(), credentials.getToken()).createScanner(MetadataTable.NAME,
Authorizations.EMPTY);
+      String metaTable = MetadataTable.NAME;
+      if (tableId.equals(MetadataTable.ID))
+        metaTable = RootTable.NAME;
+      Scanner scanner = instance.getConnector(credentials.getPrincipal(), credentials.getToken()).createScanner(metaTable,
Authorizations.EMPTY);
       scanner = new IsolatedScanner(scanner);
       TabletsSection.TabletColumnFamily.PREV_ROW_COLUMN.fetch(scanner);
       scanner.fetchColumnFamily(TabletsSection.CurrentLocationColumnFamily.NAME);

http://git-wip-us.apache.org/repos/asf/accumulo/blob/e86a8d06/core/src/main/java/org/apache/accumulo/core/tabletserver/log/LogEntry.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/accumulo/core/tabletserver/log/LogEntry.java b/core/src/main/java/org/apache/accumulo/core/tabletserver/log/LogEntry.java
index 7864f2d..fc2da4b 100644
--- a/core/src/main/java/org/apache/accumulo/core/tabletserver/log/LogEntry.java
+++ b/core/src/main/java/org/apache/accumulo/core/tabletserver/log/LogEntry.java
@@ -21,9 +21,14 @@ import java.util.ArrayList;
 import java.util.Arrays;
 import java.util.Collection;
 
+import org.apache.accumulo.core.data.Key;
 import org.apache.accumulo.core.data.KeyExtent;
+import org.apache.accumulo.core.data.Value;
+import org.apache.accumulo.core.metadata.schema.MetadataSchema;
+import org.apache.accumulo.core.util.StringUtil;
 import org.apache.hadoop.io.DataInputBuffer;
 import org.apache.hadoop.io.DataOutputBuffer;
+import org.apache.hadoop.io.Text;
 
 public class LogEntry {
   public KeyExtent extent;
@@ -71,4 +76,35 @@ public class LogEntry {
     this.logSet = logSet;
   }
   
+  static private final Text EMPTY_TEXT = new Text();
+
+  public static LogEntry fromKeyValue(Key key, Value value) {
+    LogEntry result = new LogEntry();
+    result.extent = new KeyExtent(key.getRow(), EMPTY_TEXT);
+    String[] parts = key.getColumnQualifier().toString().split("/", 2);
+    result.server = parts[0];
+    result.filename = parts[1];
+    parts = value.toString().split("\\|");
+    result.tabletId = Integer.parseInt(parts[1]);
+    result.logSet = Arrays.asList(parts[0].split(";"));
+    result.timestamp = key.getTimestamp();
+    return result;
+  }
+  
+  public Text getRow() {
+    return extent.getMetadataEntry();
+  }
+  
+  public Text getColumnFamily() {
+    return MetadataSchema.TabletsSection.LogColumnFamily.NAME;
+  }
+  
+  public Text getColumnQualifier() {
+    return new Text(server + "/" + filename);
+  }
+  
+  public Value getValue() {
+    return new Value((StringUtil.join(logSet, ";") + "|" + tabletId).getBytes());
+  }
+  
 }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/e86a8d06/core/src/main/java/org/apache/accumulo/core/util/shell/commands/OnlineCommand.java
----------------------------------------------------------------------
diff --git a/core/src/main/java/org/apache/accumulo/core/util/shell/commands/OnlineCommand.java
b/core/src/main/java/org/apache/accumulo/core/util/shell/commands/OnlineCommand.java
index bbf2b72..7b6ebe2 100644
--- a/core/src/main/java/org/apache/accumulo/core/util/shell/commands/OnlineCommand.java
+++ b/core/src/main/java/org/apache/accumulo/core/util/shell/commands/OnlineCommand.java
@@ -19,7 +19,7 @@ package org.apache.accumulo.core.util.shell.commands;
 import org.apache.accumulo.core.client.AccumuloException;
 import org.apache.accumulo.core.client.AccumuloSecurityException;
 import org.apache.accumulo.core.client.TableNotFoundException;
-import org.apache.accumulo.core.metadata.MetadataTable;
+import org.apache.accumulo.core.metadata.RootTable;
 import org.apache.accumulo.core.util.shell.Shell;
 import org.apache.commons.cli.CommandLine;
 import org.apache.commons.cli.Option;
@@ -37,8 +37,8 @@ public class OnlineCommand extends TableOperation {
   
   @Override
   protected void doTableOp(final Shell shellState, final String tableName) throws AccumuloException,
AccumuloSecurityException, TableNotFoundException {
-    if (tableName.equals(MetadataTable.NAME)) {
-      Shell.log.info("  The " + MetadataTable.NAME + " is always online.");
+    if (tableName.equals(RootTable.NAME)) {
+      Shell.log.info("  The " + RootTable.NAME + " is always online.");
     } else {
       shellState.getConnector().tableOperations().online(tableName, wait);
       Shell.log.info("Online of table " + tableName + (wait ? " completed." : " initiated..."));

http://git-wip-us.apache.org/repos/asf/accumulo/blob/e86a8d06/server/base/src/main/java/org/apache/accumulo/server/master/state/MetaDataTableScanner.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/master/state/MetaDataTableScanner.java
b/server/base/src/main/java/org/apache/accumulo/server/master/state/MetaDataTableScanner.java
index bae614d..5471fac 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/master/state/MetaDataTableScanner.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/master/state/MetaDataTableScanner.java
@@ -50,7 +50,7 @@ public class MetaDataTableScanner implements Iterator<TabletLocationState>
{
   private static final Logger log = Logger.getLogger(MetaDataTableScanner.class);
   
   BatchScanner mdScanner = null;
-  Iterator<Entry<Key,Value>> iter;
+  Iterator<Entry<Key,Value>> iter = null;
   
   public MetaDataTableScanner(Instance instance, Credentials credentials, Range range, CurrentState
state) {
     this(instance, credentials, range, state, MetadataTable.NAME);
@@ -67,6 +67,8 @@ public class MetaDataTableScanner implements Iterator<TabletLocationState>
{
     } catch (Exception ex) {
       if (mdScanner != null)
         mdScanner.close();
+      iter = null;
+      mdScanner = null;
       throw new RuntimeException(ex);
     }
   }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/e86a8d06/server/base/src/main/java/org/apache/accumulo/server/master/state/ZooTabletStateStore.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/master/state/ZooTabletStateStore.java
b/server/base/src/main/java/org/apache/accumulo/server/master/state/ZooTabletStateStore.java
index 2c5b709..c792917 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/master/state/ZooTabletStateStore.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/master/state/ZooTabletStateStore.java
@@ -23,9 +23,7 @@ import java.util.Iterator;
 import java.util.List;
 
 import org.apache.accumulo.core.metadata.RootTable;
-import org.apache.accumulo.server.master.state.TServerInstance;
-import org.apache.accumulo.server.master.state.TabletLocationState;
-import org.apache.accumulo.server.util.MetadataTableUtil;
+import org.apache.accumulo.core.tabletserver.log.LogEntry;
 import org.apache.commons.lang.NotImplementedException;
 import org.apache.log4j.Logger;
 
@@ -84,7 +82,7 @@ public class ZooTabletStateStore extends TabletStateStore {
           for (String entry : store.getChildren(RootTable.ZROOT_TABLET_WALOGS)) {
             byte[] logInfo = store.get(RootTable.ZROOT_TABLET_WALOGS + "/" + entry);
             if (logInfo != null) {
-              MetadataTableUtil.LogEntry logEntry = new MetadataTableUtil.LogEntry();
+              LogEntry logEntry = new LogEntry();
               logEntry.fromBytes(logInfo);
               logs.add(logEntry.logSet);
               log.debug("root tablet logSet " + logEntry.logSet);

http://git-wip-us.apache.org/repos/asf/accumulo/blob/e86a8d06/server/base/src/main/java/org/apache/accumulo/server/util/MetadataTableUtil.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/util/MetadataTableUtil.java
b/server/base/src/main/java/org/apache/accumulo/server/util/MetadataTableUtil.java
index 6979268..cbe42b7 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/util/MetadataTableUtil.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/util/MetadataTableUtil.java
@@ -18,8 +18,6 @@ package org.apache.accumulo.server.util;
 
 import java.io.IOException;
 import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.Collection;
 import java.util.Collections;
 import java.util.Comparator;
 import java.util.HashMap;
@@ -66,11 +64,11 @@ import org.apache.accumulo.core.metadata.schema.MetadataSchema.TabletsSection.Lo
 import org.apache.accumulo.core.metadata.schema.MetadataSchema.TabletsSection.ScanFileColumnFamily;
 import org.apache.accumulo.core.security.Authorizations;
 import org.apache.accumulo.core.security.Credentials;
+import org.apache.accumulo.core.tabletserver.log.LogEntry;
 import org.apache.accumulo.core.tabletserver.thrift.ConstraintViolationException;
 import org.apache.accumulo.core.util.ColumnFQ;
 import org.apache.accumulo.core.util.FastFormat;
 import org.apache.accumulo.core.util.Pair;
-import org.apache.accumulo.core.util.StringUtil;
 import org.apache.accumulo.core.util.UtilWaitThread;
 import org.apache.accumulo.core.zookeeper.ZooUtil;
 import org.apache.accumulo.fate.zookeeper.IZooReaderWriter;
@@ -88,8 +86,6 @@ import org.apache.accumulo.server.zookeeper.ZooLock;
 import org.apache.accumulo.server.zookeeper.ZooReaderWriter;
 import org.apache.hadoop.fs.FileStatus;
 import org.apache.hadoop.fs.Path;
-import org.apache.hadoop.io.DataInputBuffer;
-import org.apache.hadoop.io.DataOutputBuffer;
 import org.apache.hadoop.io.Text;
 import org.apache.log4j.Logger;
 import org.apache.zookeeper.KeeperException;
@@ -467,55 +463,6 @@ public class MetadataTableUtil {
     bw.close();
   }
 
-  public static class LogEntry {
-    public KeyExtent extent;
-    public long timestamp;
-    public String server;
-    public String filename;
-    public int tabletId;
-    public Collection<String> logSet;
-
-    @Override
-    public String toString() {
-      return extent.toString() + " " + filename + " (" + tabletId + ")";
-    }
-
-    public String getName() {
-      return server + "/" + filename;
-    }
-
-    public byte[] toBytes() throws IOException {
-      DataOutputBuffer out = new DataOutputBuffer();
-      extent.write(out);
-      out.writeLong(timestamp);
-      out.writeUTF(server);
-      out.writeUTF(filename.toString());
-      out.write(tabletId);
-      out.write(logSet.size());
-      for (String s : logSet) {
-        out.writeUTF(s);
-      }
-      return Arrays.copyOf(out.getData(), out.getLength());
-    }
-
-    public void fromBytes(byte bytes[]) throws IOException {
-      DataInputBuffer inp = new DataInputBuffer();
-      inp.reset(bytes, bytes.length);
-      extent = new KeyExtent();
-      extent.readFields(inp);
-      timestamp = inp.readLong();
-      server = inp.readUTF();
-      filename = inp.readUTF();
-      tabletId = inp.read();
-      int count = inp.read();
-      ArrayList<String> logSet = new ArrayList<String>(count);
-      for (int i = 0; i < count; i++)
-        logSet.add(inp.readUTF());
-      this.logSet = logSet;
-    }
-
-  }
-
   static String getZookeeperLogLocation() {
     return ZooUtil.getRoot(HdfsZooInstance.getInstance()) + RootTable.ZROOT_TABLET_WALOGS;
   }
@@ -542,26 +489,12 @@ public class MetadataTableUtil {
         UtilWaitThread.sleep(1000);
       }
     } else {
-      String value = StringUtil.join(entry.logSet, ";") + "|" + entry.tabletId;
-      Mutation m = new Mutation(entry.extent.getMetadataEntry());
-      m.put(LogColumnFamily.NAME, new Text(entry.server + "/" + entry.filename), new Value(value.getBytes()));
+      Mutation m = new Mutation(entry.getRow());
+      m.put(entry.getColumnFamily(), entry.getColumnQualifier(), entry.getValue());
       update(credentials, zooLock, m, entry.extent);
     }
   }
 
-  public static LogEntry entryFromKeyValue(Key key, Value value) {
-    MetadataTableUtil.LogEntry e = new MetadataTableUtil.LogEntry();
-    e.extent = new KeyExtent(key.getRow(), EMPTY_TEXT);
-    String[] parts = key.getColumnQualifier().toString().split("/", 2);
-    e.server = parts[0];
-    e.filename = parts[1];
-    parts = value.toString().split("\\|");
-    e.tabletId = Integer.parseInt(parts[1]);
-    e.logSet = Arrays.asList(parts[0].split(";"));
-    e.timestamp = key.getTimestamp();
-    return e;
-  }
-
   public static String getRootTabletDir() throws IOException {
     IZooReaderWriter zoo = ZooReaderWriter.getInstance();
     String zpath = ZooUtil.getRoot(HdfsZooInstance.getInstance()) + RootTable.ZROOT_TABLET_PATH;
@@ -605,7 +538,7 @@ public class MetadataTableUtil {
         }
 
         if (entry.getKey().getColumnFamily().equals(LogColumnFamily.NAME)) {
-          result.add(entryFromKeyValue(entry.getKey(), entry.getValue()));
+          result.add(LogEntry.fromKeyValue(entry.getKey(), entry.getValue()));
         } else if (entry.getKey().getColumnFamily().equals(DataFileColumnFamily.NAME)) {
           DataFileValue dfv = new DataFileValue(entry.getValue().get());
           sizes.put(new FileRef(fs, entry.getKey()), dfv);
@@ -632,7 +565,7 @@ public class MetadataTableUtil {
         Text row = entry.getKey().getRow();
         if (entry.getKey().getColumnFamily().equals(LogColumnFamily.NAME)) {
           if (row.equals(pattern)) {
-            result.add(entryFromKeyValue(entry.getKey(), entry.getValue()));
+            result.add(LogEntry.fromKeyValue(entry.getKey(), entry.getValue()));
           }
         }
       }
@@ -723,7 +656,7 @@ public class MetadataTableUtil {
         return rootTableEntries.next();
       }
       Entry<Key,Value> entry = metadataEntries.next();
-      return entryFromKeyValue(entry.getKey(), entry.getValue());
+      return LogEntry.fromKeyValue(entry.getKey(), entry.getValue());
     }
 
     @Override

http://git-wip-us.apache.org/repos/asf/accumulo/blob/e86a8d06/server/base/src/main/java/org/apache/accumulo/server/util/OfflineMetadataScanner.java
----------------------------------------------------------------------
diff --git a/server/base/src/main/java/org/apache/accumulo/server/util/OfflineMetadataScanner.java
b/server/base/src/main/java/org/apache/accumulo/server/util/OfflineMetadataScanner.java
index cefec22..cdb18a5 100644
--- a/server/base/src/main/java/org/apache/accumulo/server/util/OfflineMetadataScanner.java
+++ b/server/base/src/main/java/org/apache/accumulo/server/util/OfflineMetadataScanner.java
@@ -49,13 +49,13 @@ import org.apache.accumulo.core.metadata.schema.MetadataSchema;
 import org.apache.accumulo.core.metadata.schema.MetadataSchema.TabletsSection.DataFileColumnFamily;
 import org.apache.accumulo.core.metadata.schema.MetadataSchema.TabletsSection.LogColumnFamily;
 import org.apache.accumulo.core.security.Authorizations;
+import org.apache.accumulo.core.tabletserver.log.LogEntry;
 import org.apache.accumulo.core.util.LocalityGroupUtil;
 import org.apache.accumulo.core.util.TextUtil;
 import org.apache.accumulo.server.client.HdfsZooInstance;
 import org.apache.accumulo.server.conf.ServerConfiguration;
 import org.apache.accumulo.server.fs.VolumeManager;
 import org.apache.accumulo.server.fs.VolumeManagerImpl;
-import org.apache.accumulo.server.util.MetadataTableUtil.LogEntry;
 import org.apache.hadoop.fs.FileStatus;
 import org.apache.hadoop.fs.FileSystem;
 import org.apache.hadoop.fs.Path;

http://git-wip-us.apache.org/repos/asf/accumulo/blob/e86a8d06/server/gc/src/main/java/org/apache/accumulo/gc/GarbageCollectWriteAheadLogs.java
----------------------------------------------------------------------
diff --git a/server/gc/src/main/java/org/apache/accumulo/gc/GarbageCollectWriteAheadLogs.java
b/server/gc/src/main/java/org/apache/accumulo/gc/GarbageCollectWriteAheadLogs.java
index 776d68a..98b7bd6 100644
--- a/server/gc/src/main/java/org/apache/accumulo/gc/GarbageCollectWriteAheadLogs.java
+++ b/server/gc/src/main/java/org/apache/accumulo/gc/GarbageCollectWriteAheadLogs.java
@@ -33,6 +33,7 @@ import org.apache.accumulo.core.client.Instance;
 import org.apache.accumulo.core.conf.AccumuloConfiguration;
 import org.apache.accumulo.core.gc.thrift.GCStatus;
 import org.apache.accumulo.core.gc.thrift.GcCycleStats;
+import org.apache.accumulo.core.tabletserver.log.LogEntry;
 import org.apache.accumulo.core.tabletserver.thrift.TabletClientService;
 import org.apache.accumulo.core.tabletserver.thrift.TabletClientService.Client;
 import org.apache.accumulo.core.util.AddressUtil;
@@ -225,7 +226,7 @@ public class GarbageCollectWriteAheadLogs {
   private int removeMetadataEntries(Map<Path,String> fileToServerMap, Set<Path>
sortedWALogs, GCStatus status) throws IOException, KeeperException,
       InterruptedException {
     int count = 0;
-    Iterator<MetadataTableUtil.LogEntry> iterator = MetadataTableUtil.getLogEntries(SystemCredentials.get());
+    Iterator<LogEntry> iterator = MetadataTableUtil.getLogEntries(SystemCredentials.get());
     while (iterator.hasNext()) {
       for (String entry : iterator.next().logSet) {
         String parts[] = entry.split("/", 2);

http://git-wip-us.apache.org/repos/asf/accumulo/blob/e86a8d06/server/master/src/main/java/org/apache/accumulo/master/Master.java
----------------------------------------------------------------------
diff --git a/server/master/src/main/java/org/apache/accumulo/master/Master.java b/server/master/src/main/java/org/apache/accumulo/master/Master.java
index 8a1a9b2..887f527 100644
--- a/server/master/src/main/java/org/apache/accumulo/master/Master.java
+++ b/server/master/src/main/java/org/apache/accumulo/master/Master.java
@@ -428,9 +428,9 @@ public class Master implements LiveTServerSet.Listener, TableObserver,
CurrentSt
     return result;
   }
 
-  private void checkNotMetadataID(String tableId, TableOperation operation) throws ThriftTableOperationException
{
-    if (MetadataTable.ID.equals(tableId) || RootTable.ID.equals(tableId)) {
-      String why = "Table names cannot be == " + RootTable.NAME + " or " + MetadataTable.NAME;
+  private void checkNotRootID(String tableId, TableOperation operation) throws ThriftTableOperationException
{
+    if (RootTable.ID.equals(tableId)) {
+      String why = "Table name cannot be == " + RootTable.NAME;
       log.warn(why);
       throw new ThriftTableOperationException(tableId, null, operation, TableOperationExceptionType.OTHER,
why);
     }
@@ -908,7 +908,7 @@ public class Master implements LiveTServerSet.Listener, TableObserver,
CurrentSt
         }
         case ONLINE: {
           final String tableId = ByteBufferUtil.toString(arguments.get(0));
-          checkNotMetadataID(tableId, TableOperation.ONLINE);
+          checkNotRootID(tableId, TableOperation.ONLINE);
 
           if (!security.canOnlineOfflineTable(c, tableId, op))
             throw new ThriftSecurityException(c.getPrincipal(), SecurityErrorCode.PERMISSION_DENIED);
@@ -918,7 +918,7 @@ public class Master implements LiveTServerSet.Listener, TableObserver,
CurrentSt
         }
         case OFFLINE: {
           final String tableId = ByteBufferUtil.toString(arguments.get(0));
-          checkNotMetadataID(tableId, TableOperation.OFFLINE);
+          checkNotRootID(tableId, TableOperation.OFFLINE);
 
           if (!security.canOnlineOfflineTable(c, tableId, op))
             throw new ThriftSecurityException(c.getPrincipal(), SecurityErrorCode.PERMISSION_DENIED);

http://git-wip-us.apache.org/repos/asf/accumulo/blob/e86a8d06/server/master/src/main/java/org/apache/accumulo/master/TabletGroupWatcher.java
----------------------------------------------------------------------
diff --git a/server/master/src/main/java/org/apache/accumulo/master/TabletGroupWatcher.java
b/server/master/src/main/java/org/apache/accumulo/master/TabletGroupWatcher.java
index d82ee00..8609105 100644
--- a/server/master/src/main/java/org/apache/accumulo/master/TabletGroupWatcher.java
+++ b/server/master/src/main/java/org/apache/accumulo/master/TabletGroupWatcher.java
@@ -55,11 +55,11 @@ import org.apache.accumulo.core.security.Authorizations;
 import org.apache.accumulo.core.tabletserver.thrift.NotServingTabletException;
 import org.apache.accumulo.core.util.Daemon;
 import org.apache.accumulo.core.util.UtilWaitThread;
-import org.apache.accumulo.server.ServerConstants;
 import org.apache.accumulo.master.Master.TabletGoalState;
 import org.apache.accumulo.master.state.MergeStats;
 import org.apache.accumulo.master.state.TableCounts;
 import org.apache.accumulo.master.state.TableStats;
+import org.apache.accumulo.server.ServerConstants;
 import org.apache.accumulo.server.fs.FileRef;
 import org.apache.accumulo.server.fs.VolumeManager.FileType;
 import org.apache.accumulo.server.master.LiveTServerSet.TServerConnection;

http://git-wip-us.apache.org/repos/asf/accumulo/blob/e86a8d06/server/tserver/src/main/java/org/apache/accumulo/tserver/Tablet.java
----------------------------------------------------------------------
diff --git a/server/tserver/src/main/java/org/apache/accumulo/tserver/Tablet.java b/server/tserver/src/main/java/org/apache/accumulo/tserver/Tablet.java
index 818f978..ee3b243 100644
--- a/server/tserver/src/main/java/org/apache/accumulo/tserver/Tablet.java
+++ b/server/tserver/src/main/java/org/apache/accumulo/tserver/Tablet.java
@@ -89,6 +89,7 @@ import org.apache.accumulo.core.metadata.schema.MetadataSchema.TabletsSection.Sc
 import org.apache.accumulo.core.security.Authorizations;
 import org.apache.accumulo.core.security.ColumnVisibility;
 import org.apache.accumulo.core.security.Credentials;
+import org.apache.accumulo.core.tabletserver.log.LogEntry;
 import org.apache.accumulo.core.util.CachedConfiguration;
 import org.apache.accumulo.core.util.LocalityGroupUtil;
 import org.apache.accumulo.core.util.LocalityGroupUtil.LocalityGroupConfigurationError;
@@ -114,7 +115,6 @@ import org.apache.accumulo.server.tablets.UniqueNameAllocator;
 import org.apache.accumulo.server.util.FileUtil;
 import org.apache.accumulo.server.util.MasterMetadataUtil;
 import org.apache.accumulo.server.util.MetadataTableUtil;
-import org.apache.accumulo.server.util.MetadataTableUtil.LogEntry;
 import org.apache.accumulo.server.util.TabletOperations;
 import org.apache.accumulo.server.zookeeper.ZooReaderWriter;
 import org.apache.accumulo.start.classloader.vfs.AccumuloVFSClassLoader;
@@ -1183,7 +1183,7 @@ public class Tablet {
         Key key = entry.getKey();
         if (key.getRow().equals(row)) {
           if (key.getColumnFamily().equals(LogColumnFamily.NAME)) {
-            logEntries.add(MetadataTableUtil.entryFromKeyValue(key, entry.getValue()));
+            logEntries.add(LogEntry.fromKeyValue(key, entry.getValue()));
           }
         }
       }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/e86a8d06/server/tserver/src/main/java/org/apache/accumulo/tserver/TabletServer.java
----------------------------------------------------------------------
diff --git a/server/tserver/src/main/java/org/apache/accumulo/tserver/TabletServer.java b/server/tserver/src/main/java/org/apache/accumulo/tserver/TabletServer.java
index 2ba25ba..e7ac7fc 100644
--- a/server/tserver/src/main/java/org/apache/accumulo/tserver/TabletServer.java
+++ b/server/tserver/src/main/java/org/apache/accumulo/tserver/TabletServer.java
@@ -116,6 +116,7 @@ import org.apache.accumulo.core.security.AuthorizationContainer;
 import org.apache.accumulo.core.security.Authorizations;
 import org.apache.accumulo.core.security.SecurityUtil;
 import org.apache.accumulo.core.security.thrift.TCredentials;
+import org.apache.accumulo.core.tabletserver.log.LogEntry;
 import org.apache.accumulo.core.tabletserver.thrift.ActiveCompaction;
 import org.apache.accumulo.core.tabletserver.thrift.ActiveScan;
 import org.apache.accumulo.core.tabletserver.thrift.ConstraintViolationException;
@@ -173,7 +174,6 @@ import org.apache.accumulo.server.util.FileSystemMonitor;
 import org.apache.accumulo.server.util.Halt;
 import org.apache.accumulo.server.util.MasterMetadataUtil;
 import org.apache.accumulo.server.util.MetadataTableUtil;
-import org.apache.accumulo.server.util.MetadataTableUtil.LogEntry;
 import org.apache.accumulo.server.util.TServerUtils;
 import org.apache.accumulo.server.util.TServerUtils.ServerAddress;
 import org.apache.accumulo.server.util.time.RelativeTime;
@@ -3004,7 +3004,7 @@ public class TabletServer extends AbstractMetricsImpl implements org.apache.accu
     List<String> logSet = new ArrayList<String>();
     for (DfsLogger log : logs)
       logSet.add(log.getFileName());
-    MetadataTableUtil.LogEntry entry = new MetadataTableUtil.LogEntry();
+    LogEntry entry = new LogEntry();
     entry.extent = extent;
     entry.tabletId = id;
     entry.timestamp = now;


Mime
View raw message