Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 2F9212009D9 for ; Thu, 19 May 2016 23:02:03 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id 2E165160A00; Thu, 19 May 2016 21:02:03 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 72D541609AE for ; Thu, 19 May 2016 23:02:02 +0200 (CEST) Received: (qmail 93020 invoked by uid 500); 19 May 2016 21:02:01 -0000 Mailing-List: contact dev-help@apex.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@apex.incubator.apache.org Delivered-To: mailing list dev@apex.incubator.apache.org Received: (qmail 93009 invoked by uid 99); 19 May 2016 21:02:01 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd1-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 19 May 2016 21:02:01 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd1-us-west.apache.org (ASF Mail Server at spamd1-us-west.apache.org) with ESMTP id 04043C385F for ; Thu, 19 May 2016 21:02:01 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd1-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -5.446 X-Spam-Level: X-Spam-Status: No, score=-5.446 tagged_above=-999 required=6.31 tests=[KAM_LAZY_DOMAIN_SECURITY=1, RCVD_IN_DNSWL_HI=-5, RCVD_IN_MSPIKE_H3=-0.01, RCVD_IN_MSPIKE_WL=-0.01, RP_MATCHES_RCVD=-1.426] autolearn=disabled Received: from mx2-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd1-us-west.apache.org [10.40.0.7]) (amavisd-new, port 10024) with ESMTP id JN-mFKU9KSu0 for ; Thu, 19 May 2016 21:02:00 +0000 (UTC) Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by mx2-lw-eu.apache.org (ASF Mail Server at mx2-lw-eu.apache.org) with SMTP id 847A760CEF for ; Thu, 19 May 2016 21:01:59 +0000 (UTC) Received: (qmail 92964 invoked by uid 99); 19 May 2016 21:01:58 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 19 May 2016 21:01:58 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 21A19DFB73; Thu, 19 May 2016 21:01:58 +0000 (UTC) From: PramodSSImmaneni To: dev@apex.incubator.apache.org Reply-To: dev@apex.incubator.apache.org References: In-Reply-To: Subject: [GitHub] incubator-apex-core pull request: APEXCORE-460 A keytab passed fro... Content-Type: text/plain Message-Id: <20160519210158.21A19DFB73@git1-us-west.apache.org> Date: Thu, 19 May 2016 21:01:58 +0000 (UTC) archived-at: Thu, 19 May 2016 21:02:03 -0000 Github user PramodSSImmaneni commented on a diff in the pull request: https://github.com/apache/incubator-apex-core/pull/337#discussion_r63954030 --- Diff: engine/src/main/java/com/datatorrent/stram/client/StramAppLauncher.java --- @@ -577,17 +604,9 @@ public ApplicationId launchApp(AppFactory appConfig) throws Exception dag.setAttribute(LogicalPlan.HDFS_TOKEN_LIFE_TIME, hdfsTokenMaxLifeTime); long rmTokenMaxLifeTime = conf.getLong(StramClientUtils.DT_RM_TOKEN_MAX_LIFE_TIME, conf.getLong(YarnConfiguration.DELEGATION_TOKEN_MAX_LIFETIME_KEY, YarnConfiguration.DELEGATION_TOKEN_MAX_LIFETIME_DEFAULT)); dag.setAttribute(LogicalPlan.RM_TOKEN_LIFE_TIME, rmTokenMaxLifeTime); - if (conf.get(StramClientUtils.KEY_TAB_FILE) != null) { - dag.setAttribute(LogicalPlan.KEY_TAB_FILE, conf.get(StramClientUtils.KEY_TAB_FILE)); - } else if (conf.get(StramUserLogin.DT_AUTH_KEYTAB) != null) { - Path localKeyTabPath = new Path(conf.get(StramUserLogin.DT_AUTH_KEYTAB)); - try (FileSystem fs = StramClientUtils.newFileSystemInstance(conf)) { - Path destPath = new Path(StramClientUtils.getDTDFSRootDir(fs, conf), localKeyTabPath.getName()); - if (!fs.exists(destPath)) { - fs.copyFromLocalFile(false, false, localKeyTabPath, destPath); - } - dag.setAttribute(LogicalPlan.KEY_TAB_FILE, destPath.toString()); - } + // TODO:- Need to see if other token refresh attributes are needed if security is not enabled + if (UserGroupInformation.isSecurityEnabled()) { + setTokenRefreshKeytab(dag, conf); --- End diff -- Also change is that it checks if the command line keytab from StramUserLogin.getKeytab() is available --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastructure@apache.org or file a JIRA ticket with INFRA. ---