You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by "Ghais Issa (Created) (JIRA)" <ji...@apache.org> on 2012/01/24 17:32:40 UTC

[jira] [Created] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Result.getValue and Result.getColumnLatest return the wrong column.
-------------------------------------------------------------------

                 Key: HBASE-5271
                 URL: https://issues.apache.org/jira/browse/HBASE-5271
             Project: HBase
          Issue Type: Bug
          Components: client
    Affects Versions: 0.90.5
            Reporter: Ghais Issa


In the following example result.getValue returns the wrong column

KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
Result result = new Result(new KeyValue[] { kv });
System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Zhihong Yu (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13194076#comment-13194076 ] 

Zhihong Yu commented on HBASE-5271:
-----------------------------------

Integrated to 0.90, 0.92 and TRUNK.

Thanks for the patch Ghais.

Thanks for the review Lars.
                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>            Assignee: Ghais Issa
>             Fix For: 0.94.0, 0.90.7, 0.92.1
>
>         Attachments: 5271-90.txt, 5271-v2.txt, fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Ghais Issa (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ghais Issa updated HBASE-5271:
------------------------------

    Status: Patch Available  (was: Open)
    
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>         Attachments: fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Hadoop QA (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13192581#comment-13192581 ] 

Hadoop QA commented on HBASE-5271:
----------------------------------

-1 overall.  Here are the results of testing the latest attachment 
  http://issues.apache.org/jira/secure/attachment/12511739/5271-90.txt
  against trunk revision .

    +1 @author.  The patch does not contain any @author tags.

    +1 tests included.  The patch appears to include 3 new or modified tests.

    -1 patch.  The patch command could not apply the patch.

Console output: https://builds.apache.org/job/PreCommit-HBASE-Build/848//console

This message is automatically generated.
                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>             Fix For: 0.94.0, 0.90.6, 0.92.1
>
>         Attachments: 5271-90.txt, 5271-v2.txt, fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Lars Hofhansl (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13194023#comment-13194023 ] 

Lars Hofhansl commented on HBASE-5271:
--------------------------------------

+1

This is actually pretty bad now. Imagine you pass a long family byte[] to matchingColumn. Now we could potentially compare past the size of the KeyValue backing array.
                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>            Assignee: Ghais Issa
>             Fix For: 0.94.0, 0.90.7, 0.92.1
>
>         Attachments: 5271-90.txt, 5271-v2.txt, fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Hadoop QA (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13192527#comment-13192527 ] 

Hadoop QA commented on HBASE-5271:
----------------------------------

-1 overall.  Here are the results of testing the latest attachment 
  http://issues.apache.org/jira/secure/attachment/12511722/fixKeyValueMatchingColumn.diff
  against trunk revision .

    +1 @author.  The patch does not contain any @author tags.

    +1 tests included.  The patch appears to include 3 new or modified tests.

    -1 javadoc.  The javadoc tool appears to have generated -145 warning messages.

    +1 javac.  The applied patch does not increase the total number of javac compiler warnings.

    -1 findbugs.  The patch appears to introduce 156 new Findbugs (version 1.3.9) warnings.

    +1 release audit.  The applied patch does not increase the total number of release audit warnings.

     -1 core tests.  The patch failed these unit tests:
                       org.apache.hadoop.hbase.replication.TestReplication
                  org.apache.hadoop.hbase.mapreduce.TestImportTsv
                  org.apache.hadoop.hbase.mapred.TestTableMapReduce
                  org.apache.hadoop.hbase.mapreduce.TestHFileOutputFormat

Test results: https://builds.apache.org/job/PreCommit-HBASE-Build/847//testReport/
Findbugs warnings: https://builds.apache.org/job/PreCommit-HBASE-Build/847//artifact/trunk/patchprocess/newPatchFindbugsWarnings.html
Console output: https://builds.apache.org/job/PreCommit-HBASE-Build/847//console

This message is automatically generated.
                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>             Fix For: 0.94.0, 0.90.6, 0.92.1
>
>         Attachments: fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Zhihong Yu (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13192524#comment-13192524 ] 

Zhihong Yu commented on HBASE-5271:
-----------------------------------

+1 on patch.
                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>             Fix For: 0.94.0, 0.90.6, 0.92.1
>
>         Attachments: fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Zhihong Yu (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13192282#comment-13192282 ] 

Zhihong Yu commented on HBASE-5271:
-----------------------------------

Can you write up a unit test which demonstrates this issue ?

Thanks
                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Assigned] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Zhihong Yu (Assigned) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Zhihong Yu reassigned HBASE-5271:
---------------------------------

    Assignee: Ghais Issa
    
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>            Assignee: Ghais Issa
>             Fix For: 0.94.0, 0.90.6, 0.92.1
>
>         Attachments: 5271-90.txt, 5271-v2.txt, fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

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

stack updated HBASE-5271:
-------------------------

    Resolution: Fixed
        Status: Resolved  (was: Patch Available)

Was committed a while back.  Thanks for the patch Ghais.
                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>            Assignee: Ghais Issa
>             Fix For: 0.94.0, 0.90.7, 0.92.1
>
>         Attachments: 5271-90.txt, 5271-v2.txt, fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Zhihong Yu (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13194012#comment-13194012 ] 

Zhihong Yu commented on HBASE-5271:
-----------------------------------

Will integrate if there is no objection.
                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>            Assignee: Ghais Issa
>             Fix For: 0.94.0, 0.90.7, 0.92.1
>
>         Attachments: 5271-90.txt, 5271-v2.txt, fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Ghais Issa (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ghais Issa updated HBASE-5271:
------------------------------

    Attachment: fixKeyValueMatchingColumn.diff

I believe this patch fixes the issue.
It looks like the KeyValue.matchingColumn was incorrectly passing in the family.length instead of the actual column's family length.

Is there some reviewboard I should submit to, or is there some page which explains the submission process?
                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>         Attachments: fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Zhihong Yu (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13192481#comment-13192481 ] 

Zhihong Yu commented on HBASE-5271:
-----------------------------------

See http://hbase.apache.org/book.html#developer

For large patch, https://reviews.apache.org can be used for review.

You can push the 'Submit Patch' button to let Hadoop QA run through the tests.
                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>         Attachments: fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Zhihong Yu (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Zhihong Yu updated HBASE-5271:
------------------------------

    Fix Version/s: 0.92.1
                   0.90.6
                   0.94.0
     Hadoop Flags: Reviewed
    
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>             Fix For: 0.94.0, 0.90.6, 0.92.1
>
>         Attachments: fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Zhihong Yu (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13192368#comment-13192368 ] 

Zhihong Yu commented on HBASE-5271:
-----------------------------------

@Ghais:
Do you want to provide a patch that fixes this?
                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>         Attachments: testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Hudson (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13200638#comment-13200638 ] 

Hudson commented on HBASE-5271:
-------------------------------

Integrated in HBase-0.92-security #90 (See [https://builds.apache.org/job/HBase-0.92-security/90/])
    HBASE-5271  Result.getValue and Result.getColumnLatest return the wrong column (Ghais Issa)

tedyu : 
Files : 
* /hbase/branches/0.92/CHANGES.txt
* /hbase/branches/0.92/src/main/java/org/apache/hadoop/hbase/KeyValue.java
* /hbase/branches/0.92/src/test/java/org/apache/hadoop/hbase/TestKeyValue.java

                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>            Assignee: Ghais Issa
>             Fix For: 0.94.0, 0.90.7, 0.92.1
>
>         Attachments: 5271-90.txt, 5271-v2.txt, fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Hudson (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13194186#comment-13194186 ] 

Hudson commented on HBASE-5271:
-------------------------------

Integrated in HBase-0.92 #263 (See [https://builds.apache.org/job/HBase-0.92/263/])
    HBASE-5271  Result.getValue and Result.getColumnLatest return the wrong column (Ghais Issa)

tedyu : 
Files : 
* /hbase/branches/0.92/CHANGES.txt
* /hbase/branches/0.92/src/main/java/org/apache/hadoop/hbase/KeyValue.java
* /hbase/branches/0.92/src/test/java/org/apache/hadoop/hbase/TestKeyValue.java

                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>            Assignee: Ghais Issa
>             Fix For: 0.94.0, 0.90.7, 0.92.1
>
>         Attachments: 5271-90.txt, 5271-v2.txt, fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Lars Hofhansl (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13192435#comment-13192435 ] 

Lars Hofhansl commented on HBASE-5271:
--------------------------------------

Good find. From the code it looks like only a prefix of the family needs to match. D'oh.
                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>         Attachments: testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Zhihong Yu (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13192532#comment-13192532 ] 

Zhihong Yu commented on HBASE-5271:
-----------------------------------

There was no hanging test in PreCommit build 847.

Will integrate the patch tonight.
                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>             Fix For: 0.94.0, 0.90.6, 0.92.1
>
>         Attachments: fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Hudson (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13196716#comment-13196716 ] 

Hudson commented on HBASE-5271:
-------------------------------

Integrated in HBase-TRUNK #2648 (See [https://builds.apache.org/job/HBase-TRUNK/2648/])
    HBASE-5271  Result.getValue and Result.getColumnLatest return the wrong column (Ghais Issa)

tedyu : 
Files : 
* /hbase/trunk/CHANGES.txt
* /hbase/trunk/src/main/java/org/apache/hadoop/hbase/KeyValue.java
* /hbase/trunk/src/test/java/org/apache/hadoop/hbase/TestKeyValue.java

                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>            Assignee: Ghais Issa
>             Fix For: 0.94.0, 0.90.7, 0.92.1
>
>         Attachments: 5271-90.txt, 5271-v2.txt, fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Ghais Issa (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Ghais Issa updated HBASE-5271:
------------------------------

    Attachment: testGetValue.diff

Added a unit test in the TestResult.java class.
                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>         Attachments: testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "ramkrishna.s.vasudevan (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

ramkrishna.s.vasudevan updated HBASE-5271:
------------------------------------------

    Fix Version/s:     (was: 0.90.6)
                   0.90.7

Updated affects version to 0.90.7
                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>            Assignee: Ghais Issa
>             Fix For: 0.94.0, 0.90.7, 0.92.1
>
>         Attachments: 5271-90.txt, 5271-v2.txt, fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Hudson (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13194502#comment-13194502 ] 

Hudson commented on HBASE-5271:
-------------------------------

Integrated in HBase-TRUNK-security #92 (See [https://builds.apache.org/job/HBase-TRUNK-security/92/])
    HBASE-5271  Result.getValue and Result.getColumnLatest return the wrong column (Ghais Issa)

tedyu : 
Files : 
* /hbase/trunk/CHANGES.txt
* /hbase/trunk/src/main/java/org/apache/hadoop/hbase/KeyValue.java
* /hbase/trunk/src/test/java/org/apache/hadoop/hbase/TestKeyValue.java

                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>            Assignee: Ghais Issa
>             Fix For: 0.94.0, 0.90.7, 0.92.1
>
>         Attachments: 5271-90.txt, 5271-v2.txt, fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (HBASE-5271) Result.getValue and Result.getColumnLatest return the wrong column.

Posted by "Zhihong Yu (Updated) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HBASE-5271?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Zhihong Yu updated HBASE-5271:
------------------------------

    Attachment: 5271-90.txt
                5271-v2.txt

Updated patch by wrapping a long line.
                
> Result.getValue and Result.getColumnLatest return the wrong column.
> -------------------------------------------------------------------
>
>                 Key: HBASE-5271
>                 URL: https://issues.apache.org/jira/browse/HBASE-5271
>             Project: HBase
>          Issue Type: Bug
>          Components: client
>    Affects Versions: 0.90.5
>            Reporter: Ghais Issa
>             Fix For: 0.94.0, 0.90.6, 0.92.1
>
>         Attachments: 5271-90.txt, 5271-v2.txt, fixKeyValueMatchingColumn.diff, testGetValue.diff
>
>
> In the following example result.getValue returns the wrong column
> KeyValue kv = new KeyValue(Bytes.toBytes("r"), Bytes.toBytes("24"), Bytes.toBytes("2"), Bytes.toBytes(7L));
> Result result = new Result(new KeyValue[] { kv });
> System.out.println(Bytes.toLong(result.getValue(Bytes.toBytes("2"), Bytes.toBytes("2")))); //prints 7.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira