falcon-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sowmya...@apache.org
Subject falcon git commit: FALCON-1487 In secure cluster setup Hcat process/feed scheduling or replication fails. Contributed by Sowmya Ramesh.
Date Tue, 06 Oct 2015 21:35:33 GMT
Repository: falcon
Updated Branches:
  refs/heads/master b921247c3 -> be95c5fc6


FALCON-1487 In secure cluster setup Hcat process/feed scheduling or replication fails. Contributed
by Sowmya Ramesh.


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

Branch: refs/heads/master
Commit: be95c5fc66c9537333d50b96b41680235f5fbc6c
Parents: b921247
Author: Sowmya Ramesh <sramesh@hortonworks.com>
Authored: Tue Oct 6 14:35:24 2015 -0700
Committer: Sowmya Ramesh <sramesh@hortonworks.com>
Committed: Tue Oct 6 14:35:24 2015 -0700

----------------------------------------------------------------------
 CHANGES.txt                                            |  2 ++
 .../org/apache/falcon/oozie/OozieBundleBuilder.java    | 13 +++++++++++++
 2 files changed, 15 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/falcon/blob/be95c5fc/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index 9d584c7..b3d5f0d 100755
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -49,6 +49,8 @@ Trunk (Unreleased)
     FALCON-1403 Revisit IT cleanup and teardown(Narayan Periwal via Pallavi Rao)
 
   BUG FIXES
+    FALCON-1487 In secure cluster setup Hcat process/feed scheduling or replication fails(Sowmya
Ramesh)
+
     FALCON-1339 List feed entities shows scheduled Feed entities as submitted(Balu Vellanki
via Sowmya Ramesh)
 
     FALCON-1499 Lifecycle Retention Issues(Ajay Yadava)

http://git-wip-us.apache.org/repos/asf/falcon/blob/be95c5fc/oozie/src/main/java/org/apache/falcon/oozie/OozieBundleBuilder.java
----------------------------------------------------------------------
diff --git a/oozie/src/main/java/org/apache/falcon/oozie/OozieBundleBuilder.java b/oozie/src/main/java/org/apache/falcon/oozie/OozieBundleBuilder.java
index 8026967..af3f44d 100644
--- a/oozie/src/main/java/org/apache/falcon/oozie/OozieBundleBuilder.java
+++ b/oozie/src/main/java/org/apache/falcon/oozie/OozieBundleBuilder.java
@@ -21,6 +21,7 @@ package org.apache.falcon.oozie;
 import org.apache.falcon.FalconException;
 import org.apache.falcon.entity.ClusterHelper;
 import org.apache.falcon.entity.EntityUtil;
+import org.apache.falcon.entity.HiveUtil;
 import org.apache.falcon.entity.v0.Entity;
 import org.apache.falcon.entity.v0.cluster.Cluster;
 import org.apache.falcon.hadoop.HadoopClientFactory;
@@ -34,6 +35,7 @@ import org.apache.falcon.workflow.engine.AbstractWorkflowEngine;
 import org.apache.hadoop.fs.FileSystem;
 import org.apache.hadoop.fs.Path;
 import org.apache.oozie.client.OozieClient;
+import org.apache.falcon.Tag;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -83,6 +85,17 @@ public abstract class OozieBundleBuilder<T extends Entity> extends
OozieEntityBu
             coord.setAppPath(getStoragePath(coordPath));
             coordProps.put(OozieClient.USER_NAME, CurrentUser.getUser());
             coordProps.setProperty(AbstractWorkflowEngine.NAME_NODE, ClusterHelper.getStorageUrl(cluster));
+            if (EntityUtil.isTableStorageType(cluster, entity)) {
+                Tag tag = EntityUtil.getWorkflowNameTag(coordName, entity);
+                if (tag == Tag.REPLICATION) {
+                    // todo: kludge send source hcat creds for coord dependency check to
pass
+                    String srcClusterName = EntityUtil.getWorkflowNameSuffix(coordName, entity);
+                    coordProps.putAll(HiveUtil.getHiveCredentials(ClusterHelper.getCluster(srcClusterName)));
+                } else {
+                    coordProps.putAll(HiveUtil.getHiveCredentials(cluster));
+                }
+            }
+
             coord.setConfiguration(getConfig(coordProps));
             bundle.getCoordinator().add(coord);
         }


Mime
View raw message