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

Travis Crawford commented on HCATALOG-523:
------------------------------------------

Hey [~pengfeng] -

Can you rebase & repost this patch? I just submitted HCATALOG-364 which also 
touched {{PigHCatUtil}} and this does not apply cleanly now.

Looking for usages of {{PigHCatUtil.transformToPigMap}} I only see that used 
internally. Can you think of a good reason this method is public? I can't think 
of a good reason not to make this private, which would help tighten up our API.

{code}
fynn:hcatalog travis$ find . -name '*.java' -exec grep transformToPigMap {} \;
            result = transformToPigMap((Map<String, Object>) o, hfs);
    public static Map<String, Object> transformToPigMap(Map<String, Object> 
map, HCatFieldSchema hfs) throws Exception {
fynn:hcatalog travis$
{code}
                
> PigHCatUtil should not assume map key type can be casted to String
> ------------------------------------------------------------------
>
>                 Key: HCATALOG-523
>                 URL: https://issues.apache.org/jira/browse/HCATALOG-523
>             Project: HCatalog
>          Issue Type: Bug
>    Affects Versions: 0.4, 0.5
>            Reporter: Feng Peng
>            Assignee: Feng Peng
>         Attachments: HCATALOG-523.patch
>
>
> HCatalog in general allows any primitive types to be the key of the map. In 
> PigHCatUtil, it assumes the key of the map can be casted to String, which 
> breaks the conversion to Pig tuple when the underlying data has other 
> primitive types (such as integers) as the map key.

--
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