falcon-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rostafiyc...@apache.org
Subject git commit: FALCON-826 unify staging and working dir requirements. Contributed by Raghav Kumar Gautam
Date Wed, 22 Oct 2014 08:51:36 GMT
Repository: incubator-falcon
Updated Branches:
  refs/heads/master 07a0b588e -> e4eacd221


FALCON-826 unify staging and working dir requirements. Contributed by Raghav Kumar Gautam


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

Branch: refs/heads/master
Commit: e4eacd2216b5dc55331a8ad9acc484bba83814c7
Parents: 07a0b58
Author: Ruslan Ostafiychuk <rostafiychuk@apache.org>
Authored: Wed Oct 22 11:50:06 2014 +0300
Committer: Ruslan Ostafiychuk <rostafiychuk@apache.org>
Committed: Wed Oct 22 11:50:06 2014 +0300

----------------------------------------------------------------------
 falcon-regression/CHANGES.txt                         |  3 +++
 falcon-regression/README.md                           |  9 +++++++++
 .../falcon/regression/core/util/BundleUtil.java       | 14 ++++++++++++++
 3 files changed, 26 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/e4eacd22/falcon-regression/CHANGES.txt
----------------------------------------------------------------------
diff --git a/falcon-regression/CHANGES.txt b/falcon-regression/CHANGES.txt
index 88cd808..7b48b74 100644
--- a/falcon-regression/CHANGES.txt
+++ b/falcon-regression/CHANGES.txt
@@ -14,6 +14,9 @@ Trunk (Unreleased)
    via Samarth Gupta)
 
   IMPROVEMENTS
+   FALCON-826 unify staging and working dir requirements (Raghav Kumar Gautam via Ruslan
+   Ostafiychuk)
+
    FALCON-811 falcon superuser should be used instead of admin (Raghav Kumar Gautam via Ruslan
    Ostafiychuk)
 

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/e4eacd22/falcon-regression/README.md
----------------------------------------------------------------------
diff --git a/falcon-regression/README.md b/falcon-regression/README.md
index 691e17c..12b15dd 100644
--- a/falcon-regression/README.md
+++ b/falcon-regression/README.md
@@ -81,6 +81,15 @@ For each cluster specify properties:
     cluster1.service_stop_cmd = /usr/lib/falcon/bin/falcon-stop
     cluster1.service_start_cmd = /usr/lib/falcon/bin/falcon-start
 
+Setting up HDFS Dirs
+--------------------
+On all cluster as user that started falcon server do:
+
+    hdfs dfs -mkdir -p  /tmp/falcon-regression-staging
+    hdfs dfs -chmod 777 /tmp/falcon-regression-staging
+    hdfs dfs -mkdir -p  /tmp/falcon-regression-working
+    hdfs dfs -chmod 755 /tmp/falcon-regression-working
+
 Running Tests
 -------------
 After creating Merlin.properties file. You can run the following commands to run the tests.

http://git-wip-us.apache.org/repos/asf/incubator-falcon/blob/e4eacd22/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/BundleUtil.java
----------------------------------------------------------------------
diff --git a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/BundleUtil.java
b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/BundleUtil.java
index dfa9992..b9acc3b 100644
--- a/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/BundleUtil.java
+++ b/falcon-regression/merlin-core/src/main/java/org/apache/falcon/regression/core/util/BundleUtil.java
@@ -20,6 +20,7 @@ package org.apache.falcon.regression.core.util;
 
 import org.apache.commons.io.FileUtils;
 import org.apache.commons.io.IOUtils;
+import org.apache.falcon.entity.v0.cluster.Location;
 import org.apache.falcon.regression.Entities.ClusterMerlin;
 import org.apache.falcon.regression.Entities.FeedMerlin;
 import org.apache.falcon.regression.Entities.ProcessMerlin;
@@ -102,8 +103,21 @@ public final class BundleUtil {
             if (data.contains("uri:ivory:cluster:0.1") || data.contains("uri:falcon:cluster:0.1"))
{
                 LOGGER.info("data been added to cluster");
                 ClusterMerlin clusterMerlin = new ClusterMerlin(data);
+                //set ACL
                 clusterMerlin.setACL(MerlinConstants.CURRENT_USER_NAME,
                         MerlinConstants.CURRENT_USER_GROUP, "*");
+                //set staging and working locations
+                clusterMerlin.getLocations().getLocations().clear();
+                final Location staging = new Location();
+                staging.setName("staging");
+                staging.setPath(Config.getProperty("merlin.staging.location",
+                        "/tmp/falcon-regression-staging"));
+                clusterMerlin.getLocations().getLocations().add(staging);
+                final Location working = new Location();
+                working.setName("working");
+                working.setPath(Config.getProperty("merlin.working.location",
+                        "/tmp/falcon-regression-working"));
+                clusterMerlin.getLocations().getLocations().add(working);
                 clusterData = clusterMerlin.toString();
             } else if (data.contains("uri:ivory:feed:0.1")
                     ||


Mime
View raw message