You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mrunit.apache.org by "Jim Donofrio (JIRA)" <ji...@apache.org> on 2012/09/30 18:34:07 UTC

[jira] [Created] (MRUNIT-154) shuffle in MapReduceDriverBase does not support comparators that only override compare(byte[] b1, int s1, int l1, byte[] b2, int s2, int l2)

Jim Donofrio created MRUNIT-154:
-----------------------------------

             Summary: shuffle in MapReduceDriverBase does not support comparators that only override compare(byte[] b1, int s1, int l1, byte[] b2, int s2, int l2)
                 Key: MRUNIT-154
                 URL: https://issues.apache.org/jira/browse/MRUNIT-154
             Project: MRUnit
          Issue Type: Bug
            Reporter: Jim Donofrio


>From MRUNIT-114:


Because the shuffle method in MapReduceDriverBase calls the key ordering comparator using compare(Object,Object), it does not call the correct method on classes which only override and do all the work in compare(byte[] b1, int s1, int l1, byte[] b2, int s2, int l2), like KeyFieldBasedComparator.

It might be better to check whether the two keys are BinaryComparable, casting, and calling this method if possible. Even if a user's comparator doesn't override it, the default implementation of this in WritableComparator would still be OK. 

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

[jira] [Assigned] (MRUNIT-154) shuffle in MapReduceDriverBase does not support comparators that only override compare(byte[] b1, int s1, int l1, byte[] b2, int s2, int l2)

Posted by "Dave Beech (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/MRUNIT-154?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Dave Beech reassigned MRUNIT-154:
---------------------------------

    Assignee: Dave Beech
    
> shuffle in MapReduceDriverBase does not support comparators that only override compare(byte[] b1, int s1, int l1, byte[] b2, int s2, int l2)
> --------------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: MRUNIT-154
>                 URL: https://issues.apache.org/jira/browse/MRUNIT-154
>             Project: MRUnit
>          Issue Type: Bug
>            Reporter: Jim Donofrio
>            Assignee: Dave Beech
>
> From MRUNIT-114:
> Because the shuffle method in MapReduceDriverBase calls the key ordering comparator using compare(Object,Object), it does not call the correct method on classes which only override and do all the work in compare(byte[] b1, int s1, int l1, byte[] b2, int s2, int l2), like KeyFieldBasedComparator.
> It might be better to check whether the two keys are BinaryComparable, casting, and calling this method if possible. Even if a user's comparator doesn't override it, the default implementation of this in WritableComparator would still be OK. 

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