ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From atk...@apache.org
Subject ambari git commit: AMBARI-22333 Ambari 3.0: Implement new design for metrics of service summary. (atkach)
Date Mon, 30 Oct 2017 14:04:46 GMT
Repository: ambari
Updated Branches:
  refs/heads/trunk 4be5b8d01 -> 0041ab254


AMBARI-22333 Ambari 3.0: Implement new design for metrics of service summary. (atkach)


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

Branch: refs/heads/trunk
Commit: 0041ab2540f2ad99481d8e1708e12adbee3aa404
Parents: 4be5b8d
Author: Andrii Tkach <atkach@apache.org>
Authored: Mon Oct 30 14:42:43 2017 +0200
Committer: Andrii Tkach <atkach@apache.org>
Committed: Mon Oct 30 14:42:43 2017 +0200

----------------------------------------------------------------------
 ambari-web/app/messages.js                      |  23 ++-
 ambari-web/app/styles/application.less          |   8 +-
 .../templates/main/service/services/hdfs.hbs    | 116 ++++++++----
 .../templates/main/service/services/yarn.hbs    | 184 +++++++++++++++----
 .../app/views/main/service/services/yarn.js     |  21 ++-
 .../views/main/service/services/yarn_test.js    |  22 ---
 6 files changed, 253 insertions(+), 121 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/0041ab25/ambari-web/app/messages.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js
