[GitHub] twill pull request #39: (TWILL-225) Refactor TwillPreprer to allow configura...
Github user asfgit closed the pull request at: https://github.com/apache/twill/pull/39 --- 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 infrastruct...@apache.org or file a JIRA ticket with INFRA. ---
[GitHub] twill pull request #39: (TWILL-225) Refactor TwillPreprer to allow configura...
Github user anwar6953 commented on a diff in the pull request: https://github.com/apache/twill/pull/39#discussion_r107265236 --- Diff: twill-yarn/src/main/java/org/apache/twill/yarn/YarnTwillPreparer.java --- @@ -455,21 +475,40 @@ private void saveLogLevels(String runnableName, MaplogL this.logLevels.put(runnableName, newLevels); } + /** + * Creates an {@link Credentials} by copying the {@link Credentials} of the current user. + */ private Credentials createCredentials() { Credentials credentials = new Credentials(); try { credentials.addAll(UserGroupInformation.getCurrentUser().getCredentials()); +} catch (IOException e) { --- End diff -- I guess app submission would fail if caller doesn't acquire required credentials in its own way anyways. --- 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 infrastruct...@apache.org or file a JIRA ticket with INFRA. ---
[GitHub] twill pull request #39: (TWILL-225) Refactor TwillPreprer to allow configura...
Github user chtyim commented on a diff in the pull request: https://github.com/apache/twill/pull/39#discussion_r107264780 --- Diff: twill-yarn/src/main/java/org/apache/twill/yarn/YarnTwillPreparer.java --- @@ -455,21 +475,40 @@ private void saveLogLevels(String runnableName, MaplogL this.logLevels.put(runnableName, newLevels); } + /** + * Creates an {@link Credentials} by copying the {@link Credentials} of the current user. + */ private Credentials createCredentials() { Credentials credentials = new Credentials(); try { credentials.addAll(UserGroupInformation.getCurrentUser().getCredentials()); +} catch (IOException e) { --- End diff -- I don't think so. Even if this call fail, if the caller is able to acquire required credentials in his own way and add them via the `addSecureStore` method, then the app can still be submitted and executed correctly. --- 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 infrastruct...@apache.org or file a JIRA ticket with INFRA. ---
[GitHub] twill pull request #39: (TWILL-225) Refactor TwillPreprer to allow configura...
Github user anwar6953 commented on a diff in the pull request: https://github.com/apache/twill/pull/39#discussion_r107262119 --- Diff: twill-yarn/src/main/java/org/apache/twill/yarn/YarnTwillPreparer.java --- @@ -455,21 +475,40 @@ private void saveLogLevels(String runnableName, MaplogL this.logLevels.put(runnableName, newLevels); } + /** + * Creates an {@link Credentials} by copying the {@link Credentials} of the current user. + */ private Credentials createCredentials() { Credentials credentials = new Credentials(); try { credentials.addAll(UserGroupInformation.getCurrentUser().getCredentials()); +} catch (IOException e) { --- End diff -- shouldn't this be fatal? --- 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 infrastruct...@apache.org or file a JIRA ticket with INFRA. ---
[GitHub] twill pull request #39: (TWILL-225) Refactor TwillPreprer to allow configura...
Github user chtyim commented on a diff in the pull request: https://github.com/apache/twill/pull/39#discussion_r10700 --- Diff: twill-yarn/src/main/java/org/apache/twill/yarn/YarnTwillPreparer.java --- @@ -155,25 +153,16 @@ public String apply(Class cls) { private ClassAcceptor classAcceptor; private final MapmaxRetries = Maps.newHashMap(); - YarnTwillPreparer(YarnConfiguration yarnConfig, TwillSpecification twillSpec, RunId runId, -YarnAppClient yarnAppClient, String zkConnectString, Location appLocation, Set twillClassPaths, + YarnTwillPreparer(Configuration config, TwillSpecification twillSpec, RunId runId, --- End diff -- It's more generic. We actually not using any specific method from `YarnConfiguration` in this class. --- 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 infrastruct...@apache.org or file a JIRA ticket with INFRA. ---