hadoop-yarn-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Zhijie Shen (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (YARN-2709) Add retry for timeline client getDelegationToken method
Date Tue, 21 Oct 2014 21:10:34 GMT

    [ https://issues.apache.org/jira/browse/YARN-2709?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14179107#comment-14179107
] 

Zhijie Shen commented on YARN-2709:
-----------------------------------

Almost good to me. Some nits:

1. Can you add a comment to say the following config is to bypass the issue in HADOOP-11215.
{code}
    conf.set(CommonConfigurationKeysPublic.HADOOP_SECURITY_AUTHENTICATION,
        "kerberos");
{code}

2. For both retry test cases, set newMaxRetries to 5 and newIntervalMs to 500? Make sure it's
able to retry multiple times?
{code}
    int newMaxRetries = 1;
    long newIntervalMs = 1500;
{coe}

3. token is an unused var
{code}
      Token<TimelineDelegationTokenIdentifier> token = client.getDelegationToken(
        UserGroupInformation.getCurrentUser().getShortUserName());
{code}

4. You can directly change connectionRetry to default visibility (no private modifier) because
the test class is in the same package, and mark it @VisibleForTesting.
{code}
  @Private
  @VisibleForTesting
  public TimelineClientConnectionRetry getConnectionRetry() {
    return connectionRetry;
  }
{code}

5. Retried is not thread safe, but it should be fine if it is not used for unit test. Would
you please add a comment?
{code}
    // Indicates if retries happened last time
    @Private
    @VisibleForTesting
    public boolean retried = false;
{code}

> Add retry for timeline client getDelegationToken method
> -------------------------------------------------------
>
>                 Key: YARN-2709
>                 URL: https://issues.apache.org/jira/browse/YARN-2709
>             Project: Hadoop YARN
>          Issue Type: Sub-task
>            Reporter: Li Lu
>            Assignee: Li Lu
>         Attachments: YARN-2709-102014-1.patch, YARN-2709-102014.patch, YARN-2709-102114.patch
>
>
> As mentioned in YARN-2673, we need to add retry mechanism to timeline client for secured
clusters. This means if the timeline server is not available, a timeline client needs to retry
to get a delegation token. 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message