tez-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From prak...@apache.org
Subject tez git commit: TEZ-2504. Tez UI: tables - show status column without scrolling, numeric 0 shown as Not available (Sreenath Somarajapuram via pramachandran)
Date Mon, 01 Jun 2015 11:15:48 GMT
Repository: tez
Updated Branches:
  refs/heads/master 5a04f0602 -> 7fe0a6b71


TEZ-2504. Tez UI: tables - show status column without scrolling, numeric 0 shown as Not available
(Sreenath Somarajapuram via pramachandran)


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

Branch: refs/heads/master
Commit: 7fe0a6b7122c31c4d2d274700faa6c04297ce3a7
Parents: 5a04f06
Author: Prakash Ramachandran <pramachandran@hortonworks.com>
Authored: Mon Jun 1 16:42:08 2015 +0530
Committer: Prakash Ramachandran <pramachandran@hortonworks.com>
Committed: Mon Jun 1 16:42:08 2015 +0530

----------------------------------------------------------------------
 CHANGES.txt                                     |  1 +
 .../scripts/components/basic-table/cell-view.js | 12 +++++-
 .../controllers/dag-task-attempts-controller.js | 26 ++++++-------
 .../webapp/app/scripts/controllers/dag_tasks.js | 28 +++++++-------
 .../app/scripts/controllers/dag_vertices.js     | 40 ++++++++++----------
 .../task_task_attempts_controller.js            | 26 ++++++-------
 .../vertex_task_attempts_controller.js          | 26 ++++++-------
 .../controllers/vertex_tasks_controller.js      | 28 +++++++-------
 8 files changed, 98 insertions(+), 89 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tez/blob/7fe0a6b7/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index bbe4fc8..c1a7b09 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -30,6 +30,7 @@ Release 0.7.1: Unreleased
 INCOMPATIBLE CHANGES
 
 ALL CHANGES:
+  TEZ-2504. Tez UI: tables - show status column without scrolling, numeric 0 shown as Not
available
   TEZ-2478. Move OneToOne routing to store events in Tasks.
   TEZ-2482. Tez UI: Mouse events not working on IE11
   TEZ-1529. ATS and TezClient integration in secure kerberos enabled cluster.

http://git-wip-us.apache.org/repos/asf/tez/blob/7fe0a6b7/tez-ui/src/main/webapp/app/scripts/components/basic-table/cell-view.js
----------------------------------------------------------------------
diff --git a/tez-ui/src/main/webapp/app/scripts/components/basic-table/cell-view.js b/tez-ui/src/main/webapp/app/scripts/components/basic-table/cell-view.js
index 1506577..80a4c56 100644
--- a/tez-ui/src/main/webapp/app/scripts/components/basic-table/cell-view.js
+++ b/tez-ui/src/main/webapp/app/scripts/components/basic-table/cell-view.js
@@ -18,15 +18,23 @@
 
 var ObjectPromiseController = Ember.ObjectController.extend(Ember.PromiseProxyMixin);
 
