incubator-blur-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From amccu...@apache.org
Subject [3/4] git commit: BLUR-ID:40 fix failing tests
Date Tue, 30 Oct 2012 02:38:21 GMT
BLUR-ID:40 fix failing tests

Signed-off-by: Aaron McCurry <amccurry@gmail.com>


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

Branch: refs/heads/lucene-4.0.0
Commit: f1e0b3d16f2729fd09eeda70d5d391e718a7f693
Parents: 7d1562c
Author: Gagan <gagandeepjuneja@gmail.com>
Authored: Fri Oct 26 17:16:59 2012 +0530
Committer: Aaron McCurry <amccurry@gmail.com>
Committed: Mon Oct 29 22:24:08 2012 -0400

----------------------------------------------------------------------
 .../src/test/java/org/apache/blur/MiniCluster.java |    5 +++++
 .../org/apache/blur/thrift/BlurClusterTest.java    |    3 +++
 2 files changed, 8 insertions(+), 0 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/f1e0b3d1/src/blur-core/src/test/java/org/apache/blur/MiniCluster.java
----------------------------------------------------------------------
diff --git a/src/blur-core/src/test/java/org/apache/blur/MiniCluster.java b/src/blur-core/src/test/java/org/apache/blur/MiniCluster.java
index ae7fe02..1854f52 100644
--- a/src/blur-core/src/test/java/org/apache/blur/MiniCluster.java
+++ b/src/blur-core/src/test/java/org/apache/blur/MiniCluster.java
@@ -62,6 +62,7 @@ import org.apache.blur.thrift.generated.Row;
 import org.apache.blur.thrift.generated.RowMutation;
 import org.apache.blur.thrift.generated.TableDescriptor;
 import org.apache.blur.utils.BlurUtil;
+import org.apache.commons.lang.StringUtils;
 import org.apache.hadoop.conf.Configuration;
 import org.apache.hadoop.fs.FileSystem;
 import org.apache.hadoop.hdfs.MiniDFSCluster;
@@ -426,6 +427,10 @@ public abstract class MiniCluster {
   public static void startDfs(Configuration conf, boolean format, String name) {
     File path = new File(TMPDIR, name);
     System.setProperty("test.build.data", path.getAbsolutePath());
+    String permission = System.getProperty("dfs.datanode.data.dir.perm");
+    if(StringUtils.isNotBlank(permission)){
+      conf.set("dfs.datanode.data.dir.perm", permission);
+    }
     try {
       cluster = new MiniDFSCluster(conf, 1, true, (String[]) null);
       cluster.waitActive();

http://git-wip-us.apache.org/repos/asf/incubator-blur/blob/f1e0b3d1/src/blur-core/src/test/java/org/apache/blur/thrift/BlurClusterTest.java
----------------------------------------------------------------------
diff --git a/src/blur-core/src/test/java/org/apache/blur/thrift/BlurClusterTest.java b/src/blur-core/src/test/java/org/apache/blur/thrift/BlurClusterTest.java
index 6dbc2cc..bc5ca2f 100644
--- a/src/blur-core/src/test/java/org/apache/blur/thrift/BlurClusterTest.java
+++ b/src/blur-core/src/test/java/org/apache/blur/thrift/BlurClusterTest.java
@@ -47,6 +47,9 @@ public class BlurClusterTest {
 
   @BeforeClass
   public static void startCluster() {
+    // Considering default umask in 002 and deirectories are created with 775 permissions.
+    // This can be altered in case umask value is different.
+    System.setProperty("dfs.datanode.data.dir.perm", "775");
     MiniCluster.startBlurCluster("cluster", 2, 3);
   }
 


Mime
View raw message