You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@accumulo.apache.org by el...@apache.org on 2014/06/05 06:43:01 UTC
[19/35] git commit: ACCUMULO-2041 provide alternative name for
entries in a WAL
ACCUMULO-2041 provide alternative name for entries in a WAL
Project: http://git-wip-us.apache.org/repos/asf/accumulo/repo
Commit: http://git-wip-us.apache.org/repos/asf/accumulo/commit/a13f788d
Tree: http://git-wip-us.apache.org/repos/asf/accumulo/tree/a13f788d
Diff: http://git-wip-us.apache.org/repos/asf/accumulo/diff/a13f788d
Branch: refs/heads/ACCUMULO-378
Commit: a13f788d45db934412bbd45da9650110a5cd1dd0
Parents: 459d304
Author: Eric C. Newton <er...@gmail.com>
Authored: Tue Jun 3 14:48:56 2014 -0400
Committer: Eric C. Newton <er...@gmail.com>
Committed: Tue Jun 3 14:48:56 2014 -0400
----------------------------------------------------------------------
.../org/apache/accumulo/tserver/log/LocalWALRecovery.java | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/accumulo/blob/a13f788d/server/tserver/src/main/java/org/apache/accumulo/tserver/log/LocalWALRecovery.java
----------------------------------------------------------------------
diff --git a/server/tserver/src/main/java/org/apache/accumulo/tserver/log/LocalWALRecovery.java b/server/tserver/src/main/java/org/apache/accumulo/tserver/log/LocalWALRecovery.java
index 868188a..191e41b 100644
--- a/server/tserver/src/main/java/org/apache/accumulo/tserver/log/LocalWALRecovery.java
+++ b/server/tserver/src/main/java/org/apache/accumulo/tserver/log/LocalWALRecovery.java
@@ -36,6 +36,7 @@ import org.apache.hadoop.fs.FSDataOutputStream;
import org.apache.hadoop.fs.FileSystem;
import org.apache.hadoop.fs.Path;
import org.apache.hadoop.io.SequenceFile;
+import org.apache.hadoop.io.WritableName;
import org.apache.hadoop.io.SequenceFile.Reader;
import org.apache.log4j.Logger;
@@ -47,8 +48,14 @@ import com.google.common.annotations.VisibleForTesting;
/**
* This class will attempt to rewrite any local WALs to HDFS.
*/
+@SuppressWarnings("deprecation")
public class LocalWALRecovery implements Runnable {
private static final Logger log = Logger.getLogger(LocalWALRecovery.class);
+
+ static {
+ WritableName.addName(LogFileKey.class, org.apache.accumulo.server.logger.LogFileKey.class.getName());
+ WritableName.addName(LogFileValue.class, org.apache.accumulo.server.logger.LogFileValue.class.getName());
+ }
public static void main(String[] args) throws IOException {
AccumuloConfiguration configuration = SiteConfiguration.getInstance(SiteConfiguration.getDefaultConfiguration());
@@ -145,7 +152,6 @@ public class LocalWALRecovery implements Runnable {
Path localWal = new Path(file.toURI());
FileSystem localFs = FileSystem.getLocal(fs.getConf());
- @SuppressWarnings("deprecation")
Reader reader = new SequenceFile.Reader(localFs, localWal, localFs.getConf());
// Reader reader = new SequenceFile.Reader(localFs.getConf(), SequenceFile.Reader.file(localWal));
Path tmp = new Path(options.destination + "/" + name + ".copy");