kylin-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From zhongj...@apache.org
Subject kylin git commit: KYLIN-1287 UI update for streaming build action
Date Tue, 05 Jan 2016 07:18:51 GMT
Repository: kylin
Updated Branches:
  refs/heads/2.0-rc 684c05ca7 -> 9f0fab121


KYLIN-1287 UI update for streaming build action


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

Branch: refs/heads/2.0-rc
Commit: 9f0fab1212da3b72c3a9f7e7d58081d2809f0c54
Parents: 684c05c
Author: jian <jiazhong@apache.org>
Authored: Tue Jan 5 15:18:14 2016 +0800
Committer: jian <jiazhong@apache.org>
Committed: Tue Jan 5 15:18:29 2016 +0800

----------------------------------------------------------------------
 build/conf/kylin.properties                     |  4 ++++
 .../test_case_data/sandbox/kylin.properties     |  4 ++++
 webapp/app/js/controllers/cubes.js              | 24 ++++++++++++++++++-
 webapp/app/partials/cubes/cubes.html            |  1 +
 .../app/partials/cubes/streaming_build_tip.html | 25 ++++++++++++++++++++
 5 files changed, 57 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/kylin/blob/9f0fab12/build/conf/kylin.properties
----------------------------------------------------------------------
diff --git a/build/conf/kylin.properties b/build/conf/kylin.properties
index d029b4c..a4b8c3b 100644
--- a/build/conf/kylin.properties
+++ b/build/conf/kylin.properties
@@ -140,6 +140,10 @@ kylin.web.help.0=start|Getting Started|
 kylin.web.help.1=odbc|ODBC Driver|
 kylin.web.help.2=tableau|Tableau Guide|
 kylin.web.help.3=onboard|Cube Design Tutorial|
+
+#guide user how to build streaming cube
+kylin.web.streaming.guide=http://kylin.apache.org/
+
 #hadoop url link ,optional
 kylin.web.hadoop=
 #job diagnostic url link ,optional

http://git-wip-us.apache.org/repos/asf/kylin/blob/9f0fab12/examples/test_case_data/sandbox/kylin.properties
----------------------------------------------------------------------
diff --git a/examples/test_case_data/sandbox/kylin.properties b/examples/test_case_data/sandbox/kylin.properties
index 6f19cc7..d349084 100644
--- a/examples/test_case_data/sandbox/kylin.properties
+++ b/examples/test_case_data/sandbox/kylin.properties
@@ -111,6 +111,10 @@ kylin.web.help.0=start|Getting Started|
 kylin.web.help.1=odbc|ODBC Driver|
 kylin.web.help.2=tableau|Tableau Guide|
 kylin.web.help.3=onboard|Cube Design Tutorial|
+
+#guide user how to build streaming cube
+kylin.web.streaming.guide=http://kylin.apache.org/
+
 #hadoop url link ,optional
 kylin.web.hadoop=
 #job diagnostic url link ,optional

http://git-wip-us.apache.org/repos/asf/kylin/blob/9f0fab12/webapp/app/js/controllers/cubes.js
----------------------------------------------------------------------
diff --git a/webapp/app/js/controllers/cubes.js b/webapp/app/js/controllers/cubes.js
index 0f10434..7bc35f9 100644
--- a/webapp/app/js/controllers/cubes.js
+++ b/webapp/app/js/controllers/cubes.js
@@ -19,7 +19,7 @@
 'use strict';
 
 KylinApp
-  .controller('CubesCtrl', function ($scope, $q, $routeParams, $location, $modal, MessageService,
CubeDescService, CubeService, JobService, UserService, ProjectService, SweetAlert, loadingRequest,
$log, cubeConfig, ProjectModel, ModelService, MetaModel, CubeList,modelsManager,cubesManager,StreamingList)
{
+  .controller('CubesCtrl', function ($scope, $q, $routeParams, $location, $modal, MessageService,
CubeDescService, CubeService, JobService, UserService, ProjectService, SweetAlert, loadingRequest,
$log, cubeConfig, ProjectModel, ModelService, MetaModel, CubeList,modelsManager,cubesManager,StreamingList,kylinConfig)
{
 
     $scope.cubeConfig = cubeConfig;
     $scope.cubeList = CubeList;
@@ -279,6 +279,18 @@ KylinApp
     };
 
     $scope.startJobSubmit = function (cube) {
+
+      // for streaming cube build tip
+      if(cube.streaming){
+        $modal.open({
+          templateUrl: 'streamingBuild.html',
+          controller: streamingBuildCtrl,
+          resolve: {
+          }
+        });
+        return;
+      }
+
       $scope.metaModel={
         model:modelsManager.getModelByCube(cube.name)
       }
@@ -510,3 +522,13 @@ var jobSubmitCtrl = function ($scope, $modalInstance, CubeService, MessageServic
   };
 };
 
+
+var streamingBuildCtrl = function ($scope, $modalInstance,kylinConfig) {
+  $scope.kylinConfig = kylinConfig;
+  var streamingGuildeUrl = kylinConfig.getProperty("kylin.web.streaming.guide");
+  $scope.streamingBuildUrl = streamingGuildeUrl?streamingGuildeUrl:"http://kylin.apache.org/";
+
+  $scope.cancel = function () {
+    $modalInstance.dismiss('cancel');
+  };
+}

http://git-wip-us.apache.org/repos/asf/kylin/blob/9f0fab12/webapp/app/partials/cubes/cubes.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/cubes/cubes.html b/webapp/app/partials/cubes/cubes.html
index fdf3277..2b456f4 100644
--- a/webapp/app/partials/cubes/cubes.html
+++ b/webapp/app/partials/cubes/cubes.html
@@ -133,6 +133,7 @@
 </div>
 
 <div ng-include="'partials/jobs/job_submit.html'"></div>
+<div ng-include="'partials/cubes/streaming_build_tip.html'"></div>
 <div ng-include="'partials/jobs/job_refresh.html'"></div>
 <div ng-include="'partials/jobs/job_merge.html'"></div>
 <div ng-include="'partials/projects/project_create.html'"></div>

http://git-wip-us.apache.org/repos/asf/kylin/blob/9f0fab12/webapp/app/partials/cubes/streaming_build_tip.html
----------------------------------------------------------------------
diff --git a/webapp/app/partials/cubes/streaming_build_tip.html b/webapp/app/partials/cubes/streaming_build_tip.html
new file mode 100644
index 0000000..80c5875
--- /dev/null
+++ b/webapp/app/partials/cubes/streaming_build_tip.html
@@ -0,0 +1,25 @@
+<!--
+* 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="streamingBuild.html">
+      <div class="callout callout-info">
+        <button type="button" class="close" data-dismiss="alert" ng-click="cancel()">×</button>
+        <h4><i class="fa fa-bullhorn"></i> Tips</h4>
+        Streaming cube build is not supported on UI, click <a href="{{streamingBuildUrl}}"
style="color:blue;" target="_blank">here</a> to see how to schedule streaming cube.
+    </div>
+</script>


Mime
View raw message