index 0123356..ebf2f8a 100644
--- a/ambari-web/app/messages.js
+++ b/ambari-web/app/messages.js
@@ -2938,8 +2938,8 @@ Em.I18n.translations = {
   'dashboard.services.uptime':'{0}',
   'dashboard.services.summary.slaves.live': 'Live',
   'dashboard.services.hdfs.summary':'{0} of {1} nodes live, {2}% capacity used',
-  'dashboard.services.hdfs.summary.components': 'COMPONENT',
-  'dashboard.services.hdfs.summary.service-metrics': 'SERVICE METRICS',
+  'dashboard.services.hdfs.summary.components': 'Components',
+  'dashboard.services.hdfs.summary.service-metrics': 'Service Metrics',
   'dashboard.services.hdfs.nanmenode':'NameNode',
   'dashboard.services.hdfs.snanmenode':'Secondary NameNode',
   'dashboard.services.hdfs.journalnodes':'JournalNodes',
@@ -3007,14 +3007,21 @@ Em.I18n.translations = {
   'dashboard.services.yarn.nodeManagers.status.tooltip.rebooted': 'This is the number of
NodeManagers that are in the rebooted state as reported from the ResourceManager.',
   'dashboard.services.yarn.nodeManagers.status.tooltip.decommissioned': 'This is the number
of NodeManagers that are decommissioned as reported from the ResourceManager.',
   'dashboard.services.yarn.containers': 'Containers',
-  'dashboard.services.yarn.containers.msg': '{0} / {1} / {2}',
-  'dashboard.services.yarn.containers.msgDesc': 'allocated / pending / reserved',
+  'dashboard.services.yarn.containers.allocated': 'allocated',
+  'dashboard.services.yarn.containers.pending': 'pending',
+  'dashboard.services.yarn.containers.reserved': 'reserved',
   'dashboard.services.yarn.apps': 'Applications',
-  'dashboard.services.yarn.apps.msg': '{0} / {1} / {2} / {3} / {4} / {5}',
-  'dashboard.services.yarn.apps.msgDesc': 'submitted / running / pending / completed / killed
/ failed',
+  'dashboard.services.yarn.apps.submitted': 'submitted',
+  'dashboard.services.yarn.apps.running': 'running',
+  'dashboard.services.yarn.apps.pending': 'pending',
+  'dashboard.services.yarn.apps.completed': 'completed',
+  'dashboard.services.yarn.apps.killed': 'killed',
+  'dashboard.services.yarn.apps.failed': 'failed',
+
   'dashboard.services.yarn.memory': 'Cluster Memory',
-  'dashboard.services.yarn.memory.msg': '{0} / {1} / {2}',
-  'dashboard.services.yarn.memory.msgDesc': 'used / reserved / available',
+  'dashboard.services.yarn.memory.used': 'used',
+  'dashboard.services.yarn.memory.reserved': 'reserved',
+  'dashboard.services.yarn.memory.available': 'available',
   'dashboard.services.yarn.queues': 'Queues',
   'dashboard.services.yarn.queues.msg': '{0} Queues',
   'dashboard.services.hawq.hawqSegments':'HAWQ Segments',

http://git-wip-us.apache.org/repos/asf/ambari/blob/0041ab25/ambari-web/app/styles/application.less
----------------------------------------------------------------------
diff --git a/ambari-web/app/styles/application.less b/ambari-web/app/styles/application.less
index d40ab8e..df86c7f 100644
--- a/ambari-web/app/styles/application.less
+++ b/ambari-web/app/styles/application.less
@@ -2754,11 +2754,10 @@ a.abort-icon:hover {
   }
   .component-summary, .metrics-summary {
     .col-md-2 {
-      float:left;
-      padding-left: 0px;
+      float: left;
+      padding-left: 0;
       top: 7px;
-      font-size: 12px;
-      font-weight: bold;
+      font-size: 16px;
     }
     .col-md-10 {
       float: right;
@@ -2769,6 +2768,7 @@ a.abort-icon:hover {
     .info-desc {
       font-size: 12px;
       color: #999999;
+      text-transform: capitalize;
     }
   }
 }

http://git-wip-us.apache.org/repos/asf/ambari/blob/0041ab25/ambari-web/app/templates/main/service/services/hdfs.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/service/services/hdfs.hbs b/ambari-web/app/templates/main/service/services/hdfs.hbs
index fec5bac..bb927aa 100644
--- a/ambari-web/app/templates/main/service/services/hdfs.hbs
+++ b/ambari-web/app/templates/main/service/services/hdfs.hbs
@@ -55,32 +55,6 @@
           </div>
         </div>
       {{/if}}
-      {{! Data Node Counts }}
-      <div class="row datanode-count col-md-3">
-        <div class="summary-value">
-          {{#if view.service.metricsNotAvailable}}
-          <div class="main-info">
-            {{t services.service.summary.notAvailable}}
-            </div>
-          {{else}}
-            <div class="main-info">
-              <p {{translateAttr data-original-title="dashboard.services.hdfs.datanode.status.tooltip.live"
}}
-                      rel="tooltip">
-                 {{view.service.liveDataNodes.length}}&nbsp;{{t dashboard.services.hdfs.nodes.live}}
-              </p>
-              <p {{translateAttr data-original-title="dashboard.services.hdfs.datanode.status.tooltip.dead"
}}
-                      rel="tooltip">
-                 {{view.service.deadDataNodes.length}}&nbsp;{{t dashboard.services.hdfs.nodes.dead}}
-              </p>
-              <p {{translateAttr data-original-title="dashboard.services.hdfs.datanode.status.tooltip.decommission"
}}
-                      rel="tooltip">
-                {{view.service.decommissionDataNodes.length}}&nbsp;{{t dashboard.services.hdfs.nodes.decom}}
-              </p>
-            </div>
-          {{/if}}
-        </div>
-        <div class="summary-label">{{t dashboard.services.hdfs.datanodecounts}}</div>
-      </div>
       {{! JournalNodes }}
       {{#if view.isJournalNodeCreated}}
         <div {{bindAttr class=":row :component :col-md-3 view.journalNodeComponent.componentName"}}>
@@ -121,6 +95,59 @@
           </div>
         </div>
       {{/if}}
+      {{! indent next row}}
+      <div class="row"></div>
+      {{! Data Node Counts live }}
+      <div class="row datanode-count-live col-md-3">
+        <div class="summary-value">
+          {{#if view.service.metricsNotAvailable}}
+            <div class="main-info">
+              {{t services.service.summary.notAvailable}}
+            </div>
+          {{else}}
+            <span class="main-info" rel="tooltip"
+              {{translateAttr data-original-title="dashboard.services.hdfs.datanode.status.tooltip.live"
}}>
+              {{view.service.liveDataNodes.length}}
+            </span>
+            <div class="info-desc">{{t dashboard.services.hdfs.nodes.live}}</div>
+            {{/if}}
+        </div>
+        <div class="summary-label">{{t dashboard.services.hdfs.datanodecounts}}</div>
+      </div>
+      {{! Data Node Counts dead }}
+      <div class="row datanode-count-dead col-md-3">
+        <div class="summary-value">
+          {{#if view.service.metricsNotAvailable}}
+            <div class="main-info">
+              {{t services.service.summary.notAvailable}}
+            </div>
+          {{else}}
+            <span class="main-info" rel="tooltip"
+              {{translateAttr data-original-title="dashboard.services.hdfs.datanode.status.tooltip.dead"
}}>
+              {{view.service.deadDataNodes.length}}
+            </span>
+            <div class="info-desc">{{t dashboard.services.hdfs.nodes.dead}}</div>
+          {{/if}}
+        </div>
+        <div class="summary-label">{{t dashboard.services.hdfs.datanodecounts}}</div>
+      </div>
+      {{! Data Node Counts decommission }}
+      <div class="row datanode-count-decommission col-md-3">
+        <div class="summary-value">
+          {{#if view.service.metricsNotAvailable}}
+            <div class="main-info">
+              {{t services.service.summary.notAvailable}}
+            </div>
+          {{else}}
+            <span class="main-info" rel="tooltip"
+              {{translateAttr data-original-title="dashboard.services.hdfs.datanode.status.tooltip.decommission"
}}>
+              {{view.service.decommissionDataNodes.length}}
+            </span>
+            <div class="info-desc">{{t dashboard.services.hdfs.nodes.decom}}</div>
+          {{/if}}
+        </div>
+        <div class="summary-label">{{t dashboard.services.hdfs.datanodecounts}}</div>
+      </div>
     </div>
   </div>
   {{! left column end }}
@@ -156,21 +183,34 @@
         <div class="summary-value main-info">{{view.dfsTotalBlocks}}</div>
         <div class="summary-label">{{t services.service.summary.blocksTotal}}</div>
       </div>
-      {{! Block Errors }}
-      <div class="row block-errors col-md-3 summary-value">
-        <div class="main-info">
-          <p>
-            {{view.dfsCorruptBlocks}}&nbsp;{{t dashboard.services.hdfs.blockErrors.corrupt}}
-          </p>
-          <p>
-            {{view.dfsMissingBlocks}}&nbsp;{{t dashboard.services.hdfs.blockErrors.missing}}
-          </p>
-          <p>
-            {{view.dfsUnderReplicatedBlocks}}&nbsp;{{t dashboard.services.hdfs.blockErrors.replicated}}
-          </p>
+      {{! indent next row}}
+      <div class="row"></div>
+      {{! Block Errors corrupt }}
+      <div class="row block-errors-corrupt col-md-3">
+        <div class="summary-value main-info">
+          <div class="main-info">{{view.dfsCorruptBlocks}}</div>
+          <div class="info-desc">{{t dashboard.services.hdfs.blockErrors.corrupt}}</div>
+        </div>
+        <div class="summary-label">{{t services.service.summary.blockErrors}}</div>
+      </div>
+      {{! Block Errors missing }}
+      <div class="row block-errors-missing col-md-3">
+        <div class="summary-value main-info">
+          <div class="main-info">{{view.dfsMissingBlocks}}</div>
+          <div class="info-desc">{{t dashboard.services.hdfs.blockErrors.missing}}</div>
+        </div>
+        <div class="summary-label">{{t services.service.summary.blockErrors}}</div>
+      </div>
+      {{! Block Errors replicated }}
+      <div class="row block-errors-replicated col-md-3">
+        <div class="summary-value main-info">
+          <div class="main-info">{{view.dfsUnderReplicatedBlocks}}</div>
+          <div class="info-desc">{{t dashboard.services.hdfs.blockErrors.replicated}}</div>
         </div>
         <div class="summary-label">{{t services.service.summary.blockErrors}}</div>
       </div>
+      {{! indent next row}}
+      <div class="row"></div>
       {{! Total Files And Directories }}
       <div class="row total-files-dirs col-md-3">
         <div class="summary-value main-info">{{view.dfsTotalFiles}}</div>

http://git-wip-us.apache.org/repos/asf/ambari/blob/0041ab25/ambari-web/app/templates/main/service/services/yarn.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/main/service/services/yarn.hbs b/ambari-web/app/templates/main/service/services/yarn.hbs
index aa8ee48..86182a9 100644
--- a/ambari-web/app/templates/main/service/services/yarn.hbs
+++ b/ambari-web/app/templates/main/service/services/yarn.hbs
@@ -52,41 +52,67 @@
           </a>
         </div>
       </div>
+      {{! indent next row}}
+      <div class="row"></div>
       {{! ResourceManager Uptime }}
       <div class="row col-md-3 resourcemanager-uptime">
         <div class="summary-value main-info">{{view.nodeUptime}}</div>
         <div class="summary-label">{{t dashboard.services.yarn.resourceManager.uptime}}</div>
       </div>
-      {{! NodeManagers status }}
-      <div class="row col-md-3 nodemanager-status">
-        <div class="summary-value">
-          <div class="main-info">
-            <span {{translateAttr data-original-title="dashboard.services.yarn.nodeManagers.status.tooltip.active"}}
-                    rel="tooltip">
-              {{view._nmActive}} </span> /
-            <span {{translateAttr data-original-title="dashboard.services.yarn.nodeManagers.status.tooltip.lost"}}
-                    rel="tooltip">
-              {{view._nmLost}} </span> /
-            <span {{translateAttr data-original-title="dashboard.services.yarn.nodeManagers.status.tooltip.unhealthy"}}
-                    rel="tooltip">
-              {{view._nmUnhealthy}} </span> /
-            <span {{translateAttr data-original-title="dashboard.services.yarn.nodeManagers.status.tooltip.rebooted"}}
-                    rel="tooltip">
-              {{view._nmRebooted}} </span> /
-            <span {{translateAttr data-original-title="dashboard.services.yarn.nodeManagers.status.tooltip.decommissioned"}}
-                    rel="tooltip">
-              {{view._nmDecom}} </span>
-          </div>
-          <div class="info-desc">
-            <span {{t dashboard.services.yarn.nodeManagers.status.active}} </span>
/
-            <span {{t dashboard.services.yarn.nodeManagers.status.lost}} </span>
/
-            <span {{t dashboard.services.yarn.nodeManagers.status.unhealthy}} </span>
/
-            <span {{t dashboard.services.yarn.nodeManagers.status.rebooted}} </span>
/
-            <span {{t dashboard.services.yarn.nodeManagers.status.decommissioned}} </span>
-          </div>
-        </div>
+      {{! indent next row}}
+      <div class="row"></div>
+      {{! NodeManagers active }}
+      <div class="row col-md-3 nodemanager-active">
+        <span class="summary-value main-info"
+          {{translateAttr data-original-title="dashboard.services.yarn.nodeManagers.status.tooltip.active"}}
+          rel="tooltip">
+          {{view._nmActive}}
+        </span>
+        <div class="info-desc">{{t dashboard.services.yarn.nodeManagers.status.active}}</div>
+        <div class="summary-label">{{t dashboard.services.yarn.nodeManagers.status}}</div>
+      </div>
+      {{! NodeManagers lost }}
+      <div class="row col-md-3 nodemanager-lost">
+        <span class="summary-value main-info"
+          {{translateAttr data-original-title="dashboard.services.yarn.nodeManagers.status.tooltip.lost"}}
+          rel="tooltip">
+          {{view._nmLost}}
+        </span>
+        <div class="info-desc">{{t dashboard.services.yarn.nodeManagers.status.lost}}</div>
+        <div class="summary-label">{{t dashboard.services.yarn.nodeManagers.status}}</div>
+      </div>
+      {{! NodeManagers unhealthy }}
+      <div class="row col-md-3 nodemanager-unhealthy">
+        <span class="summary-value main-info"
+          {{translateAttr data-original-title="dashboard.services.yarn.nodeManagers.status.tooltip.unhealthy"}}
+          rel="tooltip">
+          {{view._nmUnhealthy}}
+        </span>
+        <div class="info-desc">{{t dashboard.services.yarn.nodeManagers.status.unhealthy}}</div>
+        <div class="summary-label">{{t dashboard.services.yarn.nodeManagers.status}}</div>
+      </div>
+      {{! NodeManagers rebooted }}
+      <div class="row col-md-3 nodemanager-rebooted">
+        <span class="summary-value main-info"
+          {{translateAttr data-original-title="dashboard.services.yarn.nodeManagers.status.tooltip.rebooted"}}
+          rel="tooltip">
+          {{view._nmRebooted}}
+        </span>
+        <div class="info-desc">{{t dashboard.services.yarn.nodeManagers.status.rebooted}}</div>
+        <div class="summary-label">{{t dashboard.services.yarn.nodeManagers.status}}</div>
+      </div>
+      {{! NodeManagers decommissioned }}
+      <div class="row col-md-3 nodemanager-decommissioned">
+        <span class="summary-value main-info"
+          {{translateAttr data-original-title="dashboard.services.yarn.nodeManagers.status.tooltip.decommissioned"}}
+          rel="tooltip">
+          {{view._nmDecom}}
+        </span>
+        <div class="info-desc">{{t dashboard.services.yarn.nodeManagers.status.decommissioned}}</div>
         <div class="summary-label">{{t dashboard.services.yarn.nodeManagers.status}}</div>
       </div>
+      {{! indent next row}}
+      <div class="row"></div>
       {{! ResourceManager Heap }}
       <div class="row col-md-3 resourcemanager-heap">
         <div class="summary-value main-info">{{view.nodeHeap}}</div>
@@ -99,30 +125,108 @@
   <div class="col-md-12 metrics-summary">
     <div class="col-md-2">{{t dashboard.services.hdfs.summary.service-metrics}}</div>
     <div class="col-md-10">
-      {{! Containers }}
-      <div class="row col-md-3 yarn-containers">
+      {{! Containers allocated }}
+      <div class="row col-md-3 yarn-containers-allocated">
         <div class="summary-value">
-          <div class="main-info">{{view.containers}}</div>
-          <div class="info-desc">{{t dashboard.services.yarn.containers.msgDesc}}</div>
+          <div class="main-info">{{view._allocated}}</div>
+          <div class="info-desc">{{t dashboard.services.yarn.containers.allocated}}</div>
         </div>
         <div class="summary-label">{{t dashboard.services.yarn.containers}}</div>
       </div>
-      {{! Applications }}
-      <div class="row col-md-3 yarn-applications">
+      {{! Containers pending }}
+      <div class="row col-md-3 yarn-containers-pending">
+        <div class="summary-value">
+          <div class="main-info">{{view._pending}}</div>
+          <div class="info-desc">{{t dashboard.services.yarn.containers.pending}}</div>
+        </div>
+        <div class="summary-label">{{t dashboard.services.yarn.containers}}</div>
+      </div>
+      {{! Containers reserved }}
+      <div class="row col-md-3 yarn-containers-reserved">
+        <div class="summary-value">
+          <div class="main-info">{{view._reserved}}</div>
+          <div class="info-desc">{{t dashboard.services.yarn.containers.reserved}}</div>
+        </div>
+        <div class="summary-label">{{t dashboard.services.yarn.containers}}</div>
+      </div>
+      {{! indent next row}}
+      <div class="row"></div>
+      {{! Applications submitted }}
+      <div class="row col-md-3 yarn-applications-submitted">
+        <div class="summary-value">
+          <div class="main-info">{{view._appsSubmitted}}</div>
+          <div class="info-desc">{{t dashboard.services.yarn.apps.submitted}}</div>
+        </div>
+        <div class="summary-label">{{t dashboard.services.yarn.apps}}</div>
+      </div>
+      {{! Applications running }}
+      <div class="row col-md-3 yarn-applications-running">
         <div class="summary-value">
-          <div class="main-info">{{view.apps}}</div>
-          <div class="info-desc">{{t dashboard.services.yarn.apps.msgDesc}}</div>
+          <div class="main-info">{{view._appsRunning}}</div>
+          <div class="info-desc">{{t dashboard.services.yarn.apps.running}}</div>
         </div>
         <div class="summary-label">{{t dashboard.services.yarn.apps}}</div>
       </div>
-      {{! Memory }}
-      <div class="row col-md-3 yarn-memory">
+      {{! Applications pending }}
+      <div class="row col-md-3 yarn-applications-pending">
+        <div class="summary-value">
+          <div class="main-info">{{view._appsPending}}</div>
+          <div class="info-desc">{{t dashboard.services.yarn.apps.pending}}</div>
+        </div>
+        <div class="summary-label">{{t dashboard.services.yarn.apps}}</div>
+      </div>
+      {{! Applications completed }}
+      <div class="row col-md-3 yarn-applications-completed">
+        <div class="summary-value">
+          <div class="main-info">{{view._appsCompleted}}</div>
+          <div class="info-desc">{{t dashboard.services.yarn.apps.completed}}</div>
+        </div>
+        <div class="summary-label">{{t dashboard.services.yarn.apps}}</div>
+      </div>
+      {{! Applications killed }}
+      <div class="row col-md-3 yarn-applications-killed">
+        <div class="summary-value">
+          <div class="main-info">{{view._appsKilled}}</div>
+          <div class="info-desc">{{t dashboard.services.yarn.apps.killed}}</div>
+        </div>
+        <div class="summary-label">{{t dashboard.services.yarn.apps}}</div>
+      </div>
+      {{! Applications failed }}
+      <div class="row col-md-3 yarn-applications-failed">
+        <div class="summary-value">
+          <div class="main-info">{{view._appsFailed}}</div>
+          <div class="info-desc">{{t dashboard.services.yarn.apps.failed}}</div>
+        </div>
+        <div class="summary-label">{{t dashboard.services.yarn.apps}}</div>
+      </div>
+      {{! indent next row}}
+      <div class="row"></div>
+      {{! Memory allocated }}
+      <div class="row col-md-3 yarn-memory-allocated">
+        <div class="summary-value">
+          <div class="main-info">{{view.allocatedMemoryFormatted}}</div>
+          <div class="info-desc">{{t dashboard.services.yarn.memory.used}}</div>
+        </div>
+        <div class="summary-label">{{t dashboard.services.yarn.memory}}</div>
+      </div>
+      {{! Memory reserved }}
+      <div class="row col-md-3 yarn-memory-reserved">
+        <div class="summary-value">
+          <div class="main-info">{{view.reservedMemoryFormatted}}</div>
+          <div class="info-desc">{{t dashboard.services.yarn.memory.reserved}}</div>
+        </div>
+        <div class="summary-label">{{t dashboard.services.yarn.memory}}</div>
+      </div>
+      {{! Memory available }}
+      <div class="row col-md-3 yarn-memory-available">
         <div class="summary-value">
-          <div class="main-info">{{view.memory}}</div>
-          <div class="info-desc">{{t dashboard.services.yarn.memory.msgDesc}}</div>
+          <div class="main-info">{{view.availableMemoryFormatted}}</div>
+          <div class="info-desc">{{t dashboard.services.yarn.memory.available}}</div>
         </div>
         <div class="summary-label">{{t dashboard.services.yarn.memory}}</div>
       </div>
+      {{! indent next row}}
+      <div class="row"></div>
       {{! Queues }}
       <div class="row col-md-3 yarn-queues">
         <div class="summary-value main-info">

http://git-wip-us.apache.org/repos/asf/ambari/blob/0041ab25/ambari-web/app/views/main/service/services/yarn.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/views/main/service/services/yarn.js b/ambari-web/app/views/main/service/services/yarn.js
index 3533585..3c5c7a3 100644
--- a/ambari-web/app/views/main/service/services/yarn.js
+++ b/ambari-web/app/views/main/service/services/yarn.js
@@ -60,7 +60,6 @@ App.MainDashboardServiceYARNView = App.MainDashboardServiceView.extend({
   _allocated: Em.computed.formatUnavailable('service.containersAllocated'),
   _pending: Em.computed.formatUnavailable('service.containersPending'),
   _reserved: Em.computed.formatUnavailable('service.containersReserved'),
-  containers: Em.computed.i18nFormat('dashboard.services.yarn.containers.msg', '_allocated',
'_pending', '_reserved'),
 
   _appsSubmitted: Em.computed.formatUnavailable('service.appsSubmitted'),
   _appsRunning: Em.computed.formatUnavailable('service.appsRunning'),
@@ -68,14 +67,18 @@ App.MainDashboardServiceYARNView = App.MainDashboardServiceView.extend({
   _appsCompleted: Em.computed.formatUnavailable('service.appsCompleted'),
   _appsKilled: Em.computed.formatUnavailable('service.appsKilled'),
   _appsFailed: Em.computed.formatUnavailable('service.appsFailed'),
-  apps: Em.computed.i18nFormat('dashboard.services.yarn.apps.msg', '_appsSubmitted', '_appsRunning',
'_appsPending', '_appsCompleted', '_appsKilled', '_appsFailed'),
-
-  memory: function () {
-    return Em.I18n.t('dashboard.services.yarn.memory.msg').format(
-        numberUtils.bytesToSize(this.get('service.allocatedMemory'), 1, 'parseFloat', 1024
* 1024), 
-        numberUtils.bytesToSize(this.get('service.reservedMemory'), 1, 'parseFloat', 1024
* 1024), 
-        numberUtils.bytesToSize(this.get('service.availableMemory'), 1, 'parseFloat', 1024
* 1024));
-  }.property('service.allocatedMemory', 'service.reservedMemory', 'service.availableMemory'),
+
+  allocatedMemoryFormatted: function() {
+    return numberUtils.bytesToSize(this.get('service.allocatedMemory'), 1, 'parseFloat',
1024 * 1024);
+  }.property('service.allocatedMemory'),
+
+  reservedMemoryFormatted: function() {
+    return numberUtils.bytesToSize(this.get('service.reservedMemory'), 1, 'parseFloat', 1024
* 1024);
+  }.property('service.reservedMemory'),
+
+  availableMemoryFormatted: function() {
+    return numberUtils.bytesToSize(this.get('service.availableMemory'), 1, 'parseFloat',
1024 * 1024);
+  }.property('service.availableMemory'),
 
   _queuesCountFormatted: Em.computed.formatUnavailable('service.queuesCount'),
   queues: Em.computed.i18nFormat('dashboard.services.yarn.queues.msg', '_queuesCountFormatted'),

http://git-wip-us.apache.org/repos/asf/ambari/blob/0041ab25/ambari-web/test/views/main/service/services/yarn_test.js
----------------------------------------------------------------------
diff --git a/ambari-web/test/views/main/service/services/yarn_test.js b/ambari-web/test/views/main/service/services/yarn_test.js
index d422d47..01b3d92 100644
--- a/ambari-web/test/views/main/service/services/yarn_test.js
+++ b/ambari-web/test/views/main/service/services/yarn_test.js
@@ -94,28 +94,6 @@ describe('App.MainDashboardServiceYARNView', function () {
     });
   });
 
-  describe("#memory", function() {
-
-    beforeEach(function() {
-      sinon.stub(numberUtils, 'bytesToSize', function(arg1) {
-        return arg1;
-      })
-    });
-    afterEach(function() {
-      numberUtils.bytesToSize.restore();
-    });
-
-    it("should return formatted memory", function() {
-      view.set('service', Em.Object.create({
-        allocatedMemory: 1,
-        reservedMemory: 2,
-        availableMemory: 3
-      }));
-      view.propertyDidChange('memory');
-      expect(view.get('memory')).to.be.equal(Em.I18n.t('dashboard.services.yarn.memory.msg').format(1,2,3));
-    });
-  });
-
   describe("#didInsertElement()", function() {
 
     beforeEach(function() {


Mime
View raw message