You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@apex.apache.org by pr...@apache.org on 2017/02/24 15:16:44 UTC
[1/3] apex-core git commit: APEXCORE-636 - user level kerberos support
Repository: apex-core
Updated Branches:
refs/heads/master 1e3d47bef -> 911ccb269
APEXCORE-636 - user level kerberos support
Project: http://git-wip-us.apache.org/repos/asf/apex-core/repo
Commit: http://git-wip-us.apache.org/repos/asf/apex-core/commit/6f1e051c
Tree: http://git-wip-us.apache.org/repos/asf/apex-core/tree/6f1e051c
Diff: http://git-wip-us.apache.org/repos/asf/apex-core/diff/6f1e051c
Branch: refs/heads/master
Commit: 6f1e051c41ea65784f206dffcd03e587d05af89d
Parents: f9101d9
Author: devtagare <de...@gmail.com>
Authored: Tue Feb 7 18:42:17 2017 -0800
Committer: devtagare <de...@gmail.com>
Committed: Thu Feb 23 16:05:43 2017 -0800
----------------------------------------------------------------------
.../java/com/datatorrent/stram/client/StramAppLauncher.java | 5 +++--
.../java/com/datatorrent/stram/client/StramClientUtils.java | 4 +++-
.../java/com/datatorrent/stram/client/StramAppLauncherTest.java | 2 +-
3 files changed, 7 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/apex-core/blob/6f1e051c/engine/src/main/java/com/datatorrent/stram/client/StramAppLauncher.java
----------------------------------------------------------------------
diff --git a/engine/src/main/java/com/datatorrent/stram/client/StramAppLauncher.java b/engine/src/main/java/com/datatorrent/stram/client/StramAppLauncher.java
index 216771d..97420de 100644
--- a/engine/src/main/java/com/datatorrent/stram/client/StramAppLauncher.java
+++ b/engine/src/main/java/com/datatorrent/stram/client/StramAppLauncher.java
@@ -543,8 +543,8 @@ public class StramAppLauncher
private void setTokenRefreshCredentials(LogicalPlan dag, Configuration conf) throws IOException
{
- String principal = StramUserLogin.getPrincipal();
- String keytabPath = conf.get(StramClientUtils.KEY_TAB_FILE);
+ String principal = conf.get(StramClientUtils.TOKEN_REFRESH_PRINCIPAL, StramUserLogin.getPrincipal());
+ String keytabPath = conf.get(StramClientUtils.TOKEN_REFRESH_KEYTAB, conf.get(StramClientUtils.KEY_TAB_FILE));
if (keytabPath == null) {
String keytab = StramUserLogin.getKeytab();
if (keytab != null) {
@@ -558,6 +558,7 @@ public class StramAppLauncher
}
}
}
+ LOG.debug("User principal is {}, keytab is {}", principal, keytabPath);
if ((principal != null) && (keytabPath != null)) {
dag.setAttribute(LogicalPlan.PRINCIPAL, principal);
dag.setAttribute(LogicalPlan.KEY_TAB_FILE, keytabPath);
http://git-wip-us.apache.org/repos/asf/apex-core/blob/6f1e051c/engine/src/main/java/com/datatorrent/stram/client/StramClientUtils.java
----------------------------------------------------------------------
diff --git a/engine/src/main/java/com/datatorrent/stram/client/StramClientUtils.java b/engine/src/main/java/com/datatorrent/stram/client/StramClientUtils.java
index 461f057..050729d 100644
--- a/engine/src/main/java/com/datatorrent/stram/client/StramClientUtils.java
+++ b/engine/src/main/java/com/datatorrent/stram/client/StramClientUtils.java
@@ -110,10 +110,12 @@ public class StramClientUtils
public static final String DT_HDFS_TOKEN_MAX_LIFE_TIME = StreamingApplication.DT_PREFIX + "namenode.delegation.token.max-lifetime";
public static final String HDFS_TOKEN_MAX_LIFE_TIME = "dfs.namenode.delegation.token.max-lifetime";
public static final String DT_RM_TOKEN_MAX_LIFE_TIME = StreamingApplication.DT_PREFIX + "resourcemanager.delegation.token.max-lifetime";
+ @Deprecated
public static final String KEY_TAB_FILE = StramUserLogin.DT_AUTH_PREFIX + "store.keytab";
public static final String TOKEN_ANTICIPATORY_REFRESH_FACTOR = StramUserLogin.DT_AUTH_PREFIX + "token.refresh.factor";
public static final long DELEGATION_TOKEN_MAX_LIFETIME_DEFAULT = 7 * 24 * 60 * 60 * 1000;
-
+ public static final String TOKEN_REFRESH_PRINCIPAL = StramUserLogin.DT_AUTH_PREFIX + "token.refresh.principal";
+ public static final String TOKEN_REFRESH_KEYTAB = StramUserLogin.DT_AUTH_PREFIX + "token.refresh.keytab";
/**
* TBD<p>
* <br>
http://git-wip-us.apache.org/repos/asf/apex-core/blob/6f1e051c/engine/src/test/java/com/datatorrent/stram/client/StramAppLauncherTest.java
----------------------------------------------------------------------
diff --git a/engine/src/test/java/com/datatorrent/stram/client/StramAppLauncherTest.java b/engine/src/test/java/com/datatorrent/stram/client/StramAppLauncherTest.java
index ad1dbd6..5d4c84b 100644
--- a/engine/src/test/java/com/datatorrent/stram/client/StramAppLauncherTest.java
+++ b/engine/src/test/java/com/datatorrent/stram/client/StramAppLauncherTest.java
@@ -98,7 +98,7 @@ public class StramAppLauncherTest
{
Configuration conf = new Configuration(false);
File storeKeytab = new File(dfsDir, "keytab2");
- conf.set(StramClientUtils.KEY_TAB_FILE, storeKeytab.getPath());
+ conf.set(StramClientUtils.TOKEN_REFRESH_KEYTAB, storeKeytab.getPath());
StramUserLogin.authenticate(principal, sourceKeytab.getPath());
LogicalPlan dag = applyTokenRefreshKeytab(FileSystem.newInstance(conf), conf);
Assert.assertEquals("Token refresh principal", principal, dag.getValue(LogicalPlan.PRINCIPAL));
[2/3] apex-core git commit: Merge branch 'APEXCORE-636' of
github.com:devtagare/incubator-apex-core
Posted by pr...@apache.org.
Merge branch 'APEXCORE-636' of github.com:devtagare/incubator-apex-core
Project: http://git-wip-us.apache.org/repos/asf/apex-core/repo
Commit: http://git-wip-us.apache.org/repos/asf/apex-core/commit/a98cc938
Tree: http://git-wip-us.apache.org/repos/asf/apex-core/tree/a98cc938
Diff: http://git-wip-us.apache.org/repos/asf/apex-core/diff/a98cc938
Branch: refs/heads/master
Commit: a98cc938bbfdac9cf0507ea379fdf71282d01814
Parents: 7106b76 6f1e051
Author: Pramod Immaneni <pr...@datatorrent.com>
Authored: Fri Feb 24 07:13:27 2017 -0800
Committer: Pramod Immaneni <pr...@datatorrent.com>
Committed: Fri Feb 24 07:13:27 2017 -0800
----------------------------------------------------------------------
.../java/com/datatorrent/stram/client/StramAppLauncher.java | 5 +++--
.../java/com/datatorrent/stram/client/StramClientUtils.java | 4 +++-
.../java/com/datatorrent/stram/client/StramAppLauncherTest.java | 2 +-
3 files changed, 7 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
[3/3] apex-core git commit: Merge branch 'master' of
https://git-wip-us.apache.org/repos/asf/apex-core
Posted by pr...@apache.org.
Merge branch 'master' of https://git-wip-us.apache.org/repos/asf/apex-core
Project: http://git-wip-us.apache.org/repos/asf/apex-core/repo
Commit: http://git-wip-us.apache.org/repos/asf/apex-core/commit/911ccb26
Tree: http://git-wip-us.apache.org/repos/asf/apex-core/tree/911ccb26
Diff: http://git-wip-us.apache.org/repos/asf/apex-core/diff/911ccb26
Branch: refs/heads/master
Commit: 911ccb269c575f759cd91fe154b05cbf8156bc2a
Parents: a98cc93 1e3d47b
Author: Pramod Immaneni <pr...@datatorrent.com>
Authored: Fri Feb 24 07:16:17 2017 -0800
Committer: Pramod Immaneni <pr...@datatorrent.com>
Committed: Fri Feb 24 07:16:17 2017 -0800
----------------------------------------------------------------------
.../stram/codec/DefaultStatefulStreamCodec.java | 22 ++++-----
.../stram/codec/StatefulStreamCodec.java | 6 +--
.../codec/DefaultStatefulStreamCodecTest.java | 50 ++++++++++++--------
3 files changed, 43 insertions(+), 35 deletions(-)
----------------------------------------------------------------------