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

Scott Forman commented on HDFS-3627:
------------------------------------

Thanks for your comments, Daryn.
1. I believe that the changes in this patch enable OIV to convert from xml back 
to binary image.  Our group needed this functionality, and so we made this 
change.  Without these changes, the Delegation Keys in the binary image cannot 
be correctly composed. 
2. Latest patch modifies IndentedImageVisitor.java so that 
ImageElement.DELEGATION_KEY_EXPIRY_DATE is human-readable.  I checked the 
outputs for the other visitors, and only the IndentedImageVisitor and 
XmlImageVisitor output the Delegation Keys.
3. I believe the OEV does decode the delegation key, but it prints out the 
encoded key as a hex string.  So I changed the OIV to also print out the 
encoded key as a hex string.

I agree that it would be nice if the xml encode/decode code was common between 
OIV and OEV, but it would be a big change now.  It is also surprising that the 
OEV has a binary processor that allows the XML output to be converted to 
binary, but that the OIV does not.  We needed this functionality and hope to 
contribute it back soon.
                
> OfflineImageViewer oiv Indented processor prints out the Java class name in 
> the DELEGATION_KEY field
> ----------------------------------------------------------------------------------------------------
>
>                 Key: HDFS-3627
>                 URL: https://issues.apache.org/jira/browse/HDFS-3627
>             Project: Hadoop HDFS
>          Issue Type: Bug
>    Affects Versions: 0.23.0
>            Reporter: Ravi Prakash
>            Priority: Minor
>         Attachments: HDFS-3627.patch, HDFS-3627.patch, HDFS-3627.patch, 
> HDFS-3627.patch, HDFS-3627.patch
>
>
> Instead of the contents of the delegation key this is printed out
> DELEGATION_KEY = 
> org.apache.hadoop.security.token.delegation.DelegationKey@1e2ca7
>     DELEGATION_KEY = 
> org.apache.hadoop.security.token.delegation.DelegationKey@105bd58
>     DELEGATION_KEY = 
> org.apache.hadoop.security.token.delegation.DelegationKey@1d1e730
>     DELEGATION_KEY = 
> org.apache.hadoop.security.token.delegation.DelegationKey@1a116c9
>     DELEGATION_KEY = 
> org.apache.hadoop.security.token.delegation.DelegationKey@df1832

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to