accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vi...@apache.org
Subject git commit: ACCUMULO-1618 - adding trash variable checks to dispersed WAL cleanup code
Date Mon, 09 Sep 2013 16:08:05 GMT
Updated Branches:
  refs/heads/1.5.1-SNAPSHOT f1af6f91d -> 368fe1c44


ACCUMULO-1618 - adding trash variable checks to dispersed WAL cleanup code


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

Branch: refs/heads/1.5.1-SNAPSHOT
Commit: 368fe1c447bf17e91baf7ced2049c9ac611f1b96
Parents: f1af6f9
Author: John Vines <jvines@gmail.com>
Authored: Mon Sep 9 11:44:57 2013 -0400
Committer: John Vines <jvines@gmail.com>
Committed: Mon Sep 9 11:44:57 2013 -0400

----------------------------------------------------------------------
 .../main/java/org/apache/accumulo/server/tabletserver/Tablet.java  | 2 +-
 .../java/org/apache/accumulo/server/tabletserver/TabletServer.java | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/accumulo/blob/368fe1c4/server/src/main/java/org/apache/accumulo/server/tabletserver/Tablet.java
----------------------------------------------------------------------
diff --git a/server/src/main/java/org/apache/accumulo/server/tabletserver/Tablet.java b/server/src/main/java/org/apache/accumulo/server/tabletserver/Tablet.java
index 7223738..6162105 100644
--- a/server/src/main/java/org/apache/accumulo/server/tabletserver/Tablet.java
+++ b/server/src/main/java/org/apache/accumulo/server/tabletserver/Tablet.java
@@ -1042,7 +1042,7 @@ public class Tablet {
           Trash trash = new Trash(fs, fs.getConf());
           for (Path path : oldDatafiles) {
             Path deleteFile = new Path(location + "/delete+" + compactName + "+" + path.getName());
-            if (!trash.moveToTrash(deleteFile))
+            if (acuTableConf.getBoolean(Property.GC_TRASH_IGNORE) || !trash.moveToTrash(deleteFile))
               fs.delete(deleteFile, true);
           }
         }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/368fe1c4/server/src/main/java/org/apache/accumulo/server/tabletserver/TabletServer.java
----------------------------------------------------------------------
diff --git a/server/src/main/java/org/apache/accumulo/server/tabletserver/TabletServer.java
b/server/src/main/java/org/apache/accumulo/server/tabletserver/TabletServer.java
index 07d8828..3c936f9 100644
--- a/server/src/main/java/org/apache/accumulo/server/tabletserver/TabletServer.java
+++ b/server/src/main/java/org/apache/accumulo/server/tabletserver/TabletServer.java
@@ -2095,7 +2095,7 @@ public class TabletServer extends AbstractMetricsImpl implements org.apache.accu
             log.info("Deleting walog " + filename);
             Trash trash = new Trash(fs, fs.getConf());
             Path sourcePath = new Path(source);
-            if (!trash.moveToTrash(sourcePath) && !fs.delete(sourcePath, true))
+            if (!(!acuConf.getBoolean(Property.GC_TRASH_IGNORE) && trash.moveToTrash(sourcePath))
&& !fs.delete(sourcePath, true))
               log.warn("Failed to delete walog " + source);
             Path recoveryPath = new Path(Constants.getRecoveryDir(acuConf), filename);
             try {


Mime
View raw message