Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.0.0
    • Labels:
      None

      Description

      HBase can optionally not cache any blocks touched by a specific scan operation.
      See Scan.setCacheBlocks(boolean). We should expose this via a query hint.
      Something like /*+ NO_CACHING */

      1. phoenix-13.txt
        3 kB
        Lars Hofhansl
      2. phoenix-13-v2.txt
        4 kB
        Lars Hofhansl

        Activity

        Hide
        enis Enis Soztutar added a comment -

        Bulk close of all issues that has been resolved in a released version.

        Show
        enis Enis Soztutar added a comment - Bulk close of all issues that has been resolved in a released version.
        Hide
        hudson Hudson added a comment -

        FAILURE: Integrated in Apache Phoenix - Build:master #25 (See https://builds.apache.org/job/Phoenix/25/)
        PHOENIX-13 Provide a nocache hint to a query. (LarsH) (larsh: rev d40c5066edeb112fb59f7bebe6c78e2fb346d929)

        • phoenix-core/src/main/java/org/apache/phoenix/compile/StatementContext.java
        • phoenix-core/src/main/java/org/apache/phoenix/parse/HintNode.java
        • phoenix-core/src/main/java/org/apache/phoenix/compile/QueryCompiler.java
        • phoenix-core/src/test/java/org/apache/phoenix/compile/QueryCompileTest.java
        Show
        hudson Hudson added a comment - FAILURE: Integrated in Apache Phoenix - Build:master #25 (See https://builds.apache.org/job/Phoenix/25/ ) PHOENIX-13 Provide a nocache hint to a query. (LarsH) (larsh: rev d40c5066edeb112fb59f7bebe6c78e2fb346d929) phoenix-core/src/main/java/org/apache/phoenix/compile/StatementContext.java phoenix-core/src/main/java/org/apache/phoenix/parse/HintNode.java phoenix-core/src/main/java/org/apache/phoenix/compile/QueryCompiler.java phoenix-core/src/test/java/org/apache/phoenix/compile/QueryCompileTest.java
        Hide
        lhofhansl Lars Hofhansl added a comment -

        Push to master.

        Show
        lhofhansl Lars Hofhansl added a comment - Push to master.
        Hide
        jamestaylor James Taylor added a comment -

        Test looks good, thanks.

        How about just NO_CACHE, as this matches what other relational databases do (http://www.orafaq.com/tuningguide/hints.html), plus it's more consistent with the NO_INDEX hint?

        Show
        jamestaylor James Taylor added a comment - Test looks good, thanks. How about just NO_CACHE, as this matches what other relational databases do ( http://www.orafaq.com/tuningguide/hints.html ), plus it's more consistent with the NO_INDEX hint?
        Hide
        lhofhansl Lars Hofhansl added a comment -

        With test.

        Everybody happy with NO_BLOCK_CACHING as a hint?
        Could also be DO_NOT_CACHE_BLOCKS.

        If no objections/comments. I'll commit tomorrow.

        Show
        lhofhansl Lars Hofhansl added a comment - With test. Everybody happy with NO_BLOCK_CACHING as a hint? Could also be DO_NOT_CACHE_BLOCKS. If no objections/comments. I'll commit tomorrow.
        Hide
        lhofhansl Lars Hofhansl added a comment -

        Was wondering where to put a test for this.
        I was actually looking around for classes beginning with Test* (that's how all HBase test classes are named)

        Show
        lhofhansl Lars Hofhansl added a comment - Was wondering where to put a test for this. I was actually looking around for classes beginning with Test* (that's how all HBase test classes are named)
        Hide
        jamestaylor James Taylor added a comment -

        Looks good, Lars Hofhansl. How about adding a test in QueryCompileTest, similar to testNullInScanKey() that just confirms that the right thing was added to the Scan during compilation?

        Then, I think you should have the perms necessary to check it in.

        Thanks for the contribution!

        Show
        jamestaylor James Taylor added a comment - Looks good, Lars Hofhansl . How about adding a test in QueryCompileTest, similar to testNullInScanKey() that just confirms that the right thing was added to the Scan during compilation? Then, I think you should have the perms necessary to check it in. Thanks for the contribution!
        Hide
        lhofhansl Lars Hofhansl added a comment -

        Here's a simple patch that does this.
        Hooking this into QueryCompiler ensures that this always happens (for DELETE, JOINs, etc)... If I understand this all correctly.

        Show
        lhofhansl Lars Hofhansl added a comment - Here's a simple patch that does this. Hooking this into QueryCompiler ensures that this always happens (for DELETE, JOINs, etc)... If I understand this all correctly.

          People

          • Assignee:
            lhofhansl Lars Hofhansl
            Reporter:
            lhofhansl Lars Hofhansl
          • Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development