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 2015/03/14 01:02:13 UTC

[01/47] incubator-kylin git commit: refactor loadHiveTable Code to tableModel & KYLIN-373

Repository: incubator-kylin
Updated Branches:
  refs/heads/master a3b4bccd9 -> 2efaf25df


refactor loadHiveTable Code to tableModel & KYLIN-373


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

Branch: refs/heads/master
Commit: 24210b16e084a8fc9030fba41a72300cbfaa66bb
Parents: 698537b
Author: jiazhong <ji...@ebay.com>
Authored: Tue Mar 3 18:55:16 2015 +0800
Committer: jiazhong <ji...@ebay.com>
Committed: Tue Mar 3 18:55:16 2015 +0800

----------------------------------------------------------------------
 webapp/app/js/controllers/cubeSchema.js         | 41 ++++++++--
 webapp/app/js/controllers/sourceMeta.js         | 62 +---------------
 webapp/app/js/model/projectModel.js             |  3 +
 webapp/app/js/model/tableModel.js               | 78 +++++++++++++++++++-
 .../app/partials/cubeDesigner/incremental.html  |  8 +-
 webapp/app/partials/cubes/cube_schema.html      |  2 +-
 .../app/partials/tables/source_table_tree.html  |  2 +-
 7 files changed, 122 insertions(+), 74 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/24210b16/webapp/app/js/controllers/cubeSchema.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/cubeSchema.js b/webapp/app/js/controllers/cubeSchema.js
index 17f7b71..9654ac7 100755
--- a/webapp/app/js/controllers/cubeSchema.js
+++ b/webapp/app/js/controllers/cubeSchema.js
@@ -18,7 +18,7 @@
 
 'use strict';
 
