You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kylin.apache.org by li...@apache.org on 2016/01/04 03:22:02 UTC
kylin git commit: minor, bug fix in HBaseResourceStore.getFromHTable()
Repository: kylin
Updated Branches:
refs/heads/2.x-staging 61023779a -> e24adf7e7
minor, bug fix in HBaseResourceStore.getFromHTable()
Project: http://git-wip-us.apache.org/repos/asf/kylin/repo
Commit: http://git-wip-us.apache.org/repos/asf/kylin/commit/e24adf7e
Tree: http://git-wip-us.apache.org/repos/asf/kylin/tree/e24adf7e
Diff: http://git-wip-us.apache.org/repos/asf/kylin/diff/e24adf7e
Branch: refs/heads/2.x-staging
Commit: e24adf7e75f106d8ceceab0af52d77f19b37dc1c
Parents: 6102377
Author: Li, Yang <ya...@ebay.com>
Authored: Mon Jan 4 10:21:52 2016 +0800
Committer: Li, Yang <ya...@ebay.com>
Committed: Mon Jan 4 10:21:52 2016 +0800
----------------------------------------------------------------------
.../java/org/apache/kylin/storage/hbase/HBaseResourceStore.java | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/kylin/blob/e24adf7e/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 10ef6c0..50ea757 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
@@ -337,8 +337,9 @@ public class HBaseResourceStore extends ResourceStore {
HTableInterface table = getConnection().getTable(getAllInOneTableName());
try {
- Result result = table.get(get);
- return result == null || result.isEmpty() ? null : result;
+ Result result = table.get(get);
+ boolean exists = result != null && (!result.isEmpty() || (result.getExists() != null && result.getExists()));
+ return exists ? result : null;
} finally {
IOUtils.closeQuietly(table);
}