[
https://issues.apache.org/jira/browse/YARN-2023?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Hong Zhiguo updated YARN-2023:
------------------------------
Attachment: YARN-2023.patch
It's caused by below commit:
{code}
commit 37e0d8224bc7f660c3319e86cf6bebfc497d1de6
Author: Arpit Agarwal <[email protected]>
Date: Fri May 2 18:38:30 2014 +0000
HADOOP-10562. Namenode exits on exception without printing stack trace in
AbstractDelegationTokenSecretManager. (Contributed by Suresh Srinivas)
git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1592002
13f79535-47bb-0310-9956-ffa450edef68
{code}
The related change:
{code}
index d892c5d..b9e26b5 100644
---
a/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/security/token/delegation/AbstractDelegationTokenSecretManager.java
+++
b/hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/security/token/delegation/AbstractDelegationTokenSecretManager.java
...
@@ -386,8 +382,8 @@ public synchronized long renewToken(Token<TokenIdent> token,
}
byte[] password = createPassword(token.getIdentifier(), key.getKey());
if (!Arrays.equals(password, token.getPassword())) {
- throw new AccessControlException("Client " + renewer
- + " is trying to renew a token with " + "wrong password");
+ throw new AccessControlException(renewer +
+ " is trying to renew a token with wrong password");
}
{code}
I didn't go deep into this commit, but I think there must be reason for above
change.
So the easiest fix is a trival change in
TestClientRMService.testTokenRenewalWrongUser.
> TestClientRMService fails on trunk
> ----------------------------------
>
> Key: YARN-2023
> URL: https://issues.apache.org/jira/browse/YARN-2023
> Project: Hadoop YARN
> Issue Type: Bug
> Components: resourcemanager
> Reporter: Hong Zhiguo
> Assignee: Hong Zhiguo
> Attachments: YARN-2023.patch
>
>
> testTokenRenewalWrongUser(org.apache.hadoop.yarn.server.resourcemanager.TestClientRMService)
> Time elapsed: 0.015 sec <<< FAILURE!
> java.lang.AssertionError: null
> at org.junit.Assert.fail(Assert.java:86)
> at org.junit.Assert.assertTrue(Assert.java:41)
> at org.junit.Assert.assertTrue(Assert.java:52)
> at
> org.apache.hadoop.yarn.server.resourcemanager.TestClientRMService$4.run(TestClientRMService.java:481)
> at
> org.apache.hadoop.yarn.server.resourcemanager.TestClientRMService$4.run(TestClientRMService.java:474)
> at java.security.AccessController.doPrivileged(Native Method)
> at javax.security.auth.Subject.doAs(Subject.java:415)
> at
> org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1606)
> at
> org.apache.hadoop.yarn.server.resourcemanager.TestClientRMService.testTokenRenewalWrongUser(TestClientRMService.java:474)
> Results :
> Failed tests:
> TestClientRMService.testTokenRenewalWrongUser:474 null
--
This message was sent by Atlassian JIRA
(v6.2#6252)