ajayydv commented on a change in pull request #627: HDDS-1299. Support
TokenIssuer interface for running jobs with OzoneFileSystem.
URL: https://github.com/apache/hadoop/pull/627#discussion_r267937938
##########
File path:
hadoop-ozone/ozonefs/src/main/java/org/apache/hadoop/fs/ozone/OzoneClientAdapterImpl.java
##########
@@ -289,7 +291,7 @@ public boolean hasNextKey(String key) {
@Override
public Token<OzoneTokenIdentifier> getDelegationToken(String renewer)
throws IOException {
- if (!securityEnabled) {
+ if (!securityEnabled || renewer == null) {
Review comment:
Seems issuing token even if renewer is not passed seems to be legit case.
public void setRenewer(Text renewer) {
if (renewer == null) {
this.renewer = new Text();
} else {
HadoopKerberosName renewerKrbName = new
HadoopKerberosName(renewer.toString());
try {
this.renewer = new Text(renewerKrbName.getShortName());
} catch (IOException e) {
throw new RuntimeException(e);
}
}
}
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]