|
@@ -198,11 +198,12 @@ extends AbstractDelegationTokenIdentifier>
|
|
throws InvalidToken {
|
|
throws InvalidToken {
|
|
DelegationTokenInformation info = currentTokens.get(identifier);
|
|
DelegationTokenInformation info = currentTokens.get(identifier);
|
|
if (info == null) {
|
|
if (info == null) {
|
|
- throw new InvalidToken("token is expired or doesn't exist");
|
|
|
|
|
|
+ throw new InvalidToken("token (" + identifier.toString()
|
|
|
|
+ + ") can't be found in cache");
|
|
}
|
|
}
|
|
long now = System.currentTimeMillis();
|
|
long now = System.currentTimeMillis();
|
|
if (info.getRenewDate() < now) {
|
|
if (info.getRenewDate() < now) {
|
|
- throw new InvalidToken("token is expired");
|
|
|
|
|
|
+ throw new InvalidToken("token (" + identifier.toString() + ") is expired");
|
|
}
|
|
}
|
|
return info.getPassword();
|
|
return info.getPassword();
|
|
}
|
|
}
|