kylin git commit: KYLIN-3074 Change cube access to project access in ExternalAclProvider.java

2017-12-05 Thread shaofengshi
Repository: kylin
Updated Branches:
  refs/heads/master ed319575e -> 6474e22fe


KYLIN-3074 Change cube access to project access in ExternalAclProvider.java

Signed-off-by: shaofengshi 


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

Branch: refs/heads/master
Commit: 6474e22fe09012d9c22e20685a55de6b43d181a4
Parents: ed31957
Author: peng.jianhua 
Authored: Tue Dec 5 15:31:20 2017 +0800
Committer: shaofengshi 
Committed: Tue Dec 5 16:15:28 2017 +0800

--
 .../kylin/rest/security/AclPermissionFactory.java   | 11 +--
 .../kylin/rest/security/ExternalAclProvider.java| 16 
 webapp/app/partials/cubes/cubes.html|  4 ++--
 webapp/app/partials/models/models_tree.html |  2 +-
 4 files changed, 20 insertions(+), 13 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/kylin/blob/6474e22f/server-base/src/main/java/org/apache/kylin/rest/security/AclPermissionFactory.java
--
diff --git 
a/server-base/src/main/java/org/apache/kylin/rest/security/AclPermissionFactory.java
 
b/server-base/src/main/java/org/apache/kylin/rest/security/AclPermissionFactory.java
index d662403..aeba5fb 100644
--- 
a/server-base/src/main/java/org/apache/kylin/rest/security/AclPermissionFactory.java
+++ 
b/server-base/src/main/java/org/apache/kylin/rest/security/AclPermissionFactory.java
@@ -45,8 +45,15 @@ public class AclPermissionFactory extends 
DefaultPermissionFactory {
 Object fieldValue = field.get(null);
 
 if (Permission.class.isAssignableFrom(fieldValue.getClass())) {
-// Found a Permission static field
-permissions.add((Permission) fieldValue);
+Permission perm = (Permission) fieldValue;
+String permissionName = field.getName();
+if (permissionName.equals(AclPermissionType.ADMINISTRATION)
+|| 
permissionName.equals(AclPermissionType.MANAGEMENT)
+|| 
permissionName.equals(AclPermissionType.OPERATION)
+|| permissionName.equals(AclPermissionType.READ)) {
+// Found a Permission static field
+permissions.add(perm);
+}
 }
 } catch (Exception ignore) {
 //ignore on purpose

http://git-wip-us.apache.org/repos/asf/kylin/blob/6474e22f/server-base/src/main/java/org/apache/kylin/rest/security/ExternalAclProvider.java
--
diff --git 
a/server-base/src/main/java/org/apache/kylin/rest/security/ExternalAclProvider.java
 
b/server-base/src/main/java/org/apache/kylin/rest/security/ExternalAclProvider.java
index 395f44d..9e977d0 100644
--- 
a/server-base/src/main/java/org/apache/kylin/rest/security/ExternalAclProvider.java
+++ 
b/server-base/src/main/java/org/apache/kylin/rest/security/ExternalAclProvider.java
@@ -52,22 +52,22 @@ abstract public class ExternalAclProvider {
 
 // 

 
-public final static String CUBE_ADMIN = "CUBE ADMIN";
-public final static String CUBE_EDIT = "CUBE EDIT";
-public final static String CUBE_OPERATION = "CUBE OPERATION";
-public final static String CUBE_QUERY = "CUBE QUERY";
+public final static String ADMINISTRATION = "ADMIN";
+public final static String MANAGEMENT = "MANAGEMENT";
+public final static String OPERATION = "OPERATION";
+public final static String READ = "QUERY";
 
 // used by ranger ExternalAclProvider
 public static String transformPermission(Permission p) {
 String permString = null;
 if (AclPermission.ADMINISTRATION.equals(p)) {
-permString = CUBE_ADMIN;
+permString = ADMINISTRATION;
 } else if (AclPermission.MANAGEMENT.equals(p)) {
-permString = CUBE_EDIT;
+permString = MANAGEMENT;
 } else if (AclPermission.OPERATION.equals(p)) {
-permString = CUBE_OPERATION;
+permString = OPERATION;
 } else if (AclPermission.READ.equals(p)) {
-permString = CUBE_QUERY;
+permString = READ;
 } else {
 permString = p.getPattern();
 }

http://git-wip-us.apache.org/repos/asf/kylin/blob/6474e22f/webapp/app/partials/cubes/cubes.html
--
diff --git 

kylin git commit: format update

2017-12-05 Thread shaofengshi
Repository: kylin
Updated Branches:
  refs/heads/document 46da08607 -> 5889e32d1


format update

Signed-off-by: shaofengshi 


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

Branch: refs/heads/document
Commit: 5889e32d1c51da0a731feb2676f6dd5948ce558d
Parents: 46da086
Author: joannahe 
Authored: Tue Dec 5 17:13:36 2017 +0800
Committer: shaofengshi 
Committed: Tue Dec 5 17:43:30 2017 +0800

--
 website/_docs21/tutorial/Qlik.cn.md |  49 +--
 website/_docs21/tutorial/Qlik.md|  37 --
 website/images/tutorial/2.1/Qlik/measure.png| Bin 34087 -> 0 bytes
 .../tutorial/2.1/Qlik/odbc_connection.png   | Bin 43145 -> 254828 bytes
 4 files changed, 44 insertions(+), 42 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/kylin/blob/5889e32d/website/_docs21/tutorial/Qlik.cn.md
--
diff --git a/website/_docs21/tutorial/Qlik.cn.md 
b/website/_docs21/tutorial/Qlik.cn.md
index d4e6536..0423b9d 100644
--- a/website/_docs21/tutorial/Qlik.cn.md
+++ b/website/_docs21/tutorial/Qlik.cn.md
@@ -12,7 +12,7 @@ Qlik Sense 是新一代自助式数据可视化工å…
·ã€‚它是一款完整的商
 
 有关安装信息,参考页面 [Kylin ODBC 
驱动](http://kylin.apache.org/cn/docs21/tutorial/odbc.html).
 
-###安装 Qlik Sense
+### 安装 Qlik Sense
 
 有关 Olik Sense 的安装说明,请访问 [Qlik Sense Desktop 
download](https://www.qlik.com/us/try-or-buy/download-qlik-sense).
 
@@ -20,29 +20,30 @@ Qlik Sense 是新一代自助式数据可视化工å…
·ã€‚它是一款完整的商
 
 配置完本地 DSN 并成功安装 Qlik Sense 
后,可执行以下步骤来用 Qlik Sense 连接 Apache Kylin:
 
-1. 打开 **Qlik Sense Desktop**.
-2. 输入 Qlik 用户名和密ç 
ï¼ŒæŽ¥ç€ç³»ç»Ÿå°†å¼¹å‡ºä»¥ä¸‹å¯¹è¯æ¡†ã€‚单击**创建新应用程序**.
+- 打开 **Qlik Sense Desktop**.
 
-![Create New 
Application](../../images/tutorial/2.1/Qlik/welcome_to_qlik_desktop.png)
 
-3. 为新建的应用程序指定名称. 
+- 输入 Qlik 用户名和密ç 
ï¼ŒæŽ¥ç€ç³»ç»Ÿå°†å¼¹å‡ºä»¥ä¸‹å¯¹è¯æ¡†ã€‚单击**创建新应用程序**.
 
-![Specify a unique 
name](../../images/tutorial/2.1/Qlik/create_new_application.png)
+![](/images/tutorial/2.1/Qlik/welcome_to_qlik_desktop.png)
 
-4. 应用程序视图中有两个选项,选择下方的**脚本编辑器**。
+- 为新建的应用程序指定名称. 
 
-![Select Script Editor](../../images/tutorial/2.1/Qlik/script_editor.png)
+![](/images/tutorial/2.1/Qlik/create_new_application.png)
 
-5. 此时会显示 **数据加
载编辑器**的窗口。单击页面右上方的**创建新连接**并选择**ODBC**。
+- 应用程序视图中有两个选项,选择下方的**脚本编辑器**。
 
-![Create New Data 
Connection](../../images/tutorial/2.1/Qlik/create_data_connection.png)
+![](/images/tutorial/2.1/Qlik/script_editor.png)
 
-6. Select **DSN** you have created, ignore the account information, and then 
click **Create**. 
-7. 选择你创建的**DSN**,忽略账户信息,点击**创建**。
+- 此时会显示 **数据加
载编辑器**的窗口。单击页面右上方的**创建新连接**并选择**ODBC**。
 
-![ODBC Connection](../../images/tutorial/2.1/Qlik/odbc_connection.png)
+![Create New Data 
Connection](/images/tutorial/2.1/Qlik/create_data_connection.png)
 
-###配置Direct Query连接模式
+- 选择你创建的**DSN**,忽略账户信息,点击**创建**。
+
+![ODBC Connection](/images/tutorial/2.1/Qlik/odbc_connection.png)
+
+### 配置Direct Query连接模式
 修改默认的脚本中的"TimeFormat", "DateFormat" and "TimestampFormat" 为
 
 `SET TimeFormat='h:mm:ss';`
@@ -55,7 +56,7 @@ Qlik Sense 是新一代自助式数据可视化工å…
·ã€‚它是一款完整的商
 
 下面的截图展现了一个连接了 *Learn_kylin* 项目中的 
*kylin_sales_cube* 的Direct Query的脚本。
 
-![Script](../../images/tutorial/2.1/Qlik/script_run_result.png) 
+![Script](/images/tutorial/2.1/Qlik/script_run_result.png) 
 
 Qlik sense会基于你
定义的这个脚本在报表中相应的生成SQL查询。
 
@@ -69,7 +70,7 @@ Qlik sense会基于你
定义的这个脚本在报表中相应的生成SQL查询
 
 请确保将脚本中`LIB CONNECT TO 'kylin';` 
部分引用的DSN进行相应的修改。 
 
-```sql
+```SQL
 SET ThousandSep=',';
 SET DecimalSep='.';
 SET MoneyThousandSep=',';
@@ -127,30 +128,26 @@ on (KYLIN_COUNTRY.COUNTRY=KYLIN_ACCOUNT.ACCOUNT_COUNTRY)
 
 点击窗口右上方的**加载数据**,Qlik sense会æ 

kylin git commit: KYLIN 3067 provide dim cap in GUL

2017-12-05 Thread chen
Repository: kylin
Updated Branches:
  refs/heads/master 6474e22fe -> f3ae1c42d


KYLIN 3067 provide dim cap in GUL


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

Branch: refs/heads/master
Commit: f3ae1c42d21be10affb0e3feb81056b85c1849cf
Parents: 6474e22
Author: chenzhx 
Authored: Mon Dec 4 12:24:55 2017 +0800
Committer: chenzhx 
Committed: Tue Dec 5 17:54:49 2017 +0800

--
 webapp/app/js/controllers/cubeAdvanceSetting.js   |  6 ++
 .../partials/cubeDesigner/advanced_settings.html  | 18 +-
 webapp/app/partials/cubeDesigner/measures.html|  3 ++-
 .../partials/cubeDesigner/streamingConfig.html|  3 ++-
 4 files changed, 27 insertions(+), 3 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/kylin/blob/f3ae1c42/webapp/app/js/controllers/cubeAdvanceSetting.js
--
diff --git a/webapp/app/js/controllers/cubeAdvanceSetting.js 
b/webapp/app/js/controllers/cubeAdvanceSetting.js
index 8704ed8..7758238 100755
--- a/webapp/app/js/controllers/cubeAdvanceSetting.js
+++ b/webapp/app/js/controllers/cubeAdvanceSetting.js
@@ -23,6 +23,7 @@ KylinApp.controller('CubeAdvanceSettingCtrl', function 
($scope, $modal,cubeConfi
 
   var needLengthKeyList=cubeConfig.needSetLengthEncodingList;
   $scope.convertedRowkeys = [];
+  $scope.dim_cap = $scope.cubeMetaFrame.aggregation_groups.length > 0 && 
$scope.cubeMetaFrame.aggregation_groups[0].select_rule.dim_cap ? 
$scope.cubeMetaFrame.aggregation_groups[0].select_rule.dim_cap : 0;
   angular.forEach($scope.cubeMetaFrame.rowkey.rowkey_columns,function(item){
 item.encoding=$scope.removeVersion(item.encoding);
 var _valueLength;
@@ -104,6 +105,11 @@ KylinApp.controller('CubeAdvanceSettingCtrl', function 
($scope, $modal,cubeConfi
   $scope.sortableOptions = {
 stop:$scope.resortRowkey
   };
+  $scope.changeDimCap  = function (dim_cap) {
+angular.forEach($scope.cubeMetaFrame.aggregation_groups, function (agg) {
+  agg.select_rule.dim_cap = dim_cap
+})
+  }
 
   $scope.addNewHierarchy = function(grp){
 grp.select_rule.hierarchy_dims.push([]);

http://git-wip-us.apache.org/repos/asf/kylin/blob/f3ae1c42/webapp/app/partials/cubeDesigner/advanced_settings.html
--
diff --git a/webapp/app/partials/cubeDesigner/advanced_settings.html 
b/webapp/app/partials/cubeDesigner/advanced_settings.html
index c423097..cc7e264 100755
--- a/webapp/app/partials/cubeDesigner/advanced_settings.html
+++ b/webapp/app/partials/cubeDesigner/advanced_settings.html
@@ -33,7 +33,15 @@
  class="table table-hover list">
 
   ID
-  Aggregation Groups
+  
+Aggregation Groups
+
+  
+  Max Dimension Combination:
+  
+
+  
+  
   
 
 
@@ -580,6 +588,14 @@

  
 
+
+  
+
    +
  1. Dimension limitations mean max dimensions may be contained within a group of SQL queries.
  2. +
  3. In a set of queries, if each query required the number of dimensions is not more than five, you can set 5 here.
  4. +
+
+

kylin git commit: KYLIN-3052 Support Redshift as data source

2017-12-05 Thread shaofengshi
Repository: kylin
Updated Branches:
  refs/heads/KYLIN-3052 [created] fb2c9a5b6


KYLIN-3052 Support Redshift as data source

Signed-off-by: shaofengshi 


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

Branch: refs/heads/KYLIN-3052
Commit: fb2c9a5b6e033907e5109d2b0cb0027fdd5e5647
Parents: 6474e22
Author: ZhansShaoxiong 
Authored: Sat Dec 2 15:28:00 2017 +0800
Committer: shaofengshi 
Committed: Tue Dec 5 17:55:11 2017 +0800

--
 .../org/apache/kylin/job/constant/ExecutableConstants.java  | 1 +
 .../java/org/apache/kylin/rest/service/TableService.java| 8 
 .../java/org/apache/kylin/source/jdbc/JdbcHiveMRInput.java  | 3 ++-
 .../kylin/source/jdbc/metadata/MySQLJdbcMetadata.java   | 6 ++
 .../kylin/source/jdbc/metadata/MySQLJdbcMetadataTest.java   | 9 ++---
 5 files changed, 11 insertions(+), 16 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/kylin/blob/fb2c9a5b/core-job/src/main/java/org/apache/kylin/job/constant/ExecutableConstants.java
--
diff --git 
a/core-job/src/main/java/org/apache/kylin/job/constant/ExecutableConstants.java 
b/core-job/src/main/java/org/apache/kylin/job/constant/ExecutableConstants.java
index f3caf3b..cf61722 100644
--- 
a/core-job/src/main/java/org/apache/kylin/job/constant/ExecutableConstants.java
+++ 
b/core-job/src/main/java/org/apache/kylin/job/constant/ExecutableConstants.java
@@ -35,6 +35,7 @@ public final class ExecutableConstants {
 public static final String STEP_NAME_BUILD_DICTIONARY = "Build Dimension 
Dictionary";
 public static final String STEP_NAME_BUILD_UHC_DICTIONARY = "Build UHC 
Dictionary";
 public static final String STEP_NAME_CREATE_FLAT_HIVE_TABLE = "Create 
Intermediate Flat Hive Table";
+public static final String STEP_NAME_SQOOP_TO_FLAT_HIVE_TABLE = "Sqoop To 
Flat Hive Table";
 public static final String STEP_NAME_MATERIALIZE_HIVE_VIEW_IN_LOOKUP = 
"Materialize Hive View in Lookup Tables";
 public static final String STEP_NAME_FACT_DISTINCT_COLUMNS = "Extract Fact 
Table Distinct Columns";
 public static final String STEP_NAME_CALCULATE_STATS_FROM_BASE_CUBOID = 
"Calculate Statistics from Base Cuboid";

http://git-wip-us.apache.org/repos/asf/kylin/blob/fb2c9a5b/server-base/src/main/java/org/apache/kylin/rest/service/TableService.java
--
diff --git 
a/server-base/src/main/java/org/apache/kylin/rest/service/TableService.java 
b/server-base/src/main/java/org/apache/kylin/rest/service/TableService.java
index ffb71a6..901ac46 100644
--- a/server-base/src/main/java/org/apache/kylin/rest/service/TableService.java
+++ b/server-base/src/main/java/org/apache/kylin/rest/service/TableService.java
@@ -119,7 +119,7 @@ public class TableService extends BasicService {
 SetMultimap db2tables = LinkedHashMultimap.create();
 for (String fullTableName : tables) {
 String[] parts = HadoopUtil.parseHiveTableName(fullTableName);
-db2tables.put(parts[0].toUpperCase(), parts[1].toUpperCase());
+db2tables.put(parts[0], parts[1]);
 }
 
 // load all tables first
@@ -128,9 +128,9 @@ public class TableService extends BasicService {
 for (Map.Entry entry : db2tables.entries()) {
 Pair pair = 
explr.loadTableMetadata(entry.getKey(), entry.getValue(), project);
 TableDesc tableDesc = pair.getFirst();
-
Preconditions.checkState(tableDesc.getDatabase().equals(entry.getKey()));
-
Preconditions.checkState(tableDesc.getName().equals(entry.getValue()));
-
Preconditions.checkState(tableDesc.getIdentity().equals(entry.getKey() + "." + 
entry.getValue()));
+
Preconditions.checkState(tableDesc.getDatabase().equals(entry.getKey().toUpperCase()));
+
Preconditions.checkState(tableDesc.getName().equals(entry.getValue().toUpperCase()));
+
Preconditions.checkState(tableDesc.getIdentity().equals(entry.getKey().toUpperCase()
 + "." + entry.getValue().toUpperCase()));
 TableExtDesc extDesc = pair.getSecond();
 
Preconditions.checkState(tableDesc.getIdentity().equals(extDesc.getIdentity()));
 allMeta.add(pair);

http://git-wip-us.apache.org/repos/asf/kylin/blob/fb2c9a5b/source-hive/src/main/java/org/apache/kylin/source/jdbc/JdbcHiveMRInput.java
--
diff --git 

kylin git commit: KYLIN-3029 The warning window of exist cube name is not work

2017-12-05 Thread chen
Repository: kylin
Updated Branches:
  refs/heads/master f3ae1c42d -> 577acc5a7


KYLIN-3029 The warning window of exist cube name is not work


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

Branch: refs/heads/master
Commit: 577acc5a7c10291d4d5458d9afa620c823822061
Parents: f3ae1c4
Author: peng.jianhua 
Authored: Wed Nov 29 21:33:22 2017 +0800
Committer: chenzhx 
Committed: Tue Dec 5 17:56:47 2017 +0800

--
 webapp/app/js/controllers/cubeSchema.js | 24 
 1 file changed, 12 insertions(+), 12 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/kylin/blob/577acc5a/webapp/app/js/controllers/cubeSchema.js
--
diff --git a/webapp/app/js/controllers/cubeSchema.js 
b/webapp/app/js/controllers/cubeSchema.js
index 590168b..0af7cc2 100755
--- a/webapp/app/js/controllers/cubeSchema.js
+++ b/webapp/app/js/controllers/cubeSchema.js
@@ -160,6 +160,18 @@ KylinApp.controller('CubeSchemaCtrl', function ($scope, 
QueryService, UserServic
 
 });
 
+var queryParam = {offset: 0, limit: 65535};
+
+CubeService.list(queryParam, function (all_cubes) {
+  if($scope.allCubes.length > 0){
+$scope.allCubes.splice(0,$scope.allCubes.length);
+  }
+
+  for (var i = 0; i < all_cubes.length; i++) {
+$scope.allCubes.push(all_cubes[i].name.toUpperCase());
+  }
+});
+
 // ~ public methods
 $scope.filterProj = function(project){
 return $scope.userService.hasRole('ROLE_ADMIN') || 
$scope.hasPermission(project,$scope.permissions.ADMINISTRATION.mask);
@@ -292,18 +304,6 @@ KylinApp.controller('CubeSchemaCtrl', function ($scope, 
QueryService, UserServic
 
   $scope.check_cube_info = function(){
 
-var queryParam = {offset: 0, limit: 65535};
-
-CubeService.list(queryParam, function (all_cubes) {
-  if($scope.allCubes.length > 0){
-$scope.allCubes.splice(0,$scope.allCubes.length);
-  }
-
-  for (var i = 0; i < all_cubes.length; i++) {
-$scope.allCubes.push(all_cubes[i].name.toUpperCase());
-  }
-});
-
 if(($scope.state.mode === "edit") 
&&$scope.cubeMode=="addNewCube"&&($scope.allCubes.indexOf($scope.cubeMetaFrame.name.toUpperCase())
 >= 0)){
   SweetAlert.swal('Oops...', "The cube named [" + 
$scope.cubeMetaFrame.name.toUpperCase() + "] already exists", 'warning');
   return false;



[2/2] kylin git commit: KYLIN-3068 use dfs.blocksize instead of deprecated parameter name

2017-12-05 Thread shaofengshi
KYLIN-3068 use dfs.blocksize instead of deprecated parameter name

Signed-off-by: shaofengshi 


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

Branch: refs/heads/master
Commit: 14dd92e00fa1548889bf6e6bba8010f8a6a8cfcf
Parents: 5c435cd
Author: Seva Ostapenko 
Authored: Tue Dec 5 17:38:57 2017 -0500
Committer: shaofengshi 
Committed: Wed Dec 6 09:08:33 2017 +0800

--
 .../kylin/source/hive/cardinality/HiveColumnCardinalityJob.java| 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
--


http://git-wip-us.apache.org/repos/asf/kylin/blob/14dd92e0/source-hive/src/main/java/org/apache/kylin/source/hive/cardinality/HiveColumnCardinalityJob.java
--
diff --git 
a/source-hive/src/main/java/org/apache/kylin/source/hive/cardinality/HiveColumnCardinalityJob.java
 
b/source-hive/src/main/java/org/apache/kylin/source/hive/cardinality/HiveColumnCardinalityJob.java
index 3942a68..dd32a58 100644
--- 
a/source-hive/src/main/java/org/apache/kylin/source/hive/cardinality/HiveColumnCardinalityJob.java
+++ 
b/source-hive/src/main/java/org/apache/kylin/source/hive/cardinality/HiveColumnCardinalityJob.java
@@ -86,7 +86,7 @@ public class HiveColumnCardinalityJob extends 
AbstractHadoopJob {
 
 Path output = new Path(getOptionValue(OPTION_OUTPUT_PATH));
 FileOutputFormat.setOutputPath(job, output);
-job.getConfiguration().set("dfs.block.size", "67108864");
+job.getConfiguration().set("dfs.blocksize", "67108864");
 
job.getConfiguration().set("mapreduce.output.fileoutputformat.compress", 
"false");
 
 // Mapper



[1/2] kylin git commit: KYLIN-3052 Support Redshift as data source

2017-12-05 Thread shaofengshi
Repository: kylin
Updated Branches:
  refs/heads/master 577acc5a7 -> 14dd92e00


KYLIN-3052 Support Redshift as data source

Signed-off-by: shaofengshi 


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

Branch: refs/heads/master
Commit: 5c435cd3554e926f176143633a09a27554905788
Parents: 577acc5
Author: ZhansShaoxiong 
Authored: Sat Dec 2 15:28:00 2017 +0800
Committer: shaofengshi 
Committed: Wed Dec 6 09:08:13 2017 +0800

--
 .../org/apache/kylin/job/constant/ExecutableConstants.java  | 1 +
 .../java/org/apache/kylin/rest/service/TableService.java| 8 
 .../java/org/apache/kylin/source/jdbc/JdbcHiveMRInput.java  | 3 ++-
 .../kylin/source/jdbc/metadata/MySQLJdbcMetadata.java   | 6 ++
 .../kylin/source/jdbc/metadata/MySQLJdbcMetadataTest.java   | 9 ++---
 5 files changed, 11 insertions(+), 16 deletions(-)
--


http://git-wip-us.apache.org/repos/asf/kylin/blob/5c435cd3/core-job/src/main/java/org/apache/kylin/job/constant/ExecutableConstants.java
--
diff --git 
a/core-job/src/main/java/org/apache/kylin/job/constant/ExecutableConstants.java 
b/core-job/src/main/java/org/apache/kylin/job/constant/ExecutableConstants.java
index f3caf3b..cf61722 100644
--- 
a/core-job/src/main/java/org/apache/kylin/job/constant/ExecutableConstants.java
+++ 
b/core-job/src/main/java/org/apache/kylin/job/constant/ExecutableConstants.java
@@ -35,6 +35,7 @@ public final class ExecutableConstants {
 public static final String STEP_NAME_BUILD_DICTIONARY = "Build Dimension 
Dictionary";
 public static final String STEP_NAME_BUILD_UHC_DICTIONARY = "Build UHC 
Dictionary";
 public static final String STEP_NAME_CREATE_FLAT_HIVE_TABLE = "Create 
Intermediate Flat Hive Table";
+public static final String STEP_NAME_SQOOP_TO_FLAT_HIVE_TABLE = "Sqoop To 
Flat Hive Table";
 public static final String STEP_NAME_MATERIALIZE_HIVE_VIEW_IN_LOOKUP = 
"Materialize Hive View in Lookup Tables";
 public static final String STEP_NAME_FACT_DISTINCT_COLUMNS = "Extract Fact 
Table Distinct Columns";
 public static final String STEP_NAME_CALCULATE_STATS_FROM_BASE_CUBOID = 
"Calculate Statistics from Base Cuboid";

http://git-wip-us.apache.org/repos/asf/kylin/blob/5c435cd3/server-base/src/main/java/org/apache/kylin/rest/service/TableService.java
--
diff --git 
a/server-base/src/main/java/org/apache/kylin/rest/service/TableService.java 
b/server-base/src/main/java/org/apache/kylin/rest/service/TableService.java
index ffb71a6..901ac46 100644
--- a/server-base/src/main/java/org/apache/kylin/rest/service/TableService.java
+++ b/server-base/src/main/java/org/apache/kylin/rest/service/TableService.java
@@ -119,7 +119,7 @@ public class TableService extends BasicService {
 SetMultimap db2tables = LinkedHashMultimap.create();
 for (String fullTableName : tables) {
 String[] parts = HadoopUtil.parseHiveTableName(fullTableName);
-db2tables.put(parts[0].toUpperCase(), parts[1].toUpperCase());
+db2tables.put(parts[0], parts[1]);
 }
 
 // load all tables first
@@ -128,9 +128,9 @@ public class TableService extends BasicService {
 for (Map.Entry entry : db2tables.entries()) {
 Pair pair = 
explr.loadTableMetadata(entry.getKey(), entry.getValue(), project);
 TableDesc tableDesc = pair.getFirst();
-
Preconditions.checkState(tableDesc.getDatabase().equals(entry.getKey()));
-
Preconditions.checkState(tableDesc.getName().equals(entry.getValue()));
-
Preconditions.checkState(tableDesc.getIdentity().equals(entry.getKey() + "." + 
entry.getValue()));
+
Preconditions.checkState(tableDesc.getDatabase().equals(entry.getKey().toUpperCase()));
+
Preconditions.checkState(tableDesc.getName().equals(entry.getValue().toUpperCase()));
+
Preconditions.checkState(tableDesc.getIdentity().equals(entry.getKey().toUpperCase()
 + "." + entry.getValue().toUpperCase()));
 TableExtDesc extDesc = pair.getSecond();
 
Preconditions.checkState(tableDesc.getIdentity().equals(extDesc.getIdentity()));
 allMeta.add(pair);

http://git-wip-us.apache.org/repos/asf/kylin/blob/5c435cd3/source-hive/src/main/java/org/apache/kylin/source/jdbc/JdbcHiveMRInput.java
--
diff --git 

svn commit: r1817203 - in /kylin/site: ./ cn/docs21/install/ cn/docs21/tutorial/ docs21/ docs21/gettingstarted/ docs21/howto/ docs21/install/ docs21/tutorial/ images/tutorial/2.1/Qlik/

2017-12-05 Thread lidong
Author: lidong
Date: Tue Dec  5 14:01:33 2017
New Revision: 1817203

URL: http://svn.apache.org/viewvc?rev=1817203=rev
Log:
format update

Modified:
kylin/site/cn/docs21/install/index.html
kylin/site/cn/docs21/tutorial/Qlik.html
kylin/site/docs21/gettingstarted/best_practices.html
kylin/site/docs21/gettingstarted/concepts.html
kylin/site/docs21/gettingstarted/events.html
kylin/site/docs21/gettingstarted/faq.html
kylin/site/docs21/gettingstarted/terminology.html
kylin/site/docs21/howto/howto_backup_metadata.html
kylin/site/docs21/howto/howto_build_cube_with_restapi.html
kylin/site/docs21/howto/howto_cleanup_storage.html
kylin/site/docs21/howto/howto_enable_zookeeper_acl.html
kylin/site/docs21/howto/howto_install_ranger_kylin_plugin.html
kylin/site/docs21/howto/howto_jdbc.html
kylin/site/docs21/howto/howto_ldap_and_sso.html
kylin/site/docs21/howto/howto_optimize_build.html
kylin/site/docs21/howto/howto_optimize_cubes.html
kylin/site/docs21/howto/howto_update_coprocessor.html
kylin/site/docs21/howto/howto_upgrade.html
kylin/site/docs21/howto/howto_use_beeline.html
kylin/site/docs21/howto/howto_use_distributed_scheduler.html
kylin/site/docs21/howto/howto_use_restapi.html
kylin/site/docs21/howto/howto_use_restapi_in_js.html
kylin/site/docs21/index.html
kylin/site/docs21/install/advance_settings.html
kylin/site/docs21/install/hadoop_env.html
kylin/site/docs21/install/index.html
kylin/site/docs21/install/kylin_aws_emr.html
kylin/site/docs21/install/kylin_cluster.html
kylin/site/docs21/install/kylin_docker.html
kylin/site/docs21/release_notes.html
kylin/site/docs21/tutorial/Qlik.html
kylin/site/docs21/tutorial/acl.html
kylin/site/docs21/tutorial/create_cube.html
kylin/site/docs21/tutorial/cube_build_job.html
kylin/site/docs21/tutorial/cube_build_performance.html
kylin/site/docs21/tutorial/cube_spark.html
kylin/site/docs21/tutorial/cube_streaming.html
kylin/site/docs21/tutorial/flink.html
kylin/site/docs21/tutorial/hue.html
kylin/site/docs21/tutorial/kylin_sample.html
kylin/site/docs21/tutorial/microstrategy.html
kylin/site/docs21/tutorial/odbc.html
kylin/site/docs21/tutorial/powerbi.html
kylin/site/docs21/tutorial/project_level_acl.html
kylin/site/docs21/tutorial/query_pushdown.html
kylin/site/docs21/tutorial/squirrel.html
kylin/site/docs21/tutorial/tableau.html
kylin/site/docs21/tutorial/tableau_91.html
kylin/site/docs21/tutorial/web.html
kylin/site/feed.xml
kylin/site/images/tutorial/2.1/Qlik/odbc_connection.png

Modified: kylin/site/cn/docs21/install/index.html
URL: 
http://svn.apache.org/viewvc/kylin/site/cn/docs21/install/index.html?rev=1817203=1817202=1817203=diff
==
--- kylin/site/cn/docs21/install/index.html (original)
+++ kylin/site/cn/docs21/install/index.html Tue Dec  5 14:01:33 2017
@@ -2866,7 +2866,7 @@
 
   
 
-  Integration with Qlik Sense  
+  Qlik Sense  
   
 
 

Modified: kylin/site/cn/docs21/tutorial/Qlik.html
URL: 
http://svn.apache.org/viewvc/kylin/site/cn/docs21/tutorial/Qlik.html?rev=1817203=1817202=1817203=diff
==
--- kylin/site/cn/docs21/tutorial/Qlik.html (original)
+++ kylin/site/cn/docs21/tutorial/Qlik.html Tue Dec  5 14:01:33 2017
@@ -1505,7 +1505,7 @@
 
 有关安装信息,参考页面 http://kylin.apache.org/cn/docs21/tutorial/odbc.html;>Kylin ODBC 
驱动.
 
-###安装 Qlik Sense
+安装 Qlik Sense
 
 有关 Olik Sense 的安装说明,请访问 https://www.qlik.com/us/try-or-buy/download-qlik-sense;>Qlik Sense 
Desktop download.
 
@@ -1513,40 +1513,43 @@
 
 配置完本地 DSN 并成功安装 Qlik Sense 
后,可执行以下步骤来用 Qlik Sense 连接 Apache Kylin:
 
-
-  打开 Qlik Sense Desktop.
-  输入 Qlik 用户名和密ç 
ï¼ŒæŽ¥ç€ç³»ç»Ÿå°†å¼¹å‡ºä»¥ä¸‹å¯¹è¯æ¡†ã€‚单击创建新应用程序.
-
+
+  
+打开 Qlik Sense Desktop.
+  
+  
+输入 Qlik 用户名和密ç 
ï¼ŒæŽ¥ç€ç³»ç»Ÿå°†å¼¹å‡ºä»¥ä¸‹å¯¹è¯æ¡†ã€‚单击创建新应用程序.
+  
+
 
-
+
 
-
+
   为新建的应用程序指定名称.
-
+
 
-
+
 
-
+
   
应用程序视图中有两个选项,选择下方的脚本编辑器。
-
+
 
-
+
 
-
+
   此时会显示 数据加
载编辑器的窗口。单击页面右上方的创建新连接并选择ODBC。
-
+
 
-
+
 
-
-  Select DSN you have created, ignore the account 
information, and then click Create.
+
   选择你
创建的DSN,忽略账户信息,点击创建。
-
+
 
-
+
 
-###配置Direct Query连接模式
-修改默认的脚本中的”TimeFormat”, “DateFormat” and 
“TimestampFormat” 为
+配置Direct Query连接模式
+修改默认的脚本中的”TimeFormat”, “DateFormat” and 
“TimestampFormat” 为
 
 SET TimeFormat='h:mm:ss';
 SET