kylin-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mahong...@apache.org
Subject kylin git commit: Need not to shrink scan cache when hbase rows can be large
Date Thu, 21 Apr 2016 10:11:30 GMT
Repository: kylin
Updated Branches:
  refs/heads/yang-m1 10a2f65e4 -> 154b27fb1


Need not to shrink scan cache when hbase rows can be large


Project: http://git-wip-us.apache.org/repos/asf/kylin/repo
Commit: http://git-wip-us.apache.org/repos/asf/kylin/commit/154b27fb
Tree: http://git-wip-us.apache.org/repos/asf/kylin/tree/154b27fb
Diff: http://git-wip-us.apache.org/repos/asf/kylin/diff/154b27fb

Branch: refs/heads/yang-m1
Commit: 154b27fb190d6e8fe8d2b8e469807b03ad05a774
Parents: 10a2f65
Author: Hongbin Ma <mahongbin@apache.org>
Authored: Thu Apr 21 18:11:15 2016 +0800
Committer: Hongbin Ma <mahongbin@apache.org>
Committed: Thu Apr 21 18:11:21 2016 +0800

----------------------------------------------------------------------
 .../org/apache/kylin/storage/hbase/HBaseResourceStore.java   | 4 +++-
 .../storage/hbase/cube/v1/CubeSegmentTupleIterator.java      | 6 +++---
 .../org/apache/kylin/storage/hbase/cube/v2/CubeHBaseRPC.java | 8 ++++----
 3 files changed, 10 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/kylin/blob/154b27fb/storage-hbase/src/main/java/org/apache/kylin/storage/hbase/HBaseResourceStore.java
----------------------------------------------------------------------
diff --git a/storage-hbase/src/main/java/org/apache/kylin/storage/hbase/HBaseResourceStore.java
b/storage-hbase/src/main/java/org/apache/kylin/storage/hbase/HBaseResourceStore.java
index bb5382f..2262482 100644
--- a/storage-hbase/src/main/java/org/apache/kylin/storage/hbase/HBaseResourceStore.java
+++ b/storage-hbase/src/main/java/org/apache/kylin/storage/hbase/HBaseResourceStore.java
@@ -148,7 +148,9 @@ public class HBaseResourceStore extends ResourceStore {
 
     private void tuneScanParameters(Scan scan) {
         // divide by 10 as some resource like dictionary or snapshot can be very large
-        scan.setCaching(kylinConfig.getHBaseScanCacheRows() / 10);
+        // scan.setCaching(kylinConfig.getHBaseScanCacheRows() / 10);
+        scan.setCaching(kylinConfig.getHBaseScanCacheRows());
+
         scan.setMaxResultSize(kylinConfig.getHBaseScanMaxResultSize());
         scan.setCacheBlocks(true);
     }

http://git-wip-us.apache.org/repos/asf/kylin/blob/154b27fb/storage-hbase/src/main/java/org/apache/kylin/storage/hbase/cube/v1/CubeSegmentTupleIterator.java
----------------------------------------------------------------------
diff --git a/storage-hbase/src/main/java/org/apache/kylin/storage/hbase/cube/v1/CubeSegmentTupleIterator.java
b/storage-hbase/src/main/java/org/apache/kylin/storage/hbase/cube/v1/CubeSegmentTupleIterator.java
index d7ea2a0..9eb05d2 100644
--- a/storage-hbase/src/main/java/org/apache/kylin/storage/hbase/cube/v1/CubeSegmentTupleIterator.java
+++ b/storage-hbase/src/main/java/org/apache/kylin/storage/hbase/cube/v1/CubeSegmentTupleIterator.java
@@ -258,9 +258,9 @@ public class CubeSegmentTupleIterator implements ITupleIterator {
         scan.setCacheBlocks(true);
 
         // cache less when there are memory hungry measures
-        if (RowValueDecoder.hasMemHungryMeasures(rowValueDecoders)) {
-            scan.setCaching(scan.getCaching() / 10);
-        }
+//        if (RowValueDecoder.hasMemHungryMeasures(rowValueDecoders)) {
+//            scan.setCaching(scan.getCaching() / 10);
+//        }
     }
 
     private void applyFuzzyFilter(Scan scan, HBaseKeyRange keyRange) {

http://git-wip-us.apache.org/repos/asf/kylin/blob/154b27fb/storage-hbase/src/main/java/org/apache/kylin/storage/hbase/cube/v2/CubeHBaseRPC.java
----------------------------------------------------------------------
diff --git a/storage-hbase/src/main/java/org/apache/kylin/storage/hbase/cube/v2/CubeHBaseRPC.java
b/storage-hbase/src/main/java/org/apache/kylin/storage/hbase/cube/v2/CubeHBaseRPC.java
index 8563a5e..7567b96 100644
--- a/storage-hbase/src/main/java/org/apache/kylin/storage/hbase/cube/v2/CubeHBaseRPC.java
+++ b/storage-hbase/src/main/java/org/apache/kylin/storage/hbase/cube/v2/CubeHBaseRPC.java
@@ -117,8 +117,8 @@ public abstract class CubeHBaseRPC {
         KylinConfig config = cubeSeg.getCubeDesc().getConfig();
         int hbaseCaching = config.getHBaseScanCacheRows();
         int hbaseMaxResultSize = config.getHBaseScanMaxResultSize();
-        if (isMemoryHungry(selectedColBlocks))
-            hbaseCaching /= 10;
+//        if (isMemoryHungry(selectedColBlocks))
+//            hbaseCaching /= 10;
 
         return new RawScan(start, end, selectedColumns, hbaseFuzzyKeys, hbaseCaching, hbaseMaxResultSize);
     }
@@ -155,8 +155,8 @@ public abstract class CubeHBaseRPC {
         KylinConfig config = cubeSeg.getCubeDesc().getConfig();
         int hbaseCaching = config.getHBaseScanCacheRows();
         int hbaseMaxResultSize = config.getHBaseScanMaxResultSize();
-        if (isMemoryHungry(selectedColBlocks))
-            hbaseCaching /= 10;
+//        if (isMemoryHungry(selectedColBlocks))
+//            hbaseCaching /= 10;
 
         for (short i = 0; i < startKeys.size(); ++i) {
             ret.add(new RawScan(startKeys.get(i), endKeys.get(i), selectedColumns, hbaseFuzzyKeys,
hbaseCaching, hbaseMaxResultSize));


Mime
View raw message