Skip to content

Commit

Permalink
Fix review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
vikramahuja1001 committed Jul 11, 2024
1 parent 621997d commit e90f12a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,7 @@ private void renewIfRequired(long currentTime, DelegationTokenIdentifier id, Del
id.getKind(), new Text());
renewToken(t, UserGroupInformation.getCurrentUser().getShortUserName());
} catch (IOException e) {
throw new InvalidToken("Unable to renew token: " + id);
throw new InvalidToken("Unable to renew token: " + id + " due to " + e.getMessage());
}
} else if (currentTime > id.getMaxDate()) {
// In this case expiry time has passed and this token cannot be further renewed.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ private TokenStoreDelegationTokenSecretManager createTokenMgr(DelegationTokenSto
long tokenRenewInterval = renewSecs * 1000;
long tokenGcInterval = gcTime * 1000;
return new TokenStoreDelegationTokenSecretManager(secretKeyInterval, tokenMaxLifetime,
tokenRenewInterval, tokenGcInterval, tokenStore);
tokenRenewInterval, tokenGcInterval, tokenStore);
}


Expand Down Expand Up @@ -98,8 +98,8 @@ private DelegationTokenIdentifier getID(String tokenStr) throws IOException {
try {
mgr.startThreads();
String tokenStr =
mgr.getDelegationToken(UserGroupInformation.getCurrentUser().getShortUserName(),
UserGroupInformation.getCurrentUser().getShortUserName());
mgr.getDelegationToken(UserGroupInformation.getCurrentUser().getShortUserName(),
UserGroupInformation.getCurrentUser().getShortUserName());
DelegationTokenIdentifier id = getID(tokenStr);
Assert.assertNotNull(mgr.verifyDelegationToken(tokenStr));

Expand Down

0 comments on commit e90f12a

Please sign in to comment.