-KylinApp.controller('CubeSchemaCtrl', function ($scope, QueryService, UserService, ProjectService, AuthenticationService,$filter,ModelService,MetaModel,CubeDescModel,CubeList) {
+KylinApp.controller('CubeSchemaCtrl', function ($scope, QueryService, UserService, ProjectService, AuthenticationService,$filter,ModelService,MetaModel,CubeDescModel,CubeList,TableModel,ProjectModel) {
 
     $scope.projects = [];
     $scope.newDimension = null;
@@ -186,6 +186,7 @@ KylinApp.controller('CubeSchemaCtrl', function ($scope, QueryService, UserServic
 
     $scope.nextView = function () {
         var stepIndex = $scope.wizardSteps.indexOf($scope.curStep);
+
         if (stepIndex < ($scope.wizardSteps.length - 1)) {
             $scope.curStep.isComplete = true;
             $scope.curStep = $scope.wizardSteps[stepIndex + 1];
@@ -196,6 +197,23 @@ KylinApp.controller('CubeSchemaCtrl', function ($scope, QueryService, UserServic
         }
     };
 
+    $scope.goToStep = function(stepIndex){
+        for(var i=0;i<$scope.wizardSteps.length;i++){
+            if(i<=stepIndex){
+                $scope.wizardSteps[i].isComplete = true;
+            }else{
+                $scope.wizardSteps[i].isComplete = false;
+            }
+        }
+        if (stepIndex < ($scope.wizardSteps.length)) {
+            $scope.curStep = $scope.wizardSteps[stepIndex];
+
+            AuthenticationService.ping(function (data) {
+                UserService.setCurUser(data);
+            });
+        }
+    }
+
     // ~ private methods
     function initProject() {
         ProjectService.list({}, function (projects) {
@@ -204,13 +222,22 @@ KylinApp.controller('CubeSchemaCtrl', function ($scope, QueryService, UserServic
             var cubeName = (!!$scope.routeParams.cubeName)? $scope.routeParams.cubeName:$scope.state.cubeName;
             if (cubeName) {
                 var projName = null;
-                angular.forEach($scope.projects, function (project, index) {
-                    angular.forEach(project.realizations, function (unit, index) {
-                        if (!projName && unit.type=="CUBE"&&unit.realization === cubeName) {
-                            projName = project.name;
-                        }
+                if(ProjectModel.getSelectedProject()){
+                    projName=ProjectModel.getSelectedProject();
+                }else{
+                    angular.forEach($scope.projects, function (project, index) {
+                        angular.forEach(project.realizations, function (unit, index) {
+                            if (!projName && unit.type=="CUBE"&&unit.realization === cubeName) {
+                                projName = project.name;
+                            }
+                        });
                     });
-                });
+                }
+
+                if(!ProjectModel.getSelectedProject()){
+                    ProjectModel.setSelectedProject(projName);
+                    TableModel.aceSrcTbLoaded();
+                }
 
                 $scope.cubeMetaFrame.project = projName;
             }

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/24210b16/webapp/app/js/controllers/sourceMeta.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/sourceMeta.js b/webapp/app/js/controllers/sourceMeta.js
index 6f14e83..1e100a0 100755
--- a/webapp/app/js/controllers/sourceMeta.js
+++ b/webapp/app/js/controllers/sourceMeta.js
@@ -41,70 +41,14 @@ KylinApp
        };
 
         $scope.aceSrcTbLoaded = function (forceLoad) {
-            $scope.tableModel.selectedSrcDb = [];
-            $scope.treeOptions = {
-                nodeChildren: "columns",
-                injectClasses: {
-                    ul: "a1",
-                    li: "a2",
-                    liSelected: "a7",
-                    iExpanded: "a3",
-                    iCollapsed: "a4",
-                    iLeaf: "a5",
-                    label: "a6",
-                    labelSelected: "a8"
-                }
-            };
-
-            $scope.tableModel.selectedSrcTable = {};
-            var defer = $q.defer();
-
-            $scope.loading = true;
-            var param = {
-                ext: true,
-                project:$scope.projectModel.selectedProject
-            };
-            if (forceLoad)
+             if (forceLoad)
             {
-//                param.timestamp = new Date().getTime();
                 $httpDefaultCache.removeAll();
             }
-            TableService.list(param, function (tables) {
-                var tableMap = [];
-                angular.forEach(tables, function (table) {
-                    if (!tableMap[table.database]) {
-                        tableMap[table.database] = [];
-                    }
-                    angular.forEach(table.columns, function (column) {
-                        if(table.cardinality[column.name]) {
-                            column.cardinality = table.cardinality[column.name];
-                        }else{
-                            column.cardinality = null;
-                        }
-                        column.id = parseInt(column.id);
-                    });
-                    tableMap[table.database].push(table);
-                });
-
-//                Sort Table
-                for (var key in  tableMap) {
-                    var obj = tableMap[key];
-                    obj.sort(innerSort);
-                }
-
-              $scope.tableModel.selectedSrcDb = [];
-                for (var key in  tableMap) {
-                    var tables = tableMap[key];
-                    $scope.tableModel.selectedSrcDb.push({
-                        "name": key,
-                        "columns": tables
-                    });
-                }
+            $scope.loading = true;
+            TableModel.aceSrcTbLoaded(forceLoad).then(function(){
                 $scope.loading = false;
-                defer.resolve();
             });
-
-            return defer.promise;
         };
 
         $scope.$watch('projectModel.selectedProject', function (newValue, oldValue) {

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/24210b16/webapp/app/js/model/projectModel.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/model/projectModel.js b/webapp/app/js/model/projectModel.js
index 8f60d6c..b0c05fe 100644
--- a/webapp/app/js/model/projectModel.js
+++ b/webapp/app/js/model/projectModel.js
@@ -27,6 +27,9 @@ KylinApp.service('ProjectModel',function(){
             this.selectedProject = project;
         }
     };
+    this.getSelectedProject = function(project) {
+         return this.selectedProject;
+    };
 
     this.setProjects = function(projects){
         if(projects.length){

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/24210b16/webapp/app/js/model/tableModel.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/model/tableModel.js b/webapp/app/js/model/tableModel.js
index a3bc820..687acb5 100755
--- a/webapp/app/js/model/tableModel.js
+++ b/webapp/app/js/model/tableModel.js
@@ -16,9 +16,10 @@
  * limitations under the License.
 */
 
-KylinApp.service('TableModel', function() {
+KylinApp.service('TableModel', function(ProjectModel,$q,TableService) {
 
 
+    var _this = this;
    //for tables in cubeDesigner
     this.selectProjectTables = [];
 
@@ -45,5 +46,80 @@ KylinApp.service('TableModel', function() {
     }
 
 
+    this.treeOptions = {
+        nodeChildren: "columns",
+        injectClasses: {
+            ul: "a1",
+            li: "a2",
+            liSelected: "a7",
+            iExpanded: "a3",
+            iCollapsed: "a4",
+            iLeaf: "a5",
+            label: "a6",
+            labelSelected: "a8"
+        }
+    };
+
+    this.aceSrcTbLoaded = function (forceLoad) {
+        _this.selectedSrcDb = [];
+
+        _this.selectedSrcTable = {};
+        var defer = $q.defer();
+
+        var param = {
+            ext: true,
+            project:ProjectModel.selectedProject
+        };
+
+        if(!ProjectModel.selectedProject){
+            defer.resolve();
+            return defer.promise;
+        }
+
+        TableService.list(param, function (tables) {
+            var tableMap = [];
+            angular.forEach(tables, function (table) {
+                if (!tableMap[table.database]) {
+                    tableMap[table.database] = [];
+                }
+                angular.forEach(table.columns, function (column) {
+                    if(table.cardinality[column.name]) {
+                        column.cardinality = table.cardinality[column.name];
+                    }else{
+                        column.cardinality = null;
+                    }
+                    column.id = parseInt(column.id);
+                });
+                tableMap[table.database].push(table);
+            });
+
+//                Sort Table
+            for (var key in  tableMap) {
+                var obj = tableMap[key];
+                obj.sort(_this.innerSort);
+            }
+
+            _this.selectedSrcDb = [];
+            for (var key in  tableMap) {
+                var tables = tableMap[key];
+                _this.selectedSrcDb.push({
+                    "name": key,
+                    "columns": tables
+                });
+            }
+            defer.resolve();
+        });
+
+        return defer.promise;
+    };
+    this.innerSort =function(a, b) {
+        var nameA = a.name.toLowerCase(), nameB = b.name.toLowerCase();
+        if (nameA < nameB) //sort string ascending
+            return -1;
+        if (nameA > nameB)
+            return 1;
+        return 0; //default return value (no sorting)
+    };
+
 });
 

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/24210b16/webapp/app/partials/cubeDesigner/incremental.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/cubeDesigner/incremental.html b/webapp/app/partials/cubeDesigner/incremental.html
index 365ef43..6ee70b7 100755
--- a/webapp/app/partials/cubeDesigner/incremental.html
+++ b/webapp/app/partials/cubeDesigner/incremental.html
@@ -42,7 +42,7 @@
                 <label class="control-label col-xs-12 col-sm-3 no-padding-right font-color-default"><b>Partition Date Column</b></label>
                 <div class="col-xs-12 col-sm-6">
 
-                    <select style="width: 100%" chosen data-placeholder="e.g. TEST_KYLIN_FACT.CAL_DT"
+                    <select style="width: 100%" chosen data-placeholder="e.g. DEFAULT.TEST_KYLIN_FACT.CAL_DT"
                             ng-required="metaModel.model.partition_desc.partition_date_start"
                             ng-model="metaModel.model.partition_desc.partition_date_column"
                             ng-if="state.mode=='edit'"
@@ -50,8 +50,7 @@
                         <option value=""></option>
                     </select>
                     <span ng-if="state.mode=='view'">
-                        {{!!(metaModel.model.partition_desc.partition_date_column)?
-                        metaModel.model.partition_desc.partition_date_column: 'Undefined'}}</span>
+                        {{!!(metaModel.model.partition_desc.partition_date_column)?metaModel.model.partition_desc.partition_date_column: ''}}</span>
                 </div>
             </div>
         </div>
@@ -64,8 +63,7 @@
                     <input type="text" class="form-control" datepicker-popup="yyyy-MM-dd"
                            ng-model="metaModel.model.partition_desc.partition_date_start" ng-if="state.mode=='edit'"
                            placeholder="Click to choose start date..." is-open="opened" />
-                    <span ng-if="state.mode=='view'">{{
-                        (metaModel.model.partition_desc.partition_date_start)|date:'yyyy-MM-dd HH:mm:ss' }}</span>
+                    <span ng-if="state.mode=='view'&&metaModel.model.partition_desc.partition_date_column">{{(metaModel.model.partition_desc.partition_date_start)|reverseToGMT0 }}</span>
                 </div>
             </div>
         </div>

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/24210b16/webapp/app/partials/cubes/cube_schema.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/cubes/cube_schema.html b/webapp/app/partials/cubes/cube_schema.html
index 5a7178a..b9359f0 100644
--- a/webapp/app/partials/cubes/cube_schema.html
+++ b/webapp/app/partials/cubes/cube_schema.html
@@ -28,7 +28,7 @@
                 <ul class="wizard-steps">
                     <li ng-repeat="step in wizardSteps"
                         class="{{step==curStep?'active':''}} {{step.isComplete?'complete':''}}">
-                        <span class="step">{{step.step = ($index + 1)}}</span>
+                        <span style="cursor:pointer;" ng-click="goToStep($index)" class="step">{{step.step = ($index + 1)}}</span>
                         <span class="title">{{step.title}}</span>
                      </li>
                 </ul>

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/24210b16/webapp/app/partials/tables/source_table_tree.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/tables/source_table_tree.html b/webapp/app/partials/tables/source_table_tree.html
index f2cd7ed..f381077 100755
--- a/webapp/app/partials/tables/source_table_tree.html
+++ b/webapp/app/partials/tables/source_table_tree.html
@@ -37,7 +37,7 @@
         <treecontrol ng-if="tableModel.selectedSrcDb.length > 0" class="tree-light"
                      dirSelection="true"
                      tree-model="tableModel.selectedSrcDb"
-                     options="treeOptions"
+                     options="tableModel.treeOptions"
                      on-selection="showSelected(node)"
                      selected-node="tableModel.selectedSrcTable">
             {{node.name}} {{!!(node.datatype)?'(' + trimType(node.datatype) + ')' : ''}}


[10/47] incubator-kylin git commit: Merge pull request #439 from janzhongi/staging

Posted by li...@apache.org.
Merge pull request #439 from janzhongi/staging

enhance cube wizard & KYLIN-622

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

Branch: refs/heads/master
Commit: 3d3e31280b79be95e49d36fc7021de9f6b3033b5
Parents: 49a4769 21dc31a
Author: Zhong,Jian <ji...@ebay.com>
Authored: Thu Mar 5 20:43:37 2015 +0800
Committer: Zhong,Jian <ji...@ebay.com>
Committed: Thu Mar 5 20:43:37 2015 +0800

----------------------------------------------------------------------
 .../kylin/metadata/model/PartitionDesc.java     |   3 +-
 webapp/app/js/controllers/admin.js              | 431 +++++++++----------
 webapp/app/js/controllers/cubeEdit.js           |  67 ++-
 webapp/app/js/controllers/cubeSchema.js         |  16 +-
 webapp/app/js/controllers/cubes.js              |  55 +--
 webapp/app/js/controllers/page.js               |   2 +-
 .../cubeDesigner/advanced_settings.html         |   2 +-
 .../app/partials/cubeDesigner/incremental.html  |   2 +
 webapp/app/partials/jobs/job_merge.html         |   2 +-
 webapp/app/partials/jobs/job_refresh.html       |   2 +-
 webapp/app/partials/jobs/job_submit.html        | 170 ++++----
 11 files changed, 400 insertions(+), 352 deletions(-)
----------------------------------------------------------------------



[23/47] incubator-kylin git commit: Merge pull request #443 from janzhongi/staging

Posted by li...@apache.org.
Merge pull request #443 from janzhongi/staging

support 'string' and 'date' type column as options for partition column

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

Branch: refs/heads/master
Commit: a9bf9a34c59118f3712cfae8df7bf82e0a6e7814
Parents: 4be14bb f983e6c
Author: Zhong,Jian <ji...@ebay.com>
Authored: Mon Mar 9 17:10:09 2015 +0800
Committer: Zhong,Jian <ji...@ebay.com>
Committed: Mon Mar 9 17:10:09 2015 +0800

----------------------------------------------------------------------
 webapp/app/js/controllers/cubeEdit.js             | 2 +-
 webapp/app/partials/cubeDesigner/incremental.html | 3 ++-
 2 files changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------



[45/47] incubator-kylin git commit: Merge branch 'staging' of https://github.com/KylinOLAP/Kylin into staging

Posted by li...@apache.org.
Merge branch 'staging' of https://github.com/KylinOLAP/Kylin into staging


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

Branch: refs/heads/master
Commit: 2bbaee6c2a665dfd6b02dfde3758890e76a82e5b
Parents: a5821c8 83fc04b
Author: Shao Feng, Shi <sh...@ebay.com>
Authored: Wed Mar 11 11:22:04 2015 +0800
Committer: Shao Feng, Shi <sh...@ebay.com>
Committed: Wed Mar 11 11:22:04 2015 +0800

----------------------------------------------------------------------
 docs/website/download/index.md                  |   2 +-
 .../org/apache/kylin/jdbc/util/SQLTypeMap.java  |   6 +-
 .../kylin/job/execution/AbstractExecutable.java |  10 +-
 server/src/main/resources/kylinSecurity.xml     |   2 +-
 webapp/app/js/controllers/auth.js               |   2 -
 webapp/app/js/controllers/cube.js               |   2 +-
 webapp/app/js/controllers/cubeAdvanceSetting.js |   1 +
 webapp/app/js/controllers/cubeDimensions.js     |   1 -
 webapp/app/js/controllers/cubeModel.js          |  21 +--
 webapp/app/js/filters/filter.js                 |   1 +
 webapp/app/js/listeners.js                      |   7 -
 webapp/app/less/component.less                  |  17 +--
 .../cubeDesigner/advanced_settings.html         | 141 ++++++++++---------
 .../app/partials/cubeDesigner/data_model.html   |  12 +-
 .../app/partials/cubeDesigner/dimensions.html   |   2 +-
 webapp/app/partials/cubes/cube_schema.html      |   2 +-
 16 files changed, 120 insertions(+), 109 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/2bbaee6c/job/src/main/java/org/apache/kylin/job/execution/AbstractExecutable.java
----------------------------------------------------------------------


[13/47] incubator-kylin git commit: update download page

Posted by li...@apache.org.
update download page


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

Branch: refs/heads/master
Commit: fcae14e9a8c9cc6fb0f25ebaedb06af39800d167
Parents: c9147ca
Author: lukehan <lu...@apache.org>
Authored: Fri Mar 6 14:55:01 2015 +0800
Committer: lukehan <lu...@apache.org>
Committed: Fri Mar 6 14:55:01 2015 +0800

----------------------------------------------------------------------
 docs/website/download/index.md | 19 +++++++++++++------
 1 file changed, 13 insertions(+), 6 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/fcae14e9/docs/website/download/index.md
----------------------------------------------------------------------
diff --git a/docs/website/download/index.md b/docs/website/download/index.md
index 1c6b935..da40c6e 100644
--- a/docs/website/download/index.md
+++ b/docs/website/download/index.md
@@ -13,21 +13,28 @@ title: Community
           <div class="row" style="margin-top:-20px;">
             <div class="col-sm-4 col-md-4">
 
-              <p class="big_text">Binary Package</p>
+              <p class="big_text">Binary Package (v0.7.x)</p>
               <p><a href="http://kylin.incubator.apache.org/download/kylin-0.7.1-SNAPSHOT.tgz" target="_blank">v0.7.1-SNAPSHOT</a> 
-              <br/>date - Feb 12, 2015 <br/></p>
+              <br/>Updated Date - March 2, 2015 <br/>							
+							</p>
             </div>
 
             <div class="col-sm-4 col-md-4">
               <p class="big_text">Source Code Repo</p>
-              <p>v0.6.6 (Master branch): <a href="https://github.com/apache/incubator-kylin" target="_blank"> https://github.com/apache/incubator-kylin</a></p>              
-              <p>v0.7.1 (Inverted-Index branch): <a href="https://github.com/apache/incubator-kylin/tree/inverted-index" target="_blank">https://github.com/apache/incubator-kylin/tree/inverted-index</a></p>
+							<p>v0.7.1 (master branch): 
+              <a href="https://github.com/apache/incubator-kylin" target="_blank" >
+                https://github.com/apache/incubator-kylin
+              </a></p>
+              <p>v0.6.6 (v0.6 branch): <a href="https://github.com/apache/incubator-kylin/tree/0.6" target="_blank"> https://github.com/apache/incubator-kylin/tree/0.6</a></p>              
+              
             </div>
 
             <div class="col-sm-4 col-md-4">
-              <p class="big_text">Installation Guide</p>              
+              <p class="big_text">Installation Guide</p> 
+							<p>v0.7.x: <a href="https://github.com/KylinOLAP/Kylin/blob/master/docs/Installation/install_and_run.md" target="_blank">https://github.com/KylinOLAP/Kylin/blob/master/docs/Installation/install_and_run.md</a></p>
+             
               <p>v0.6.x: <a href="https://github.com/KylinOLAP/Kylin/wiki/On-Hadoop-CLI-installation" target="_blank">https://github.com/KylinOLAP/Kylin/wiki/On-Hadoop-CLI-installation</a></p>
-              <p>v0.7.x: <a href="https://github.com/KylinOLAP/Kylin/blob/inverted-index/docs/Installation/install_and_run.md" target="_blank">https://github.com/KylinOLAP/Kylin/blob/inverted-index/docs/Installation/install_and_run.md</a></p>
+              
 
             </div>
           </div>


[31/47] incubator-kylin git commit: Merge branch 'staging' of https://github.com/KylinOLAP/Kylin into staging

Posted by li...@apache.org.
Merge branch 'staging' of https://github.com/KylinOLAP/Kylin into staging


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

Branch: refs/heads/master
Commit: 76e5fd3e7ada79046ee7ee2b844e5dfdbbfbeaf5
Parents: 30991df 2157fe5
Author: lukehan <lu...@apache.org>
Authored: Mon Mar 9 17:25:28 2015 -0700
Committer: lukehan <lu...@apache.org>
Committed: Mon Mar 9 17:25:28 2015 -0700

----------------------------------------------------------------------
 .../org/apache/kylin/cube/model/CubeDesc.java   |  4 -
 .../org/apache/kylin/jdbc/util/SQLTypeMap.java  |  6 +-
 .../kylin/metadata/model/DataModelDesc.java     |  5 ++
 .../kylin/metadata/model/PartitionDesc.java     | 12 +--
 .../metadata/tool/HiveSourceTableLoader.java    | 13 ++-
 webapp/app/js/controllers/cubeEdit.js           | 90 +++++++++++++-------
 webapp/app/js/controllers/cubeModel.js          | 35 ++++++--
 webapp/app/js/controllers/cubeSchema.js         |  7 --
 webapp/app/js/model/jobListModel.js             | 11 ---
 webapp/app/js/model/metaModel.js                |  2 +-
 .../cubeDesigner/advanced_settings.html         |  1 +
 .../app/partials/cubeDesigner/dimensions.html   |  1 -
 .../app/partials/cubeDesigner/incremental.html  | 10 ++-
 13 files changed, 121 insertions(+), 76 deletions(-)
----------------------------------------------------------------------



[17/47] incubator-kylin git commit: Merge pull request #440 from janzhongi/staging

Posted by li...@apache.org.
Merge pull request #440 from janzhongi/staging

enhance aggregation group generate logic,add mandatory removed logic

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

Branch: refs/heads/master
Commit: cfbd6ae29bdac822eec632e6c0eb0930f403ed28
Parents: e6b7e27 38aac2c
Author: Zhong,Jian <ji...@ebay.com>
Authored: Fri Mar 6 18:21:17 2015 +0800
Committer: Zhong,Jian <ji...@ebay.com>
Committed: Fri Mar 6 18:21:17 2015 +0800

----------------------------------------------------------------------
 webapp/app/js/controllers/cubeEdit.js           | 88 +++++++++++++-------
 webapp/app/js/controllers/cubeSchema.js         |  7 --
 webapp/app/js/model/jobListModel.js             | 11 ---
 .../cubeDesigner/advanced_settings.html         |  1 +
 4 files changed, 60 insertions(+), 47 deletions(-)
----------------------------------------------------------------------



[26/47] incubator-kylin git commit: Merge pull request #441 from mustangore/fix-jdbc-wrap-values

Posted by li...@apache.org.
Merge pull request #441 from mustangore/fix-jdbc-wrap-values

[Kylin-626] Fix JDBC driver when returning float or double values

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

Branch: refs/heads/master
Commit: b6a2bd0ba1ef299bb35659725864f36250a10edf
Parents: e6b7e27 64eeed3
Author: liyang-gmt8 <li...@apache.org>
Authored: Mon Mar 9 18:09:17 2015 +0800
Committer: liyang-gmt8 <li...@apache.org>
Committed: Mon Mar 9 18:09:17 2015 +0800

----------------------------------------------------------------------
 jdbc/src/main/java/org/apache/kylin/jdbc/util/SQLTypeMap.java | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
----------------------------------------------------------------------



[16/47] incubator-kylin git commit: enhance aggregation group generate logic, add mandatory removed logic

Posted by li...@apache.org.
enhance aggregation group generate logic,add mandatory removed logic


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

Branch: refs/heads/master
Commit: 38aac2c09360efe5df14c2229eafec15a506133f
Parents: 21dc31a
Author: jiazhong <ji...@ebay.com>
Authored: Fri Mar 6 18:20:21 2015 +0800
Committer: jiazhong <ji...@ebay.com>
Committed: Fri Mar 6 18:20:21 2015 +0800

----------------------------------------------------------------------
 webapp/app/js/controllers/cubeEdit.js           | 88 +++++++++++++-------
 webapp/app/js/controllers/cubeSchema.js         |  7 --
 webapp/app/js/model/jobListModel.js             | 11 ---
 .../cubeDesigner/advanced_settings.html         |  1 +
 4 files changed, 60 insertions(+), 47 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/38aac2c0/webapp/app/js/controllers/cubeEdit.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/cubeEdit.js b/webapp/app/js/controllers/cubeEdit.js
index e903f65..d1fb103 100755
--- a/webapp/app/js/controllers/cubeEdit.js
+++ b/webapp/app/js/controllers/cubeEdit.js
@@ -255,6 +255,17 @@ KylinApp.controller('CubeEditCtrl', function ($scope, $q, $routeParams, $locatio
         }
     }
 
+    $scope.updateMandatory = function(rowkey_column){
+        if(!rowkey_column.mandatory){
+            angular.forEach($scope.cubeMetaFrame.rowkey.aggregation_groups, function (group, index) {
+                   var index = group.indexOf(rowkey_column.column);
+                   if(index>-1){
+                       group.splice(index,1);
+                   }
+            });
+        }
+    }
+
     function reGenerateRowKey(){
         $log.log("reGen rowkey & agg group");
         var tmpRowKeyColumns = [];
@@ -328,6 +339,16 @@ KylinApp.controller('CubeEditCtrl', function ($scope, $q, $routeParams, $locatio
 
         });
 
+
+        //rm mandatory column from aggregation item
+        angular.forEach($scope.cubeMetaFrame.rowkey.rowkey_columns,function(value,index){
+                if(value.mandatory){
+                    tmpAggregationItems = _.filter(tmpAggregationItems,function(item){
+                           return item!=value.column;
+                    });
+                }
+        });
+
         var rowkeyColumns = $scope.cubeMetaFrame.rowkey.rowkey_columns;
         var newRowKeyColumns = sortSharedData(rowkeyColumns,tmpRowKeyColumns);
         var increasedColumns = increasedColumn(rowkeyColumns,tmpRowKeyColumns);
@@ -368,7 +389,10 @@ KylinApp.controller('CubeEditCtrl', function ($scope, $q, $routeParams, $locatio
 
         if($scope.cubeMode==="addNewCube"){
 
-          if(!tmpAggregationItems.length) return;
+          if(!tmpAggregationItems.length) {
+              $scope.cubeMetaFrame.rowkey.aggregation_groups=[];
+              return;
+          }
 
             var newUniqAggregationItem = [];
             angular.forEach(tmpAggregationItems, function (item, index) {
@@ -377,52 +401,58 @@ KylinApp.controller('CubeEditCtrl', function ($scope, $q, $routeParams, $locatio
                 }
             });
 
-          var hierarchyItems = [];
-          for(var m=0;m<hierarchyItemArray.length;m++){
-            for(var n=0;n<hierarchyItemArray[m].length;n++){
-              hierarchyItems.push(hierarchyItemArray[m][n]);
-            }
-          }
+          var hierarchyItems = hierarchyItemArray.join().split(",");
           var unHierarchyItems = increasedData(hierarchyItems,newUniqAggregationItem);
-//            hierarchyItems
+          //hierarchyItems
           var increasedDataGroups = sliceGroupItemToGroups(unHierarchyItems);
+          if(!hierarchyItemArray.length){
+              $scope.cubeMetaFrame.rowkey.aggregation_groups = increasedDataGroups;
+              return;
+          };
+
           var lastAggregationGroup = increasedDataGroups.length===0?[]:increasedDataGroups[increasedDataGroups.length-1];
+
           if(lastAggregationGroup.length<10){
             if(lastAggregationGroup.length+hierarchyItemArray.length<=10){
               lastAggregationGroup = lastAggregationGroup.concat(hierarchyItems);
               if(increasedDataGroups.length==0){
+                //case only hierarchy
                 increasedDataGroups[0]=lastAggregationGroup;
               }else{
                 increasedDataGroups[increasedDataGroups.length-1]=lastAggregationGroup;
               }
             }
             else{
-              var spareLength = 10-lastAggregationGroup.length;
-              var partialHierarchy =lastAggregationGroup.concat(hierarchyItemArray.slice(0,spareLength));
-              //add hierarchy to last group and make sure length less than 10
-              lastAggregationGroup = lastAggregationGroup.concat(partialHierarchy);
-              var spareHierarchy = hierarchyItemArray.slice(spareLength+1,hierarchyItemArray.length-1);
-              if(spareHierarchy.length){
-                lastAggregationGroup.push(spareHierarchy);
-              }
-              increasedDataGroups[increasedDataGroups.length-1]=lastAggregationGroup;
+                var cutIndex = 10-lastAggregationGroup.length;
+                var partialHierarchy =hierarchyItemArray.slice(0,cutIndex).join().split(",");
+                //add hierarchy to last group and make sure length less than 10
+                lastAggregationGroup = lastAggregationGroup.concat(partialHierarchy);
+                increasedDataGroups[increasedDataGroups.length-1]=lastAggregationGroup;
+                var leftHierarchy = hierarchyItemArray.slice(cutIndex);
+
+                var leftHierarchyLength = leftHierarchy.length;
+                var grpLength = parseInt(leftHierarchyLength/10);
+                if(leftHierarchyLength%10==0&&leftHierarchyLength!=0){
+                    grpLength--;
+                }
+                for(var i=0;i<=grpLength;i++){
+                    var hierAggGroupUnit = leftHierarchy.slice(i*10,(i+1)*10).join().split(",");
+                    increasedDataGroups.push(hierAggGroupUnit);
+                }
             }
           }
+          //lastAggregationGroup length >=10
           else{
-            if(hierarchyItemArray.length<=10){
-              increasedDataGroups.push(hierarchyItems);
-            }else{
-              var partialHierarchy =lastAggregationGroup.concat(hierarchyItemArray.slice(0,10));
-              //add hierarchy to last group and make sure length less than 10
-              increasedDataGroups.push(partialHierarchy);
-              var spareHierarchy = hierarchyItemArray.slice(11,hierarchyItemArray.length-1);
-              if(spareHierarchy.length){
-                increasedDataGroups.push(spareHierarchy);
+              var hierrachyArrayLength = hierarchyItemArray.length;
+              var grpLength = parseInt(hierrachyArrayLength/10);
+              if(hierrachyArrayLength%10==0&&hierrachyArrayLength!=0){
+                  grpLength--;
+              }
+              for(var i=0;i<=grpLength;i++){
+                   var hierAggGroupUnit = hierarchyItemArray.slice(i*10,(i+1)*10).join().split(",");
+                   increasedDataGroups.push(hierAggGroupUnit);
               }
-            }
           }
-
-
             //! here get the latest aggregation groups,only effect when add newCube
             $scope.cubeMetaFrame.rowkey.aggregation_groups = increasedDataGroups;
         }

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/38aac2c0/webapp/app/js/controllers/cubeSchema.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/cubeSchema.js b/webapp/app/js/controllers/cubeSchema.js
index b0de094..d883b59 100755
--- a/webapp/app/js/controllers/cubeSchema.js
+++ b/webapp/app/js/controllers/cubeSchema.js
@@ -62,13 +62,6 @@ KylinApp.controller('CubeSchemaCtrl', function ($scope, QueryService, UserServic
             ModelService.get({model_name: $scope.cubeMetaFrame.model_name}, function (model) {
                 if (model) {
                     $scope.metaModel.model = model;
-
-                    //convert GMT mills ,to make sure partition date show GMT Date
-                    //should run only one time
-                    //if($scope.metaModel.model.partition_desc&&$scope.metaModel.model.partition_desc.partition_date_start)
-                    //{
-                    //    $scope.metaModel.model.partition_desc.partition_date_start+=new Date().getTimezoneOffset()*60000;
-                    //}
                 }
             });
 

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/38aac2c0/webapp/app/js/model/jobListModel.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/model/jobListModel.js b/webapp/app/js/model/jobListModel.js
index 166e4e4..764791a 100755
--- a/webapp/app/js/model/jobListModel.js
+++ b/webapp/app/js/model/jobListModel.js
@@ -36,10 +36,6 @@ KylinApp.service('JobList',function(JobService,$q){
                 }
             });
 
-//            $scope.state.loading = false;
-//            if (angular.isDefined($scope.state.selectedJob)) {
-//                $scope.state.selectedJob = $scope.jobs[selectedJob.uuid];
-//            }
             defer.resolve(jobs.length);
         });
 
@@ -47,13 +43,6 @@ KylinApp.service('JobList',function(JobService,$q){
 
     };
 
-//    this.removeCube = function(cube){
-//        var cubeIndex = _this.cubes.indexOf(cube);
-//        if (cubeIndex > -1) {
-//            _this.cubes.splice(cubeIndex, 1);
-//        }
-//    }
-
     this.removeAll = function(){
         _this.jobs=[];
     };

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/38aac2c0/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 e29e6a4..dfa05c6 100755
--- a/webapp/app/partials/cubeDesigner/advanced_settings.html
+++ b/webapp/app/partials/cubeDesigner/advanced_settings.html
@@ -119,6 +119,7 @@
                     <button type="button " ng-if="state.mode=='edit'"
                             class="btn btn-xs btn-default {{rowkey_column.mandatory? 'active':''}}"
                             ng-model="rowkey_column.mandatory"
+                            ng-click="updateMandatory(rowkey_column);"
                             btn-checkbox btn-checkbox-true="true" btn-checkbox-false="false">
                         {{rowkey_column.mandatory? 'Y':'N'}}
                     </button>


[25/47] incubator-kylin git commit: Fix a bug in parsing partition column

Posted by li...@apache.org.
Fix a bug in parsing partition column

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

Branch: refs/heads/master
Commit: 6074fb4e571617919f057053a24e820c57f9de2d
Parents: f020763
Author: Shao Feng, Shi <sh...@ebay.com>
Authored: Mon Mar 9 17:33:37 2015 +0800
Committer: Shao Feng, Shi <sh...@ebay.com>
Committed: Mon Mar 9 17:33:37 2015 +0800

----------------------------------------------------------------------
 .../main/java/org/apache/kylin/cube/model/CubeDesc.java |  4 ----
 .../org/apache/kylin/metadata/model/DataModelDesc.java  |  5 +++++
 .../org/apache/kylin/metadata/model/PartitionDesc.java  | 12 +++++++-----
 3 files changed, 12 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/6074fb4e/cube/src/main/java/org/apache/kylin/cube/model/CubeDesc.java
----------------------------------------------------------------------
diff --git a/cube/src/main/java/org/apache/kylin/cube/model/CubeDesc.java b/cube/src/main/java/org/apache/kylin/cube/model/CubeDesc.java
index 1f7e02a..0c9cf7a 100644
--- a/cube/src/main/java/org/apache/kylin/cube/model/CubeDesc.java
+++ b/cube/src/main/java/org/apache/kylin/cube/model/CubeDesc.java
@@ -449,10 +449,6 @@ public class CubeDesc extends RootPersistentEntity {
 
         initMeasureReferenceToColumnFamily();
 
-        if (null != this.model.getPartitionDesc()) {
-            this.model.getPartitionDesc().init(columnMap);
-        }
-
         // check all dimension columns are presented on rowkey
         List<TblColRef> dimCols = listDimensionColumnsExcludingDerived();
         if (rowkey.getRowKeyColumns().length != dimCols.size()) {

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/6074fb4e/metadata/src/main/java/org/apache/kylin/metadata/model/DataModelDesc.java
----------------------------------------------------------------------
diff --git a/metadata/src/main/java/org/apache/kylin/metadata/model/DataModelDesc.java b/metadata/src/main/java/org/apache/kylin/metadata/model/DataModelDesc.java
index 6d1bc65..c9271fc 100644
--- a/metadata/src/main/java/org/apache/kylin/metadata/model/DataModelDesc.java
+++ b/metadata/src/main/java/org/apache/kylin/metadata/model/DataModelDesc.java
@@ -143,8 +143,13 @@ public class DataModelDesc extends RootPersistentEntity {
 
     public void init(Map<String, TableDesc> tables) {
         initJoinColumns(tables);
+        initPartitionDesc(tables);
     }
 
+    private void initPartitionDesc(Map<String, TableDesc> tables) {
+        if(this.partitionDesc != null)
+            this.partitionDesc.init(tables);
+    }
     private void initJoinColumns(Map<String, TableDesc> tables) {
         // join columns may or may not present in cube;
         // here we don't modify 'allColumns' and 'dimensionColumns';

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/6074fb4e/metadata/src/main/java/org/apache/kylin/metadata/model/PartitionDesc.java
----------------------------------------------------------------------
diff --git a/metadata/src/main/java/org/apache/kylin/metadata/model/PartitionDesc.java b/metadata/src/main/java/org/apache/kylin/metadata/model/PartitionDesc.java
index 3b3fe94..cf0a8e3 100644
--- a/metadata/src/main/java/org/apache/kylin/metadata/model/PartitionDesc.java
+++ b/metadata/src/main/java/org/apache/kylin/metadata/model/PartitionDesc.java
@@ -47,7 +47,7 @@ public class PartitionDesc {
 
     private TblColRef partitionDateColumnRef;
 
-    public void init(Map<String, Map<String, TblColRef>> columnMap) {
+    public void init(Map<String, TableDesc> tables) {
         if (StringUtils.isNotEmpty(partitionDateColumn)) {
             partitionDateColumn = partitionDateColumn.toUpperCase();
 
@@ -55,11 +55,13 @@ public class PartitionDesc {
 
             if (null != columns && columns.length == 3) {
                 String tableName = columns[0].toUpperCase() + "." + columns[1].toUpperCase();
-                Map<String, TblColRef> cols = columnMap.get(tableName);
-                if (cols != null) {
-                    partitionDateColumnRef = cols.get(columns[2].toUpperCase());
+
+                TableDesc table = tables.get(tableName);
+                ColumnDesc col = table.findColumnByName(columns[2]);
+                if (col != null) {
+                    partitionDateColumnRef = new TblColRef(col);
                 } else {
-                    throw new IllegalStateException("The table '" + tableName + "' provided in 'partition_date_column' doesn't exist.");
+                    throw new IllegalStateException("The column '" + partitionDateColumn + "' provided in 'partition_date_column' doesn't exist.");
                 }
             } else {
                 throw new IllegalStateException("The 'partition_date_column' format is invalid: " + partitionDateColumn + ", it should be {db}.{table}.{column}.");


[34/47] incubator-kylin git commit: Merge pull request #444 from vipinkumar7/patch-1

Posted by li...@apache.org.
Merge pull request #444 from vipinkumar7/patch-1

updated kylin.sh

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

Branch: refs/heads/master
Commit: e66e92af5390e43a68956ef7c308d20c83a49ce1
Parents: b6a2bd0 9497073
Author: qianhao.zhou <qi...@ebay.com>
Authored: Tue Mar 10 14:12:58 2015 +0800
Committer: qianhao.zhou <qi...@ebay.com>
Committed: Tue Mar 10 14:12:58 2015 +0800

----------------------------------------------------------------------
 bin/kylin.sh | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------



[02/47] incubator-kylin git commit: Merge pull request #436 from janzhongi/inverted-index

Posted by li...@apache.org.
Merge pull request #436 from janzhongi/inverted-index

refactor loadHiveTable Code to tableModel & KYLIN-373

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

Branch: refs/heads/master
Commit: 2d90b17149fac79368993a90121e72a2c2eb4ce6
Parents: 352b32b 24210b1
Author: Zhong,Jian <ji...@ebay.com>
Authored: Tue Mar 3 18:56:25 2015 +0800
Committer: Zhong,Jian <ji...@ebay.com>
Committed: Tue Mar 3 18:56:25 2015 +0800

----------------------------------------------------------------------
 webapp/app/js/controllers/cubeSchema.js         | 41 ++++++++--
 webapp/app/js/controllers/sourceMeta.js         | 62 +---------------
 webapp/app/js/model/projectModel.js             |  3 +
 webapp/app/js/model/tableModel.js               | 78 +++++++++++++++++++-
 .../app/partials/cubeDesigner/incremental.html  |  8 +-
 webapp/app/partials/cubes/cube_schema.html      |  2 +-
 .../app/partials/tables/source_table_tree.html  |  2 +-
 7 files changed, 122 insertions(+), 74 deletions(-)
----------------------------------------------------------------------



[29/47] incubator-kylin git commit: fix KYLIN-516

Posted by li...@apache.org.
fix KYLIN-516


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

Branch: refs/heads/master
Commit: 8dcc9a63ec1953e22fc7937513fd42b2e90cb2a1
Parents: 4905a59
Author: jiazhong <ji...@ebay.com>
Authored: Mon Mar 9 23:04:28 2015 +0800
Committer: jiazhong <ji...@ebay.com>
Committed: Mon Mar 9 23:04:28 2015 +0800

----------------------------------------------------------------------
 webapp/app/partials/cubes/cube_schema.html | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/8dcc9a63/webapp/app/partials/cubes/cube_schema.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/cubes/cube_schema.html b/webapp/app/partials/cubes/cube_schema.html
index b9359f0..ab9564a 100644
--- a/webapp/app/partials/cubes/cube_schema.html
+++ b/webapp/app/partials/cubes/cube_schema.html
@@ -47,7 +47,7 @@
                         </div>
                     </div>
                     <div class="col-xs-4">
-                        <button class="btn btn-prev" ng-click="preView()" ng-show="curStep.title!='Cube Info'" ng-disabled="design_form.$invalid">
+                        <button class="btn btn-prev" ng-click="preView()" ng-show="curStep.title!='Cube Info'">
                             <i class="ace-icon fa fa-arrow-left"></i>
                             Prev
                         </button>


[38/47] incubator-kylin git commit: fix filter 0 bytes bug , when bytes is 0 show '0 bytes' KYLIN-572

Posted by li...@apache.org.
fix filter 0 bytes bug
, when bytes is 0 show '0 bytes' KYLIN-572


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

Branch: refs/heads/master
Commit: 7dae30ef66b4132b84b4fcc4b635b838af5aaffb
Parents: ec0fb0f
Author: jiazhong <ji...@ebay.com>
Authored: Tue Mar 10 15:25:37 2015 +0800
Committer: jiazhong <ji...@ebay.com>
Committed: Tue Mar 10 15:25:37 2015 +0800

----------------------------------------------------------------------
 webapp/app/js/controllers/cubeAdvanceSetting.js | 1 +
 webapp/app/js/filters/filter.js                 | 1 +
 2 files changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/7dae30ef/webapp/app/js/controllers/cubeAdvanceSetting.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/cubeAdvanceSetting.js b/webapp/app/js/controllers/cubeAdvanceSetting.js
index 4c30905..f1bd991 100644
--- a/webapp/app/js/controllers/cubeAdvanceSetting.js
+++ b/webapp/app/js/controllers/cubeAdvanceSetting.js
@@ -27,6 +27,7 @@ KylinApp.controller('CubeAdvanceSettingCtrl', function ($scope, $modal,cubeConfi
             }
         }
     );
+    //edit model
     if($scope.state.mode==="edit") {
         $scope.metaModel = MetaModel;
     }

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/7dae30ef/webapp/app/js/filters/filter.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/filters/filter.js b/webapp/app/js/filters/filter.js
index f3364c7..555e31d 100755
--- a/webapp/app/js/filters/filter.js
+++ b/webapp/app/js/filters/filter.js
@@ -83,6 +83,7 @@ KylinApp
     // Convert bytes into human readable format.
     .filter('bytes', function() {
         return function(bytes, precision) {
+            if (bytes === 0) { return '0 bytes' };
             if (isNaN(parseFloat(bytes)) || !isFinite(bytes)) {
                 return '-';
             }


[44/47] incubator-kylin git commit: KYLIN-629 Kylin failed to run mapreduce job if there is no mapreduce.application.classpath in mapred-site.xml

Posted by li...@apache.org.
KYLIN-629 Kylin failed to run mapreduce job if there is no mapreduce.application.classpath in mapred-site.xml

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

Branch: refs/heads/master
Commit: a5821c83f8393853dba271522c2c96bd912f0b0e
Parents: 93f1f26
Author: Shao Feng, Shi <sh...@ebay.com>
Authored: Wed Mar 11 11:21:26 2015 +0800
Committer: Shao Feng, Shi <sh...@ebay.com>
Committed: Wed Mar 11 11:21:26 2015 +0800

----------------------------------------------------------------------
 .../kylin/job/hadoop/AbstractHadoopJob.java     | 64 ++++++++++++++------
 1 file changed, 44 insertions(+), 20 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/a5821c83/job/src/main/java/org/apache/kylin/job/hadoop/AbstractHadoopJob.java
----------------------------------------------------------------------
diff --git a/job/src/main/java/org/apache/kylin/job/hadoop/AbstractHadoopJob.java b/job/src/main/java/org/apache/kylin/job/hadoop/AbstractHadoopJob.java
index ff19357..087dd04 100644
--- a/job/src/main/java/org/apache/kylin/job/hadoop/AbstractHadoopJob.java
+++ b/job/src/main/java/org/apache/kylin/job/hadoop/AbstractHadoopJob.java
@@ -23,18 +23,6 @@ package org.apache.kylin.job.hadoop;
  *
  */
 
-import org.apache.kylin.common.KylinConfig;
-import org.apache.kylin.common.persistence.ResourceStore;
-import org.apache.kylin.common.util.StringSplitter;
-import org.apache.kylin.cube.CubeInstance;
-import org.apache.kylin.cube.CubeSegment;
-import org.apache.kylin.invertedindex.IIInstance;
-import org.apache.kylin.invertedindex.IISegment;
-import org.apache.kylin.job.JobInstance;
-import org.apache.kylin.job.exception.JobException;
-import org.apache.kylin.job.tools.OptionsHelper;
-import org.apache.kylin.metadata.MetadataManager;
-import org.apache.kylin.metadata.model.TableDesc;
 import org.apache.commons.cli.Option;
 import org.apache.commons.cli.OptionBuilder;
 import org.apache.commons.cli.Options;
@@ -50,9 +38,22 @@ import org.apache.hadoop.mapreduce.InputSplit;
 import org.apache.hadoop.mapreduce.Job;
 import org.apache.hadoop.mapreduce.lib.input.FileInputFormat;
 import org.apache.hadoop.util.ReflectionUtils;
-import org.apache.hadoop.util.StringUtils;
 import org.apache.hadoop.util.Tool;
 import org.apache.hadoop.util.ToolRunner;
+import org.apache.kylin.common.KylinConfig;
+import org.apache.kylin.common.persistence.ResourceStore;
+import org.apache.kylin.common.util.CliCommandExecutor;
+import org.apache.kylin.common.util.StringSplitter;
+import org.apache.kylin.cube.CubeInstance;
+import org.apache.kylin.cube.CubeSegment;
+import org.apache.kylin.invertedindex.IIInstance;
+import org.apache.kylin.invertedindex.IISegment;
+import org.apache.kylin.job.JobInstance;
+import org.apache.kylin.job.cmd.ShellCmdOutput;
+import org.apache.kylin.job.exception.JobException;
+import org.apache.kylin.job.tools.OptionsHelper;
+import org.apache.kylin.metadata.MetadataManager;
+import org.apache.kylin.metadata.model.TableDesc;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -63,6 +64,8 @@ import java.util.ArrayList;
 import java.util.HashMap;
 import java.util.Map;
 
+import static org.apache.hadoop.util.StringUtils.formatTime;
+
 @SuppressWarnings("static-access")
 public abstract class AbstractHadoopJob extends Configured implements Tool {
     protected static final Logger logger = LoggerFactory.getLogger(AbstractHadoopJob.class);
@@ -121,7 +124,7 @@ public abstract class AbstractHadoopJob extends Configured implements Tool {
         } else {
             job.waitForCompletion(true);
             retVal = job.isSuccessful() ? 0 : 1;
-            logger.debug("Job '" + job.getJobName() + "' finished " + (job.isSuccessful() ? "successfully in " : "with failures.  Time taken ") + StringUtils.formatTime((System.nanoTime() - start) / 1000000L));
+            logger.debug("Job '" + job.getJobName() + "' finished " + (job.isSuccessful() ? "successfully in " : "with failures.  Time taken ") + formatTime((System.nanoTime() - start) / 1000000L));
         }
         return retVal;
     }
@@ -135,7 +138,7 @@ public abstract class AbstractHadoopJob extends Configured implements Tool {
             System.exit(5);
         }
     }
-    
+
     private static final String MAP_REDUCE_CLASSPATH = "mapreduce.application.classpath";
 
     protected void setJobClasspath(Job job) {
@@ -154,16 +157,37 @@ public abstract class AbstractHadoopJob extends Configured implements Tool {
             // yarn classpath is comma separated
             kylinHiveDependency = kylinHiveDependency.replace(":", ",");
             Configuration jobConf = job.getConfiguration();
-            final String classpath = jobConf.get(MAP_REDUCE_CLASSPATH);
-            if (classpath == null) {
-                jobConf.set(MAP_REDUCE_CLASSPATH, kylinHiveDependency);
-            } else {
-                jobConf.set(MAP_REDUCE_CLASSPATH, classpath + "," + kylinHiveDependency);
+            String classpath = jobConf.get(MAP_REDUCE_CLASSPATH);
+            if (classpath == null || classpath.length() == 0) {
+                logger.info("Didn't find " + MAP_REDUCE_CLASSPATH + " in job configuration, will run 'mapred classpath' to get the default value.");
+                classpath = getDefaultMapRedClasspath();
+                logger.info("The default mapred classpath is: " + classpath);
             }
+
+            jobConf.set(MAP_REDUCE_CLASSPATH, classpath + "," + kylinHiveDependency);
+
         }
         logger.info("Hadoop job classpath is: " + job.getConfiguration().get(MAP_REDUCE_CLASSPATH));
     }
 
+
+    private String getDefaultMapRedClasspath() {
+
+        String classpath = "";
+        try {
+            CliCommandExecutor executor = KylinConfig.getInstanceFromEnv().getCliCommandExecutor();
+            ShellCmdOutput output = new ShellCmdOutput();
+            executor.execute("mapred classpath", output);
+
+            classpath = output.getOutput();
+        } catch (IOException e) {
+            logger.error("Failed to run: 'mapred classpath'.", e);
+        }
+
+        return classpath;
+    }
+
+
     public void addInputDirs(String input, Job job) throws IOException {
         for (String inp : StringSplitter.split(input, ",")) {
             inp = inp.trim();


[43/47] incubator-kylin git commit: #KYLIN-627, #KYLIN_628, update binary package with bug fixes

Posted by li...@apache.org.
#KYLIN-627, #KYLIN_628,  update binary package with bug fixes


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

Branch: refs/heads/master
Commit: 83fc04ba4da161b9e33aa6e8df9651f415498d2c
Parents: 59a1d66
Author: lukehan <lu...@apache.org>
Authored: Tue Mar 10 09:51:32 2015 -0700
Committer: lukehan <lu...@apache.org>
Committed: Tue Mar 10 09:51:32 2015 -0700

----------------------------------------------------------------------
 docs/website/download/index.md | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/83fc04ba/docs/website/download/index.md
----------------------------------------------------------------------
diff --git a/docs/website/download/index.md b/docs/website/download/index.md
index 170557f..4fc10c8 100644
--- a/docs/website/download/index.md
+++ b/docs/website/download/index.md
@@ -15,7 +15,7 @@ title: Community
 
               <p class="big_text">Binary Package (v0.7.x)</p>
               <p><a href="http://kylin.incubator.apache.org/download/kylin-0.7.1-SNAPSHOT.tgz" target="_blank">v0.7.1-SNAPSHOT</a> 
-              <br/>Updated Date - March 6, 2015 <br/>							
+              <br/>Updated Date - March 9, 2015 <br/>							
 							</p>
             </div>
 


[21/47] incubator-kylin git commit: support 'string' and 'date' type column as options for partition column

Posted by li...@apache.org.
support 'string' and 'date' type column as options for partition column


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

Branch: refs/heads/master
Commit: f983e6cc0ced65349833eac7053b34411c651a88
Parents: c6adb69
Author: jiazhong <ji...@ebay.com>
Authored: Mon Mar 9 17:09:14 2015 +0800
Committer: jiazhong <ji...@ebay.com>
Committed: Mon Mar 9 17:09:14 2015 +0800

----------------------------------------------------------------------
 webapp/app/js/controllers/cubeEdit.js             | 2 +-
 webapp/app/partials/cubeDesigner/incremental.html | 3 ++-
 2 files changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/f983e6cc/webapp/app/js/controllers/cubeEdit.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/cubeEdit.js b/webapp/app/js/controllers/cubeEdit.js
index d1fb103..356a5b5 100755
--- a/webapp/app/js/controllers/cubeEdit.js
+++ b/webapp/app/js/controllers/cubeEdit.js
@@ -38,7 +38,7 @@ KylinApp.controller('CubeEditCtrl', function ($scope, $q, $routeParams, $locatio
 
     $scope.getPartitonColumns = function(tableName){
         var columns = _.filter($scope.getColumnsByTable(tableName),function(column){
-            return column.datatype==="date";
+            return column.datatype==="date"||column.datatype==="string";
         });
         return columns;
     };

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/f983e6cc/webapp/app/partials/cubeDesigner/incremental.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/cubeDesigner/incremental.html b/webapp/app/partials/cubeDesigner/incremental.html
index 6b21dc3..2d48ee5 100755
--- a/webapp/app/partials/cubeDesigner/incremental.html
+++ b/webapp/app/partials/cubeDesigner/incremental.html
@@ -50,7 +50,7 @@
                             ng-options="metaModel.model.fact_table+'.'+columns.name as metaModel.model.fact_table+'.'+columns.name for columns in getPartitonColumns(metaModel.model.fact_table)" >
                         <option value="">--Select Partition Column--</option>
                     </select>
-                    <p class="text-red"  ng-if="state.mode=='edit'">(Partition column will select 'date' type column from fact table)</p>
+                    <p class="text-red"  ng-if="state.mode=='edit'">(data format in column should be 'YYYY-MM-DD')</p>
                     <span ng-if="state.mode=='view'">
                         {{!!(metaModel.model.partition_desc.partition_date_column)?metaModel.model.partition_desc.partition_date_column: ''}}</span>
                 </div>
@@ -83,6 +83,7 @@
                     <div class="col-xs-12">
                         <ol class="text-info">
                             <li>Not required,leave as default if this cube always need full build</li>
+                            <li>Partition column will select 'date' or 'string' type column from fact table</li>
                             <li>If column selected,please indicate start date to just pull certain data from source</li>
                         </ol>
                     </div>


[33/47] incubator-kylin git commit: updated kylin.sh

Posted by li...@apache.org.
updated kylin.sh 

I was gettiing   out of memory  errors for   joins  with this configuration its working fine at lest for all quries I have tested on a sample cube build on 2 million data .

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

Branch: refs/heads/master
Commit: 9497073618af1e375a094b8b69552fc34ccaecd1
Parents: b6a2bd0
Author: vipin kumar <vi...@gmail.com>
Authored: Tue Mar 10 11:36:30 2015 +0530
Committer: vipin kumar <vi...@gmail.com>
Committed: Tue Mar 10 11:36:30 2015 +0530

----------------------------------------------------------------------
 bin/kylin.sh | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/94970736/bin/kylin.sh
----------------------------------------------------------------------
diff --git a/bin/kylin.sh b/bin/kylin.sh
index 7981bb8..fa500a3 100644
--- a/bin/kylin.sh
+++ b/bin/kylin.sh
@@ -35,8 +35,9 @@ then
 
     export HBASE_CLASSPATH_PREFIX=${tomcat_root}/bin/bootstrap.jar:${tomcat_root}/bin/tomcat-juli.jar:${tomcat_root}/lib/*:$HBASE_CLASSPATH_PREFIX
     export HBASE_CLASSPATH=$hive_dependency:${HBASE_CLASSPATH}
+    export  JAVA_OPTS="-Xms2048M -Xmx2048M"
 
-    hbase -Djava.util.logging.config.file=${tomcat_root}/conf/logging.properties \
+    hbase ${JAVA_OPTS}  -Djava.util.logging.config.file=${tomcat_root}/conf/logging.properties \
     -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager \
     -Dorg.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH=true \
     -Dorg.apache.catalina.connector.CoyoteAdapter.ALLOW_BACKSLASH=true \
@@ -76,4 +77,4 @@ then
 else
     echo "usage: kylin.sh start or kylin.sh stop"
     exit 1
-fi
\ No newline at end of file
+fi


[14/47] incubator-kylin git commit: Merge branch 'staging'

Posted by li...@apache.org.
Merge branch 'staging'


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

Branch: refs/heads/master
Commit: ef27f3a16c7cd01d073ef7e56f6f13eb27588ac3
Parents: a3b4bcc fcae14e
Author: lukehan <lu...@apache.org>
Authored: Fri Mar 6 14:55:31 2015 +0800
Committer: lukehan <lu...@apache.org>
Committed: Fri Mar 6 14:55:31 2015 +0800

----------------------------------------------------------------------
 bin/kylin.sh                                    |  79 ++++
 bin/start-kylin.sh                              |  55 ---
 bin/stop-kylin.sh                               |  21 -
 .../model/validation/rule/RowKeyAttrRule.java   |   4 +-
 docs/website/download/index.md                  |  19 +-
 job/pom.xml                                     |   9 +
 .../kylin/metadata/model/PartitionDesc.java     |   3 +-
 .../kylin/rest/controller/CubeController.java   |   8 +-
 webapp/app/js/controllers/admin.js              | 431 +++++++++----------
 webapp/app/js/controllers/cubeAdvanceSetting.js |   8 +
 webapp/app/js/controllers/cubeEdit.js           |  71 ++-
 webapp/app/js/controllers/cubeSchema.js         |  57 ++-
 webapp/app/js/controllers/cubes.js              |  55 +--
 webapp/app/js/controllers/page.js               |   2 +-
 webapp/app/js/controllers/sourceMeta.js         |  62 +--
 webapp/app/js/model/projectModel.js             |   3 +
 webapp/app/js/model/tableModel.js               |  78 +++-
 .../cubeDesigner/advanced_settings.html         |   6 +-
 .../app/partials/cubeDesigner/incremental.html  |  12 +-
 webapp/app/partials/cubes/cube_schema.html      |   2 +-
 webapp/app/partials/jobs/job_merge.html         |   2 +-
 webapp/app/partials/jobs/job_refresh.html       |   2 +-
 webapp/app/partials/jobs/job_submit.html        | 170 ++++----
 webapp/app/partials/query/query.html            |   4 +-
 webapp/app/partials/query/query_detail.html     |  17 +-
 .../app/partials/tables/source_table_tree.html  |   2 +-
 26 files changed, 652 insertions(+), 530 deletions(-)
----------------------------------------------------------------------



[39/47] incubator-kylin git commit: Merge pull request #446 from janzhongi/staging

Posted by li...@apache.org.
Merge pull request #446 from janzhongi/staging

fix filter 0 bytes bug

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

Branch: refs/heads/master
Commit: 8cca80d570c64c71050fad206492b623e43c9d77
Parents: 65445e8 7dae30e
Author: Zhong,Jian <ji...@ebay.com>
Authored: Tue Mar 10 15:27:18 2015 +0800
Committer: Zhong,Jian <ji...@ebay.com>
Committed: Tue Mar 10 15:27:18 2015 +0800

----------------------------------------------------------------------
 webapp/app/js/controllers/cubeAdvanceSetting.js | 1 +
 webapp/app/js/filters/filter.js                 | 1 +
 2 files changed, 2 insertions(+)
----------------------------------------------------------------------



[28/47] incubator-kylin git commit: fix KYLIN-220

Posted by li...@apache.org.
fix KYLIN-220


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

Branch: refs/heads/master
Commit: 4905a59ef46eec8b32260440ac3f099660e20969
Parents: f983e6c
Author: jiazhong <ji...@ebay.com>
Authored: Mon Mar 9 18:25:39 2015 +0800
Committer: jiazhong <ji...@ebay.com>
Committed: Mon Mar 9 18:25:39 2015 +0800

----------------------------------------------------------------------
 webapp/app/less/component.less                  |   9 +-
 .../cubeDesigner/advanced_settings.html         | 141 ++++++++++---------
 2 files changed, 81 insertions(+), 69 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/4905a59e/webapp/app/less/component.less
----------------------------------------------------------------------
diff --git a/webapp/app/less/component.less b/webapp/app/less/component.less
index 4817d99..c7bd1cf 100644
--- a/webapp/app/less/component.less
+++ b/webapp/app/less/component.less
@@ -835,6 +835,11 @@ span.input-icon {
 #hierarchy .localytics-chosen,#hierarchy .chosen-container {
   width: 100% !important;
 }
-#joinon .localytics-chosen,#joinon .chosen-container {
-  width: 45% !important;
+
+.sort-item {
+    padding: 2px;
+    width: 50px;
+    height: 20px;
+    cursor: move;
+//    border-left: 1px solid #333;
 }
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/4905a59e/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 dfa05c6..164ca05 100755
--- a/webapp/app/partials/cubeDesigner/advanced_settings.html
+++ b/webapp/app/partials/cubeDesigner/advanced_settings.html
@@ -91,73 +91,80 @@
         <h4 style="margin-left:42px">Rowkeys</h4>
         <table style="margin-left:42px; width:92%"
                ng-if="cubeMetaFrame.rowkey.rowkey_columns.length > 0"
-               class="table table-hover list">
-            <tr>
-                <th>ID</th>
-                <th>Column</th>
-                <th>Mandatory</th>
-                <th>Dictionary</th>
-                <th>Length</th>
-                <th ng-if="state.mode=='edit'"></th>
-            </tr>
-
-            <tr ng-repeat="rowkey_column in cubeMetaFrame.rowkey.rowkey_columns">
-                <td>
-                    <!-- ID -->
-                    <b>{{($index + 1)}}</b>
-                </td>
-                <td>
-                    <!--Column Name -->
-                    <input type="text" class="form-control" placeholder="Column Name.." ng-if="state.mode=='edit'"
-                           tooltip="rowkey column name.." tooltip-trigger="focus"
-                           ng-model="rowkey_column.column" class="form-control">
-
-                    <span ng-if="state.mode=='view'">{{rowkey_column.column}}</span>
-                </td>
-                <td>
-                    <!-- Mandatory -->
-                    <button type="button " ng-if="state.mode=='edit'"
-                            class="btn btn-xs btn-default {{rowkey_column.mandatory? 'active':''}}"
-                            ng-model="rowkey_column.mandatory"
-                            ng-click="updateMandatory(rowkey_column);"
-                            btn-checkbox btn-checkbox-true="true" btn-checkbox-false="false">
-                        {{rowkey_column.mandatory? 'Y':'N'}}
-                    </button>
-
-                    <span ng-if="state.mode=='view'">{{rowkey_column.mandatory? 'Y':'N'}}</span>
-                </td>
-
-                <td>
-                    <!--Use Dictionary-->
-                    <div>
-                        <select ng-if="state.mode=='edit'" style="width:80px;"
-                                chosen ng-model="rowkey_column.dictionary"
-                                ng-change="dictionaryUpdated(rowkey_column);"
-                                ng-options="dt as dt for dt in cubeConfig.dictionaries">
-                            <option value=""></option>
-                        </select>
-                        <span ng-if="state.mode=='view'">{{rowkey_column.dictionary}}</span>
-                    </div>
-                </td>
-
-                <td>
-                    <!--Column Length -->
-                    <input type="text" class="form-control" placeholder="Column Length.." ng-if="state.mode=='edit'"
-                           tooltip="rowkey column length.." tooltip-trigger="focus"
-                           ng-disabled="rowkey_column.dictionary=='true'"
-                           ng-model="rowkey_column.length"  class="form-control">
-
-                    <span ng-if="state.mode=='view'">{{rowkey_column.length}}</span>
-                </td>
-
-
-                <td ng-if="state.mode=='edit'">
-                    <button class="btn btn-xs btn-info"
-                            ng-click="removeElement(cubeMetaFrame.rowkey.rowkey_columns, rowkey_column)"><i
-                            class="fa fa-minus"></i>
-                    </button>
-                </td>
-            </tr>
+               class="table table-hover list"
+                >
+           <thead>
+                <tr>
+                    <th>ID</th>
+                    <th>Column</th>
+                    <th>Mandatory</th>
+                    <th>Dictionary</th>
+                    <th>Length</th>
+                    <th ng-if="state.mode=='edit'"></th>
+                </tr>
+           </thead>
+
+            <tbody ui-sortable="state.mode=='edit'" ng-model="cubeMetaFrame.rowkey.rowkey_columns">
+
+                <tr  ng-repeat="rowkey_column in cubeMetaFrame.rowkey.rowkey_columns" ng-class="state.mode=='edit'?'sort-item':''">
+
+                    <td>
+                        <!-- ID -->
+                        <span class="ng-binding" ng-class="state.mode=='edit'?'badge':''">{{($index + 1)}}</span>
+                    </td>
+                    <td>
+                        <!--Column Name -->
+                        <input type="text" class="form-control" placeholder="Column Name.." ng-if="state.mode=='edit'"
+                               tooltip="rowkey column name.." tooltip-trigger="focus"
+                               ng-model="rowkey_column.column" class="form-control">
+
+                        <span ng-if="state.mode=='view'">{{rowkey_column.column}}</span>
+                    </td>
+                    <td>
+                        <!-- Mandatory -->
+                        <button type="button " ng-if="state.mode=='edit'"
+                                class="btn btn-xs btn-default {{rowkey_column.mandatory? 'active':''}}"
+                                ng-model="rowkey_column.mandatory"
+                                ng-click="updateMandatory(rowkey_column);"
+                                btn-checkbox btn-checkbox-true="true" btn-checkbox-false="false">
+                            {{rowkey_column.mandatory? 'Y':'N'}}
+                        </button>
+
+                        <span ng-if="state.mode=='view'">{{rowkey_column.mandatory? 'Y':'N'}}</span>
+                    </td>
+
+                    <td>
+                        <!--Use Dictionary-->
+                        <div>
+                            <select ng-if="state.mode=='edit'" style="width:80px;"
+                                    chosen ng-model="rowkey_column.dictionary"
+                                    ng-change="dictionaryUpdated(rowkey_column);"
+                                    ng-options="dt as dt for dt in cubeConfig.dictionaries">
+                                <option value=""></option>
+                            </select>
+                            <span ng-if="state.mode=='view'">{{rowkey_column.dictionary}}</span>
+                        </div>
+                    </td>
+
+                    <td>
+                        <!--Column Length -->
+                        <input type="text" class="form-control" placeholder="Column Length.." ng-if="state.mode=='edit'"
+                               tooltip="rowkey column length.." tooltip-trigger="focus"
+                               ng-disabled="rowkey_column.dictionary=='true'"
+                               ng-model="rowkey_column.length"  class="form-control">
+
+                        <span ng-if="state.mode=='view'">{{rowkey_column.length}}</span>
+                    </td>
+
+
+                    <td ng-if="state.mode=='edit'">
+                        <button class="btn btn-xs btn-info"
+                                ng-click="removeElement(cubeMetaFrame.rowkey.rowkey_columns, rowkey_column)"><i
+                                class="fa fa-minus"></i>
+                        </button>
+                    </td>
+                </tr>
+            </tbody>
         </table>
 
         <button class="btn btn-sm btn-info" style="margin-left:42px"


[19/47] incubator-kylin git commit: fix KYLIN-524 & add tip for partition column field

Posted by li...@apache.org.
fix KYLIN-524 & add tip for partition column field


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

Branch: refs/heads/master
Commit: c6adb698d6b38d19fc156bb8f0ecff1cf90b88ec
Parents: cfbd6ae
Author: jiazhong <ji...@ebay.com>
Authored: Mon Mar 9 16:26:58 2015 +0800
Committer: jiazhong <ji...@ebay.com>
Committed: Mon Mar 9 16:26:58 2015 +0800

----------------------------------------------------------------------
 webapp/app/js/controllers/cubeModel.js          | 35 ++++++++++++++++----
 webapp/app/js/model/metaModel.js                |  2 +-
 .../app/partials/cubeDesigner/dimensions.html   |  1 -
 .../app/partials/cubeDesigner/incremental.html  |  9 ++---
 4 files changed, 34 insertions(+), 13 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/c6adb698/webapp/app/js/controllers/cubeModel.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/cubeModel.js b/webapp/app/js/controllers/cubeModel.js
index 45425c8..1e5fab0 100644
--- a/webapp/app/js/controllers/cubeModel.js
+++ b/webapp/app/js/controllers/cubeModel.js
@@ -18,11 +18,8 @@
 
 'use strict';
 
-KylinApp.controller('CubeModelCtrl', function ($scope, $modal,cubeConfig,ModelService,MetaModel) {
+KylinApp.controller('CubeModelCtrl', function ($scope, $modal,cubeConfig,ModelService,MetaModel,SweetAlert) {
 
-//    if($scope.state.mode==="edit") {
-//        $scope.metaModel = MetaModel;
-//    }
     $scope.cubeConfig = cubeConfig;
     var DataModel = function () {
         return {
@@ -113,9 +110,33 @@ KylinApp.controller('CubeModelCtrl', function ($scope, $modal,cubeConfig,ModelSe
         $scope.resetParams();
     };
 
-    $scope.removeLookup = function (lookup) {
-        lookupList.splice(lookupList.indexOf(lookup), 1);
-    };
+        $scope.removeLookup = function (lookup) {
+            var dimExist = _.some($scope.cubeMetaFrame.dimensions,function(item,index){
+                return item.table===lookup.table;
+            });
+            if(dimExist) {
+                SweetAlert.swal({
+                    title: '',
+                    text: "Once it's removed, all relative dimensions will be removed. Are you sure to remove the lookup table?",
+                    type: '',
+                    showCancelButton: true,
+                    confirmButtonColor: '#DD6B55',
+                    confirmButtonText: "Yes",
+                    closeOnConfirm: true
+                }, function (isConfirm) {
+                    if (isConfirm) {
+                        for (var i = $scope.cubeMetaFrame.dimensions.length - 1; i >= 0; i--) {
+                            if ($scope.cubeMetaFrame.dimensions[i].table === lookup.table) {
+                                $scope.cubeMetaFrame.dimensions.splice(i, 1);
+                            }
+                        }
+                        lookupList.splice(lookupList.indexOf(lookup), 1);
+                    }
+                });
+            }else{
+                lookupList.splice(lookupList.indexOf(lookup), 1);
+            }
+        };
 
     $scope.resetParams = function () {
         $scope.lookupState.editing = false;

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/c6adb698/webapp/app/js/model/metaModel.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/model/metaModel.js b/webapp/app/js/model/metaModel.js
index 9fd5ed6..a21c83c 100644
--- a/webapp/app/js/model/metaModel.js
+++ b/webapp/app/js/model/metaModel.js
@@ -70,7 +70,7 @@ KylinApp.service('MetaModel',function(){
                 fact_table: '',
                 lookups: [],
                 filter_condition:'',
-                capacity:'',
+                capacity:'MEDIUM',
                 "partition_desc" : {
                     "partition_date_column" : '',
                     "partition_date_start" : 0,

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/c6adb698/webapp/app/partials/cubeDesigner/dimensions.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/cubeDesigner/dimensions.html b/webapp/app/partials/cubeDesigner/dimensions.html
index 21ef2f5..acb351f 100644
--- a/webapp/app/partials/cubeDesigner/dimensions.html
+++ b/webapp/app/partials/cubeDesigner/dimensions.html
@@ -125,7 +125,6 @@
     </div>
 </div>
 
-
 <!-- Edit Dimension Form -->
 <script type="text/ng-template" id="addEditDimension.html">
     <div class="modal-header">

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/c6adb698/webapp/app/partials/cubeDesigner/incremental.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/cubeDesigner/incremental.html b/webapp/app/partials/cubeDesigner/incremental.html
index 6f40371..6b21dc3 100755
--- a/webapp/app/partials/cubeDesigner/incremental.html
+++ b/webapp/app/partials/cubeDesigner/incremental.html
@@ -46,9 +46,11 @@
                             ng-required="metaModel.model.partition_desc.partition_date_start"
                             ng-model="metaModel.model.partition_desc.partition_date_column"
                             ng-if="state.mode=='edit'"
+                            data-placement=""
                             ng-options="metaModel.model.fact_table+'.'+columns.name as metaModel.model.fact_table+'.'+columns.name for columns in getPartitonColumns(metaModel.model.fact_table)" >
-                        <option value=""></option>
+                        <option value="">--Select Partition Column--</option>
                     </select>
+                    <p class="text-red"  ng-if="state.mode=='edit'">(Partition column will select 'date' type column from fact table)</p>
                     <span ng-if="state.mode=='view'">
                         {{!!(metaModel.model.partition_desc.partition_date_column)?metaModel.model.partition_desc.partition_date_column: ''}}</span>
                 </div>
@@ -80,9 +82,8 @@
                 <div class="row">
                     <div class="col-xs-12">
                         <ol class="text-info">
-                            <li>Leave as default if this cube always need full build</li>
-                            <li>Please indicate partition column of Fact Table in Hive</li>
-                            <li>Please indicate start date to just pull certain data from source</li>
+                            <li>Not required,leave as default if this cube always need full build</li>
+                            <li>If column selected,please indicate start date to just pull certain data from source</li>
                         </ol>
                     </div>
                 </div>


[36/47] incubator-kylin git commit: Merge pull request #445 from janzhongi/staging

Posted by li...@apache.org.
Merge pull request #445 from janzhongi/staging

fix UI issues when create&edit cube, KYLIN-220,KYLIN-516,KYLIN-517

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

Branch: refs/heads/master
Commit: 65445e82833120e52f1af6aaaf2fe6464bb4cb3e
Parents: e80ce69 ec0fb0f
Author: Zhong,Jian <ji...@ebay.com>
Authored: Tue Mar 10 14:49:36 2015 +0800
Committer: Zhong,Jian <ji...@ebay.com>
Committed: Tue Mar 10 14:49:36 2015 +0800

----------------------------------------------------------------------
 webapp/app/js/controllers/cubeDimensions.js     |   1 -
 webapp/app/js/controllers/cubeModel.js          |  21 +--
 webapp/app/less/component.less                  |  17 +--
 .../cubeDesigner/advanced_settings.html         | 141 ++++++++++---------
 .../app/partials/cubeDesigner/data_model.html   |  12 +-
 .../app/partials/cubeDesigner/dimensions.html   |   2 +-
 webapp/app/partials/cubes/cube_schema.html      |   2 +-
 7 files changed, 102 insertions(+), 94 deletions(-)
----------------------------------------------------------------------



[40/47] incubator-kylin git commit: config right authorize url Kylin-570

Posted by li...@apache.org.
config right authorize url Kylin-570


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

Branch: refs/heads/master
Commit: 2e981533a024d4b9e5ee7f1d8132ed5ca16b5563
Parents: 7dae30e
Author: jiazhong <ji...@ebay.com>
Authored: Tue Mar 10 17:17:52 2015 +0800
Committer: jiazhong <ji...@ebay.com>
Committed: Tue Mar 10 17:17:52 2015 +0800

----------------------------------------------------------------------
 server/src/main/resources/kylinSecurity.xml | 2 +-
 webapp/app/js/controllers/auth.js           | 2 --
 webapp/app/js/controllers/cube.js           | 2 +-
 webapp/app/js/listeners.js                  | 7 -------
 4 files changed, 2 insertions(+), 11 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/2e981533/server/src/main/resources/kylinSecurity.xml
----------------------------------------------------------------------
diff --git a/server/src/main/resources/kylinSecurity.xml b/server/src/main/resources/kylinSecurity.xml
index af1b83b..518a9bd 100644
--- a/server/src/main/resources/kylinSecurity.xml
+++ b/server/src/main/resources/kylinSecurity.xml
@@ -12,7 +12,7 @@
 	<scr:http auto-config="true" use-expressions="true">
 		<scr:http-basic entry-point-ref="unauthorisedEntryPoint" />
 
-		<scr:intercept-url pattern="/api/user/authenticate*/**" access="permitAll" />
+		<scr:intercept-url pattern="/api/user/authentication*/**" access="permitAll" />
 		<scr:intercept-url pattern="/api/query*/**" access="isAuthenticated()" />
 		<scr:intercept-url pattern="/api/metadata*/**" access="isAuthenticated()" />
 		<scr:intercept-url pattern="/api/**/metrics" access="permitAll" />

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/2e981533/webapp/app/js/controllers/auth.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/auth.js b/webapp/app/js/controllers/auth.js
index 376d1b1..f7fbfea 100644
--- a/webapp/app/js/controllers/auth.js
+++ b/webapp/app/js/controllers/auth.js
@@ -43,7 +43,5 @@ KylinApp.controller('LoginCtrl', function ($scope, $rootScope, $location, $base6
             $scope.loading = false;
             $scope.error = "Unable to login, please check your username/password.";
         });
-
-        console.debug("Login event requested.");
     };
 });

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/2e981533/webapp/app/js/controllers/cube.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/cube.js b/webapp/app/js/controllers/cube.js
index 689496a..607706d 100755
--- a/webapp/app/js/controllers/cube.js
+++ b/webapp/app/js/controllers/cube.js
@@ -18,7 +18,7 @@
 
 'use strict';
 
-KylinApp.controller('CubeCtrl', function ($scope, AccessService, MessageService, CubeService, TableService, CubeGraphService, UserService, AuthenticationService,SweetAlert) {
+KylinApp.controller('CubeCtrl', function ($scope, AccessService, MessageService, CubeService, TableService, CubeGraphService, UserService,SweetAlert) {
     $scope.newAccess = null;
     $scope.state = {jsonEdit: false};
 

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/2e981533/webapp/app/js/listeners.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/listeners.js b/webapp/app/js/listeners.js
index 45f886a..4524696 100644
--- a/webapp/app/js/listeners.js
+++ b/webapp/app/js/listeners.js
@@ -92,11 +92,4 @@ KylinApp.run(function ($rootScope,$http, $location, UserService, AuthenticationS
 
     });
 
-    /**
-     * On 'event:error', resend all the 500 requests.
-     */
-//    $rootScope.$on('event:error', function (event, message) {
-//        var msg = !!(message) ? message : 'Failed to take action.';
-//        SweetAlert.swal('Oops...', 'Action Failed: ' + msg, 'error');
-//    });
 });


[05/47] incubator-kylin git commit: fix KYLIN-621

Posted by li...@apache.org.
fix KYLIN-621


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

Branch: refs/heads/master
Commit: bf1520b08a2497197cabb4975353d2d5a756fc80
Parents: 8227739
Author: qianhao.zhou <qi...@ebay.com>
Authored: Thu Mar 5 10:16:14 2015 +0800
Committer: qianhao.zhou <qi...@ebay.com>
Committed: Thu Mar 5 10:16:14 2015 +0800

----------------------------------------------------------------------
 job/pom.xml | 9 +++++++++
 1 file changed, 9 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/bf1520b0/job/pom.xml
----------------------------------------------------------------------
diff --git a/job/pom.xml b/job/pom.xml
index c8fbc73..1fff5af 100644
--- a/job/pom.xml
+++ b/job/pom.xml
@@ -268,6 +268,15 @@
                 <configuration>
                     <shadedArtifactAttached>true</shadedArtifactAttached>
                     <shadedClassifierName>job</shadedClassifierName>
+                    <filters>
+                        <filter>
+                            <excludes>
+                                <exclude>META-INF/*.SF</exclude>
+                                <exclude>META-INF/*.DSA</exclude>
+                                <exclude>META-INF/*.RSA</exclude>
+                            </excludes>
+                        </filter>
+                    </filters>
                 </configuration>
 
             </plugin>


[22/47] incubator-kylin git commit: KYLIN-627 Hive tables' partition column was not sync into Kylin

Posted by li...@apache.org.
KYLIN-627 Hive tables' partition column was not sync into Kylin

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

Branch: refs/heads/master
Commit: afff4e76a8e7a11549efeac57f845694d9f558a2
Parents: cfbd6ae
Author: Shao Feng, Shi <sh...@ebay.com>
Authored: Mon Mar 9 17:09:16 2015 +0800
Committer: Shao Feng, Shi <sh...@ebay.com>
Committed: Mon Mar 9 17:09:16 2015 +0800

----------------------------------------------------------------------
 .../kylin/metadata/tool/HiveSourceTableLoader.java     | 13 +++++++++----
 1 file changed, 9 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/afff4e76/metadata/src/main/java/org/apache/kylin/metadata/tool/HiveSourceTableLoader.java
----------------------------------------------------------------------
diff --git a/metadata/src/main/java/org/apache/kylin/metadata/tool/HiveSourceTableLoader.java b/metadata/src/main/java/org/apache/kylin/metadata/tool/HiveSourceTableLoader.java
index 00891d9..5297188 100644
--- a/metadata/src/main/java/org/apache/kylin/metadata/tool/HiveSourceTableLoader.java
+++ b/metadata/src/main/java/org/apache/kylin/metadata/tool/HiveSourceTableLoader.java
@@ -81,15 +81,21 @@ public class HiveSourceTableLoader {
         for (String tableName : tables) {
             Table table = null;
             HiveClient hiveClient = new HiveClient();
+            List<FieldSchema> partitionFields = null;
             List<FieldSchema> fields = null;
             try {
                 table = hiveClient.getHiveTable(database, tableName);
+                partitionFields = table.getPartitionKeys();
                 fields = hiveClient.getHiveTableFields(database, tableName);
             } catch (Exception e) {
                 e.printStackTrace();
                 throw new IOException(e);
             }
 
+            if (fields != null && partitionFields != null && partitionFields.size() > 0) {
+                fields.addAll(partitionFields);
+            }
+
             long tableSize = hiveClient.getFileSizeForTable(table);
             long tableFileNum = hiveClient.getFileNumberForTable(table);
             TableDesc tableDesc = metaMgr.getTableDesc(database + "." + tableName);
@@ -113,12 +119,11 @@ public class HiveSourceTableLoader {
             }
             tableDesc.setColumns(columns.toArray(new ColumnDesc[columnNumber]));
 
-            List<FieldSchema> partitionCols = table.getPartitionKeys();
             StringBuffer partitionColumnString = new StringBuffer();
-            for (int i = 0, n = partitionCols.size(); i < n; i++) {
+            for (int i = 0, n = partitionFields.size(); i < n; i++) {
                 if (i > 0)
                     partitionColumnString.append(", ");
-                partitionColumnString.append(partitionCols.get(i).getName().toUpperCase());
+                partitionColumnString.append(partitionFields.get(i).getName().toUpperCase());
             }
 
             Map<String, String> map = metaMgr.getTableDescExd(tableDesc.getIdentity());
@@ -135,7 +140,7 @@ public class HiveSourceTableLoader {
             map.put(MetadataConstants.TABLE_EXD_PC, partitionColumnString.toString());
             map.put(MetadataConstants.TABLE_EXD_TFS, String.valueOf(tableSize));
             map.put(MetadataConstants.TABLE_EXD_TNF, String.valueOf(tableFileNum));
-            map.put(MetadataConstants.TABLE_EXD_PARTITIONED, Boolean.valueOf(partitionCols != null && partitionCols.size()>0).toString());
+            map.put(MetadataConstants.TABLE_EXD_PARTITIONED, Boolean.valueOf(partitionFields != null && partitionFields.size() > 0).toString());
 
             metaMgr.saveSourceTable(tableDesc);
             metaMgr.saveTableExd(tableDesc.getIdentity(), map);


[03/47] incubator-kylin git commit: fix KYLIN-547

Posted by li...@apache.org.
fix KYLIN-547


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

Branch: refs/heads/master
Commit: d83913c09c529f72cd9251fcb1fe8f7594c02ad7
Parents: 2d90b17
Author: jiazhong <ji...@ebay.com>
Authored: Wed Mar 4 20:11:55 2015 +0800
Committer: jiazhong <ji...@ebay.com>
Committed: Wed Mar 4 20:11:55 2015 +0800

----------------------------------------------------------------------
 .../kylin/cube/model/validation/rule/RowKeyAttrRule.java     | 4 ++--
 .../org/apache/kylin/rest/controller/CubeController.java     | 8 ++++----
 webapp/app/js/controllers/cubeAdvanceSetting.js              | 8 ++++++++
 webapp/app/partials/cubeDesigner/advanced_settings.html      | 4 +++-
 webapp/app/partials/cubeDesigner/incremental.html            | 2 +-
 5 files changed, 18 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/d83913c0/cube/src/main/java/org/apache/kylin/cube/model/validation/rule/RowKeyAttrRule.java
----------------------------------------------------------------------
diff --git a/cube/src/main/java/org/apache/kylin/cube/model/validation/rule/RowKeyAttrRule.java b/cube/src/main/java/org/apache/kylin/cube/model/validation/rule/RowKeyAttrRule.java
index 7d769a8..5cd0343 100644
--- a/cube/src/main/java/org/apache/kylin/cube/model/validation/rule/RowKeyAttrRule.java
+++ b/cube/src/main/java/org/apache/kylin/cube/model/validation/rule/RowKeyAttrRule.java
@@ -62,10 +62,10 @@ public class RowKeyAttrRule implements IValidatorRule<CubeDesc> {
 
         for (int i = 0; i < rcd.length; i++) {
             RowKeyColDesc rd = rcd[i];
-            if (rd.getLength() != 0 && !StringUtils.isEmpty(rd.getDictionary())) {
+            if (rd.getLength() != 0 && (!StringUtils.isEmpty(rd.getDictionary())&&!rd.getDictionary().equals("false"))) {
                 context.addResult(ResultLevel.ERROR, "Rowkey column " + rd.getColumn() + " must not have both 'length' and 'dictionary' attribute");
             }
-            if (rd.getLength() == 0 && StringUtils.isEmpty(rd.getDictionary())) {
+            if (rd.getLength() == 0 && (StringUtils.isEmpty(rd.getDictionary())||rd.getDictionary().equals("false"))) {
                 context.addResult(ResultLevel.ERROR, "Rowkey column " + rd.getColumn() + " must not have both 'length' and 'dictionary' empty");
             }
         }

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/d83913c0/server/src/main/java/org/apache/kylin/rest/controller/CubeController.java
----------------------------------------------------------------------
diff --git a/server/src/main/java/org/apache/kylin/rest/controller/CubeController.java b/server/src/main/java/org/apache/kylin/rest/controller/CubeController.java
index be91436..51224b8 100644
--- a/server/src/main/java/org/apache/kylin/rest/controller/CubeController.java
+++ b/server/src/main/java/org/apache/kylin/rest/controller/CubeController.java
@@ -311,7 +311,7 @@ public class CubeController extends BasicController {
         } catch (IOException e) {
             // TODO Auto-generated catch block
             logger.error("Failed to deal with the request:" + e.getLocalizedMessage(), e);
-            throw new InternalErrorException("Failed to deal with the request: " + e.getLocalizedMessage() + e.getMessage());
+            throw new InternalErrorException("Failed to deal with the request: " + e.getLocalizedMessage());
         }
 
         CubeDesc desc = deserializeCubeDesc(cubeRequest);
@@ -372,7 +372,7 @@ public class CubeController extends BasicController {
         } catch (IOException e) {
             // TODO Auto-generated catch block
             logger.error("Failed to deal with the request:" + e.getLocalizedMessage(), e);
-            throw new InternalErrorException("Failed to deal with the request: " + e.getLocalizedMessage() + e.getMessage());
+            throw new InternalErrorException("Failed to deal with the request: " + e.getLocalizedMessage());
         }
 
         //update cube
@@ -398,7 +398,7 @@ public class CubeController extends BasicController {
             throw new ForbiddenException("You don't have right to update this cube.");
         } catch (Exception e) {
             logger.error("Failed to deal with the request:" + e.getLocalizedMessage(), e);
-            throw new InternalErrorException("Failed to deal with the request: " + e.getLocalizedMessage() + e.getMessage());
+            throw new InternalErrorException("Failed to deal with the request: " + e.getLocalizedMessage());
         }
 
         if (desc.getError().isEmpty()) {
@@ -476,7 +476,7 @@ public class CubeController extends BasicController {
     private DataModelDesc deserializeDataModelDesc(CubeRequest cubeRequest) {
         DataModelDesc desc = null;
         try {
-            logger.debug("Saving cube " + cubeRequest.getModelDescData());
+            logger.debug("Saving MODEL " + cubeRequest.getModelDescData());
             desc = JsonUtil.readValue(cubeRequest.getModelDescData(), DataModelDesc.class);
         } catch (JsonParseException e) {
             logger.error("The data model definition is not valid.", e);

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/d83913c0/webapp/app/js/controllers/cubeAdvanceSetting.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/cubeAdvanceSetting.js b/webapp/app/js/controllers/cubeAdvanceSetting.js
index 782e8ba..4c30905 100644
--- a/webapp/app/js/controllers/cubeAdvanceSetting.js
+++ b/webapp/app/js/controllers/cubeAdvanceSetting.js
@@ -30,4 +30,12 @@ KylinApp.controller('CubeAdvanceSettingCtrl', function ($scope, $modal,cubeConfi
     if($scope.state.mode==="edit") {
         $scope.metaModel = MetaModel;
     }
+
+
+    $scope.dictionaryUpdated = function(rowkey_column){
+        if(rowkey_column.dictionary==="true"){
+            rowkey_column.length=0;
+        }
+
+    }
 });

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/d83913c0/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 b0d4f4f..e9b533a 100755
--- a/webapp/app/partials/cubeDesigner/advanced_settings.html
+++ b/webapp/app/partials/cubeDesigner/advanced_settings.html
@@ -131,6 +131,7 @@
                     <div>
                         <select ng-if="state.mode=='edit'" style="width:80px;"
                                 chosen ng-model="rowkey_column.dictionary"
+                                ng-change="dictionaryUpdated(rowkey_column);"
                                 ng-options="dt as dt for dt in cubeConfig.dictionaries">
                             <option value=""></option>
                         </select>
@@ -142,7 +143,8 @@
                     <!--Column Length -->
                     <input type="text" class="form-control" placeholder="Column Length.." ng-if="state.mode=='edit'"
                            tooltip="rowkey column length.." tooltip-trigger="focus"
-                           ng-model="rowkey_column.length" class="form-control">
+                           ng-disabled="rowkey_column.dictionary=='true'"
+                           ng-model="rowkey_column.length"  class="form-control">
 
                     <span ng-if="state.mode=='view'">{{rowkey_column.length}}</span>
                 </td>

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/d83913c0/webapp/app/partials/cubeDesigner/incremental.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/cubeDesigner/incremental.html b/webapp/app/partials/cubeDesigner/incremental.html
index 6ee70b7..b3bf34e 100755
--- a/webapp/app/partials/cubeDesigner/incremental.html
+++ b/webapp/app/partials/cubeDesigner/incremental.html
@@ -88,4 +88,4 @@
         </div>
     </div>
 </div>
-</div>
\ No newline at end of file
+</div>


[32/47] incubator-kylin git commit: add stacktrace to job output when exception occurs

Posted by li...@apache.org.
add stacktrace to job output when exception occurs


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

Branch: refs/heads/master
Commit: e80ce69dba08a9acc69a105cf8f175a873228170
Parents: 2157fe5
Author: qianhao.zhou <qi...@ebay.com>
Authored: Tue Mar 10 11:24:58 2015 +0800
Committer: qianhao.zhou <qi...@ebay.com>
Committed: Tue Mar 10 11:24:58 2015 +0800

----------------------------------------------------------------------
 .../apache/kylin/job/execution/AbstractExecutable.java    | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/e80ce69d/job/src/main/java/org/apache/kylin/job/execution/AbstractExecutable.java
----------------------------------------------------------------------
diff --git a/job/src/main/java/org/apache/kylin/job/execution/AbstractExecutable.java b/job/src/main/java/org/apache/kylin/job/execution/AbstractExecutable.java
index c0c6160..0a230d8 100644
--- a/job/src/main/java/org/apache/kylin/job/execution/AbstractExecutable.java
+++ b/job/src/main/java/org/apache/kylin/job/execution/AbstractExecutable.java
@@ -33,6 +33,8 @@ import org.apache.commons.lang3.tuple.Pair;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
+import java.io.PrintWriter;
+import java.io.StringWriter;
 import java.util.Collections;
 import java.util.List;
 import java.util.Map;
@@ -81,7 +83,13 @@ public abstract class AbstractExecutable implements Executable, Idempotent {
     protected void onExecuteError(Throwable exception, ExecutableContext executableContext) {
         if (!isDiscarded()) {
             executableManager.addJobInfo(getId(), END_TIME, Long.toString(System.currentTimeMillis()));
-            executableManager.updateJobOutput(getId(), ExecutableState.ERROR, null, exception.getLocalizedMessage());
+            String output = null;
+            if (exception != null) {
+                final StringWriter out = new StringWriter();
+                exception.printStackTrace(new PrintWriter(out));
+                output = out.toString();
+            }
+            executableManager.updateJobOutput(getId(), ExecutableState.ERROR, null, output);
         } else {
         }
     }


[18/47] incubator-kylin git commit: [Kylin-626] Fix JDBC driver when returning float or double values

Posted by li...@apache.org.
[Kylin-626] Fix JDBC driver when returning float or double values


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

Branch: refs/heads/master
Commit: 64eeed308a69d8e303696898b609c8d1f18493da
Parents: e6b7e27
Author: Mustangore <mu...@gmail.com>
Authored: Fri Mar 6 14:47:13 2015 +0100
Committer: Mustangore <mu...@gmail.com>
Committed: Fri Mar 6 14:47:13 2015 +0100

----------------------------------------------------------------------
 jdbc/src/main/java/org/apache/kylin/jdbc/util/SQLTypeMap.java | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/64eeed30/jdbc/src/main/java/org/apache/kylin/jdbc/util/SQLTypeMap.java
----------------------------------------------------------------------
diff --git a/jdbc/src/main/java/org/apache/kylin/jdbc/util/SQLTypeMap.java b/jdbc/src/main/java/org/apache/kylin/jdbc/util/SQLTypeMap.java
index 07370d7..ec7df0b 100644
--- a/jdbc/src/main/java/org/apache/kylin/jdbc/util/SQLTypeMap.java
+++ b/jdbc/src/main/java/org/apache/kylin/jdbc/util/SQLTypeMap.java
@@ -160,10 +160,12 @@ public class SQLTypeMap {
         case Types.INTEGER:
             return Integer.parseInt(value);
         case Types.BIGINT:
-        case Types.REAL:
+            return Long.parseLong(value);
         case Types.FLOAT:
+            return Float.parseFloat(value);
+        case Types.REAL:
         case Types.DOUBLE:
-            return Long.parseLong(value);
+            return Double.parseDouble(value);
         case Types.BINARY:
         case Types.VARBINARY:
         case Types.LONGVARBINARY:


[47/47] incubator-kylin git commit: Merge branch 'master' of https://github.com/KylinOLAP/Kylin

Posted by li...@apache.org.
Merge branch 'master' of https://github.com/KylinOLAP/Kylin


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

Branch: refs/heads/master
Commit: 2efaf25dfab25e3e22e33383223241702a3f5300
Parents: 54dc31f e66e92a
Author: lukehan <lu...@apache.org>
Authored: Wed Mar 11 17:41:08 2015 -0700
Committer: lukehan <lu...@apache.org>
Committed: Wed Mar 11 17:41:08 2015 -0700

----------------------------------------------------------------------
 bin/kylin.sh | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------



[07/47] incubator-kylin git commit: fix html tag

Posted by li...@apache.org.
fix html tag


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

Branch: refs/heads/master
Commit: 756410745a4ceb8ee781660ebbeeae6d35d1f7f3
Parents: 7ce63f6
Author: jiazhong <ji...@ebay.com>
Authored: Thu Mar 5 14:47:28 2015 +0800
Committer: jiazhong <ji...@ebay.com>
Committed: Thu Mar 5 14:47:28 2015 +0800

----------------------------------------------------------------------
 webapp/app/partials/query/query.html | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/75641074/webapp/app/partials/query/query.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/query/query.html b/webapp/app/partials/query/query.html
index d559103..25dcf9f 100644
--- a/webapp/app/partials/query/query.html
+++ b/webapp/app/partials/query/query.html
@@ -153,7 +153,7 @@
                     <tr ng-repeat="query in cachedQueries | reverse track by $index"
                         ng-if="$index >= (cachedQueries.curPage-1)*cachedQueries.perPage && $index < cachedQueries.curPage*cachedQueries.perPage">
                         <td>
-                            <span style="color: #808080;line-height: 25px">Queried At: {{query.savedAt}} </span><span ng-if="query.project">in Project: {{query.project}}</span></span>
+                            <span style="color: #808080;line-height: 25px">Queried At: {{query.savedAt}} </span><span ng-if="query.project">in Project: {{query.project}}</span>
 
                             <div class="pull-right">
                                 <button class="btn btn-default btn-xs" ng-click="submitQuery(query.sql, query.project)"><i class="fa fa-refresh"></i>


[46/47] incubator-kylin git commit: Add a log message when a table wasn’t loaded successfully

Posted by li...@apache.org.
Add a log message when a table wasn’t loaded successfully

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

Branch: refs/heads/master
Commit: 54dc31f72af63bc37deb5cd60261f880c8de2b18
Parents: 2bbaee6
Author: Shao Feng, Shi <sh...@ebay.com>
Authored: Wed Mar 11 11:32:07 2015 +0800
Committer: Shao Feng, Shi <sh...@ebay.com>
Committed: Wed Mar 11 11:32:07 2015 +0800

----------------------------------------------------------------------
 .../src/main/java/org/apache/kylin/metadata/MetadataManager.java    | 1 +
 1 file changed, 1 insertion(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/54dc31f7/metadata/src/main/java/org/apache/kylin/metadata/MetadataManager.java
----------------------------------------------------------------------
diff --git a/metadata/src/main/java/org/apache/kylin/metadata/MetadataManager.java b/metadata/src/main/java/org/apache/kylin/metadata/MetadataManager.java
index 97d5d51..aedefd4 100644
--- a/metadata/src/main/java/org/apache/kylin/metadata/MetadataManager.java
+++ b/metadata/src/main/java/org/apache/kylin/metadata/MetadataManager.java
@@ -257,6 +257,7 @@ public class MetadataManager {
         ResourceStore store = getStore();
         TableDesc t = store.getResource(path, TableDesc.class, TABLE_SERIALIZER);
         if (t == null) {
+            logger.error("Didn't load table at " + path);
             return null;
         }
         t.init();


[42/47] incubator-kylin git commit: Merge branch 'staging' of https://github.com/KylinOLAP/Kylin into staging

Posted by li...@apache.org.
Merge branch 'staging' of https://github.com/KylinOLAP/Kylin into staging


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

Branch: refs/heads/master
Commit: 59a1d6658301cdd6d4cbcd52daafdb1480389d3a
Parents: 76e5fd3 5f9e2c9
Author: lukehan <lu...@apache.org>
Authored: Tue Mar 10 09:47:08 2015 -0700
Committer: lukehan <lu...@apache.org>
Committed: Tue Mar 10 09:47:08 2015 -0700

----------------------------------------------------------------------
 .../kylin/job/execution/AbstractExecutable.java |  10 +-
 server/src/main/resources/kylinSecurity.xml     |   2 +-
 webapp/app/js/controllers/auth.js               |   2 -
 webapp/app/js/controllers/cube.js               |   2 +-
 webapp/app/js/controllers/cubeAdvanceSetting.js |   1 +
 webapp/app/js/controllers/cubeDimensions.js     |   1 -
 webapp/app/js/controllers/cubeModel.js          |  21 +--
 webapp/app/js/filters/filter.js                 |   1 +
 webapp/app/js/listeners.js                      |   7 -
 webapp/app/less/component.less                  |  17 +--
 .../cubeDesigner/advanced_settings.html         | 141 ++++++++++---------
 .../app/partials/cubeDesigner/data_model.html   |  12 +-
 .../app/partials/cubeDesigner/dimensions.html   |   2 +-
 webapp/app/partials/cubes/cube_schema.html      |   2 +-
 14 files changed, 115 insertions(+), 106 deletions(-)
----------------------------------------------------------------------



[35/47] incubator-kylin git commit: fix KYLIN-517

Posted by li...@apache.org.
fix KYLIN-517


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

Branch: refs/heads/master
Commit: ec0fb0f80e424cfa6983960f861b6c3e69c06c53
Parents: 8dcc9a6
Author: jiazhong <ji...@ebay.com>
Authored: Tue Mar 10 14:43:52 2015 +0800
Committer: jiazhong <ji...@ebay.com>
Committed: Tue Mar 10 14:43:52 2015 +0800

----------------------------------------------------------------------
 webapp/app/js/controllers/cubeDimensions.js     |  1 -
 webapp/app/js/controllers/cubeModel.js          | 21 +++++++++++---------
 webapp/app/less/component.less                  | 14 +++++--------
 .../app/partials/cubeDesigner/data_model.html   | 12 +++++------
 .../app/partials/cubeDesigner/dimensions.html   |  2 +-
 5 files changed, 23 insertions(+), 27 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/ec0fb0f8/webapp/app/js/controllers/cubeDimensions.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/cubeDimensions.js b/webapp/app/js/controllers/cubeDimensions.js
index e57e05b..f323d1f 100644
--- a/webapp/app/js/controllers/cubeDimensions.js
+++ b/webapp/app/js/controllers/cubeDimensions.js
@@ -395,7 +395,6 @@ KylinApp.controller('CubeDimensionsCtrl', function ($scope, $modal,MetaModel) {
     if ($scope.state.mode == 'edit') {
         $scope.$on('$destroy', function () {
            // $scope.dimensionsAdapter();
-
             // Emit dimensions edit event in order to re-generate row key.
             $scope.$emit('DimensionsEdited');
         });

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/ec0fb0f8/webapp/app/js/controllers/cubeModel.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/cubeModel.js b/webapp/app/js/controllers/cubeModel.js
index 1e5fab0..2874742 100644
--- a/webapp/app/js/controllers/cubeModel.js
+++ b/webapp/app/js/controllers/cubeModel.js
@@ -18,7 +18,7 @@
 
 'use strict';
 
-KylinApp.controller('CubeModelCtrl', function ($scope, $modal,cubeConfig,ModelService,MetaModel,SweetAlert) {
+KylinApp.controller('CubeModelCtrl', function ($scope, $modal,cubeConfig,ModelService,MetaModel,SweetAlert,$log) {
 
     $scope.cubeConfig = cubeConfig;
     var DataModel = function () {
@@ -138,17 +138,20 @@ KylinApp.controller('CubeModelCtrl', function ($scope, $modal,cubeConfig,ModelSe
             }
         };
 
+
+    $scope.addNewJoin = function(){
+        $scope.newLookup.join.primary_key.push("null");
+        $scope.newLookup.join.foreign_key.push("null");
+    };
+
+    $scope.removeJoin = function($index){
+        $scope.newLookup.join.primary_key.splice($index,1);
+        $scope.newLookup.join.foreign_key.splice($index,1);
+    };
+
     $scope.resetParams = function () {
         $scope.lookupState.editing = false;
         $scope.lookupState.editingIndex = -1;
-
         $scope.newLookup = Lookup();
     };
-
-    // This is for legacy compatibility, assign 'fact_table' property. TODO new cube schema change.
-//    $scope.$on('$destroy', function () {
-//        if (!$scope.cubeMetaFrame.fact_table) {
-//            $scope.cubeMetaFrame.fact_table = $scope.cubeMetaFrame.model.fact_table;
-//        }
-//    });
 });

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/ec0fb0f8/webapp/app/less/component.less
----------------------------------------------------------------------
diff --git a/webapp/app/less/component.less b/webapp/app/less/component.less
index c7bd1cf..4caf964 100644
--- a/webapp/app/less/component.less
+++ b/webapp/app/less/component.less
@@ -828,18 +828,14 @@ span.input-icon {
   background-color: #C6C41D;
 }
 
-//style fix chosen bug
-#derived .localytics-chosen,#derived .chosen-container{
-  width:85% !important;
-}
-#hierarchy .localytics-chosen,#hierarchy .chosen-container {
-  width: 100% !important;
-}
-
 .sort-item {
     padding: 2px;
     width: 50px;
     height: 20px;
     cursor: move;
-//    border-left: 1px solid #333;
+}
+
+.cube-dimension .dl-horizontal{
+  margin-top: 0px !important;
+  margin-bottom: 0px !important;
 }
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/ec0fb0f8/webapp/app/partials/cubeDesigner/data_model.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/cubeDesigner/data_model.html b/webapp/app/partials/cubeDesigner/data_model.html
index bdfda69..4aeb1da 100644
--- a/webapp/app/partials/cubeDesigner/data_model.html
+++ b/webapp/app/partials/cubeDesigner/data_model.html
@@ -78,7 +78,7 @@
                 <!-- Join Condition -->
                 <td>
                     <ul class="list-unstyled">
-                        <li ng-repeat="pk in lookup.join.primary_key">
+                        <li ng-repeat="pk in lookup.join.primary_key track by $index">
                             <code>{{lookup.table + '.' + pk}} = {{metaModel.model.fact_table + '.' + lookup.join.foreign_key[$index]}}</code>
                         </li>
                     </ul>
@@ -146,11 +146,9 @@
                                                 ng-options="columns.name as columns.name for columns in getColumnsByTable(metaModel.model.fact_table)" >
                                             <option value=""></option>
                                         </select>
-                                        <button class="pull-right btn btn-xs btn-danger" style="cursor: pointer" tooltip="Delete Join Condition"
-                                                ng-click="newLookup.join.primary_key.length=newLookup.join.primary_key.length-1;
-                                                                removeElement(newLookup.join.primary_key, newLookup.join.primary_key[$index]);
-                                                                removeElement(newLookup.join.foreign_key, newLookup.join.foreign_key[$index]);">
-                                            <i class="fa fa-trash-o"></i>
+                                        <button class="pull-right btn btn-xs btn-danger" style="cursor: pointer" tooltip="Delete"
+                                                ng-click="removeJoin($index);">
+                                            <i class="fa fa-trash-o pointer"></i>
                                         </button>
                                     </div>
                                     <div class="space-4"></div>
@@ -163,7 +161,7 @@
                             <div class="col-sm-3">
                                 <button class="btn btn-xs btn-info"
                                         ng-if="newLookup.join.type"
-                                        ng-click="newLookup.join.primary_key.length=newLookup.join.primary_key.length+1; ">
+                                        ng-click="addNewJoin();">
                                     <i class="fa fa-plus"></i> New Join Condition</button>
                             </div>
                         </div>

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/ec0fb0f8/webapp/app/partials/cubeDesigner/dimensions.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/cubeDesigner/dimensions.html b/webapp/app/partials/cubeDesigner/dimensions.html
index acb351f..dbbc46d 100644
--- a/webapp/app/partials/cubeDesigner/dimensions.html
+++ b/webapp/app/partials/cubeDesigner/dimensions.html
@@ -58,7 +58,7 @@
                 <th ng-if="state.mode=='edit'">Actions</th>
             </tr>
         </thead>
-        <tbody>
+        <tbody class="cube-dimension">
             <tr ng-repeat="dimension in cubeMetaFrame.dimensions | filter:dimState.filter track by $index">
                 <!--ID -->
                 <td>


[37/47] incubator-kylin git commit: Add more logs in hadoop job

Posted by li...@apache.org.
Add more logs in hadoop job

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

Branch: refs/heads/master
Commit: 93f1f26e3e1f07ecd3919517a82c0bb9faadc4a3
Parents: 6074fb4
Author: Shao Feng, Shi <sh...@ebay.com>
Authored: Tue Mar 10 15:21:12 2015 +0800
Committer: Shao Feng, Shi <sh...@ebay.com>
Committed: Tue Mar 10 15:21:12 2015 +0800

----------------------------------------------------------------------
 .../java/org/apache/kylin/job/execution/AbstractExecutable.java     | 1 +
 .../main/java/org/apache/kylin/job/hadoop/AbstractHadoopJob.java    | 1 +
 2 files changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/93f1f26e/job/src/main/java/org/apache/kylin/job/execution/AbstractExecutable.java
----------------------------------------------------------------------
diff --git a/job/src/main/java/org/apache/kylin/job/execution/AbstractExecutable.java b/job/src/main/java/org/apache/kylin/job/execution/AbstractExecutable.java
index c0c6160..4e15709 100644
--- a/job/src/main/java/org/apache/kylin/job/execution/AbstractExecutable.java
+++ b/job/src/main/java/org/apache/kylin/job/execution/AbstractExecutable.java
@@ -98,6 +98,7 @@ public abstract class AbstractExecutable implements Executable, Idempotent {
             onExecuteStart(executableContext);
             result = doWork(executableContext);
         } catch (Throwable e) {
+            logger.error("error running Executable", e);
             onExecuteError(e, executableContext);
             throw new ExecuteException(e);
         }

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/93f1f26e/job/src/main/java/org/apache/kylin/job/hadoop/AbstractHadoopJob.java
----------------------------------------------------------------------
diff --git a/job/src/main/java/org/apache/kylin/job/hadoop/AbstractHadoopJob.java b/job/src/main/java/org/apache/kylin/job/hadoop/AbstractHadoopJob.java
index a8dc687..ff19357 100644
--- a/job/src/main/java/org/apache/kylin/job/hadoop/AbstractHadoopJob.java
+++ b/job/src/main/java/org/apache/kylin/job/hadoop/AbstractHadoopJob.java
@@ -161,6 +161,7 @@ public abstract class AbstractHadoopJob extends Configured implements Tool {
                 jobConf.set(MAP_REDUCE_CLASSPATH, classpath + "," + kylinHiveDependency);
             }
         }
+        logger.info("Hadoop job classpath is: " + job.getConfiguration().get(MAP_REDUCE_CLASSPATH));
     }
 
     public void addInputDirs(String input, Job job) throws IOException {


[27/47] incubator-kylin git commit: Merge branch 'master' into staging

Posted by li...@apache.org.
Merge branch 'master' into staging


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

Branch: refs/heads/master
Commit: 2157fe52a7f2b401c1f3c4742238ee390a996149
Parents: 6074fb4 b6a2bd0
Author: liyang@apache.org <ya...@D-SHC-00801746.corp.ebay.com>
Authored: Mon Mar 9 11:22:43 2015 +0100
Committer: liyang@apache.org <ya...@D-SHC-00801746.corp.ebay.com>
Committed: Mon Mar 9 11:22:43 2015 +0100

----------------------------------------------------------------------
 jdbc/src/main/java/org/apache/kylin/jdbc/util/SQLTypeMap.java | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
----------------------------------------------------------------------



[30/47] incubator-kylin git commit: update download page

Posted by li...@apache.org.
update download page


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

Branch: refs/heads/master
Commit: 30991df514eca1488aeb67c4881fe957f8508a46
Parents: e6b7e27
Author: lukehan <lu...@apache.org>
Authored: Mon Mar 9 17:25:21 2015 -0700
Committer: lukehan <lu...@apache.org>
Committed: Mon Mar 9 17:25:21 2015 -0700

----------------------------------------------------------------------
 docs/website/download/index.md | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/30991df5/docs/website/download/index.md
----------------------------------------------------------------------
diff --git a/docs/website/download/index.md b/docs/website/download/index.md
index da40c6e..170557f 100644
--- a/docs/website/download/index.md
+++ b/docs/website/download/index.md
@@ -15,7 +15,7 @@ title: Community
 
               <p class="big_text">Binary Package (v0.7.x)</p>
               <p><a href="http://kylin.incubator.apache.org/download/kylin-0.7.1-SNAPSHOT.tgz" target="_blank">v0.7.1-SNAPSHOT</a> 
-              <br/>Updated Date - March 2, 2015 <br/>							
+              <br/>Updated Date - March 6, 2015 <br/>							
 							</p>
             </div>
 


[12/47] incubator-kylin git commit: fix script

Posted by li...@apache.org.
fix script


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

Branch: refs/heads/master
Commit: c9147ca40b6ad66e9e7558e887445df36f579cbd
Parents: 4a59d38
Author: qianhao.zhou <qi...@ebay.com>
Authored: Fri Mar 6 14:22:36 2015 +0800
Committer: qianhao.zhou <qi...@ebay.com>
Committed: Fri Mar 6 14:22:36 2015 +0800

----------------------------------------------------------------------
 bin/kylin.sh | 3 +++
 1 file changed, 3 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/c9147ca4/bin/kylin.sh
----------------------------------------------------------------------
diff --git a/bin/kylin.sh b/bin/kylin.sh
index 4efaf9e..7981bb8 100644
--- a/bin/kylin.sh
+++ b/bin/kylin.sh
@@ -54,6 +54,7 @@ then
         echo "Please visit http://<ip>:7070/kylin"
     fi
     echo "You can check the log at ${tomcat_root}/logs/kylin.log"
+    exit 0
 elif [ $1 == "stop" ]
 then
     if [ ! -f "${KYLIN_HOME}/pid" ]
@@ -71,6 +72,8 @@ then
         kill $pid
     fi
     rm ${KYLIN_HOME}/pid
+    exit 0
 else
     echo "usage: kylin.sh start or kylin.sh stop"
+    exit 1
 fi
\ No newline at end of file


[11/47] incubator-kylin git commit: fix script

Posted by li...@apache.org.
fix script


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

Branch: refs/heads/master
Commit: 4a59d38ff67407e38521f6ab7061b10ca2c57df4
Parents: 3d3e312
Author: qianhao.zhou <qi...@ebay.com>
Authored: Fri Mar 6 14:09:08 2015 +0800
Committer: qianhao.zhou <qi...@ebay.com>
Committed: Fri Mar 6 14:09:08 2015 +0800

----------------------------------------------------------------------
 bin/kylin.sh       | 76 +++++++++++++++++++++++++++++++++++++++++++++++++
 bin/start-kylin.sh | 55 -----------------------------------
 bin/stop-kylin.sh  | 21 --------------
 3 files changed, 76 insertions(+), 76 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/4a59d38f/bin/kylin.sh
----------------------------------------------------------------------
diff --git a/bin/kylin.sh b/bin/kylin.sh
new file mode 100644
index 0000000..4efaf9e
--- /dev/null
+++ b/bin/kylin.sh
@@ -0,0 +1,76 @@
+#!/bin/sh
+
+if [ $1 == "start" ]
+then
+    dir=$(dirname ${0})
+    source ${dir}/check-env.sh
+    tomcat_root=${dir}/../tomcat
+    export tomcat_root
+
+    #if [ ! -z "$KYLIN_LD_LIBRARY_PATH" ]
+    #then
+    #    echo "KYLIN_LD_LIBRARY_PATH is set to $KYLIN_LD_LIBRARY_PATH"
+    #else
+    #    exit 1
+    #fi
+
+    #The location of all hadoop/hbase configurations are difficult to get.
+    #Plus, some of the system properties are secretly set in hadoop/hbase shell command.
+    #For example, in hdp 2.2, there is a system property called hdp.version,
+    #which we cannot get until running hbase or hadoop shell command.
+    #
+    #To save all these troubles, we use hbase runjar to start tomcat.
+    #In this way we no longer need to explicitly configure hadoop/hbase related classpath for tomcat,
+    #hbase command will do all the dirty tasks for us:
+
+    #-Djava.library.path=${KYLIN_LD_LIBRARY_PATH} \
+
+
+    useSandbox=`cat ${KYLIN_HOME}/conf/kylin.properties | grep 'kylin.sandbox' | awk -F '=' '{print $2}'`
+    spring_profile="default"
+    if [ "$useSandbox" = "true" ]
+        then spring_profile="sandbox"
+    fi
+    source ${dir}/find-hive-dependency.sh
+
+    export HBASE_CLASSPATH_PREFIX=${tomcat_root}/bin/bootstrap.jar:${tomcat_root}/bin/tomcat-juli.jar:${tomcat_root}/lib/*:$HBASE_CLASSPATH_PREFIX
+    export HBASE_CLASSPATH=$hive_dependency:${HBASE_CLASSPATH}
+
+    hbase -Djava.util.logging.config.file=${tomcat_root}/conf/logging.properties \
+    -Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager \
+    -Dorg.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH=true \
+    -Dorg.apache.catalina.connector.CoyoteAdapter.ALLOW_BACKSLASH=true \
+    -Djava.endorsed.dirs=${tomcat_root}/endorsed  \
+    -Dcatalina.base=${tomcat_root} \
+    -Dcatalina.home=${tomcat_root} \
+    -Djava.io.tmpdir=${tomcat_root}/temp  \
+    -Dkylin.hive.dependency=${hive_dependency} \
+    -Dspring.profiles.active=${spring_profile} \
+    org.apache.hadoop.util.RunJar ${tomcat_root}/bin/bootstrap.jar  org.apache.catalina.startup.Bootstrap start > ${tomcat_root}/logs/kylin.log 2>&1 & echo $! > ${KYLIN_HOME}/pid &
+    echo "A new Kylin instance is started by $USER, stop it using \"stop-kylin.sh\""
+    if [ "$useSandbox" = "true" ]
+        then echo "Please visit http://<your_sandbox_ip>:7070/kylin to play with the cubes! (Useranme: ADMIN, Password: KYLIN)"
+    else
+        echo "Please visit http://<ip>:7070/kylin"
+    fi
+    echo "You can check the log at ${tomcat_root}/logs/kylin.log"
+elif [ $1 == "stop" ]
+then
+    if [ ! -f "${KYLIN_HOME}/pid" ]
+    then
+        echo "kylin is not running, please check"
+        exit 1
+    fi
+    pid=`cat ${KYLIN_HOME}/pid`
+    if [ "$pid" = "" ]
+    then
+        echo "kylin is not running, please check"
+        exit 1
+    else
+        echo "stopping kylin:$pid"
+        kill $pid
+    fi
+    rm ${KYLIN_HOME}/pid
+else
+    echo "usage: kylin.sh start or kylin.sh stop"
+fi
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/4a59d38f/bin/start-kylin.sh
----------------------------------------------------------------------
diff --git a/bin/start-kylin.sh b/bin/start-kylin.sh
deleted file mode 100644
index 70cbb62..0000000
--- a/bin/start-kylin.sh
+++ /dev/null
@@ -1,55 +0,0 @@
-#!/bin/sh
-
-dir=$(dirname ${0})
-source ${dir}/check-env.sh
-
-tomcat_root=${dir}/../tomcat
-export tomcat_root
-
-#if [ ! -z "$KYLIN_LD_LIBRARY_PATH" ]
-#then
-#    echo "KYLIN_LD_LIBRARY_PATH is set to $KYLIN_LD_LIBRARY_PATH"
-#else
-#    exit 1
-#fi
-
-#The location of all hadoop/hbase configurations are difficult to get.
-#Plus, some of the system properties are secretly set in hadoop/hbase shell command.
-#For example, in hdp 2.2, there is a system property called hdp.version,
-#which we cannot get until running hbase or hadoop shell command.
-#
-#To save all these troubles, we use hbase runjar to start tomcat.
-#In this way we no longer need to explicitly configure hadoop/hbase related classpath for tomcat,
-#hbase command will do all the dirty tasks for us:
-
-#-Djava.library.path=${KYLIN_LD_LIBRARY_PATH} \
-
-
-useSandbox=`cat ${KYLIN_HOME}/conf/kylin.properties | grep 'kylin.sandbox' | awk -F '=' '{print $2}'`
-spring_profile="default"
-if [ "$useSandbox" = "true" ]
-    then spring_profile="sandbox"
-fi
-source ${dir}/find-hive-dependency.sh
-
-export HBASE_CLASSPATH_PREFIX=${tomcat_root}/bin/bootstrap.jar:${tomcat_root}/bin/tomcat-juli.jar:${tomcat_root}/lib/*:$HBASE_CLASSPATH_PREFIX
-export HBASE_CLASSPATH=$hive_dependency:${HBASE_CLASSPATH}
-
-hbase -Djava.util.logging.config.file=${tomcat_root}/conf/logging.properties \
--Djava.util.logging.manager=org.apache.juli.ClassLoaderLogManager \
--Dorg.apache.tomcat.util.buf.UDecoder.ALLOW_ENCODED_SLASH=true \
--Dorg.apache.catalina.connector.CoyoteAdapter.ALLOW_BACKSLASH=true \
--Djava.endorsed.dirs=${tomcat_root}/endorsed  \
--Dcatalina.base=${tomcat_root} \
--Dcatalina.home=${tomcat_root} \
--Djava.io.tmpdir=${tomcat_root}/temp  \
--Dkylin.hive.dependency=${hive_dependency} \
--Dspring.profiles.active=${spring_profile} \
-org.apache.hadoop.util.RunJar ${tomcat_root}/bin/bootstrap.jar  org.apache.catalina.startup.Bootstrap start > ${tomcat_root}/logs/kylin.log 2>&1 & echo $! > ${KYLIN_HOME}/pid &
-echo "A new Kylin instance is started by $USER, stop it using \"stop-kylin.sh\""
-if [ "$useSandbox" = "true" ]
-    then echo "Please visit http://<your_sandbox_ip>:7070/kylin to play with the cubes! (Useranme: ADMIN, Password: KYLIN)"
-else
-    echo "Please visit http://<ip>:7070/kylin"
-fi
-echo "You can check the log at ${tomcat_root}/logs/kylin.log"

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/4a59d38f/bin/stop-kylin.sh
----------------------------------------------------------------------
diff --git a/bin/stop-kylin.sh b/bin/stop-kylin.sh
deleted file mode 100644
index dad0a83..0000000
--- a/bin/stop-kylin.sh
+++ /dev/null
@@ -1,21 +0,0 @@
-#!/bin/sh
-
-dir=$(dirname ${0})
-source ${dir}/check-env.sh
-
-if [ ! -f "${KYLIN_HOME}/pid" ]
-then
-    echo "no pid found"
-    exit 1
-fi
-
-pid=`cat ${KYLIN_HOME}/pid`
-if [ "$pid" = "" ]
-then
-    echo "pid is empty"
-    exit 1
-else
-    echo "stopping kylin:$pid"
-    kill $pid
-fi
-rm ${KYLIN_HOME}/pid


[09/47] incubator-kylin git commit: enhance cube wizard & KYLIN-622

Posted by li...@apache.org.
enhance cube wizard & KYLIN-622


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

Branch: refs/heads/master
Commit: 21dc31aa8b1dc27c9b5a78ecd3929ab2e0ff9e0f
Parents: 7564107
Author: jiazhong <ji...@ebay.com>
Authored: Thu Mar 5 20:37:11 2015 +0800
Committer: jiazhong <ji...@ebay.com>
Committed: Thu Mar 5 20:37:11 2015 +0800

----------------------------------------------------------------------
 .../kylin/metadata/model/PartitionDesc.java     |   3 +-
 webapp/app/js/controllers/admin.js              | 431 +++++++++----------
 webapp/app/js/controllers/cubeEdit.js           |  67 ++-
 webapp/app/js/controllers/cubeSchema.js         |  16 +-
 webapp/app/js/controllers/cubes.js              |  55 +--
 webapp/app/js/controllers/page.js               |   2 +-
 .../cubeDesigner/advanced_settings.html         |   2 +-
 .../app/partials/cubeDesigner/incremental.html  |   2 +
 webapp/app/partials/jobs/job_merge.html         |   2 +-
 webapp/app/partials/jobs/job_refresh.html       |   2 +-
 webapp/app/partials/jobs/job_submit.html        | 170 ++++----
 11 files changed, 400 insertions(+), 352 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/21dc31aa/metadata/src/main/java/org/apache/kylin/metadata/model/PartitionDesc.java
----------------------------------------------------------------------
diff --git a/metadata/src/main/java/org/apache/kylin/metadata/model/PartitionDesc.java b/metadata/src/main/java/org/apache/kylin/metadata/model/PartitionDesc.java
index b079734..3b3fe94 100644
--- a/metadata/src/main/java/org/apache/kylin/metadata/model/PartitionDesc.java
+++ b/metadata/src/main/java/org/apache/kylin/metadata/model/PartitionDesc.java
@@ -23,6 +23,7 @@ import java.util.Map;
 import com.fasterxml.jackson.annotation.JsonAutoDetect;
 import com.fasterxml.jackson.annotation.JsonAutoDetect.Visibility;
 import com.fasterxml.jackson.annotation.JsonProperty;
+import org.apache.commons.lang3.StringUtils;
 import org.apache.kylin.common.util.StringSplitter;
 
 /**
@@ -47,7 +48,7 @@ public class PartitionDesc {
     private TblColRef partitionDateColumnRef;
 
     public void init(Map<String, Map<String, TblColRef>> columnMap) {
-        if (null != partitionDateColumn) {
+        if (StringUtils.isNotEmpty(partitionDateColumn)) {
             partitionDateColumn = partitionDateColumn.toUpperCase();
 
             String[] columns = StringSplitter.split(partitionDateColumn, ".");

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/21dc31aa/webapp/app/js/controllers/admin.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/admin.js b/webapp/app/js/controllers/admin.js
index 17ad0b0..a15411a 100644
--- a/webapp/app/js/controllers/admin.js
+++ b/webapp/app/js/controllers/admin.js
@@ -1,216 +1,215 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements.  See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership.  The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License.  You may obtain a copy of the License at
- *
- *     http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
-*/
-
-'use strict';
-
-KylinApp.controller('AdminCtrl', function ($scope,AdminService, CacheService, TableService,loadingRequest, MessageService, $modal,SweetAlert) {
-    $scope.configStr = "";
-    $scope.envStr = "";
-
-    $scope.getEnv = function(){
-        AdminService.env({}, function(env){
-            $scope.envStr = env.env;
-            MessageService.sendMsg('Server environment get successfully', 'success', {});
-//            SweetAlert.swal('Success!', 'Server environment get successfully', 'success');
-        },function(e){
-            if(e.data&& e.data.exception){
-                var message =e.data.exception;
-                var msg = !!(message) ? message : 'Failed to take action.';
-                SweetAlert.swal('Oops...', msg, 'error');
-            }else{
-                SweetAlert.swal('Oops...', "Failed to take action.", 'error');
-            }
-        });
-    }
-
-    $scope.getConfig = function(){
-        AdminService.config({}, function(config){
-            $scope.configStr = config.config;
-            MessageService.sendMsg('Server config get successfully', 'success', {});
-        },function(e){
-            if(e.data&& e.data.exception){
-                var message =e.data.exception;
-                var msg = !!(message) ? message : 'Failed to take action.';
-                SweetAlert.swal('Oops...', msg, 'error');
-            }else{
-                SweetAlert.swal('Oops...', "Failed to take action.", 'error');
-            }
-        });
-    }
-
-    $scope.reloadMeta = function(){
-        SweetAlert.swal({
-            title: '',
-            text: 'Are you sure to reload metadata and clean cache?',
-            type: '',
-            showCancelButton: true,
-            confirmButtonColor: '#DD6B55',
-            confirmButtonText: "Yes",
-            closeOnConfirm: true
-        }, function(isConfirm) {
-            if(isConfirm){
-                CacheService.clean({}, function () {
-                    SweetAlert.swal('Success!', 'Cache reload successfully', 'success');
-                },function(e){
-                    if(e.data&& e.data.exception){
-                        var message =e.data.exception;
-                        var msg = !!(message) ? message : 'Failed to take action.';
-                        SweetAlert.swal('Oops...', msg, 'error');
-                    }else{
-                        SweetAlert.swal('Oops...', "Failed to take action.", 'error');
-                    }
-                });
-            }
-
-        });
-    }
-
-    $scope.calCardinality = function (tableName) {
-        $modal.open({
-            templateUrl: 'calCardinality.html',
-            controller: CardinalityGenCtrl,
-            resolve: {
-                tableName: function () {
-                    return tableName;
-                },
-                scope: function () {
-                    return $scope;
-                }
-            }
-        });
-    }
-
-    $scope.cleanStorage = function(){
-        SweetAlert.swal({
-            title: '',
-            text: 'Are you sure to clean up unused HDFS and HBase space?',
-            type: '',
-            showCancelButton: true,
-            confirmButtonColor: '#DD6B55',
-            confirmButtonText: "Yes",
-            closeOnConfirm: true
-        }, function(isConfirm) {
-            if(isConfirm){
-            AdminService.cleanStorage({}, function () {
-                SweetAlert.swal('Success!', 'Storage cleaned successfully!', 'success');
-            },function(e){
-                if(e.data&& e.data.exception){
-                    var message =e.data.exception;
-                    var msg = !!(message) ? message : 'Failed to take action.';
-                    SweetAlert.swal('Oops...', msg, 'error');
-                }else{
-                    SweetAlert.swal('Oops...', "Failed to take action.", 'error');
-                }
-            });
-            }
-        });
-    }
-
-    $scope.disableCache = function(){
-        SweetAlert.swal({
-            title: '',
-            text: 'Are you sure to disable query cache?',
-            type: '',
-            showCancelButton: true,
-            confirmButtonColor: '#DD6B55',
-            confirmButtonText: "Yes",
-            closeOnConfirm: true
-        }, function(isConfirm) {
-            if(isConfirm){
-            AdminService.updateConfig({}, {key: 'kylin.query.cache.enabled',value:false}, function () {
-                SweetAlert.swal('Success!', 'Cache disabled successfully!', 'success');
-            },function(e){
-                if(e.data&& e.data.exception){
-                    var message =e.data.exception;
-                    var msg = !!(message) ? message : 'Failed to take action.';
-                    SweetAlert.swal('Oops...', msg, 'error');
-                }else{
-                    SweetAlert.swal('Oops...', "Failed to take action.", 'error');
-                }
-            });
-            }
-
-        });
-
-    }
-
-    $scope.toSetConfig = function(){
-        $modal.open({
-            templateUrl: 'updateConfig.html',
-            controller: updateConfigCtrl,
-            resolve: {
-            }
-        });
-    }
-
-    var CardinalityGenCtrl = function ($scope, $modalInstance, tableName, MessageService) {
-        $scope.tableName = tableName;
-        $scope.delimiter = 0;
-        $scope.format = 0;
-        $scope.cancel = function () {
-            $modalInstance.dismiss('cancel');
-        };
-        $scope.calculate = function () {
-            $modalInstance.dismiss();
-            loadingRequest.show();
-            TableService.genCardinality({tableName: $scope.tableName}, {delimiter: $scope.delimiter, format: $scope.format}, function (result) {
-                loadingRequest.hide();
-                SweetAlert.swal('Success!', 'Cardinality job was calculated successfully. . Click Refresh button ...', 'success');
-            },function(e){
-                loadingRequest.hide();
-                console.log(e);
-                if(e.data&& e.data.exception){
-                    var message =e.data.exception;
-                    var msg = !!(message) ? message : 'Failed to take action.';
-                    SweetAlert.swal('Oops...', msg, 'error');
-                }else{
-                    SweetAlert.swal('Oops...', "Failed to take action.", 'error');
-                }
-            });
-        }
-    };
-
-    var updateConfigCtrl = function ($scope, $modalInstance, AdminService, MessageService) {
-        $scope.state = {
-            key:null,
-            value:null
-        };
-        $scope.cancel = function () {
-            $modalInstance.dismiss('cancel');
-        };
-        $scope.update = function () {
-
-
-                AdminService.updateConfig({}, {key: $scope.state.key, value: $scope.state.value}, function (result) {
-                    SweetAlert.swal('Success!', 'Config updated successfully!', 'success');
-                    $modalInstance.dismiss();
-                },function(e){
-                    if(e.data&& e.data.exception){
-                        var message =e.data.exception;
-                        var msg = !!(message) ? message : 'Failed to take action.';
-                        SweetAlert.swal('Oops...', msg, 'error');
-                    }else{
-                        SweetAlert.swal('Oops...', "Failed to take action.", 'error');
-                    }
-                });
-                }
-    };
-
-    $scope.getEnv();
-    $scope.getConfig();
-});
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+*/
+
+'use strict';
+
+KylinApp.controller('AdminCtrl', function ($scope,AdminService, CacheService, TableService,loadingRequest, MessageService, $modal,SweetAlert) {
+    $scope.configStr = "";
+    $scope.envStr = "";
+
+    $scope.getEnv = function(){
+        AdminService.env({}, function(env){
+            $scope.envStr = env.env;
+            MessageService.sendMsg('Server environment get successfully', 'success', {});
+//            SweetAlert.swal('Success!', 'Server environment get successfully', 'success');
+        },function(e){
+            if(e.data&& e.data.exception){
+                var message =e.data.exception;
+                var msg = !!(message) ? message : 'Failed to take action.';
+                SweetAlert.swal('Oops...', msg, 'error');
+            }else{
+                SweetAlert.swal('Oops...', "Failed to take action.", 'error');
+            }
+        });
+    }
+
+    $scope.getConfig = function(){
+        AdminService.config({}, function(config){
+            $scope.configStr = config.config;
+            MessageService.sendMsg('Server config get successfully', 'success', {});
+        },function(e){
+            if(e.data&& e.data.exception){
+                var message =e.data.exception;
+                var msg = !!(message) ? message : 'Failed to take action.';
+                SweetAlert.swal('Oops...', msg, 'error');
+            }else{
+                SweetAlert.swal('Oops...', "Failed to take action.", 'error');
+            }
+        });
+    }
+
+    $scope.reloadMeta = function(){
+        SweetAlert.swal({
+            title: '',
+            text: 'Are you sure to reload metadata and clean cache?',
+            type: '',
+            showCancelButton: true,
+            confirmButtonColor: '#DD6B55',
+            confirmButtonText: "Yes",
+            closeOnConfirm: true
+        }, function(isConfirm) {
+            if(isConfirm){
+                CacheService.clean({}, function () {
+                    SweetAlert.swal('Success!', 'Cache reload successfully', 'success');
+                },function(e){
+                    if(e.data&& e.data.exception){
+                        var message =e.data.exception;
+                        var msg = !!(message) ? message : 'Failed to take action.';
+                        SweetAlert.swal('Oops...', msg, 'error');
+                    }else{
+                        SweetAlert.swal('Oops...', "Failed to take action.", 'error');
+                    }
+                });
+            }
+
+        });
+    }
+
+    $scope.calCardinality = function (tableName) {
+        $modal.open({
+            templateUrl: 'calCardinality.html',
+            controller: CardinalityGenCtrl,
+            resolve: {
+                tableName: function () {
+                    return tableName;
+                },
+                scope: function () {
+                    return $scope;
+                }
+            }
+        });
+    }
+
+    $scope.cleanStorage = function(){
+        SweetAlert.swal({
+            title: '',
+            text: 'Are you sure to clean up unused HDFS and HBase space?',
+            type: '',
+            showCancelButton: true,
+            confirmButtonColor: '#DD6B55',
+            confirmButtonText: "Yes",
+            closeOnConfirm: true
+        }, function(isConfirm) {
+            if(isConfirm){
+            AdminService.cleanStorage({}, function () {
+                SweetAlert.swal('Success!', 'Storage cleaned successfully!', 'success');
+            },function(e){
+                if(e.data&& e.data.exception){
+                    var message =e.data.exception;
+                    var msg = !!(message) ? message : 'Failed to take action.';
+                    SweetAlert.swal('Oops...', msg, 'error');
+                }else{
+                    SweetAlert.swal('Oops...', "Failed to take action.", 'error');
+                }
+            });
+            }
+        });
+    }
+
+    $scope.disableCache = function(){
+        SweetAlert.swal({
+            title: '',
+            text: 'Are you sure to disable query cache?',
+            type: '',
+            showCancelButton: true,
+            confirmButtonColor: '#DD6B55',
+            confirmButtonText: "Yes",
+            closeOnConfirm: true
+        }, function(isConfirm) {
+            if(isConfirm){
+            AdminService.updateConfig({}, {key: 'kylin.query.cache.enabled',value:false}, function () {
+                SweetAlert.swal('Success!', 'Cache disabled successfully!', 'success');
+            },function(e){
+                if(e.data&& e.data.exception){
+                    var message =e.data.exception;
+                    var msg = !!(message) ? message : 'Failed to take action.';
+                    SweetAlert.swal('Oops...', msg, 'error');
+                }else{
+                    SweetAlert.swal('Oops...', "Failed to take action.", 'error');
+                }
+            });
+            }
+
+        });
+
+    }
+
+    $scope.toSetConfig = function(){
+        $modal.open({
+            templateUrl: 'updateConfig.html',
+            controller: updateConfigCtrl,
+            resolve: {
+            }
+        });
+    }
+
+    var CardinalityGenCtrl = function ($scope, $modalInstance, tableName, MessageService) {
+        $scope.tableName = tableName;
+        $scope.delimiter = 0;
+        $scope.format = 0;
+        $scope.cancel = function () {
+            $modalInstance.dismiss('cancel');
+        };
+        $scope.calculate = function () {
+            $modalInstance.dismiss();
+            loadingRequest.show();
+            TableService.genCardinality({tableName: $scope.tableName}, {delimiter: $scope.delimiter, format: $scope.format}, function (result) {
+                loadingRequest.hide();
+                SweetAlert.swal('Success!', 'Cardinality job was calculated successfully. . Click Refresh button ...', 'success');
+            },function(e){
+                loadingRequest.hide();
+                if(e.data&& e.data.exception){
+                    var message =e.data.exception;
+                    var msg = !!(message) ? message : 'Failed to take action.';
+                    SweetAlert.swal('Oops...', msg, 'error');
+                }else{
+                    SweetAlert.swal('Oops...', "Failed to take action.", 'error');
+                }
+            });
+        }
+    };
+
+    var updateConfigCtrl = function ($scope, $modalInstance, AdminService, MessageService) {
+        $scope.state = {
+            key:null,
+            value:null
+        };
+        $scope.cancel = function () {
+            $modalInstance.dismiss('cancel');
+        };
+        $scope.update = function () {
+
+
+                AdminService.updateConfig({}, {key: $scope.state.key, value: $scope.state.value}, function (result) {
+                    SweetAlert.swal('Success!', 'Config updated successfully!', 'success');
+                    $modalInstance.dismiss();
+                },function(e){
+                    if(e.data&& e.data.exception){
+                        var message =e.data.exception;
+                        var msg = !!(message) ? message : 'Failed to take action.';
+                        SweetAlert.swal('Oops...', msg, 'error');
+                    }else{
+                        SweetAlert.swal('Oops...', "Failed to take action.", 'error');
+                    }
+                });
+                }
+    };
+
+    $scope.getEnv();
+    $scope.getConfig();
+});

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/21dc31aa/webapp/app/js/controllers/cubeEdit.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/cubeEdit.js b/webapp/app/js/controllers/cubeEdit.js
index 35df8a3..e903f65 100755
--- a/webapp/app/js/controllers/cubeEdit.js
+++ b/webapp/app/js/controllers/cubeEdit.js
@@ -95,7 +95,6 @@ KylinApp.controller('CubeEditCtrl', function ($scope, $q, $routeParams, $locatio
                         //should run only one time
                         if(model.partition_desc&&model.partition_desc.partition_date_start)
                         {
-                            //$scope.metaModel.partition_desc.partition_date_start+=new Date().getTimezoneOffset()*60000;
                             MetaModel.converDateToGMT();
                         }
                     }
@@ -259,10 +258,11 @@ KylinApp.controller('CubeEditCtrl', function ($scope, $q, $routeParams, $locatio
     function reGenerateRowKey(){
         $log.log("reGen rowkey & agg group");
         var tmpRowKeyColumns = [];
-        var tmpAggregationItems = [];
-        var hierarchyItems = [];
+        var tmpAggregationItems = [];//put all aggregation item
+        var hierarchyItemArray = [];//put all hierarchy items
         angular.forEach($scope.cubeMetaFrame.dimensions, function (dimension, index) {
 
+           //derived column
             if(dimension.derived&&dimension.derived.length){
                 var lookup = _.find($scope.metaModel.model.lookups,function(lookup){return lookup.table==dimension.table});
                 angular.forEach(lookup.join.foreign_key, function (fk, index) {
@@ -284,7 +284,8 @@ KylinApp.controller('CubeEditCtrl', function ($scope, $q, $routeParams, $locatio
                 })
 
             }
-            else if (dimension.column&&dimension.column.length==1) {
+            //normal column
+            else if (dimension.column&&!dimension.hierarchy&&dimension.column.length==1) {
                 for (var i = 0; i < tmpRowKeyColumns.length; i++) {
                     if(tmpRowKeyColumns[i].column == dimension.column[0])
                         break;
@@ -299,7 +300,9 @@ KylinApp.controller('CubeEditCtrl', function ($scope, $q, $routeParams, $locatio
                     tmpAggregationItems.push(dimension.column[0]);
                 }
             }
+            // hierarchy
             if(dimension.hierarchy && dimension.column.length){
+                var hierarchyUnit = [];
                 angular.forEach(dimension.column, function (hier_column, index) {
                     for (var i = 0; i < tmpRowKeyColumns.length; i++) {
                         if(tmpRowKeyColumns[i].column == hier_column)
@@ -314,10 +317,13 @@ KylinApp.controller('CubeEditCtrl', function ($scope, $q, $routeParams, $locatio
                         });
                         tmpAggregationItems.push(hier_column);
                     }
-                    if(hierarchyItems.indexOf(hier_column)==-1){
-                        hierarchyItems.push(hier_column);
+                    if(hierarchyUnit.indexOf(hier_column)==-1){
+                      hierarchyUnit.push(hier_column);
                     }
                 });
+              if(hierarchyUnit.length){
+                hierarchyItemArray.push(hierarchyUnit);
+              }
             }
 
         });
@@ -362,6 +368,8 @@ KylinApp.controller('CubeEditCtrl', function ($scope, $q, $routeParams, $locatio
 
         if($scope.cubeMode==="addNewCube"){
 
+          if(!tmpAggregationItems.length) return;
+
             var newUniqAggregationItem = [];
             angular.forEach(tmpAggregationItems, function (item, index) {
                 if(newUniqAggregationItem.indexOf(item)==-1){
@@ -369,12 +377,51 @@ KylinApp.controller('CubeEditCtrl', function ($scope, $q, $routeParams, $locatio
                 }
             });
 
-            var unHierarchyItems = increasedData(hierarchyItems,newUniqAggregationItem);
+          var hierarchyItems = [];
+          for(var m=0;m<hierarchyItemArray.length;m++){
+            for(var n=0;n<hierarchyItemArray[m].length;n++){
+              hierarchyItems.push(hierarchyItemArray[m][n]);
+            }
+          }
+          var unHierarchyItems = increasedData(hierarchyItems,newUniqAggregationItem);
 //            hierarchyItems
-            var increasedDataGroups = sliceGroupItemToGroups(unHierarchyItems);
-            if(hierarchyItems.length){
-                increasedDataGroups.push(hierarchyItems);
+          var increasedDataGroups = sliceGroupItemToGroups(unHierarchyItems);
+          var lastAggregationGroup = increasedDataGroups.length===0?[]:increasedDataGroups[increasedDataGroups.length-1];
+          if(lastAggregationGroup.length<10){
+            if(lastAggregationGroup.length+hierarchyItemArray.length<=10){
+              lastAggregationGroup = lastAggregationGroup.concat(hierarchyItems);
+              if(increasedDataGroups.length==0){
+                increasedDataGroups[0]=lastAggregationGroup;
+              }else{
+                increasedDataGroups[increasedDataGroups.length-1]=lastAggregationGroup;
+              }
+            }
+            else{
+              var spareLength = 10-lastAggregationGroup.length;
+              var partialHierarchy =lastAggregationGroup.concat(hierarchyItemArray.slice(0,spareLength));
+              //add hierarchy to last group and make sure length less than 10
+              lastAggregationGroup = lastAggregationGroup.concat(partialHierarchy);
+              var spareHierarchy = hierarchyItemArray.slice(spareLength+1,hierarchyItemArray.length-1);
+              if(spareHierarchy.length){
+                lastAggregationGroup.push(spareHierarchy);
+              }
+              increasedDataGroups[increasedDataGroups.length-1]=lastAggregationGroup;
             }
+          }
+          else{
+            if(hierarchyItemArray.length<=10){
+              increasedDataGroups.push(hierarchyItems);
+            }else{
+              var partialHierarchy =lastAggregationGroup.concat(hierarchyItemArray.slice(0,10));
+              //add hierarchy to last group and make sure length less than 10
+              increasedDataGroups.push(partialHierarchy);
+              var spareHierarchy = hierarchyItemArray.slice(11,hierarchyItemArray.length-1);
+              if(spareHierarchy.length){
+                increasedDataGroups.push(spareHierarchy);
+              }
+            }
+          }
+
 
             //! here get the latest aggregation groups,only effect when add newCube
             $scope.cubeMetaFrame.rowkey.aggregation_groups = increasedDataGroups;

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/21dc31aa/webapp/app/js/controllers/cubeSchema.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/cubeSchema.js b/webapp/app/js/controllers/cubeSchema.js
index 9654ac7..b0de094 100755
--- a/webapp/app/js/controllers/cubeSchema.js
+++ b/webapp/app/js/controllers/cubeSchema.js
@@ -61,22 +61,14 @@ KylinApp.controller('CubeSchemaCtrl', function ($scope, QueryService, UserServic
             //init model
             ModelService.get({model_name: $scope.cubeMetaFrame.model_name}, function (model) {
                 if (model) {
-//                    $scope.metaModel = MetaModel;
-
                     $scope.metaModel.model = model;
 
-                    // add model ref for cube
-                    angular.forEach(CubeList.cubes,function(cube){
-                        if(cube.name===$scope.cubeMetaFrame.name||cube.descriptor===$scope.cubeMetaFrame.name){
-                          cube.model = model;
-                        }
-                    });
                     //convert GMT mills ,to make sure partition date show GMT Date
                     //should run only one time
-                    if($scope.metaModel.model.partition_desc&&$scope.metaModel.model.partition_desc.partition_date_start)
-                    {
-                        $scope.metaModel.model.partition_desc.partition_date_start+=new Date().getTimezoneOffset()*60000;
-                    }
+                    //if($scope.metaModel.model.partition_desc&&$scope.metaModel.model.partition_desc.partition_date_start)
+                    //{
+                    //    $scope.metaModel.model.partition_desc.partition_date_start+=new Date().getTimezoneOffset()*60000;
+                    //}
                 }
             });
 

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/21dc31aa/webapp/app/js/controllers/cubes.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/cubes.js b/webapp/app/js/controllers/cubes.js
index 35266a4..df86816 100755
--- a/webapp/app/js/controllers/cubes.js
+++ b/webapp/app/js/controllers/cubes.js
@@ -83,7 +83,11 @@ KylinApp
                 CubeDescService.get({cube_name: cube.name}, {}, function (detail) {
                     if (detail.length > 0&&detail[0].hasOwnProperty("name")) {
                         cube.detail = detail[0];
-                        defer.resolve(cube.detail);
+                        ModelService.get({model_name: cube.detail.model_name}, function (model) {
+                          cube.model = model
+                          defer.resolve(cube.detail);
+                       });
+
                     }else{
                         SweetAlert.swal('Oops...', "No cube detail info loaded.", 'error');
                     }
@@ -326,43 +330,46 @@ KylinApp
         };
 
         $scope.startRefresh = function (cube) {
-            $scope.loadDetail(cube);
-
-            $modal.open({
-                templateUrl: 'jobRefresh.html',
-                controller: jobSubmitCtrl,
-                resolve: {
-                    cube: function () {
-                        return cube;
-                    },
-                    buildType: function () {
-                        return 'BUILD';
-                    }
-                }
+            $scope.loadDetail(cube).then(function(){
+              $modal.open({
+                  templateUrl: 'jobRefresh.html',
+                  controller: jobSubmitCtrl,
+                  resolve: {
+                      cube: function () {
+                          return cube;
+                      },
+                      buildType: function () {
+                          return 'BUILD';
+                      }
+                  }
+              });
             });
+
         };
 
         $scope.startMerge = function (cube) {
-            $scope.loadDetail(cube);
-
-            $modal.open({
+            $scope.loadDetail(cube).then(function(){
+              $modal.open({
                 templateUrl: 'jobMerge.html',
                 controller: jobSubmitCtrl,
                 resolve: {
-                    cube: function () {
-                        return cube;
-                    },
-                    buildType: function () {
-                        return 'MERGE';
-                    }
+                  cube: function () {
+                    return cube;
+                  },
+                  buildType: function () {
+                    return 'MERGE';
+                  }
                 }
+              });
             });
         }
     });
 
 var jobSubmitCtrl = function ($scope, $modalInstance, CubeService, MessageService, $location, cube,MetaModel, buildType,SweetAlert,loadingRequest) {
     $scope.cube = cube;
-    $scope.metaModel = MetaModel;
+    $scope.metaModel={
+      model:cube.model
+    }
     $scope.jobBuildRequest = {
         buildType: buildType,
         startTime: 0,

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/21dc31aa/webapp/app/js/controllers/page.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/page.js b/webapp/app/js/controllers/page.js
index a382b97..6cc2762 100644
--- a/webapp/app/js/controllers/page.js
+++ b/webapp/app/js/controllers/page.js
@@ -180,7 +180,7 @@ KylinApp.controller('PageCtrl', function ($scope, $q, AccessService,$modal, $loc
 
     $scope.$watch('projectModel.selectedProject', function (newValue, oldValue) {
         if(newValue!=oldValue){
-            $log.log("project updated in page controller,from:"+oldValue+" To:"+newValue);
+            //$log.log("project updated in page controller,from:"+oldValue+" To:"+newValue);
             $cookieStore.put("project",$scope.projectModel.selectedProject);
         }
 

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/21dc31aa/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 e9b533a..e29e6a4 100755
--- a/webapp/app/partials/cubeDesigner/advanced_settings.html
+++ b/webapp/app/partials/cubeDesigner/advanced_settings.html
@@ -163,4 +163,4 @@
                 ng-click="addNewRowkeyColumn()" ng-show="state.mode=='edit'">New Rowkey Column<i class="fa fa-plus"></i></button>
     </div>
 </div>
-</div>
\ No newline at end of file
+</div>

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/21dc31aa/webapp/app/partials/cubeDesigner/incremental.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/cubeDesigner/incremental.html b/webapp/app/partials/cubeDesigner/incremental.html
index b3bf34e..6f40371 100755
--- a/webapp/app/partials/cubeDesigner/incremental.html
+++ b/webapp/app/partials/cubeDesigner/incremental.html
@@ -60,9 +60,11 @@
             <div class="row">
                 <label class="control-label col-xs-12 col-sm-3 no-padding-right font-color-default"><b>Start Date</b></label>
                 <div class="col-xs-12 col-sm-6">
+                  <!--edit model will convert in MetaModel.converDateToGMT-->
                     <input type="text" class="form-control" datepicker-popup="yyyy-MM-dd"
                            ng-model="metaModel.model.partition_desc.partition_date_start" ng-if="state.mode=='edit'"
                            placeholder="Click to choose start date..." is-open="opened" />
+                  <!--vier model will convert use filter-->
                     <span ng-if="state.mode=='view'&&metaModel.model.partition_desc.partition_date_column">{{(metaModel.model.partition_desc.partition_date_start)|reverseToGMT0 }}</span>
                 </div>
             </div>

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/21dc31aa/webapp/app/partials/jobs/job_merge.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/jobs/job_merge.html b/webapp/app/partials/jobs/job_merge.html
index 123c702..c55b280 100644
--- a/webapp/app/partials/jobs/job_merge.html
+++ b/webapp/app/partials/jobs/job_merge.html
@@ -129,4 +129,4 @@
             Submit
         </button>
     </div>
-</script>
\ No newline at end of file
+</script>

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/21dc31aa/webapp/app/partials/jobs/job_refresh.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/jobs/job_refresh.html b/webapp/app/partials/jobs/job_refresh.html
index 9b70ea8..89705e0 100644
--- a/webapp/app/partials/jobs/job_refresh.html
+++ b/webapp/app/partials/jobs/job_refresh.html
@@ -96,4 +96,4 @@
                 ng-disabled="!(jobBuildRequest.startTime >= 0 && jobBuildRequest.endTime > 0)">Submit
         </button>
     </div>
-</script>
\ No newline at end of file
+</script>

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/21dc31aa/webapp/app/partials/jobs/job_submit.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/jobs/job_submit.html b/webapp/app/partials/jobs/job_submit.html
index b3f917b..1036dee 100644
--- a/webapp/app/partials/jobs/job_submit.html
+++ b/webapp/app/partials/jobs/job_submit.html
@@ -1,85 +1,85 @@
-<!--
-* Licensed to the Apache Software Foundation (ASF) under one
-* or more contributor license agreements.  See the NOTICE file
-* distributed with this work for additional information
-* regarding copyright ownership.  The ASF licenses this file
-* to you under the Apache License, Version 2.0 (the
-* "License"); you may not use this file except in compliance
-* with the License.  You may obtain a copy of the License at
-*
-*     http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an "AS IS" BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
--->
-
-<script type="text/ng-template" id="jobSubmit.html">
-    <div class="modal-header">
-        <h4 tooltip="submit">CUBE BUILD CONFIRM</h4>
-    </div>
-    <div class="modal-body" style="background-color: white">
-        <div ng-if="metaModel.model.partition_desc.partition_date_column" class="row">
-            <div class="col-md-2"></div>
-            <div class="col-md-8">
-                <div class="row">
-                    <table class="table table-striped list"
-                           ng-if="(cube.segments | filter: {status: 'NEW'}).length == 0">
-                        <tbody>
-                        <tr>
-                            <td>PARTITION DATE COLUMN</td>
-                            <td>{{metaModel.model.partition_desc.partition_date_column}}</td>
-                        </tr>
-                        <tr>
-                            <td>Start Date (Include)</td>
-                            <td>
-                                <!--no need convert UTC again-->
-                                <div ng-if="cube.segments.length == 0">
-                                    {{jobBuildRequest.startTime =
-                                    (!!metaModel.model.partition_desc.partition_date_start)?metaModel.model.partition_desc.partition_date_start:0
-                                    | reverseToGMT0 }}
-                                </div>
-                                <div ng-if="cube.segments.length > 0">
-                                    <!--no need to convert-->
-                                    <div ng-if="metaModel.model.partition_desc.partition_type=='APPEND'">
-                                        {{ jobBuildRequest.startTime = cube.segments[cube.segments.length-1].date_range_end| reverseToGMT0 }}
-                                    </div>
-                                    <!--<div ng-if="metaModel.model.partition_desc.cube_partition_type=='UPDATE_INSERT'">-->
-                                        <!--&lt;!&ndash;<datepicker ng-model="jobBuildRequest.startTime" show-weeks="true"&ndash;&gt;-->
-                                                    <!--&lt;!&ndash;required class="well well-sm"></datepicker>&ndash;&gt;-->
-                                        <!--<input type="text" datepicker-popup="yyyy-MM-dd" class="input-sm" style="width: 98%"-->
-                                               <!--ng-model="jobBuildRequest.startTime"-->
-                                               <!--placeholder="Click to choose START date..." is-open="opened" />-->
-                                    <!--</div>-->
-                                </div>
-                            </td>
-                        </tr>
-                        <tr>
-                            <td>End Date (Exclude)</td>
-                            <td>
-                                <input type="text" datepicker-popup="yyyy-MM-dd" class="input-sm" style="width: 98%"
-                                       ng-model="jobBuildRequest.endTime"
-                                       placeholder="Click to choose END date..." is-open="opened" />
-                            </td>
-                        </tr>
-                        </tbody>
-                    </table>
-
-                    <div ng-if="(cube.segments|filter: {status: 'NEW'}).length > 0">
-                        <span class="text-warning">There exists a build request of this cube, the job may be running or error. If you need a new build, please wait for its complete or discard it.</span>
-                    </div>
-                </div>
-                <div ng-if="message">
-                    <span class="text-warning">{{message}}</span>
-                </div>
-            </div>
-            <div class="col-md-2"></div>
-        </div>
-    </div>
-    <div class="modal-footer">
-        <button class="btn btn-success" ng-click="updateDate();rebuild(true)" ng-disabled="jobBuildRequest.endTime<=0">Submit</button>
-        <button class="btn btn-primary" ng-click="cancel()">Close</button>
-    </div>
-</script>
\ No newline at end of file
+<!--
+* Licensed to the Apache Software Foundation (ASF) under one
+* or more contributor license agreements.  See the NOTICE file
+* distributed with this work for additional information
+* regarding copyright ownership.  The ASF licenses this file
+* to you under the Apache License, Version 2.0 (the
+* "License"); you may not use this file except in compliance
+* with the License.  You may obtain a copy of the License at
+*
+*     http://www.apache.org/licenses/LICENSE-2.0
+*
+* Unless required by applicable law or agreed to in writing, software
+* distributed under the License is distributed on an "AS IS" BASIS,
+* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+* See the License for the specific language governing permissions and
+* limitations under the License.
+-->
+
+<script type="text/ng-template" id="jobSubmit.html">
+    <div class="modal-header">
+        <h4 tooltip="submit">CUBE BUILD CONFIRM</h4>
+    </div>
+    <div class="modal-body" style="background-color: white">
+        <div ng-if="metaModel.model.partition_desc.partition_date_column" class="row">
+            <div class="col-md-2"></div>
+            <div class="col-md-8">
+                <div class="row">
+                    <table class="table table-striped list"
+                           ng-if="(cube.segments | filter: {status: 'NEW'}).length == 0">
+                        <tbody>
+                        <tr>
+                            <td>PARTITION DATE COLUMN</td>
+                            <td>{{metaModel.model.partition_desc.partition_date_column}}</td>
+                        </tr>
+                        <tr>
+                            <td>Start Date (Include)</td>
+                            <td>
+                                <!--no need convert UTC again-->
+                                <div ng-if="cube.segments.length == 0">
+                                    {{jobBuildRequest.startTime =
+                                    (!!metaModel.model.partition_desc.partition_date_start)?metaModel.model.partition_desc.partition_date_start:0
+                                    | reverseToGMT0 }}
+                                </div>
+                                <div ng-if="cube.segments.length > 0">
+                                    <!--no need to convert-->
+                                    <div ng-if="metaModel.model.partition_desc.partition_type=='APPEND'">
+                                        {{ jobBuildRequest.startTime = cube.segments[cube.segments.length-1].date_range_end| reverseToGMT0 }}
+                                    </div>
+                                    <!--<div ng-if="metaModel.model.partition_desc.cube_partition_type=='UPDATE_INSERT'">-->
+                                        <!--&lt;!&ndash;<datepicker ng-model="jobBuildRequest.startTime" show-weeks="true"&ndash;&gt;-->
+                                                    <!--&lt;!&ndash;required class="well well-sm"></datepicker>&ndash;&gt;-->
+                                        <!--<input type="text" datepicker-popup="yyyy-MM-dd" class="input-sm" style="width: 98%"-->
+                                               <!--ng-model="jobBuildRequest.startTime"-->
+                                               <!--placeholder="Click to choose START date..." is-open="opened" />-->
+                                    <!--</div>-->
+                                </div>
+                            </td>
+                        </tr>
+                        <tr>
+                            <td>End Date (Exclude)</td>
+                            <td>
+                                <input type="text" datepicker-popup="yyyy-MM-dd" class="input-sm" style="width: 98%"
+                                       ng-model="jobBuildRequest.endTime"
+                                       placeholder="Click to choose END date..." is-open="opened" />
+                            </td>
+                        </tr>
+                        </tbody>
+                    </table>
+
+                    <div ng-if="(cube.segments|filter: {status: 'NEW'}).length > 0">
+                        <span class="text-warning">There exists a build request of this cube, the job may be running or error. If you need a new build, please wait for its complete or discard it.</span>
+                    </div>
+                </div>
+                <div ng-if="message">
+                    <span class="text-warning">{{message}}</span>
+                </div>
+            </div>
+            <div class="col-md-2"></div>
+        </div>
+    </div>
+    <div class="modal-footer">
+        <button class="btn btn-success" ng-click="updateDate();rebuild(true)" ng-disabled="jobBuildRequest.endTime<=0">Submit</button>
+        <button class="btn btn-primary" ng-click="cancel()">Close</button>
+    </div>
+</script>


[08/47] incubator-kylin git commit: Merge pull request #438 from janzhongi/staging

Posted by li...@apache.org.
Merge pull request #438 from janzhongi/staging

enhance query page

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

Branch: refs/heads/master
Commit: 49a4769a9f05f9270bd6c25655d60227953d8568
Parents: bf1520b 7564107
Author: Zhong,Jian <ji...@ebay.com>
Authored: Thu Mar 5 14:48:10 2015 +0800
Committer: Zhong,Jian <ji...@ebay.com>
Committed: Thu Mar 5 14:48:10 2015 +0800

----------------------------------------------------------------------
 webapp/app/js/controllers/cubeEdit.js       |  4 ----
 webapp/app/partials/query/query.html        |  4 ++--
 webapp/app/partials/query/query_detail.html | 17 +++++++++--------
 3 files changed, 11 insertions(+), 14 deletions(-)
----------------------------------------------------------------------



[06/47] incubator-kylin git commit: enhance query result page

Posted by li...@apache.org.
enhance query result page


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

Branch: refs/heads/master
Commit: 7ce63f6534d014a94d480e1b2c31bd8c9ecbc16c
Parents: d83913c
Author: jiazhong <ji...@ebay.com>
Authored: Thu Mar 5 14:44:35 2015 +0800
Committer: jiazhong <ji...@ebay.com>
Committed: Thu Mar 5 14:44:35 2015 +0800

----------------------------------------------------------------------
 webapp/app/js/controllers/cubeEdit.js       |  4 ----
 webapp/app/partials/query/query.html        |  4 ++--
 webapp/app/partials/query/query_detail.html | 17 +++++++++--------
 3 files changed, 11 insertions(+), 14 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/7ce63f65/webapp/app/js/controllers/cubeEdit.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/cubeEdit.js b/webapp/app/js/controllers/cubeEdit.js
index 21a666e..35df8a3 100755
--- a/webapp/app/js/controllers/cubeEdit.js
+++ b/webapp/app/js/controllers/cubeEdit.js
@@ -87,7 +87,6 @@ KylinApp.controller('CubeEditCtrl', function ($scope, $q, $routeParams, $locatio
                 $scope.cubeMetaFrame = detail[0];
                 ModelService.get({model_name: $scope.cubeMetaFrame.model_name}, function (model) {
                     if (model) {
-//                        $scope.metaModel = model;
                         MetaModel.setMetaModel(model);
                         $scope.metaModel = MetaModel;
 
@@ -105,9 +104,6 @@ KylinApp.controller('CubeEditCtrl', function ($scope, $q, $routeParams, $locatio
             }
         });
 
-        //
-        //            $scope.metaModel = null;
-
     } else {
         $scope.cubeMetaFrame = CubeDescModel.createNew();
         MetaModel.initModel();

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/7ce63f65/webapp/app/partials/query/query.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/query/query.html b/webapp/app/partials/query/query.html
index 15fed72..d559103 100644
--- a/webapp/app/partials/query/query.html
+++ b/webapp/app/partials/query/query.html
@@ -96,7 +96,7 @@
                         <td>
                             <div>
                                 <label>SQL Name:</label>&nbsp;&nbsp;&nbsp;<b style="font-size: 14px">{{query.name}}</b>
-                                <span style="color: #808080;line-height: 25px" class="pull-right">Saved At: {{query.createdDate}}</span>
+                                <!--<span style="color: #808080;line-height: 25px" class="pull-right">Saved At: {{query.createdDate}}</span>-->
                             </div>
                             <div ng-if="query.project">
                                 <label>Project: </label>
@@ -153,7 +153,7 @@
                     <tr ng-repeat="query in cachedQueries | reverse track by $index"
                         ng-if="$index >= (cachedQueries.curPage-1)*cachedQueries.perPage && $index < cachedQueries.curPage*cachedQueries.perPage">
                         <td>
-                            <span style="color: #808080;line-height: 25px">Queried At: {{query.savedAt | utcToConfigTimeZone}} <span ng-if="query.project">in Project: {{query.project}}</span></span>
+                            <span style="color: #808080;line-height: 25px">Queried At: {{query.savedAt}} </span><span ng-if="query.project">in Project: {{query.project}}</span></span>
 
                             <div class="pull-right">
                                 <button class="btn btn-default btn-xs" ng-click="submitQuery(query.sql, query.project)"><i class="fa fa-refresh"></i>

http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/7ce63f65/webapp/app/partials/query/query_detail.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/query/query_detail.html b/webapp/app/partials/query/query_detail.html
index 2cf8eb9..a4c11bf 100644
--- a/webapp/app/partials/query/query_detail.html
+++ b/webapp/app/partials/query/query_detail.html
@@ -18,12 +18,7 @@
 
 <div class="query-content" ng-controller="QueryResultCtrl" ng-if="curQuery">
 <div>
-<div ng-if="curQuery.result.partial" class="text-info">
-    Note: Current results are partial, please click 'Show All' button to get all results.
-    <button class="btn btn-default btn-xs" ng-click="reset(curQuery);curQuery.acceptPartial=false;query(curQuery)">
-        Show All
-    </button>
-</div>
+
 <div class="pull-right">
                         <span style="color: #808080">
                             <span>Start Time: {{curQuery.startTime | utcToConfigTimeZone}}</span>&nbsp;&nbsp;
@@ -79,7 +74,13 @@
      style="{{ui.fullScreen ? 'padding: 40px 40px 0px 40px':''}}">
     <label>Results <span style="vertical-align:middle;color: grey;font-size: 15px"
                          ng-if="curQuery.status=='success'">(<strong>{{curQuery.result.results.length}})</strong></span></label>
-
+    <span  ng-if="curQuery.result.partial" class="text-warning">
+       !Note: Current results are partial, please click 'Show All' button to get all results.
+      <button class="btn btn-success btn-xs" ng-click="reset(curQuery);curQuery.acceptPartial=false;query(curQuery)">
+        <i class="fa fa-download"></i>
+        Show All
+      </button>
+      </span>
     <div class="pull-right" ng-if="curQuery.status=='success'">
         <button class="btn btn-default btn-xs"
                 ng-click="curQuery.graph.show=!curQuery.graph.show;buildGraphMetadata(curQuery);resetGraph(curQuery);refreshGraphData(curQuery)">
@@ -269,4 +270,4 @@
         <button class="btn btn-primary" ng-click="saveQuery(curQuery)" ng-disabled="save_query_form.$invalid">Save
         </button>
     </div>
-</script>
\ No newline at end of file
+</script>


[04/47] incubator-kylin git commit: Merge pull request #437 from janzhongi/staging

Posted by li...@apache.org.
Merge pull request #437 from janzhongi/staging

fix KYLIN-547

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

Branch: refs/heads/master
Commit: 82277391cb0a0ec391448f732220389258261fab
Parents: 2d90b17 d83913c
Author: Zhong,Jian <ji...@ebay.com>
Authored: Wed Mar 4 20:19:25 2015 +0800
Committer: Zhong,Jian <ji...@ebay.com>
Committed: Wed Mar 4 20:19:25 2015 +0800

----------------------------------------------------------------------
 .../kylin/cube/model/validation/rule/RowKeyAttrRule.java     | 4 ++--
 .../org/apache/kylin/rest/controller/CubeController.java     | 8 ++++----
 webapp/app/js/controllers/cubeAdvanceSetting.js              | 8 ++++++++
 webapp/app/partials/cubeDesigner/advanced_settings.html      | 4 +++-
 webapp/app/partials/cubeDesigner/incremental.html            | 2 +-
 5 files changed, 18 insertions(+), 8 deletions(-)
----------------------------------------------------------------------



[41/47] incubator-kylin git commit: Merge pull request #447 from janzhongi/staging

Posted by li...@apache.org.
Merge pull request #447 from janzhongi/staging

config right authorize url Kylin-570

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

Branch: refs/heads/master
Commit: 5f9e2c9eb49a00331297658bfb50f02dfeb4fb46
Parents: 8cca80d 2e98153
Author: Zhong,Jian <ji...@ebay.com>
Authored: Tue Mar 10 17:18:54 2015 +0800
Committer: Zhong,Jian <ji...@ebay.com>
Committed: Tue Mar 10 17:18:54 2015 +0800

----------------------------------------------------------------------
 server/src/main/resources/kylinSecurity.xml | 2 +-
 webapp/app/js/controllers/auth.js           | 2 --
 webapp/app/js/controllers/cube.js           | 2 +-
 webapp/app/js/listeners.js                  | 7 -------
 4 files changed, 2 insertions(+), 11 deletions(-)
----------------------------------------------------------------------



[24/47] incubator-kylin git commit: Merge branch 'staging' of https://github.com/KylinOLAP/Kylin into staging

Posted by li...@apache.org.
Merge branch 'staging' of https://github.com/KylinOLAP/Kylin into staging


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

Branch: refs/heads/master
Commit: f020763477b14c86aee3f3c6b8c2355638a7e55b
Parents: afff4e7 a9bf9a3
Author: Shao Feng, Shi <sh...@ebay.com>
Authored: Mon Mar 9 17:10:31 2015 +0800
Committer: Shao Feng, Shi <sh...@ebay.com>
Committed: Mon Mar 9 17:10:31 2015 +0800

----------------------------------------------------------------------
 webapp/app/js/controllers/cubeEdit.js           |  2 +-
 webapp/app/js/controllers/cubeModel.js          | 35 ++++++++++++++++----
 webapp/app/js/model/metaModel.js                |  2 +-
 .../app/partials/cubeDesigner/dimensions.html   |  1 -
 .../app/partials/cubeDesigner/incremental.html  | 10 +++---
 5 files changed, 36 insertions(+), 14 deletions(-)
----------------------------------------------------------------------



[20/47] incubator-kylin git commit: Merge pull request #442 from janzhongi/staging

Posted by li...@apache.org.
Merge pull request #442 from janzhongi/staging

fix KYLIN-524 & add tip for partition column field

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

Branch: refs/heads/master
Commit: 4be14bb659abf341b7e1208933a0a21e80707033
Parents: cfbd6ae c6adb69
Author: Zhong,Jian <ji...@ebay.com>
Authored: Mon Mar 9 16:28:11 2015 +0800
Committer: Zhong,Jian <ji...@ebay.com>
Committed: Mon Mar 9 16:28:11 2015 +0800

----------------------------------------------------------------------
 webapp/app/js/controllers/cubeModel.js          | 35 ++++++++++++++++----
 webapp/app/js/model/metaModel.js                |  2 +-
 .../app/partials/cubeDesigner/dimensions.html   |  1 -
 .../app/partials/cubeDesigner/incremental.html  |  9 ++---
 4 files changed, 34 insertions(+), 13 deletions(-)
----------------------------------------------------------------------



[15/47] incubator-kylin git commit: Update install_and_run.md

Posted by li...@apache.org.
Update install_and_run.md

update start/stop shell

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

Branch: refs/heads/master
Commit: e6b7e2796ab5123c1324cedbfb2f035dd7c0b634
Parents: ef27f3a
Author: Luke Han <lu...@users.noreply.github.com>
Authored: Fri Mar 6 15:03:17 2015 +0800
Committer: Luke Han <lu...@users.noreply.github.com>
Committed: Fri Mar 6 15:03:17 2015 +0800

----------------------------------------------------------------------
 docs/Installation/install_and_run.md | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-kylin/blob/e6b7e279/docs/Installation/install_and_run.md
----------------------------------------------------------------------
diff --git a/docs/Installation/install_and_run.md b/docs/Installation/install_and_run.md
index d634b32..82369eb 100644
--- a/docs/Installation/install_and_run.md
+++ b/docs/Installation/install_and_run.md
@@ -5,8 +5,8 @@
 1. Download the release version(according to the hadoop distribution)
 2. Setup a KYLIN_HOME pointing to the corresponding directory where you extract the release tar
 3. Make sure the user has the privilege to run hadoop, hive and hbase cmd in shell. If you are not so sure, you can just run **bin/check-env.sh**, it will print out the detail information if you have some environment issues.
-4. To start Kylin, simply run **bin/start-kylin.sh**
-5. To stop Kylin, simply run **bin/stop-kylin.sh**
+4. To start Kylin, simply run **bin/kylin.sh start**
+5. To stop Kylin, simply run **bin/kylin.sh stop**
 
 
 If you are running Kylin in a cluster or you have multiple Kylin instances, please make sure you have the following property correctly configured.
@@ -27,8 +27,7 @@ If you are running Kylin in a cluster or you have multiple Kylin instances, plea
 >     │   ├── check-env.sh
 >     │   ├── find-hive-dependency.sh
 >     │   ├── health-check.sh
->     │   ├── start-kylin.sh
->     │   └── stop-kylin.sh
+>     │   └── kylin.sh
 >     │
 >     ├── conf
 >     │   ├── kylin_job_conf.xml