kylin-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lid...@apache.org
Subject [06/50] [abbrv] kylin git commit: KYLIN-2243 use at least 1Mb for TopNCounterSerializer.maxLength()
Date Tue, 20 Dec 2016 11:27:31 GMT
KYLIN-2243 use at least 1Mb for TopNCounterSerializer.maxLength()


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

Branch: refs/heads/master-cdh5.7
Commit: a4ddbbdde876d0690dd65ea8549e8d40cfb5fdd1
Parents: 8ffb0e7
Author: shaofengshi <shaofengshi@apache.org>
Authored: Mon Dec 12 14:34:19 2016 +0800
Committer: shaofengshi <shaofengshi@apache.org>
Committed: Mon Dec 12 14:34:19 2016 +0800

----------------------------------------------------------------------
 .../java/org/apache/kylin/measure/topn/TopNCounterSerializer.java  | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/kylin/blob/a4ddbbdd/core-metadata/src/main/java/org/apache/kylin/measure/topn/TopNCounterSerializer.java
----------------------------------------------------------------------
diff --git a/core-metadata/src/main/java/org/apache/kylin/measure/topn/TopNCounterSerializer.java
b/core-metadata/src/main/java/org/apache/kylin/measure/topn/TopNCounterSerializer.java
index 071e2a2..cef9177 100644
--- a/core-metadata/src/main/java/org/apache/kylin/measure/topn/TopNCounterSerializer.java
+++ b/core-metadata/src/main/java/org/apache/kylin/measure/topn/TopNCounterSerializer.java
@@ -54,7 +54,7 @@ public class TopNCounterSerializer extends DataTypeSerializer<TopNCounter<ByteAr
 
     @Override
     public int maxLength() {
-        return precision * TopNCounter.EXTRA_SPACE_RATE * (4 + 8);
+        return Math.max(precision * TopNCounter.EXTRA_SPACE_RATE * (4 + 8), 1024 * 1024);
// use at least 1M
     }
 
     @Override


Mime
View raw message