You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by "Zhihong Yu (Created) (JIRA)" <ji...@apache.org> on 2012/03/02 20:21:57 UTC

[jira] [Created] (HBASE-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

Add support for INCLUDE_AND_SEEK_USING_HINT
-------------------------------------------

                 Key: HBASE-5512
                 URL: https://issues.apache.org/jira/browse/HBASE-5512
             Project: HBase
          Issue Type: Improvement
            Reporter: Zhihong Yu


This came up from HBASE-2038
>From Anoop:

- What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
Can we add reseek() at higher level?

>From Lars:
Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

Lars Hofhansl commented on HBASE-5512:
--------------------------------------

Working on a test.
                
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

Zhihong Yu commented on HBASE-5512:
-----------------------------------

For CustomIncludeAndNextUsingHintFilter.java:
{code}
+  public KeyValue getNextKeyHint(KeyValue kv) {
+    if (count >= seekHints.length) 
+      return null;
{code}
Braces should be added around return.
Can we make an assertion above ? Since filterAllRemaining() returns true for this case, I wonder why getNextKeyHint() would still be called.
                
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>         Attachments: 5512-v2.txt, 5512.txt
>
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

Hadoop QA commented on HBASE-5512:
----------------------------------

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

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

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

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

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

    -1 findbugs.  The patch appears to introduce 154 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 passed unit tests in .

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

This message is automatically generated.
                
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>         Attachments: 5512-v2.txt, 5512.txt
>
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

Lars Hofhansl updated HBASE-5512:
---------------------------------

    Attachment: 5512-v2.txt

This version should work.
(but see caveats raised before)
                
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>         Attachments: 5512-v2.txt, 5512.txt
>
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

Lars Hofhansl commented on HBASE-5512:
--------------------------------------

Let's wait for more input in HBASE-2038. I'm feeling half way include to -1 my own patch :)
Imagine we wanted to add INCLUDE_AND_NEXT_ROW as well as INCLUDE_AND_NEXT_COL to filter. These outcomes would have to merged with whatever the colum tracker returns.
It's not complicated, but will make the code hard to read with questionable gain (as I say in HBASE-2038). I think Anoop wants to do some performance testing.
                
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>         Attachments: 5512-v2.txt, 5512.txt
>
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

Lars Hofhansl updated HBASE-5512:
---------------------------------

    Attachment: 5512.txt

Not ready (especially the test)... just storing the patch here.
                
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>         Attachments: 5512.txt
>
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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] [Issue Comment Edited] (HBASE-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

Zhihong Yu edited comment on HBASE-5512 at 3/4/12 3:42 PM:
-----------------------------------------------------------

For CustomIncludeAndNextUsingHintFilter.java:
{code}
+  public KeyValue getNextKeyHint(KeyValue kv) {
+    if (count >= seekHints.length) 
+      return null;
{code}
Braces should be added around return.
                
      was (Author: zhihyu@ebaysf.com):
    For CustomIncludeAndNextUsingHintFilter.java:
{code}
+  public KeyValue getNextKeyHint(KeyValue kv) {
+    if (count >= seekHints.length) 
+      return null;
{code}
Braces should be added around return.
Can we make an assertion above ? Since filterAllRemaining() returns true for this case, I wonder why getNextKeyHint() would still be called.
                  
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>         Attachments: 5512-v2.txt, 5512.txt
>
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

Anoop Sam John commented on HBASE-5512:
---------------------------------------

@Lars
      As u said under HBASE_2038 I dont think we can use this way to do the IHBase work :(  Mainly how the filter can return INCLUDE_AND_SEEK..   WHat we wanted ideally is at the row level say include this row and seek to next row. But any way at row level the filter contains boolean return either include the row or not.

I feel making an attempt to support the seek() reseek() at the region scanner level..
                
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>         Attachments: 5512-v2.txt, 5512.txt
>
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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] [Issue Comment Edited] (HBASE-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

Zhihong Yu edited comment on HBASE-5512 at 3/3/12 3:24 PM:
-----------------------------------------------------------

ScanQueryMatcher:
{code}
} else if (filterResponse == ReturnCode.INCLUDE_AND_SEEK_NEXT_USING_HINT) {
+        
       }
{code}
You need make filterSeek=true? 
                
      was (Author: anoopsamjohn):
    ScanQueryMatcher
} else if (filterResponse == ReturnCode.INCLUDE_AND_SEEK_NEXT_USING_HINT) {
+        
       }
You need make filterSeek=true? 
                  
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>         Attachments: 5512.txt
>
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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] [Issue Comment Edited] (HBASE-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

Zhihong Yu edited comment on HBASE-5512 at 3/4/12 3:45 PM:
-----------------------------------------------------------

CustomIncludeAndNextUsingHintFilter.java misses license and class javadoc.
In ScanQueryMatcher.java:
{code}
+    boolean filterSeek = false;
{code}
Can the above variable be named such that the name reflects semantics for INCLUDE_AND_NEXT_USING_HINT ?
That would make understanding the following code easier:
{code}
+    if (filterSeek) {
+      switch(colChecker) {
+      case INCLUDE:
{code}
                
      was (Author: zhihyu@ebaysf.com):
    CustomIncludeAndNextUsingHintFilter.java misses license and class javadoc.
{code}
+    boolean filterSeek = false;
{code}
Can the above variable be named such that the name reflects semantics for INCLUDE_AND_NEXT_USING_HINT ?
That would make understanding the following code easier:
{code}
+    if (filterSeek) {
+      switch(colChecker) {
+      case INCLUDE:
{code}
                  
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>         Attachments: 5512-v2.txt, 5512.txt
>
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

Lars Hofhansl commented on HBASE-5512:
--------------------------------------

@Anoop: Good observation :) (As I said I just needed to store the partial patch somewhere).
@Ram: Sure. Would you prefer to continue to work on this?

Also see last comment on HBASE-2038. Not entirely sure how much mileage we get from this.
                
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>         Attachments: 5512.txt
>
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

ramkrishna.s.vasudevan commented on HBASE-5512:
-----------------------------------------------

@Lars
First of all thanks for the patch Lars.
Anoop and myself were planning to work on this.  :)
                
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>         Attachments: 5512.txt
>
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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] [Issue Comment Edited] (HBASE-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

Lars Hofhansl edited comment on HBASE-5512 at 3/5/12 6:36 AM:
--------------------------------------------------------------

Let's wait for more input in HBASE-2038. I'm feeling half way inclined to -1 my own patch :)
Imagine we wanted to add INCLUDE_AND_NEXT_ROW as well as INCLUDE_AND_NEXT_COL to filter. These outcomes would have to merged with whatever the colum tracker returns.
It's not complicated, but will make the code hard to read with questionable gain (as I say in HBASE-2038). I think Anoop wants to do some performance testing.
                
      was (Author: lhofhansl):
    Let's wait for more input in HBASE-2038. I'm feeling half way include to -1 my own patch :)
Imagine we wanted to add INCLUDE_AND_NEXT_ROW as well as INCLUDE_AND_NEXT_COL to filter. These outcomes would have to merged with whatever the colum tracker returns.
It's not complicated, but will make the code hard to read with questionable gain (as I say in HBASE-2038). I think Anoop wants to do some performance testing.
                  
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>         Attachments: 5512-v2.txt, 5512.txt
>
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

Lars Hofhansl updated HBASE-5512:
---------------------------------

    Assignee: Lars Hofhansl
    
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

Anoop Sam John commented on HBASE-5512:
---------------------------------------

ScanQueryMatcher
} else if (filterResponse == ReturnCode.INCLUDE_AND_SEEK_NEXT_USING_HINT) {
+        
       }
You need make filterSeek=true? 
                
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>         Attachments: 5512.txt
>
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

Lars Hofhansl commented on HBASE-5512:
--------------------------------------

I misspoke slightly. Filters can only return INCLUDE, SKIP, NEXT_COL, NEXT_ROW, and SEEK_NEXT_USING_HINT.
ColumnTrackerd have the additional options of INCLUDE_AND_XXX.

                
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

Zhihong Yu commented on HBASE-5512:
-----------------------------------

CustomIncludeAndNextUsingHintFilter.java misses license and class javadoc.
{code}
+    boolean filterSeek = false;
{code}
Can the above variable be named such that the name reflects semantics for INCLUDE_AND_NEXT_USING_HINT ?
That would make understanding the following code easier:
{code}
+    if (filterSeek) {
+      switch(colChecker) {
+      case INCLUDE:
{code}
                
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>         Attachments: 5512-v2.txt, 5512.txt
>
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

Lars Hofhansl updated HBASE-5512:
---------------------------------

    Resolution: Won't Fix
        Status: Resolved  (was: Patch Available)

Marking as won't fix, as we now question the usefulnes.
                
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>         Attachments: 5512-v2.txt, 5512.txt
>
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

--
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-5512) Add support for INCLUDE_AND_SEEK_USING_HINT

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

Zhihong Yu updated HBASE-5512:
------------------------------

    Hadoop Flags: Reviewed
          Status: Patch Available  (was: Open)
    
> Add support for INCLUDE_AND_SEEK_USING_HINT
> -------------------------------------------
>
>                 Key: HBASE-5512
>                 URL: https://issues.apache.org/jira/browse/HBASE-5512
>             Project: HBase
>          Issue Type: Improvement
>            Reporter: Zhihong Yu
>            Assignee: Lars Hofhansl
>         Attachments: 5512-v2.txt, 5512.txt
>
>
> This came up from HBASE-2038
> From Anoop:
> - What we wanted from the filter is include a row and then seek to the next row which we are interested in. I cant see such a facility with our Filter right now. Correct me if I am wrong. So suppose we already seeked to one row and this need to be included in the result, then the Filter should return INCLUDE. Then when the next next() call happens, then only we can return a SEEK_USING_HINT. So one extra row reading is needed. This might create even one unwanted HFileBlock fetch (who knows).
> Can we add reseek() at higher level?
> From Lars:
> Yep, for that we'd need to add INCLUDE_AND_SEEK_USING_HINT (similar to the INCLUDE_AND_SEEK_NEXT_ROW that we already have). Shouldn't be hard to add, I'm happy to do that, if that's the route we want to go with this.

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