+function stringifyNumbers(content) {
+  var displayText = content.displayText;
+  if(typeof displayText == 'number') {
+    content.displayText = displayText.toString();
+  }
+  return content;
+}
+
 App.BasicTableComponent.CellView = Ember.View.extend({
   templateName: 'components/basic-table/basic-cell',
 
   classNames: ['cell-content'],
 
   _normalizeContent: function (content) {
-    return content && typeof content == 'object' ? content : {
+    return stringifyNumbers(content && typeof content == 'object' ? content : {
       displayText: content
-    };
+    });
   },
 
   cellContent: function () {

http://git-wip-us.apache.org/repos/asf/tez/blob/7fe0a6b7/tez-ui/src/main/webapp/app/scripts/controllers/dag-task-attempts-controller.js
----------------------------------------------------------------------
diff --git a/tez-ui/src/main/webapp/app/scripts/controllers/dag-task-attempts-controller.js
b/tez-ui/src/main/webapp/app/scripts/controllers/dag-task-attempts-controller.js
index b26d2eb..572e226 100644
--- a/tez-ui/src/main/webapp/app/scripts/controllers/dag-task-attempts-controller.js
+++ b/tez-ui/src/main/webapp/app/scripts/controllers/dag-task-attempts-controller.js
@@ -102,6 +102,19 @@ App.DagTaskAttemptsController = App.TablePageController.extend({
         }
       },
       {
+        id: 'status',
+        headerCellName: 'Status',
+        templateName: 'components/basic-table/status-cell',
+        contentPath: 'status',
+        getCellContent: function(row) {
+          var status = App.Helpers.misc.getFixedupDisplayStatus(row.get('status'));
+          return {
+            status: status,
+            statusIcon: App.Helpers.misc.getStatusClassForEntity(status)
+          };
+        }
+      },
+      {
         id: 'vertexName',
         headerCellName: 'Vertex Name',
         contentPath: 'vertexID',
@@ -152,19 +165,6 @@ App.DagTaskAttemptsController = App.TablePageController.extend({
         },
       },
       {
-        id: 'status',
-        headerCellName: 'Status',
-        templateName: 'components/basic-table/status-cell',
-        contentPath: 'status',
-        getCellContent: function(row) {
-          var status = App.Helpers.misc.getFixedupDisplayStatus(row.get('status'));
-          return {
-            status: status,
-            statusIcon: App.Helpers.misc.getStatusClassForEntity(status)
-          };
-        }
-      },
-      {
         id: 'containerId',
         headerCellName: 'Container',
         contentPath: 'containerId'

http://git-wip-us.apache.org/repos/asf/tez/blob/7fe0a6b7/tez-ui/src/main/webapp/app/scripts/controllers/dag_tasks.js
----------------------------------------------------------------------
diff --git a/tez-ui/src/main/webapp/app/scripts/controllers/dag_tasks.js b/tez-ui/src/main/webapp/app/scripts/controllers/dag_tasks.js
index ec4a47f..604899b 100644
--- a/tez-ui/src/main/webapp/app/scripts/controllers/dag_tasks.js
+++ b/tez-ui/src/main/webapp/app/scripts/controllers/dag_tasks.js
@@ -122,6 +122,20 @@ App.DagTasksController = App.TablePageController.extend({
         }
       },
       {
+        id: 'status',
+        headerCellName: 'Status',
+        templateName: 'components/basic-table/status-cell',
+        contentPath: 'status',
+        getCellContent: function(row) {
+          var status = row.get('status');
+          return {
+            status: status,
+            statusIcon: App.Helpers.misc.getStatusClassForEntity(status,
+              row.get('hasFailedTaskAttempts'))
+          };
+        }
+      },
+      {
         id: 'startTime',
         headerCellName: 'Start Time',
         contentPath: 'startTime',
@@ -155,20 +169,6 @@ App.DagTasksController = App.TablePageController.extend({
         },
       },
       {
-        id: 'status',
-        headerCellName: 'Status',
-        templateName: 'components/basic-table/status-cell',
-        contentPath: 'status',
-        getCellContent: function(row) {
-          var status = row.get('status');
-          return {
-            status: status,
-            statusIcon: App.Helpers.misc.getStatusClassForEntity(status,
-              row.get('hasFailedTaskAttempts'))
-          };
-        }
-      },
-      {
         id: 'actions',
         headerCellName: 'Actions',
         templateName: 'components/basic-table/task-actions-cell',

http://git-wip-us.apache.org/repos/asf/tez/blob/7fe0a6b7/tez-ui/src/main/webapp/app/scripts/controllers/dag_vertices.js
----------------------------------------------------------------------
diff --git a/tez-ui/src/main/webapp/app/scripts/controllers/dag_vertices.js b/tez-ui/src/main/webapp/app/scripts/controllers/dag_vertices.js
index e531bdf..cdfbf21 100644
--- a/tez-ui/src/main/webapp/app/scripts/controllers/dag_vertices.js
+++ b/tez-ui/src/main/webapp/app/scripts/controllers/dag_vertices.js
@@ -112,6 +112,26 @@ App.DagVerticesController = App.TablePageController.extend({
         contentPath: 'id',
       },
       {
+        id: 'status',
+        headerCellName: 'Status',
+        templateName: 'components/basic-table/status-cell',
+        contentPath: 'status',
+        getCellContent: function(row) {
+          var status = row.get('status'),
+              content = Ember.Object.create({
+                vertex: row,
+                status: status,
+                statusIcon: App.Helpers.misc.getStatusClassForEntity(status,
+                  row.get('hasFailedTaskAttempts'))
+              });
+
+          if(status == 'RUNNING') {
+            row.addObserver('progress', content, onProgressChange);
+          }
+          return content;
+        }
+      },
+      {
         id: 'startTime',
         headerCellName: 'Start Time',
         contentPath: 'startTime',
@@ -166,26 +186,6 @@ App.DagVerticesController = App.TablePageController.extend({
         contentPath: 'processorClassName'
       },
       {
-        id: 'status',
-        headerCellName: 'Status',
-        templateName: 'components/basic-table/status-cell',
-        contentPath: 'status',
-        getCellContent: function(row) {
-          var status = row.get('status'),
-              content = Ember.Object.create({
-                vertex: row,
-                status: status,
-                statusIcon: App.Helpers.misc.getStatusClassForEntity(status,
-                  row.get('hasFailedTaskAttempts'))
-              });
-
-          if(status == 'RUNNING') {
-            row.addObserver('progress', content, onProgressChange);
-          }
-          return content;
-        }
-      },
-      {
         id: 'configurations',
         headerCellName: 'Source/Sink Configs',
         templateName: 'components/basic-table/vertex-configurations-cell',

http://git-wip-us.apache.org/repos/asf/tez/blob/7fe0a6b7/tez-ui/src/main/webapp/app/scripts/controllers/task_task_attempts_controller.js
----------------------------------------------------------------------
diff --git a/tez-ui/src/main/webapp/app/scripts/controllers/task_task_attempts_controller.js
b/tez-ui/src/main/webapp/app/scripts/controllers/task_task_attempts_controller.js
index d211479..8e491a1 100644
--- a/tez-ui/src/main/webapp/app/scripts/controllers/task_task_attempts_controller.js
+++ b/tez-ui/src/main/webapp/app/scripts/controllers/task_task_attempts_controller.js
@@ -84,6 +84,19 @@ App.TaskAttemptsController = App.TablePageController.extend(App.AutoCounterColum
         }
       },
       {
+        id: 'status',
+        headerCellName: 'Status',
+        templateName: 'components/basic-table/status-cell',
+        contentPath: 'status',
+        getCellContent: function(row) {
+          var status = App.Helpers.misc.getFixedupDisplayStatus(row.get('status'));
+          return {
+            status: status,
+            statusIcon: App.Helpers.misc.getStatusClassForEntity(status)
+          };
+        }
+      },
+      {
         id: 'startTime',
         headerCellName: 'Start Time',
         contentPath: 'startTime',
@@ -117,19 +130,6 @@ App.TaskAttemptsController = App.TablePageController.extend(App.AutoCounterColum
         },
       },
       {
-        id: 'status',
-        headerCellName: 'Status',
-        templateName: 'components/basic-table/status-cell',
-        contentPath: 'status',
-        getCellContent: function(row) {
-          var status = App.Helpers.misc.getFixedupDisplayStatus(row.get('status'));
-          return {
-            status: status,
-            statusIcon: App.Helpers.misc.getStatusClassForEntity(status)
-          };
-        }
-      },
-      {
         id: 'containerId',
         headerCellName: 'Container',
         contentPath: 'containerId'

http://git-wip-us.apache.org/repos/asf/tez/blob/7fe0a6b7/tez-ui/src/main/webapp/app/scripts/controllers/vertex_task_attempts_controller.js
----------------------------------------------------------------------
diff --git a/tez-ui/src/main/webapp/app/scripts/controllers/vertex_task_attempts_controller.js
b/tez-ui/src/main/webapp/app/scripts/controllers/vertex_task_attempts_controller.js
index b4ed89a..c4a52f5 100644
--- a/tez-ui/src/main/webapp/app/scripts/controllers/vertex_task_attempts_controller.js
+++ b/tez-ui/src/main/webapp/app/scripts/controllers/vertex_task_attempts_controller.js
@@ -102,6 +102,19 @@ App.VertexTaskAttemptsController = App.TablePageController.extend(App.AutoCounte
         }
       },
       {
+        id: 'status',
+        headerCellName: 'Status',
+        templateName: 'components/basic-table/status-cell',
+        contentPath: 'status',
+        getCellContent: function(row) {
+          var status = App.Helpers.misc.getFixedupDisplayStatus(row.get('status'));
+          return {
+            status: status,
+            statusIcon: App.Helpers.misc.getStatusClassForEntity(status)
+          };
+        }
+      },
+      {
         id: 'startTime',
         headerCellName: 'Start Time',
         contentPath: 'startTime',
@@ -135,19 +148,6 @@ App.VertexTaskAttemptsController = App.TablePageController.extend(App.AutoCounte
         },
       },
       {
-        id: 'status',
-        headerCellName: 'Status',
-        templateName: 'components/basic-table/status-cell',
-        contentPath: 'status',
-        getCellContent: function(row) {
-          var status = App.Helpers.misc.getFixedupDisplayStatus(row.get('status'));
-          return {
-            status: status,
-            statusIcon: App.Helpers.misc.getStatusClassForEntity(status)
-          };
-        }
-      },
-      {
         id: 'containerId',
         headerCellName: 'Container',
         contentPath: 'containerId'

http://git-wip-us.apache.org/repos/asf/tez/blob/7fe0a6b7/tez-ui/src/main/webapp/app/scripts/controllers/vertex_tasks_controller.js
----------------------------------------------------------------------
diff --git a/tez-ui/src/main/webapp/app/scripts/controllers/vertex_tasks_controller.js b/tez-ui/src/main/webapp/app/scripts/controllers/vertex_tasks_controller.js
index 2cc0518..4735eac 100644
--- a/tez-ui/src/main/webapp/app/scripts/controllers/vertex_tasks_controller.js
+++ b/tez-ui/src/main/webapp/app/scripts/controllers/vertex_tasks_controller.js
@@ -105,6 +105,20 @@ App.VertexTasksController = App.TablePageController.extend(App.AutoCounterColumn
         }
       },
       {
+        id: 'status',
+        headerCellName: 'Status',
+        templateName: 'components/basic-table/status-cell',
+        contentPath: 'status',
+        getCellContent: function(row) {
+          var status = row.get('status');
+          return {
+            status: status,
+            statusIcon: App.Helpers.misc.getStatusClassForEntity(status,
+              row.get('hasFailedTaskAttempts'))
+          };
+        }
+      },
+      {
         id: 'startTime',
         headerCellName: 'Start Time',
         contentPath: 'startTime',
@@ -138,20 +152,6 @@ App.VertexTasksController = App.TablePageController.extend(App.AutoCounterColumn
         },
       },
       {
-        id: 'status',
-        headerCellName: 'Status',
-        templateName: 'components/basic-table/status-cell',
-        contentPath: 'status',
-        getCellContent: function(row) {
-          var status = row.get('status');
-          return {
-            status: status,
-            statusIcon: App.Helpers.misc.getStatusClassForEntity(status,
-              row.get('hasFailedTaskAttempts'))
-          };
-        }
-      },
-      {
         id: 'actions',
         headerCellName: 'Actions',
         templateName: 'components/basic-table/task-actions-cell',


Mime
View raw message